@elastic/eui 107.0.0 → 108.0.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/es/components/badge/beta_badge/beta_badge.js +1 -0
- package/es/components/badge/beta_badge/beta_badge.styles.js +1 -3
- package/es/components/badge/notification_badge/badge_notification.styles.js +2 -4
- package/es/components/basic_table/basic_table.styles.js +6 -4
- package/es/components/button/button_display/_button_display.styles.js +1 -4
- package/es/components/button/button_display/_button_display_content.styles.js +1 -4
- package/es/components/button/button_empty/button_empty.styles.js +4 -7
- package/es/components/button/button_group/button_group.styles.js +2 -12
- package/es/components/button/button_group/button_group_button.js +2 -4
- package/es/components/button/button_group/button_group_button.styles.js +22 -36
- package/es/components/button/button_icon/button_icon.js +3 -6
- package/es/components/code/code_syntax.styles.js +1 -1
- package/es/components/collapsible_nav_beta/collapsible_nav_beta.styles.js +1 -1
- package/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.styles.js +1 -4
- package/es/components/combo_box/combo_box_input/combo_box_input.js +62 -65
- package/es/components/combo_box/combo_box_input/combo_box_input.styles.js +2 -4
- package/es/components/datagrid/controls/column_selector.styles.js +1 -1
- package/es/components/datagrid/controls/column_sorting.styles.js +1 -1
- package/es/components/datagrid/controls/data_grid_toolbar_control.js +2 -15
- package/es/components/datagrid/data_grid.styles.js +0 -1
- package/es/components/date_picker/date_picker.styles.js +1 -4
- package/es/components/date_picker/date_picker_range.styles.js +4 -8
- package/es/components/date_picker/super_date_picker/super_date_picker.styles.js +12 -26
- package/es/components/filter_group/filter_button.js +7 -10
- package/es/components/filter_group/filter_button.styles.js +28 -39
- package/es/components/filter_group/filter_group.styles.js +8 -29
- package/es/components/form/field_number/field_number.styles.js +1 -4
- package/es/components/form/field_text/field_text.styles.js +1 -4
- package/es/components/form/file_picker/file_picker.js +102 -107
- package/es/components/form/file_picker/file_picker.styles.js +5 -7
- package/es/components/form/form.styles.js +17 -40
- package/es/components/form/form_control_layout/form_control_layout.styles.js +9 -22
- package/es/components/form/form_control_layout/form_control_layout_clear_button.styles.js +1 -3
- package/es/components/form/form_control_layout/form_control_layout_delimited.js +6 -8
- package/es/components/form/form_control_layout/form_control_layout_delimited.styles.js +12 -25
- package/es/components/form/form_control_layout/form_control_layout_icons.js +25 -47
- package/es/components/form/form_error_text/form_error_text.styles.js +1 -3
- package/es/components/form/form_label/form_label.js +1 -1
- package/es/components/form/form_label/form_label.styles.js +1 -5
- package/es/components/form/range/range_input.styles.js +1 -3
- package/es/components/header/header.styles.js +4 -19
- package/es/components/header/header_section/header_section_item_button.styles.js +4 -6
- package/es/components/icon/icon.js +31 -14
- package/es/components/icon/icon_map.js +1 -1
- package/es/components/key_pad_menu/key_pad_menu_item.styles.js +5 -9
- package/es/components/markdown_editor/markdown_editor_drop_zone.styles.js +3 -5
- package/es/components/modal/modal.js +23 -5
- package/es/components/panel/panel.styles.js +4 -12
- package/es/components/resizable_container/resizable_collapse_button.js +2 -3
- package/es/components/selectable/selectable_templates/selectable_template_sitewide.js +4 -5
- package/es/components/table/table_row.styles.js +3 -3
- package/es/components/toast/toast.styles.js +1 -3
- package/es/components/token/token.js +1 -3
- package/es/components/token/token.styles.js +2 -3
- package/es/components/token/token_map.js +1 -231
- package/es/global_styling/mixins/_button.js +14 -24
- package/es/index.js +0 -1
- package/es/services/color/eui_palettes.js +7 -21
- package/es/services/color/eui_palettes_hooks.js +6 -10
- package/es/services/color/vis_color_store.js +2 -2
- package/es/services/theme/provider.js +4 -9
- package/eui.d.ts +20 -2103
- package/lib/components/badge/beta_badge/beta_badge.js +1 -0
- package/lib/components/badge/beta_badge/beta_badge.styles.js +1 -3
- package/lib/components/badge/notification_badge/badge_notification.styles.js +2 -4
- package/lib/components/basic_table/basic_table.styles.js +5 -3
- package/lib/components/button/button_display/_button_display.styles.js +1 -4
- package/lib/components/button/button_display/_button_display_content.styles.js +1 -4
- package/lib/components/button/button_empty/button_empty.styles.js +4 -7
- package/lib/components/button/button_group/button_group.styles.js +2 -12
- package/lib/components/button/button_group/button_group_button.js +1 -3
- package/lib/components/button/button_group/button_group_button.styles.js +21 -35
- package/lib/components/button/button_icon/button_icon.js +1 -4
- package/lib/components/code/code_syntax.styles.js +1 -1
- package/lib/components/collapsible_nav_beta/collapsible_nav_beta.styles.js +2 -2
- package/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.styles.js +1 -4
- package/lib/components/combo_box/combo_box_input/combo_box_input.js +61 -64
- package/lib/components/combo_box/combo_box_input/combo_box_input.styles.js +2 -4
- package/lib/components/datagrid/controls/column_selector.styles.js +2 -2
- package/lib/components/datagrid/controls/column_sorting.styles.js +2 -2
- package/lib/components/datagrid/controls/data_grid_toolbar_control.js +1 -14
- package/lib/components/datagrid/data_grid.styles.js +0 -1
- package/lib/components/date_picker/date_picker.styles.js +1 -4
- package/lib/components/date_picker/date_picker_range.styles.js +4 -8
- package/lib/components/date_picker/super_date_picker/super_date_picker.styles.js +10 -24
- package/lib/components/filter_group/filter_button.js +6 -9
- package/lib/components/filter_group/filter_button.styles.js +27 -38
- package/lib/components/filter_group/filter_group.styles.js +8 -29
- package/lib/components/form/field_number/field_number.styles.js +1 -4
- package/lib/components/form/field_text/field_text.styles.js +1 -4
- package/lib/components/form/file_picker/file_picker.js +101 -106
- package/lib/components/form/file_picker/file_picker.styles.js +5 -7
- package/lib/components/form/form.styles.js +16 -39
- package/lib/components/form/form_control_layout/form_control_layout.styles.js +8 -21
- package/lib/components/form/form_control_layout/form_control_layout_clear_button.styles.js +1 -3
- package/lib/components/form/form_control_layout/form_control_layout_delimited.js +5 -7
- package/lib/components/form/form_control_layout/form_control_layout_delimited.styles.js +12 -25
- package/lib/components/form/form_control_layout/form_control_layout_icons.js +24 -46
- package/lib/components/form/form_error_text/form_error_text.styles.js +1 -3
- package/lib/components/form/form_label/form_label.js +1 -1
- package/lib/components/form/form_label/form_label.styles.js +1 -5
- package/lib/components/form/range/range_input.styles.js +1 -3
- package/lib/components/header/header.styles.js +2 -18
- package/lib/components/header/header_section/header_section_item_button.styles.js +4 -6
- package/lib/components/icon/icon.js +31 -14
- package/lib/components/icon/icon_map.js +1 -1
- package/lib/components/key_pad_menu/key_pad_menu_item.styles.js +5 -9
- package/lib/components/markdown_editor/markdown_editor_drop_zone.styles.js +3 -5
- package/lib/components/modal/modal.js +25 -5
- package/lib/components/panel/panel.styles.js +4 -12
- package/lib/components/resizable_container/resizable_collapse_button.js +1 -2
- package/lib/components/selectable/selectable_templates/selectable_template_sitewide.js +3 -4
- package/lib/components/table/table_row.styles.js +3 -3
- package/lib/components/toast/toast.styles.js +1 -3
- package/lib/components/token/token.js +1 -3
- package/lib/components/token/token.styles.js +1 -2
- package/lib/components/token/token_map.js +2 -232
- package/lib/global_styling/mixins/_button.js +11 -21
- package/lib/index.js +0 -11
- package/lib/services/color/eui_palettes.js +7 -21
- package/lib/services/color/eui_palettes_hooks.js +6 -10
- package/lib/services/color/vis_color_store.js +2 -2
- package/lib/services/theme/provider.js +4 -9
- package/optimize/es/components/badge/beta_badge/beta_badge.js +1 -0
- package/optimize/es/components/badge/beta_badge/beta_badge.styles.js +1 -3
- package/optimize/es/components/badge/notification_badge/badge_notification.styles.js +2 -4
- package/optimize/es/components/basic_table/basic_table.styles.js +6 -4
- package/optimize/es/components/button/button_display/_button_display.styles.js +1 -4
- package/optimize/es/components/button/button_display/_button_display_content.styles.js +1 -4
- package/optimize/es/components/button/button_empty/button_empty.styles.js +4 -7
- package/optimize/es/components/button/button_group/button_group.styles.js +2 -12
- package/optimize/es/components/button/button_group/button_group_button.js +2 -4
- package/optimize/es/components/button/button_group/button_group_button.styles.js +22 -36
- package/optimize/es/components/button/button_icon/button_icon.js +3 -6
- package/optimize/es/components/code/code_syntax.styles.js +1 -1
- package/optimize/es/components/collapsible_nav_beta/collapsible_nav_beta.styles.js +1 -1
- package/optimize/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.styles.js +1 -4
- package/optimize/es/components/combo_box/combo_box_input/combo_box_input.js +62 -65
- package/optimize/es/components/combo_box/combo_box_input/combo_box_input.styles.js +2 -4
- package/optimize/es/components/datagrid/controls/column_selector.styles.js +1 -1
- package/optimize/es/components/datagrid/controls/column_sorting.styles.js +1 -1
- package/optimize/es/components/datagrid/controls/data_grid_toolbar_control.js +2 -15
- package/optimize/es/components/datagrid/data_grid.styles.js +0 -1
- package/optimize/es/components/date_picker/date_picker.styles.js +1 -4
- package/optimize/es/components/date_picker/date_picker_range.styles.js +4 -8
- package/optimize/es/components/date_picker/super_date_picker/super_date_picker.styles.js +12 -26
- package/optimize/es/components/filter_group/filter_button.js +7 -10
- package/optimize/es/components/filter_group/filter_button.styles.js +28 -39
- package/optimize/es/components/filter_group/filter_group.styles.js +8 -29
- package/optimize/es/components/form/field_number/field_number.styles.js +1 -4
- package/optimize/es/components/form/field_text/field_text.styles.js +1 -4
- package/optimize/es/components/form/file_picker/file_picker.js +102 -107
- package/optimize/es/components/form/file_picker/file_picker.styles.js +5 -7
- package/optimize/es/components/form/form.styles.js +17 -40
- package/optimize/es/components/form/form_control_layout/form_control_layout.styles.js +9 -22
- package/optimize/es/components/form/form_control_layout/form_control_layout_clear_button.styles.js +1 -3
- package/optimize/es/components/form/form_control_layout/form_control_layout_delimited.js +6 -8
- package/optimize/es/components/form/form_control_layout/form_control_layout_delimited.styles.js +12 -25
- package/optimize/es/components/form/form_control_layout/form_control_layout_icons.js +25 -47
- package/optimize/es/components/form/form_error_text/form_error_text.styles.js +1 -3
- package/optimize/es/components/form/form_label/form_label.js +1 -1
- package/optimize/es/components/form/form_label/form_label.styles.js +1 -5
- package/optimize/es/components/form/range/range_input.styles.js +1 -3
- package/optimize/es/components/header/header.styles.js +4 -19
- package/optimize/es/components/header/header_section/header_section_item_button.styles.js +4 -6
- package/optimize/es/components/icon/icon.js +31 -14
- package/optimize/es/components/icon/icon_map.js +1 -1
- package/optimize/es/components/key_pad_menu/key_pad_menu_item.styles.js +5 -9
- package/optimize/es/components/markdown_editor/markdown_editor_drop_zone.styles.js +3 -5
- package/optimize/es/components/modal/modal.js +17 -4
- package/optimize/es/components/panel/panel.styles.js +4 -12
- package/optimize/es/components/resizable_container/resizable_collapse_button.js +2 -3
- package/optimize/es/components/selectable/selectable_templates/selectable_template_sitewide.js +4 -5
- package/optimize/es/components/table/table_row.styles.js +3 -3
- package/optimize/es/components/toast/toast.styles.js +1 -3
- package/optimize/es/components/token/token.js +1 -3
- package/optimize/es/components/token/token.styles.js +2 -3
- package/optimize/es/components/token/token_map.js +1 -231
- package/optimize/es/global_styling/mixins/_button.js +14 -24
- package/optimize/es/index.js +0 -1
- package/optimize/es/services/color/eui_palettes.js +7 -21
- package/optimize/es/services/color/eui_palettes_hooks.js +6 -10
- package/optimize/es/services/color/vis_color_store.js +2 -2
- package/optimize/es/services/theme/provider.js +4 -9
- package/optimize/lib/components/badge/beta_badge/beta_badge.js +1 -0
- package/optimize/lib/components/badge/beta_badge/beta_badge.styles.js +1 -3
- package/optimize/lib/components/badge/notification_badge/badge_notification.styles.js +2 -4
- package/optimize/lib/components/basic_table/basic_table.styles.js +5 -3
- package/optimize/lib/components/button/button_display/_button_display.styles.js +1 -4
- package/optimize/lib/components/button/button_display/_button_display_content.styles.js +1 -4
- package/optimize/lib/components/button/button_empty/button_empty.styles.js +4 -7
- package/optimize/lib/components/button/button_group/button_group.styles.js +2 -12
- package/optimize/lib/components/button/button_group/button_group_button.js +1 -3
- package/optimize/lib/components/button/button_group/button_group_button.styles.js +21 -35
- package/optimize/lib/components/button/button_icon/button_icon.js +1 -4
- package/optimize/lib/components/code/code_syntax.styles.js +1 -1
- package/optimize/lib/components/collapsible_nav_beta/collapsible_nav_beta.styles.js +2 -2
- package/optimize/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.styles.js +1 -4
- package/optimize/lib/components/combo_box/combo_box_input/combo_box_input.js +61 -64
- package/optimize/lib/components/combo_box/combo_box_input/combo_box_input.styles.js +2 -4
- package/optimize/lib/components/datagrid/controls/column_selector.styles.js +2 -2
- package/optimize/lib/components/datagrid/controls/column_sorting.styles.js +2 -2
- package/optimize/lib/components/datagrid/controls/data_grid_toolbar_control.js +1 -14
- package/optimize/lib/components/datagrid/data_grid.styles.js +0 -1
- package/optimize/lib/components/date_picker/date_picker.styles.js +1 -4
- package/optimize/lib/components/date_picker/date_picker_range.styles.js +4 -8
- package/optimize/lib/components/date_picker/super_date_picker/super_date_picker.styles.js +10 -24
- package/optimize/lib/components/filter_group/filter_button.js +6 -9
- package/optimize/lib/components/filter_group/filter_button.styles.js +27 -38
- package/optimize/lib/components/filter_group/filter_group.styles.js +8 -29
- package/optimize/lib/components/form/field_number/field_number.styles.js +1 -4
- package/optimize/lib/components/form/field_text/field_text.styles.js +1 -4
- package/optimize/lib/components/form/file_picker/file_picker.js +101 -106
- package/optimize/lib/components/form/file_picker/file_picker.styles.js +5 -7
- package/optimize/lib/components/form/form.styles.js +16 -39
- package/optimize/lib/components/form/form_control_layout/form_control_layout.styles.js +8 -21
- package/optimize/lib/components/form/form_control_layout/form_control_layout_clear_button.styles.js +1 -3
- package/optimize/lib/components/form/form_control_layout/form_control_layout_delimited.js +5 -7
- package/optimize/lib/components/form/form_control_layout/form_control_layout_delimited.styles.js +12 -25
- package/optimize/lib/components/form/form_control_layout/form_control_layout_icons.js +24 -46
- package/optimize/lib/components/form/form_error_text/form_error_text.styles.js +1 -3
- package/optimize/lib/components/form/form_label/form_label.js +1 -1
- package/optimize/lib/components/form/form_label/form_label.styles.js +1 -5
- package/optimize/lib/components/form/range/range_input.styles.js +1 -3
- package/optimize/lib/components/header/header.styles.js +2 -18
- package/optimize/lib/components/header/header_section/header_section_item_button.styles.js +4 -6
- package/optimize/lib/components/icon/icon.js +31 -14
- package/optimize/lib/components/icon/icon_map.js +1 -1
- package/optimize/lib/components/key_pad_menu/key_pad_menu_item.styles.js +5 -9
- package/optimize/lib/components/markdown_editor/markdown_editor_drop_zone.styles.js +3 -5
- package/optimize/lib/components/modal/modal.js +20 -4
- package/optimize/lib/components/panel/panel.styles.js +4 -12
- package/optimize/lib/components/resizable_container/resizable_collapse_button.js +1 -2
- package/optimize/lib/components/selectable/selectable_templates/selectable_template_sitewide.js +3 -4
- package/optimize/lib/components/table/table_row.styles.js +3 -3
- package/optimize/lib/components/toast/toast.styles.js +1 -3
- package/optimize/lib/components/token/token.js +1 -3
- package/optimize/lib/components/token/token.styles.js +1 -2
- package/optimize/lib/components/token/token_map.js +2 -232
- package/optimize/lib/global_styling/mixins/_button.js +11 -21
- package/optimize/lib/index.js +0 -11
- package/optimize/lib/services/color/eui_palettes.js +7 -21
- package/optimize/lib/services/color/eui_palettes_hooks.js +6 -10
- package/optimize/lib/services/color/vis_color_store.js +2 -2
- package/optimize/lib/services/theme/provider.js +4 -9
- package/package.json +6 -7
- package/test-env/components/badge/beta_badge/beta_badge.js +1 -0
- package/test-env/components/badge/beta_badge/beta_badge.styles.js +1 -3
- package/test-env/components/badge/notification_badge/badge_notification.styles.js +2 -4
- package/test-env/components/basic_table/basic_table.styles.js +5 -3
- package/test-env/components/button/button_display/_button_display.styles.js +1 -4
- package/test-env/components/button/button_display/_button_display_content.styles.js +1 -4
- package/test-env/components/button/button_empty/button_empty.styles.js +4 -7
- package/test-env/components/button/button_group/button_group.styles.js +2 -12
- package/test-env/components/button/button_group/button_group_button.js +1 -3
- package/test-env/components/button/button_group/button_group_button.styles.js +21 -35
- package/test-env/components/button/button_icon/button_icon.js +1 -4
- package/test-env/components/code/code_syntax.styles.js +1 -1
- package/test-env/components/collapsible_nav_beta/collapsible_nav_beta.styles.js +2 -2
- package/test-env/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.styles.js +1 -4
- package/test-env/components/combo_box/combo_box_input/combo_box_input.js +61 -64
- package/test-env/components/combo_box/combo_box_input/combo_box_input.styles.js +2 -4
- package/test-env/components/datagrid/controls/column_selector.styles.js +2 -2
- package/test-env/components/datagrid/controls/column_sorting.styles.js +2 -2
- package/test-env/components/datagrid/controls/data_grid_toolbar_control.js +1 -14
- package/test-env/components/datagrid/data_grid.styles.js +0 -1
- package/test-env/components/date_picker/date_picker.styles.js +1 -4
- package/test-env/components/date_picker/date_picker_range.styles.js +4 -8
- package/test-env/components/date_picker/super_date_picker/super_date_picker.styles.js +10 -24
- package/test-env/components/filter_group/filter_button.js +6 -9
- package/test-env/components/filter_group/filter_button.styles.js +27 -38
- package/test-env/components/filter_group/filter_group.styles.js +8 -29
- package/test-env/components/form/field_number/field_number.styles.js +1 -4
- package/test-env/components/form/field_text/field_text.styles.js +1 -4
- package/test-env/components/form/file_picker/file_picker.js +101 -106
- package/test-env/components/form/file_picker/file_picker.styles.js +5 -7
- package/test-env/components/form/form.styles.js +16 -39
- package/test-env/components/form/form_control_layout/form_control_layout.styles.js +8 -21
- package/test-env/components/form/form_control_layout/form_control_layout_clear_button.styles.js +1 -3
- package/test-env/components/form/form_control_layout/form_control_layout_delimited.js +5 -7
- package/test-env/components/form/form_control_layout/form_control_layout_delimited.styles.js +12 -25
- package/test-env/components/form/form_control_layout/form_control_layout_icons.js +24 -46
- package/test-env/components/form/form_error_text/form_error_text.styles.js +1 -3
- package/test-env/components/form/form_label/form_label.js +1 -1
- package/test-env/components/form/form_label/form_label.styles.js +1 -5
- package/test-env/components/form/range/range_input.styles.js +1 -3
- package/test-env/components/header/header.styles.js +2 -18
- package/test-env/components/header/header_section/header_section_item_button.styles.js +4 -6
- package/test-env/components/icon/icon_map.js +1 -1
- package/test-env/components/key_pad_menu/key_pad_menu_item.styles.js +5 -9
- package/test-env/components/markdown_editor/markdown_editor_drop_zone.styles.js +3 -5
- package/test-env/components/modal/modal.js +26 -5
- package/test-env/components/panel/panel.styles.js +4 -12
- package/test-env/components/resizable_container/resizable_collapse_button.js +1 -2
- package/test-env/components/selectable/selectable_templates/selectable_template_sitewide.js +3 -4
- package/test-env/components/table/table_row.styles.js +3 -3
- package/test-env/components/toast/toast.styles.js +1 -3
- package/test-env/components/token/token.js +1 -3
- package/test-env/components/token/token.styles.js +1 -2
- package/test-env/components/token/token_map.js +2 -232
- package/test-env/global_styling/mixins/_button.js +11 -21
- package/test-env/index.js +0 -11
- package/test-env/services/breakpoint/current_breakpoint_hook.js +1 -1
- package/test-env/services/color/eui_palettes.js +7 -21
- package/test-env/services/color/eui_palettes_hooks.js +6 -10
- package/test-env/services/color/vis_color_store.js +2 -2
- package/test-env/services/theme/provider.js +4 -9
- package/dist/eui_theme_amsterdam_dark.json +0 -463
- package/dist/eui_theme_amsterdam_dark.json.d.ts +0 -466
- package/dist/eui_theme_amsterdam_light.json +0 -463
- package/dist/eui_theme_amsterdam_light.json.d.ts +0 -466
- package/dist/eui_theme_borealis_dark.json +0 -463
- package/dist/eui_theme_borealis_dark.json.d.ts +0 -466
- package/dist/eui_theme_borealis_light.json +0 -463
- package/dist/eui_theme_borealis_light.json.d.ts +0 -466
- package/es/themes/amsterdam/global_styling/functions/index.js +0 -9
- package/es/themes/amsterdam/global_styling/functions/shadows.js +0 -9
- package/es/themes/amsterdam/global_styling/mixins/button.js +0 -9
- package/es/themes/amsterdam/global_styling/mixins/index.js +0 -10
- package/es/themes/amsterdam/global_styling/mixins/shadow.js +0 -9
- package/es/themes/amsterdam/global_styling/variables/_animation.js +0 -26
- package/es/themes/amsterdam/global_styling/variables/_borders.js +0 -49
- package/es/themes/amsterdam/global_styling/variables/_breakpoint.js +0 -9
- package/es/themes/amsterdam/global_styling/variables/_buttons.js +0 -529
- package/es/themes/amsterdam/global_styling/variables/_colors.js +0 -797
- package/es/themes/amsterdam/global_styling/variables/_colors_severity.js +0 -21
- package/es/themes/amsterdam/global_styling/variables/_colors_vis_dark.js +0 -33
- package/es/themes/amsterdam/global_styling/variables/_colors_vis_light.js +0 -125
- package/es/themes/amsterdam/global_styling/variables/_components.js +0 -724
- package/es/themes/amsterdam/global_styling/variables/_forms.js +0 -204
- package/es/themes/amsterdam/global_styling/variables/_levels.js +0 -19
- package/es/themes/amsterdam/global_styling/variables/_shadows.js +0 -439
- package/es/themes/amsterdam/global_styling/variables/_size.js +0 -23
- package/es/themes/amsterdam/global_styling/variables/_states.js +0 -26
- package/es/themes/amsterdam/global_styling/variables/_typography.js +0 -66
- package/es/themes/amsterdam/index.js +0 -10
- package/es/themes/amsterdam/theme.js +0 -41
- package/es/themes/index.js +0 -12
- package/es/themes/json/eui_theme_amsterdam_dark.json +0 -463
- package/es/themes/json/eui_theme_amsterdam_light.json +0 -463
- package/es/themes/json/eui_theme_borealis_dark.json +0 -463
- package/es/themes/json/eui_theme_borealis_light.json +0 -463
- package/es/themes/themes.js +0 -1
- package/lib/themes/amsterdam/global_styling/functions/index.js +0 -16
- package/lib/themes/amsterdam/global_styling/functions/shadows.js +0 -12
- package/lib/themes/amsterdam/global_styling/mixins/button.js +0 -54
- package/lib/themes/amsterdam/global_styling/mixins/index.js +0 -27
- package/lib/themes/amsterdam/global_styling/mixins/shadow.js +0 -16
- package/lib/themes/amsterdam/global_styling/variables/_animation.js +0 -32
- package/lib/themes/amsterdam/global_styling/variables/_borders.js +0 -53
- package/lib/themes/amsterdam/global_styling/variables/_breakpoint.js +0 -12
- package/lib/themes/amsterdam/global_styling/variables/_buttons.js +0 -533
- package/lib/themes/amsterdam/global_styling/variables/_colors.js +0 -800
- package/lib/themes/amsterdam/global_styling/variables/_colors_severity.js +0 -27
- package/lib/themes/amsterdam/global_styling/variables/_colors_vis_dark.js +0 -37
- package/lib/themes/amsterdam/global_styling/variables/_colors_vis_light.js +0 -130
- package/lib/themes/amsterdam/global_styling/variables/_components.js +0 -728
- package/lib/themes/amsterdam/global_styling/variables/_forms.js +0 -208
- package/lib/themes/amsterdam/global_styling/variables/_levels.js +0 -25
- package/lib/themes/amsterdam/global_styling/variables/_shadows.js +0 -442
- package/lib/themes/amsterdam/global_styling/variables/_size.js +0 -29
- package/lib/themes/amsterdam/global_styling/variables/_states.js +0 -32
- package/lib/themes/amsterdam/global_styling/variables/_typography.js +0 -70
- package/lib/themes/amsterdam/index.js +0 -16
- package/lib/themes/amsterdam/theme.js +0 -47
- package/lib/themes/index.js +0 -57
- package/lib/themes/json/eui_theme_amsterdam_dark.json +0 -463
- package/lib/themes/json/eui_theme_amsterdam_light.json +0 -463
- package/lib/themes/json/eui_theme_borealis_dark.json +0 -463
- package/lib/themes/json/eui_theme_borealis_light.json +0 -463
- package/lib/themes/themes.js +0 -5
- package/optimize/es/themes/amsterdam/global_styling/functions/index.js +0 -9
- package/optimize/es/themes/amsterdam/global_styling/functions/shadows.js +0 -9
- package/optimize/es/themes/amsterdam/global_styling/mixins/button.js +0 -9
- package/optimize/es/themes/amsterdam/global_styling/mixins/index.js +0 -10
- package/optimize/es/themes/amsterdam/global_styling/mixins/shadow.js +0 -9
- package/optimize/es/themes/amsterdam/global_styling/variables/_animation.js +0 -23
- package/optimize/es/themes/amsterdam/global_styling/variables/_borders.js +0 -44
- package/optimize/es/themes/amsterdam/global_styling/variables/_breakpoint.js +0 -9
- package/optimize/es/themes/amsterdam/global_styling/variables/_buttons.js +0 -518
- package/optimize/es/themes/amsterdam/global_styling/variables/_colors.js +0 -789
- package/optimize/es/themes/amsterdam/global_styling/variables/_colors_severity.js +0 -21
- package/optimize/es/themes/amsterdam/global_styling/variables/_colors_vis_dark.js +0 -30
- package/optimize/es/themes/amsterdam/global_styling/variables/_colors_vis_light.js +0 -125
- package/optimize/es/themes/amsterdam/global_styling/variables/_components.js +0 -716
- package/optimize/es/themes/amsterdam/global_styling/variables/_forms.js +0 -196
- package/optimize/es/themes/amsterdam/global_styling/variables/_levels.js +0 -19
- package/optimize/es/themes/amsterdam/global_styling/variables/_shadows.js +0 -436
- package/optimize/es/themes/amsterdam/global_styling/variables/_size.js +0 -23
- package/optimize/es/themes/amsterdam/global_styling/variables/_states.js +0 -26
- package/optimize/es/themes/amsterdam/global_styling/variables/_typography.js +0 -58
- package/optimize/es/themes/amsterdam/index.js +0 -10
- package/optimize/es/themes/amsterdam/theme.js +0 -41
- package/optimize/es/themes/index.js +0 -12
- package/optimize/es/themes/json/eui_theme_amsterdam_dark.json +0 -463
- package/optimize/es/themes/json/eui_theme_amsterdam_light.json +0 -463
- package/optimize/es/themes/json/eui_theme_borealis_dark.json +0 -463
- package/optimize/es/themes/json/eui_theme_borealis_light.json +0 -463
- package/optimize/es/themes/themes.js +0 -1
- package/optimize/lib/themes/amsterdam/global_styling/functions/index.js +0 -16
- package/optimize/lib/themes/amsterdam/global_styling/functions/shadows.js +0 -12
- package/optimize/lib/themes/amsterdam/global_styling/mixins/button.js +0 -54
- package/optimize/lib/themes/amsterdam/global_styling/mixins/index.js +0 -27
- package/optimize/lib/themes/amsterdam/global_styling/mixins/shadow.js +0 -16
- package/optimize/lib/themes/amsterdam/global_styling/variables/_animation.js +0 -30
- package/optimize/lib/themes/amsterdam/global_styling/variables/_borders.js +0 -51
- package/optimize/lib/themes/amsterdam/global_styling/variables/_breakpoint.js +0 -12
- package/optimize/lib/themes/amsterdam/global_styling/variables/_buttons.js +0 -523
- package/optimize/lib/themes/amsterdam/global_styling/variables/_colors.js +0 -793
- package/optimize/lib/themes/amsterdam/global_styling/variables/_colors_severity.js +0 -27
- package/optimize/lib/themes/amsterdam/global_styling/variables/_colors_vis_dark.js +0 -35
- package/optimize/lib/themes/amsterdam/global_styling/variables/_colors_vis_light.js +0 -130
- package/optimize/lib/themes/amsterdam/global_styling/variables/_components.js +0 -721
- package/optimize/lib/themes/amsterdam/global_styling/variables/_forms.js +0 -201
- package/optimize/lib/themes/amsterdam/global_styling/variables/_levels.js +0 -25
- package/optimize/lib/themes/amsterdam/global_styling/variables/_shadows.js +0 -440
- package/optimize/lib/themes/amsterdam/global_styling/variables/_size.js +0 -29
- package/optimize/lib/themes/amsterdam/global_styling/variables/_states.js +0 -32
- package/optimize/lib/themes/amsterdam/global_styling/variables/_typography.js +0 -63
- package/optimize/lib/themes/amsterdam/index.js +0 -16
- package/optimize/lib/themes/amsterdam/theme.js +0 -47
- package/optimize/lib/themes/index.js +0 -57
- package/optimize/lib/themes/json/eui_theme_amsterdam_dark.json +0 -463
- package/optimize/lib/themes/json/eui_theme_amsterdam_light.json +0 -463
- package/optimize/lib/themes/json/eui_theme_borealis_dark.json +0 -463
- package/optimize/lib/themes/json/eui_theme_borealis_light.json +0 -463
- package/optimize/lib/themes/themes.js +0 -5
- package/src/global_styling/functions/_colors.scss +0 -138
- package/src/global_styling/functions/_index.scss +0 -1
- package/src/global_styling/functions/_math.scss +0 -1
- package/src/global_styling/functions/_math_pow.scss +0 -82
- package/src/global_styling/index.scss +0 -3
- package/src/global_styling/mixins/_helpers.scss +0 -117
- package/src/global_styling/mixins/_index.scss +0 -8
- package/src/global_styling/mixins/_responsive.scss +0 -44
- package/src/global_styling/mixins/_shadow.scss +0 -100
- package/src/global_styling/mixins/_size.scss +0 -4
- package/src/global_styling/mixins/_states.scss +0 -17
- package/src/global_styling/mixins/_tool_tip.scss +0 -18
- package/src/global_styling/mixins/_typography.scss +0 -166
- package/src/global_styling/variables/_animations.scss +0 -6
- package/src/global_styling/variables/_borders.scss +0 -3
- package/src/global_styling/variables/_buttons.scss +0 -1
- package/src/global_styling/variables/_font_weight.scss +0 -4
- package/src/global_styling/variables/_form.scss +0 -2
- package/src/global_styling/variables/_index.scss +0 -22
- package/src/global_styling/variables/_responsive.scss +0 -1
- package/src/global_styling/variables/_shadows.scss +0 -2
- package/src/global_styling/variables/_size.scss +0 -1
- package/src/global_styling/variables/_states.scss +0 -1
- package/src/global_styling/variables/_typography.scss +0 -1
- package/src/global_styling/variables/_z_index.scss +0 -2
- package/src/themes/amsterdam/_colors_dark.scss +0 -139
- package/src/themes/amsterdam/_colors_light.scss +0 -139
- package/src/themes/amsterdam/_globals.scss +0 -11
- package/src/themes/amsterdam/global_styling/index.scss +0 -12
- package/src/themes/amsterdam/global_styling/mixins/_index.scss +0 -10
- package/src/themes/amsterdam/global_styling/mixins/_shadow.scss +0 -100
- package/src/themes/amsterdam/global_styling/mixins/_states.scss +0 -41
- package/src/themes/amsterdam/global_styling/mixins/_typography.scss +0 -81
- package/src/themes/amsterdam/global_styling/variables/_colors_severity.scss +0 -9
- package/src/themes/amsterdam/global_styling/variables/_colors_vis.scss +0 -72
- package/src/themes/amsterdam/global_styling/variables/_colors_vis_dark.scss +0 -14
- package/src/themes/amsterdam/global_styling/variables/_colors_vis_light.scss +0 -14
- package/src/themes/amsterdam/global_styling/variables/_forms.scss +0 -12
- package/src/themes/amsterdam/global_styling/variables/_index.scss +0 -8
- package/src/themes/amsterdam/global_styling/variables/_shadows.scss +0 -20
- package/src/themes/amsterdam/global_styling/variables/_states.scss +0 -11
- package/src/themes/amsterdam/global_styling/variables/_typography.scss +0 -64
- package/src/themes/amsterdam/theme_dark.scss +0 -5
- package/src/themes/amsterdam/theme_light.scss +0 -5
- package/test-env/themes/amsterdam/global_styling/functions/index.js +0 -16
- package/test-env/themes/amsterdam/global_styling/functions/shadows.js +0 -12
- package/test-env/themes/amsterdam/global_styling/mixins/button.js +0 -54
- package/test-env/themes/amsterdam/global_styling/mixins/index.js +0 -27
- package/test-env/themes/amsterdam/global_styling/mixins/shadow.js +0 -16
- package/test-env/themes/amsterdam/global_styling/variables/_animation.js +0 -30
- package/test-env/themes/amsterdam/global_styling/variables/_borders.js +0 -51
- package/test-env/themes/amsterdam/global_styling/variables/_breakpoint.js +0 -12
- package/test-env/themes/amsterdam/global_styling/variables/_buttons.js +0 -523
- package/test-env/themes/amsterdam/global_styling/variables/_colors.js +0 -793
- package/test-env/themes/amsterdam/global_styling/variables/_colors_severity.js +0 -27
- package/test-env/themes/amsterdam/global_styling/variables/_colors_vis_dark.js +0 -35
- package/test-env/themes/amsterdam/global_styling/variables/_colors_vis_light.js +0 -130
- package/test-env/themes/amsterdam/global_styling/variables/_components.js +0 -721
- package/test-env/themes/amsterdam/global_styling/variables/_forms.js +0 -201
- package/test-env/themes/amsterdam/global_styling/variables/_levels.js +0 -25
- package/test-env/themes/amsterdam/global_styling/variables/_shadows.js +0 -440
- package/test-env/themes/amsterdam/global_styling/variables/_size.js +0 -29
- package/test-env/themes/amsterdam/global_styling/variables/_states.js +0 -32
- package/test-env/themes/amsterdam/global_styling/variables/_typography.js +0 -63
- package/test-env/themes/amsterdam/index.js +0 -16
- package/test-env/themes/amsterdam/theme.js +0 -47
- package/test-env/themes/index.js +0 -57
- package/test-env/themes/json/eui_theme_amsterdam_dark.json +0 -463
- package/test-env/themes/json/eui_theme_amsterdam_light.json +0 -463
- package/test-env/themes/json/eui_theme_borealis_dark.json +0 -463
- package/test-env/themes/json/eui_theme_borealis_light.json +0 -463
- package/test-env/themes/themes.js +0 -5
|
@@ -19,7 +19,7 @@ function _objectWithoutPropertiesLoose(r, e) { if (null == r) return {}; var t =
|
|
|
19
19
|
import React from 'react';
|
|
20
20
|
import PropTypes from "prop-types";
|
|
21
21
|
import classNames from 'classnames';
|
|
22
|
-
import { useEuiMemoizedStyles, cloneElementWithCss, useEuiTheme
|
|
22
|
+
import { useEuiMemoizedStyles, cloneElementWithCss, useEuiTheme } from '../../../services';
|
|
23
23
|
import { useEuiI18n } from '../../i18n';
|
|
24
24
|
import { EuiIcon } from '../../icon';
|
|
25
25
|
import { EuiText } from '../../text';
|
|
@@ -35,8 +35,6 @@ export var EuiFormControlLayoutDelimited = function EuiFormControlLayoutDelimite
|
|
|
35
35
|
className = _ref.className,
|
|
36
36
|
_fullWidth = _ref.fullWidth,
|
|
37
37
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
38
|
-
var euiThemeContext = useEuiTheme();
|
|
39
|
-
var isRefreshVariant = useEuiThemeRefreshVariant('formVariant');
|
|
40
38
|
var _useFormContext = useFormContext(),
|
|
41
39
|
defaultFullWidth = _useFormContext.defaultFullWidth;
|
|
42
40
|
var fullWidth = _fullWidth !== null && _fullWidth !== void 0 ? _fullWidth : defaultFullWidth;
|
|
@@ -49,7 +47,7 @@ export var EuiFormControlLayoutDelimited = function EuiFormControlLayoutDelimite
|
|
|
49
47
|
});
|
|
50
48
|
var styles = useEuiMemoizedStyles(euiFormControlLayoutDelimitedStyles);
|
|
51
49
|
var cssStyles = [styles.delimited, rest.isDisabled && styles.disabled, rest.readOnly && styles.readOnly];
|
|
52
|
-
var wrapperStyles = [styles.childrenWrapper.delimited, showInvalidState && styles.childrenWrapper.invalid, (_rest$wrapperProps = rest.wrapperProps) === null || _rest$wrapperProps === void 0 ? void 0 : _rest$wrapperProps.css,
|
|
50
|
+
var wrapperStyles = [styles.childrenWrapper.delimited, showInvalidState && styles.childrenWrapper.invalid, (_rest$wrapperProps = rest.wrapperProps) === null || _rest$wrapperProps === void 0 ? void 0 : _rest$wrapperProps.css, rest.readOnly && styles.childrenWrapper.readOnly];
|
|
53
51
|
return ___EmotionJSX(EuiFormControlLayout, _extends({
|
|
54
52
|
isDelimited: true,
|
|
55
53
|
css: cssStyles,
|
|
@@ -64,10 +62,10 @@ export var EuiFormControlLayoutDelimited = function EuiFormControlLayoutDelimite
|
|
|
64
62
|
value: {
|
|
65
63
|
defaultFullWidth: fullWidth
|
|
66
64
|
}
|
|
67
|
-
}, startControl && addClassesToControl(
|
|
65
|
+
}, startControl && addClassesToControl(startControl), ___EmotionJSX(EuiFormControlDelimiter, {
|
|
68
66
|
delimiter: delimiter,
|
|
69
67
|
isInvalid: showInvalidState
|
|
70
|
-
}), endControl && addClassesToControl(
|
|
68
|
+
}), endControl && addClassesToControl(endControl)));
|
|
71
69
|
};
|
|
72
70
|
EuiFormControlLayoutDelimited.propTypes = {
|
|
73
71
|
/**
|
|
@@ -85,9 +83,9 @@ EuiFormControlLayoutDelimited.propTypes = {
|
|
|
85
83
|
delimiter: PropTypes.node,
|
|
86
84
|
className: PropTypes.string
|
|
87
85
|
};
|
|
88
|
-
var addClassesToControl = function addClassesToControl(
|
|
86
|
+
var addClassesToControl = function addClassesToControl(control) {
|
|
89
87
|
return cloneElementWithCss(control, {
|
|
90
|
-
css: euiFormControlLayoutDelimited__input
|
|
88
|
+
css: euiFormControlLayoutDelimited__input,
|
|
91
89
|
className: classNames(control.props.className, 'euiFormControlLayoutDelimited__input')
|
|
92
90
|
}, 'before');
|
|
93
91
|
};
|
|
@@ -7,51 +7,38 @@
|
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
9
|
import { css } from '@emotion/react';
|
|
10
|
-
import { isEuiThemeRefreshVariant } from '../../../services';
|
|
11
10
|
import { logicalCSS, mathWithUnits } from '../../../global_styling';
|
|
12
11
|
import { euiFormControlDisabledStyles, euiFormControlReadOnlyStyles, euiFormControlDefaultShadow, euiFormControlInvalidStyles, euiFormControlHoverStyles, euiFormVariables } from '../form.styles';
|
|
13
12
|
export var euiFormControlLayoutDelimitedStyles = function euiFormControlLayoutDelimitedStyles(euiThemeContext) {
|
|
14
13
|
var highContrastMode = euiThemeContext.highContrastMode;
|
|
15
|
-
var isRefreshVariant = isEuiThemeRefreshVariant(euiThemeContext, 'formVariant');
|
|
16
14
|
var form = euiFormVariables(euiThemeContext);
|
|
17
|
-
var invalidStyles = isRefreshVariant ? "\n :not(.euiFormControlLayoutDelimited__input, .euiFormControlLayoutDelimited__delimiter) {\n ".concat(euiFormControlInvalidStyles(euiThemeContext), "\n }\n\n &:focus-within {\n --euiFormControlStateColor: ").concat(form.borderColor, ";\n --euiFormControlStateHoverColor: ").concat(form.borderHovered, ";\n }\n\n .euiFormControlLayoutDelimited__input {\n background-color: transparent;\n }\n ") : "\n ".concat(euiFormControlInvalidStyles(euiThemeContext), ";\n ");
|
|
18
|
-
var readOnlyStyles = "\n & .euiFormControlLayoutDelimited__input {\n outline: none; \n box-shadow: none;\n --euiFormControlStateColor: transparent;\n }\n ";
|
|
19
15
|
var delimitedStyles = "\n /* Transition smoothly between disabled/readOnly background color changes */\n ".concat(euiFormControlDefaultShadow(euiThemeContext, {
|
|
20
|
-
withBorder:
|
|
21
|
-
withBackground: false
|
|
22
|
-
withBackgroundAnimation: isRefreshVariant ? false : true
|
|
16
|
+
withBorder: !highContrastMode ? true : false,
|
|
17
|
+
withBackground: false
|
|
23
18
|
}), "\n ").trim();
|
|
24
|
-
var delimitedWrapperStyles = "\n ".concat(euiFormControlDefaultShadow(euiThemeContext, {
|
|
25
|
-
withBorder: !highContrastMode,
|
|
26
|
-
withBackground: false,
|
|
27
|
-
withBackgroundAnimation: true
|
|
28
|
-
}), "\n \n &:hover {\n ").concat(euiFormControlHoverStyles(euiThemeContext), "\n box-shadow: none;\n\n /* using hover styling on wrapper instead of the children inputs */\n .euiFormControlLayoutDelimited__input:not(:focus) {\n outline: none;\n background-color: transparent;\n }\n }\n\n /* adjust for delimited behavior differing from default form layout */\n > :first-child {\n ").concat(logicalCSS('border-top-left-radius', 'inherit'), "\n ").concat(logicalCSS('border-bottom-left-radius', 'inherit'), "\n }\n\n > :last-child {\n ").concat(logicalCSS('border-top-right-radius', 'inherit'), "\n ").concat(logicalCSS('border-bottom-right-radius', 'inherit'), "\n }\n ");
|
|
29
19
|
return {
|
|
30
20
|
// Appended onto existing `euiFormControlLayout` styles
|
|
31
21
|
delimited: /*#__PURE__*/css(delimitedStyles, ";label:delimited;"),
|
|
32
22
|
disabled: /*#__PURE__*/css(euiFormControlDisabledStyles(euiThemeContext), ";label:disabled;"),
|
|
33
|
-
readOnly: /*#__PURE__*/css(euiFormControlReadOnlyStyles(euiThemeContext), "
|
|
23
|
+
readOnly: /*#__PURE__*/css(euiFormControlReadOnlyStyles(euiThemeContext), " & .euiFormControlLayoutDelimited__input{--euiFormControlStateColor:transparent;outline:none;box-shadow:none;};label:readOnly;"),
|
|
34
24
|
// Appended onto existing `euiFormControlLayout__childrenWrapper` styles
|
|
35
25
|
childrenWrapper: {
|
|
36
|
-
delimited: /*#__PURE__*/css("display:flex;",
|
|
26
|
+
delimited: /*#__PURE__*/css("display:flex;", euiFormControlDefaultShadow(euiThemeContext, {
|
|
27
|
+
withBorder: !highContrastMode,
|
|
28
|
+
withBackground: false
|
|
29
|
+
}), " &:hover{", euiFormControlHoverStyles(euiThemeContext), " box-shadow:none;.euiFormControlLayoutDelimited__input:not(:focus){outline:none;background-color:transparent;}}>:first-child{", logicalCSS('border-top-left-radius', 'inherit'), " ", logicalCSS('border-bottom-left-radius', 'inherit'), ";}>:last-child{", logicalCSS('border-top-right-radius', 'inherit'), " ", logicalCSS('border-bottom-right-radius', 'inherit'), ";};label:delimited;"),
|
|
37
30
|
invalid: /*#__PURE__*/css(euiFormControlDefaultShadow(euiThemeContext, {
|
|
38
31
|
withBorder: false,
|
|
39
|
-
withBackgroundColor: false
|
|
40
|
-
|
|
41
|
-
}), "\n ".concat(invalidStyles, "\n "), ";label:invalid;"),
|
|
32
|
+
withBackgroundColor: false
|
|
33
|
+
}), "\n :not(.euiFormControlLayoutDelimited__input, .euiFormControlLayoutDelimited__delimiter) {\n ".concat(euiFormControlInvalidStyles(euiThemeContext), "\n }\n\n &:focus-within {\n --euiFormControlStateColor: ").concat(form.borderColor, ";\n --euiFormControlStateHoverColor: ").concat(form.borderHovered, ";\n }\n\n .euiFormControlLayoutDelimited__input {\n background-color: transparent;\n }\n "), ";label:invalid;"),
|
|
42
34
|
readOnly: /*#__PURE__*/css(";label:readOnly;")
|
|
43
35
|
}
|
|
44
36
|
};
|
|
45
37
|
};
|
|
46
38
|
export var euiFormControlLayoutDelimited__delimiter = function euiFormControlLayoutDelimited__delimiter(euiThemeContext) {
|
|
47
39
|
var euiTheme = euiThemeContext.euiTheme;
|
|
48
|
-
|
|
49
|
-
var experimentalStyles = isRefreshVariant && "\n ".concat(logicalCSS('padding-horizontal', mathWithUnits([euiTheme.size.xs, euiTheme.size.xxs], function (x, y) {
|
|
40
|
+
return /*#__PURE__*/css("display:flex;align-self:stretch;flex-grow:0;align-items:center;line-height:1;", logicalCSS('padding-horizontal', mathWithUnits([euiTheme.size.xs, euiTheme.size.xxs], function (x, y) {
|
|
50
41
|
return x + y;
|
|
51
|
-
})), "
|
|
52
|
-
return /*#__PURE__*/css("display:flex;align-self:stretch;flex-grow:0;align-items:center;line-height:1;", experimentalStyles, ";;label:euiFormControlLayoutDelimited__delimiter;");
|
|
42
|
+
})), ";;label:euiFormControlLayoutDelimited__delimiter;");
|
|
53
43
|
};
|
|
54
|
-
export var euiFormControlLayoutDelimited__input =
|
|
55
|
-
var isRefreshVariant = isEuiThemeRefreshVariant(euiThemeContext, 'formVariant');
|
|
56
|
-
return /*#__PURE__*/css("box-shadow:none;border:none;border-radius:", isRefreshVariant ? '' : '0', ";text-align:center;", logicalCSS('height', '100%'), ";;label:euiFormControlLayoutDelimited__input;");
|
|
57
|
-
};
|
|
44
|
+
export var euiFormControlLayoutDelimited__input = /*#__PURE__*/css("box-shadow:none;border:none;text-align:center;", logicalCSS('height', '100%'), ";;label:euiFormControlLayoutDelimited__input;");
|
|
@@ -31,7 +31,7 @@ function _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf
|
|
|
31
31
|
|
|
32
32
|
import React, { Component } from 'react';
|
|
33
33
|
import PropTypes from "prop-types";
|
|
34
|
-
import {
|
|
34
|
+
import { RenderWithEuiStylesMemoizer } from '../../../services';
|
|
35
35
|
import { EuiIcon } from '../../icon';
|
|
36
36
|
import { EuiLoadingSpinner } from '../../loading';
|
|
37
37
|
import { EuiFormControlLayoutClearButton } from './form_control_layout_clear_button';
|
|
@@ -77,7 +77,6 @@ export var EuiFormControlLayoutIcons = /*#__PURE__*/function (_Component) {
|
|
|
77
77
|
value: function renderCustomIcon() {
|
|
78
78
|
var _this$props2 = this.props,
|
|
79
79
|
icon = _this$props2.icon,
|
|
80
|
-
compressed = _this$props2.compressed,
|
|
81
80
|
isDisabled = _this$props2.isDisabled;
|
|
82
81
|
if (!icon) {
|
|
83
82
|
return null;
|
|
@@ -90,84 +89,63 @@ export var EuiFormControlLayoutIcons = /*#__PURE__*/function (_Component) {
|
|
|
90
89
|
var iconRef = iconProps.ref,
|
|
91
90
|
side = iconProps.side,
|
|
92
91
|
iconRest = _objectWithoutProperties(iconProps, _excluded);
|
|
93
|
-
return ___EmotionJSX(
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
iconRef: iconRef
|
|
99
|
-
}, iconRest));
|
|
100
|
-
});
|
|
92
|
+
return ___EmotionJSX(EuiFormControlLayoutCustomIcon, _extends({
|
|
93
|
+
size: "m",
|
|
94
|
+
disabled: isDisabled,
|
|
95
|
+
iconRef: iconRef
|
|
96
|
+
}, iconRest));
|
|
101
97
|
}
|
|
102
98
|
}, {
|
|
103
99
|
key: "renderDropdownIcon",
|
|
104
100
|
value: function renderDropdownIcon() {
|
|
105
101
|
var _this$props3 = this.props,
|
|
106
102
|
isDropdown = _this$props3.isDropdown,
|
|
107
|
-
compressed = _this$props3.compressed,
|
|
108
103
|
isDisabled = _this$props3.isDisabled;
|
|
109
104
|
if (!isDropdown) {
|
|
110
105
|
return null;
|
|
111
106
|
}
|
|
112
|
-
return ___EmotionJSX(
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
disabled: isDisabled,
|
|
117
|
-
type: "arrowDown"
|
|
118
|
-
});
|
|
107
|
+
return ___EmotionJSX(EuiFormControlLayoutCustomIcon, {
|
|
108
|
+
size: "m",
|
|
109
|
+
disabled: isDisabled,
|
|
110
|
+
type: "arrowDown"
|
|
119
111
|
});
|
|
120
112
|
}
|
|
121
113
|
}, {
|
|
122
114
|
key: "renderLoadingSpinner",
|
|
123
115
|
value: function renderLoadingSpinner() {
|
|
124
|
-
var
|
|
125
|
-
isLoading = _this$props4.isLoading,
|
|
126
|
-
compressed = _this$props4.compressed;
|
|
116
|
+
var isLoading = this.props.isLoading;
|
|
127
117
|
if (!isLoading) {
|
|
128
118
|
return null;
|
|
129
119
|
}
|
|
130
|
-
return ___EmotionJSX(
|
|
131
|
-
|
|
132
|
-
return ___EmotionJSX(EuiLoadingSpinner, {
|
|
133
|
-
size: compressed && !isRefreshVariant ? 's' : 'm'
|
|
134
|
-
});
|
|
120
|
+
return ___EmotionJSX(EuiLoadingSpinner, {
|
|
121
|
+
size: "m"
|
|
135
122
|
});
|
|
136
123
|
}
|
|
137
124
|
}, {
|
|
138
125
|
key: "renderClearButton",
|
|
139
126
|
value: function renderClearButton() {
|
|
140
|
-
var _this$
|
|
141
|
-
clear = _this$
|
|
142
|
-
|
|
143
|
-
isDisabled = _this$props5.isDisabled;
|
|
127
|
+
var _this$props4 = this.props,
|
|
128
|
+
clear = _this$props4.clear,
|
|
129
|
+
isDisabled = _this$props4.isDisabled;
|
|
144
130
|
if (!clear) {
|
|
145
131
|
return null;
|
|
146
132
|
}
|
|
147
|
-
return ___EmotionJSX(
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
disabled: isDisabled
|
|
152
|
-
}, clear));
|
|
153
|
-
});
|
|
133
|
+
return ___EmotionJSX(EuiFormControlLayoutClearButton, _extends({
|
|
134
|
+
size: "m",
|
|
135
|
+
disabled: isDisabled
|
|
136
|
+
}, clear));
|
|
154
137
|
}
|
|
155
138
|
}, {
|
|
156
139
|
key: "renderInvalidIcon",
|
|
157
140
|
value: function renderInvalidIcon() {
|
|
158
|
-
var
|
|
159
|
-
isInvalid = _this$props6.isInvalid,
|
|
160
|
-
compressed = _this$props6.compressed;
|
|
141
|
+
var isInvalid = this.props.isInvalid;
|
|
161
142
|
if (!isInvalid) {
|
|
162
143
|
return null;
|
|
163
144
|
}
|
|
164
|
-
return ___EmotionJSX(
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
color: "danger",
|
|
169
|
-
type: "warning"
|
|
170
|
-
});
|
|
145
|
+
return ___EmotionJSX(EuiIcon, {
|
|
146
|
+
size: "m",
|
|
147
|
+
color: "danger",
|
|
148
|
+
type: "warning"
|
|
171
149
|
});
|
|
172
150
|
}
|
|
173
151
|
}]);
|
|
@@ -7,12 +7,10 @@
|
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
9
|
import { css } from '@emotion/react';
|
|
10
|
-
import { isEuiThemeRefreshVariant } from '../../../services';
|
|
11
10
|
import { euiFontSize, logicalCSS } from '../../../global_styling';
|
|
12
11
|
export var euiFormErrorTextStyles = function euiFormErrorTextStyles(euiThemeContext) {
|
|
13
12
|
var euiTheme = euiThemeContext.euiTheme;
|
|
14
|
-
var isRefreshVariant = isEuiThemeRefreshVariant(euiThemeContext, 'formVariant');
|
|
15
13
|
return {
|
|
16
|
-
euiFormErrorText: /*#__PURE__*/css(logicalCSS('padding-top', euiTheme.size.xs), " ", euiFontSize(euiThemeContext, 'xs'), " color:",
|
|
14
|
+
euiFormErrorText: /*#__PURE__*/css(logicalCSS('padding-top', euiTheme.size.xs), " ", euiFontSize(euiThemeContext, 'xs'), " color:", euiTheme.colors.textDanger, ";;label:euiFormErrorText;")
|
|
17
15
|
};
|
|
18
16
|
};
|
|
@@ -26,7 +26,7 @@ export var EuiFormLabel = function EuiFormLabel(_ref) {
|
|
|
26
26
|
className = _ref.className,
|
|
27
27
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
28
28
|
var styles = useEuiMemoizedStyles(euiFormLabelStyles);
|
|
29
|
-
var cssStyles = [styles.euiFormLabel, !isDisabled && styles.notDisabled, isInvalid && styles.invalid
|
|
29
|
+
var cssStyles = [styles.euiFormLabel, !isDisabled && styles.notDisabled, isInvalid && styles.invalid];
|
|
30
30
|
var classes = classNames('euiFormLabel', className, {
|
|
31
31
|
'euiFormLabel-isFocused': isFocused,
|
|
32
32
|
'euiFormLabel-isInvalid': isInvalid,
|
|
@@ -11,7 +11,6 @@ function _objectWithoutPropertiesLoose(r, e) { if (null == r) return {}; var t =
|
|
|
11
11
|
|
|
12
12
|
import { css } from '@emotion/react';
|
|
13
13
|
import { serializeStyles } from '@emotion/serialize';
|
|
14
|
-
import { isEuiThemeRefreshVariant } from '../../../services';
|
|
15
14
|
import { euiCanAnimate, euiTextBreakWord } from '../../../global_styling';
|
|
16
15
|
import { euiTitle } from '../../title/title.styles';
|
|
17
16
|
export var euiFormLabel = function euiFormLabel(euiThemeContext) {
|
|
@@ -27,14 +26,11 @@ export var euiFormLabel = function euiFormLabel(euiThemeContext) {
|
|
|
27
26
|
};
|
|
28
27
|
export var euiFormLabelStyles = function euiFormLabelStyles(euiThemeContext) {
|
|
29
28
|
var euiTheme = euiThemeContext.euiTheme;
|
|
30
|
-
var isRefreshVariant = isEuiThemeRefreshVariant(euiThemeContext, 'formVariant');
|
|
31
29
|
return {
|
|
32
30
|
euiFormLabel: /*#__PURE__*/css(euiFormLabel(euiThemeContext), " display:inline-block;", euiCanAnimate, "{transition:color ", euiTheme.animation.fast, " ", euiTheme.animation.resistance, ";};label:euiFormLabel;"),
|
|
33
31
|
// Skip css`` to avoid generating an extra Emotion className
|
|
34
32
|
// Use :where to reduce specificity & make the CSS easier to override by prepend/append nodes
|
|
35
33
|
notDisabled: "\n &:where([for]) {\n cursor: pointer;\n }\n ",
|
|
36
|
-
invalid: /*#__PURE__*/css("color:",
|
|
37
|
-
// Focused state should override invalid state
|
|
38
|
-
focused: /*#__PURE__*/css("color:", isRefreshVariant ? '' : euiTheme.colors.primary, ";;label:focused;")
|
|
34
|
+
invalid: /*#__PURE__*/css("color:", euiTheme.colors.textDanger, ";;label:invalid;")
|
|
39
35
|
};
|
|
40
36
|
};
|
|
@@ -7,11 +7,9 @@
|
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
9
|
import { css } from '@emotion/react';
|
|
10
|
-
import { isEuiThemeRefreshVariant } from '../../../services';
|
|
11
10
|
export var euiRangeInputStyles = function euiRangeInputStyles(euiThemeContext) {
|
|
12
11
|
var euiTheme = euiThemeContext.euiTheme;
|
|
13
|
-
var isRefreshVariant = isEuiThemeRefreshVariant(euiThemeContext, 'formVariant');
|
|
14
12
|
return {
|
|
15
|
-
euiRangeInput: /*#__PURE__*/css("inline-size:auto;min-inline-size:", euiTheme.base *
|
|
13
|
+
euiRangeInput: /*#__PURE__*/css("inline-size:auto;min-inline-size:", euiTheme.base * 3.5, "px;.euiRange__popover &,.euiDualRange__popover &{inline-size:100%;};label:euiRangeInput;")
|
|
16
14
|
};
|
|
17
15
|
};
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
import { css } from '@emotion/react';
|
|
10
10
|
import { euiShadowXSmall } from '@elastic/eui-theme-common';
|
|
11
11
|
import { logicalCSS } from '../../global_styling';
|
|
12
|
-
import {
|
|
12
|
+
import { makeHighContrastColor } from '../../services';
|
|
13
13
|
export var euiHeaderVariables = function euiHeaderVariables(euiThemeContext) {
|
|
14
14
|
var euiTheme = euiThemeContext.euiTheme;
|
|
15
15
|
return {
|
|
@@ -45,24 +45,9 @@ export var euiHeaderStyles = function euiHeaderStyles(euiThemeContext) {
|
|
|
45
45
|
* It's also possible that the dark header will go away or become unused
|
|
46
46
|
* by Kibana in the near future, at which point we can remove this
|
|
47
47
|
*/
|
|
48
|
-
|
|
48
|
+
|
|
49
49
|
var euiHeaderDarkStyles = function euiHeaderDarkStyles(euiThemeContext) {
|
|
50
|
-
var euiTheme = euiThemeContext.euiTheme
|
|
51
|
-
highContrastMode = euiThemeContext.highContrastMode;
|
|
52
|
-
var isRefreshVariant = isEuiThemeRefreshVariant(euiThemeContext, 'formVariant');
|
|
53
|
-
var _euiFormVariables = euiFormVariables(euiThemeContext),
|
|
54
|
-
controlPlaceholderText = _euiFormVariables.controlPlaceholderText;
|
|
50
|
+
var euiTheme = euiThemeContext.euiTheme;
|
|
55
51
|
var backgroundColor = euiTheme.components.headerDarkBackground;
|
|
56
|
-
|
|
57
|
-
// Specific color overrides for EuiSelectableTemplateSitewide
|
|
58
|
-
var selectableSitewide = {
|
|
59
|
-
color: euiTheme.colors.ghost,
|
|
60
|
-
borderColor: euiTheme.components.headerDarkSearchBorderColor,
|
|
61
|
-
placeholderColor: makeHighContrastColor(controlPlaceholderText, 8)(backgroundColor)
|
|
62
|
-
};
|
|
63
|
-
var formLayoutStyles = "\n .euiSelectableTemplateSitewide .euiFormControlLayout {\n background-color: transparent;\n\n input {\n box-shadow: inset 0 0 0 ".concat(euiTheme.border.width.thin, " ").concat(selectableSitewide.borderColor, ";\n }\n\n &--group {\n border-color: ").concat(
|
|
64
|
-
// the header is in a faux dark mode, we can't rely on color
|
|
65
|
-
// switch tokens as they'd be in the wrong color mode
|
|
66
|
-
highContrastMode ? euiTheme.colors.plainLight : euiTheme.components.headerDarkSearchBorderColor, ";\n\n input {\n box-shadow: none;\n }\n }\n\n &__append {\n border-color: ").concat(highContrastMode ? euiTheme.colors.plainLight : '', "\n }\n\n &:not(:focus-within) {\n /* Increase contrast of filled text to be more than placeholder text */\n color: ").concat(selectableSitewide.color, ";\n\n input {\n /* Increase contrast of placeholder text */\n &::placeholder {\n color: ").concat(selectableSitewide.placeholderColor, ";\n }\n\n /* Inherit color from form control layout */\n color: inherit;\n background-color: transparent;\n }\n\n .euiFormControlLayout__append,\n .euiFormControlLayout__prepend {\n background-color: transparent;\n }\n\n .euiFormLabel {\n color: inherit;\n }\n }\n }\n ");
|
|
67
|
-
return "\n background-color: ".concat(backgroundColor, ";\n\n .euiHeaderLogo__text,\n .euiHeaderLink,\n .euiHeaderSectionItemButton {\n color: ").concat(euiTheme.colors.ghost, ";\n }\n\n .euiHeaderLink-isActive {\n color: ").concat(makeHighContrastColor(euiTheme.colors.primary)(backgroundColor), ";\n }\n\n .euiHeaderLogo,\n .euiHeaderLink,\n .euiHeaderSectionItemButton {\n &:focus {\n background-color: ").concat(euiTheme.components.headerDarkSectionItemBackgroundFocus, ";\n }\n }\n\n .euiHeaderSectionItemButton__notification--badge {\n box-shadow: 0 0 0 ").concat(euiTheme.border.width.thin, " ").concat(backgroundColor, ";\n }\n\n .euiHeaderSectionItemButton__notification--dot {\n stroke: ").concat(backgroundColor, ";\n }\n\n ").concat(!isRefreshVariant && formLayoutStyles, " \n ");
|
|
52
|
+
return "\n background-color: ".concat(backgroundColor, ";\n\n .euiHeaderLogo__text,\n .euiHeaderLink,\n .euiHeaderSectionItemButton {\n color: ").concat(euiTheme.colors.ghost, ";\n }\n\n .euiHeaderLink-isActive {\n color: ").concat(makeHighContrastColor(euiTheme.colors.primary)(backgroundColor), ";\n }\n\n .euiHeaderLogo,\n .euiHeaderLink,\n .euiHeaderSectionItemButton {\n &:focus {\n background-color: ").concat(euiTheme.components.headerDarkSectionItemBackgroundFocus, ";\n }\n }\n\n .euiHeaderSectionItemButton__notification--badge {\n box-shadow: 0 0 0 ").concat(euiTheme.border.width.thin, " ").concat(backgroundColor, ";\n }\n\n .euiHeaderSectionItemButton__notification--dot {\n stroke: ").concat(backgroundColor, ";\n }\n ");
|
|
68
53
|
};
|
|
@@ -8,7 +8,6 @@ function _EMOTION_STRINGIFIED_CSS_ERROR__() { return "You have tried to stringif
|
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
import { css } from '@emotion/react';
|
|
11
|
-
import { isEuiThemeRefreshVariant } from '../../../services';
|
|
12
11
|
import { logicalCSS, logicalSizeCSS, mathWithUnits, euiMaxBreakpoint } from '../../../global_styling';
|
|
13
12
|
import { euiHeaderVariables } from '../header.styles';
|
|
14
13
|
var _ref = process.env.NODE_ENV === "production" ? {
|
|
@@ -31,14 +30,13 @@ export var euiHeaderSectionItemButtonStyles = function euiHeaderSectionItemButto
|
|
|
31
30
|
var _euiHeaderVariables = euiHeaderVariables(euiThemeContext),
|
|
32
31
|
childHeight = _euiHeaderVariables.childHeight;
|
|
33
32
|
var euiTheme = euiThemeContext.euiTheme;
|
|
34
|
-
var isRefreshVariant = isEuiThemeRefreshVariant(euiThemeContext, 'buttonVariant');
|
|
35
33
|
var dotSize = euiTheme.size.base;
|
|
36
|
-
var dotOffset =
|
|
34
|
+
var dotOffset = mathWithUnits(dotSize, function (x) {
|
|
37
35
|
return x * -0.5;
|
|
38
|
-
})
|
|
39
|
-
var badgeOffset =
|
|
36
|
+
});
|
|
37
|
+
var badgeOffset = mathWithUnits(euiTheme.size.s, function (x) {
|
|
40
38
|
return x * -0.5;
|
|
41
|
-
})
|
|
39
|
+
});
|
|
42
40
|
return {
|
|
43
41
|
euiHeaderSectionItemButton: /*#__PURE__*/css("position:relative;", logicalCSS('height', childHeight), " ", logicalCSS('min-width', childHeight), " ", logicalCSS('padding-horizontal', euiTheme.size.s), " text-align:center;font-size:0;", euiMaxBreakpoint(euiThemeContext, 's'), "{", logicalCSS('min-width', mathWithUnits(childHeight, function (x) {
|
|
44
42
|
return x * 0.75;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var _excluded = ["type", "size", "color", "className", "tabIndex", "title", "onIconLoad", "style", "stylesMemoizer"];
|
|
1
|
+
var _excluded = ["type", "size", "color", "className", "tabIndex", "title", "role", "onIconLoad", "style", "stylesMemoizer", "aria-hidden", "titleId"];
|
|
2
2
|
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
3
3
|
function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
|
|
4
4
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
@@ -183,9 +183,12 @@ export var EuiIconClass = /*#__PURE__*/function (_PureComponent) {
|
|
|
183
183
|
className = _this$props.className,
|
|
184
184
|
tabIndex = _this$props.tabIndex,
|
|
185
185
|
title = _this$props.title,
|
|
186
|
+
role = _this$props.role,
|
|
186
187
|
onIconLoad = _this$props.onIconLoad,
|
|
187
188
|
style = _this$props.style,
|
|
188
189
|
stylesMemoizer = _this$props.stylesMemoizer,
|
|
190
|
+
ariaHidden = _this$props['aria-hidden'],
|
|
191
|
+
titleId = _this$props.titleId,
|
|
189
192
|
rest = _objectWithoutProperties(_this$props, _excluded);
|
|
190
193
|
var _this$state = this.state,
|
|
191
194
|
isLoading = _this$state.isLoading,
|
|
@@ -210,41 +213,55 @@ export var EuiIconClass = /*#__PURE__*/function (_PureComponent) {
|
|
|
210
213
|
var styles = stylesMemoizer(euiIconStyles);
|
|
211
214
|
var cssStyles = [styles.euiIcon, styles[size], color && isNamedColor(color) && styles[color], isCustomColor && styles.customColor, isElasticLogoOutline && styles.logoElasticOutline, isAppIcon && !appIconHasColor && styles.app, isLoading && styles.isLoading, !isLoading && neededLoading && styles.isLoaded];
|
|
212
215
|
var icon = this.state.icon || empty;
|
|
216
|
+
var isAriaHidden = [true, 'true'].includes(ariaHidden !== null && ariaHidden !== void 0 ? ariaHidden : false);
|
|
217
|
+
var isPresentationOnly = !(title || this.props['aria-label'] || this.props['aria-labelledby']) || ['none', 'presentation'].includes(role !== null && role !== void 0 ? role : '') || isAriaHidden;
|
|
218
|
+
var accessibleTitle = isPresentationOnly ? undefined : title;
|
|
219
|
+
|
|
220
|
+
// implicitly set the ARIA role for the icon only if:
|
|
221
|
+
// - The user did NOT provide a `role` prop
|
|
222
|
+
// - `aria-hidden` is NOT true
|
|
223
|
+
// This ensures user-supplied `role` and `aria-hidden` always take precedence.
|
|
224
|
+
// If set, role is:
|
|
225
|
+
// - 'presentation' for decorative icons
|
|
226
|
+
// - 'img' for meaningful icons
|
|
227
|
+
var accessibleRole = function () {
|
|
228
|
+
if (isAriaHidden) return undefined;
|
|
229
|
+
if (isPresentationOnly) return 'presentation';
|
|
230
|
+
return 'img';
|
|
231
|
+
}();
|
|
213
232
|
if (typeof icon === 'string') {
|
|
214
233
|
return ___EmotionJSX("img", _extends({
|
|
215
|
-
alt:
|
|
234
|
+
alt: accessibleTitle,
|
|
216
235
|
src: icon,
|
|
217
236
|
className: classes,
|
|
218
237
|
css: cssStyles,
|
|
219
238
|
style: style,
|
|
220
|
-
tabIndex: tabIndex
|
|
239
|
+
tabIndex: tabIndex,
|
|
240
|
+
role: role !== null && role !== void 0 ? role : accessibleRole,
|
|
241
|
+
"aria-hidden": ariaHidden
|
|
221
242
|
}, rest));
|
|
222
243
|
} else {
|
|
223
244
|
var Svg = icon;
|
|
224
245
|
|
|
225
|
-
// If there is no aria-label, aria-labelledby, or title it gets aria-hidden true
|
|
226
|
-
var isAriaHidden = !(this.props['aria-label'] || this.props['aria-labelledby'] || this.props.title);
|
|
227
|
-
|
|
228
246
|
// If no aria-label or aria-labelledby is provided but there's a title, a titleId is generated
|
|
229
247
|
// The svg aria-labelledby attribute gets this titleId
|
|
230
248
|
// The svg title element gets this titleId as an id
|
|
231
|
-
var
|
|
232
|
-
titleId: generateId()
|
|
249
|
+
var accessibleTitleId = !this.props['aria-label'] && !this.props['aria-labelledby'] && title ? {
|
|
250
|
+
titleId: titleId || generateId()
|
|
233
251
|
} : undefined;
|
|
234
252
|
return ___EmotionJSX(Svg, _extends({
|
|
235
253
|
className: classes,
|
|
236
254
|
style: optionalCustomStyles,
|
|
237
255
|
css: cssStyles,
|
|
238
256
|
tabIndex: tabIndex,
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
257
|
+
title: accessibleTitle,
|
|
258
|
+
role: role !== null && role !== void 0 ? role : accessibleRole,
|
|
259
|
+
"aria-hidden": ariaHidden
|
|
260
|
+
}, accessibleTitleId, {
|
|
242
261
|
"data-icon-type": iconTitle,
|
|
243
262
|
"data-is-loaded": isLoaded || undefined,
|
|
244
263
|
"data-is-loading": isLoading || undefined
|
|
245
|
-
}, rest
|
|
246
|
-
"aria-hidden": isAriaHidden || rest['aria-hidden']
|
|
247
|
-
}));
|
|
264
|
+
}, rest));
|
|
248
265
|
}
|
|
249
266
|
}
|
|
250
267
|
}]);
|
|
@@ -501,7 +501,7 @@ export var typeToPathMap = {
|
|
|
501
501
|
vulnerabilityManagementApp: 'app_vulnerability_management',
|
|
502
502
|
warning: 'warning',
|
|
503
503
|
warningFilled: 'warning',
|
|
504
|
-
// NOTE: To be deprecated in favor of `
|
|
504
|
+
// NOTE: To be deprecated in favor of `warning`
|
|
505
505
|
watchesApp: 'app_watches',
|
|
506
506
|
web: 'web',
|
|
507
507
|
wordWrap: 'wordWrap',
|
|
@@ -7,35 +7,31 @@
|
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
9
|
import { css } from '@emotion/react';
|
|
10
|
-
import { euiShadow } from '@elastic/eui-theme-common';
|
|
11
10
|
import { logicalCSS, logicalSizeCSS, euiCanAnimate, euiFontSize } from '../../global_styling';
|
|
12
11
|
import { highContrastModeStyles } from '../../global_styling/functions/high_contrast';
|
|
13
12
|
import { euiScreenReaderOnly } from '../accessibility';
|
|
14
13
|
import { euiKeyPadMenuVariables } from './key_pad_menu.styles';
|
|
15
14
|
export var euiKeyPadMenuItemStyles = function euiKeyPadMenuItemStyles(euiThemeContext) {
|
|
16
|
-
var _euiTheme$flags;
|
|
17
15
|
var euiTheme = euiThemeContext.euiTheme;
|
|
18
16
|
var _euiKeyPadMenuVariabl = euiKeyPadMenuVariables(euiThemeContext),
|
|
19
17
|
euiKeyPadMenuSize = _euiKeyPadMenuVariabl.euiKeyPadMenuSize;
|
|
20
|
-
var hasVisColorAdjustment = (_euiTheme$flags = euiTheme.flags) === null || _euiTheme$flags === void 0 ? void 0 : _euiTheme$flags.hasVisColorAdjustment;
|
|
21
|
-
var focusTransformStyles = "\n ".concat(euiShadow(euiThemeContext, 's'), ";\n\n ").concat(euiCanAnimate, " {\n .euiKeyPadMenuItem__icon {\n transform: translateY(0);\n }\n }\n ");
|
|
22
18
|
return {
|
|
23
19
|
euiKeyPadMenuItem: /*#__PURE__*/css("display:block;padding:", euiTheme.size.xs, ";", logicalSizeCSS(euiKeyPadMenuSize), " border-radius:", euiTheme.border.radius.medium, ";color:", euiTheme.colors.textParagraph, ";", euiCanAnimate, "{transition:background-color ", euiTheme.animation.fast, " ease-in,box-shadow ", euiTheme.animation.fast, " ease-in;};label:euiKeyPadMenuItem;"),
|
|
24
|
-
enabled: /*#__PURE__*/css("&:is(:hover, :focus, :focus-within){cursor:pointer;text-decoration:underline;", highContrastModeStyles(euiThemeContext, {
|
|
20
|
+
enabled: /*#__PURE__*/css("&:is(:hover, :focus, :focus-within){cursor:pointer;text-decoration:underline;background-color:", euiTheme.colors.backgroundBaseInteractiveHover, ";", highContrastModeStyles(euiThemeContext, {
|
|
25
21
|
// Use `outline` instead of border to avoid affecting absolutely positioned children
|
|
26
22
|
preferred: "\n outline: ".concat(euiTheme.border.width.thin, " solid ").concat(euiTheme.colors.primary, ";\n ")
|
|
27
|
-
}), "
|
|
28
|
-
selected: /*#__PURE__*/css("color:", euiTheme.colors.textHeading, "
|
|
23
|
+
}), ";}&:focus{box-shadow:none;background-color:", euiTheme.colors.backgroundBaseInteractiveHover, ";};label:enabled;"),
|
|
24
|
+
selected: /*#__PURE__*/css("color:", euiTheme.colors.textHeading, ";&:is(*, :hover, :focus, :focus-within){color:", euiTheme.colors.textPrimary, ";background-color:", euiTheme.colors.backgroundBaseInteractiveSelect, ";", highContrastModeStyles(euiThemeContext, {
|
|
29
25
|
// Skip checkable items (which render a <label> instead of <button>/<a>),
|
|
30
26
|
// as they already have sufficient indication of state (checkbox or radio)
|
|
31
27
|
preferred: "\n &:not(label) {\n outline: ".concat(euiTheme.border.width.thick, " solid ").concat(euiTheme.colors.primary, ";\n outline-offset: 0;\n }\n ")
|
|
32
28
|
}), ";};label:selected;"),
|
|
33
29
|
disabled: {
|
|
34
30
|
disabled: /*#__PURE__*/css("cursor:not-allowed;color:", euiTheme.colors.textDisabled, ";", highContrastModeStyles(euiThemeContext, {
|
|
35
|
-
none: "\n .euiKeyPadMenuItem__icon {\n
|
|
31
|
+
none: "\n .euiKeyPadMenuItem__icon {\n svg * {\n fill: ".concat(euiTheme.colors.textDisabled, ";\n }\n }\n "),
|
|
36
32
|
forced: 'opacity: 0.5;'
|
|
37
33
|
}), ";;label:disabled;"),
|
|
38
|
-
selected: /*#__PURE__*/css("background-color:",
|
|
34
|
+
selected: /*#__PURE__*/css("background-color:", euiTheme.colors.backgroundBaseDisabled, ";", highContrastModeStyles(euiThemeContext, {
|
|
39
35
|
preferred: "\n &:not(label) {\n outline: ".concat(euiTheme.border.width.thick, " solid ").concat(euiTheme.colors.textDisabled, ";\n }\n ")
|
|
40
36
|
}), ";;label:selected;")
|
|
41
37
|
}
|
|
@@ -8,7 +8,6 @@ function _EMOTION_STRINGIFIED_CSS_ERROR__() { return "You have tried to stringif
|
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
import { css } from '@emotion/react';
|
|
11
|
-
import { isEuiThemeRefreshVariant } from '../../services';
|
|
12
11
|
import { logicalCSS } from '../../global_styling';
|
|
13
12
|
import { euiMarkdownEditorVariables } from './markdown_editor.styles';
|
|
14
13
|
import { euiFormControlInvalidStyles } from '../form/form.styles';
|
|
@@ -22,14 +21,13 @@ var _ref = process.env.NODE_ENV === "production" ? {
|
|
|
22
21
|
};
|
|
23
22
|
export var euiMarkdownEditorDropZoneStyles = function euiMarkdownEditorDropZoneStyles(euiThemeContext) {
|
|
24
23
|
var euiTheme = euiThemeContext.euiTheme;
|
|
25
|
-
var isRefreshVariant = isEuiThemeRefreshVariant(euiThemeContext, 'formVariant');
|
|
26
24
|
var _euiMarkdownEditorVar = euiMarkdownEditorVariables(euiThemeContext),
|
|
27
25
|
minHeight = _euiMarkdownEditorVar.minHeight;
|
|
28
26
|
return {
|
|
29
27
|
euiMarkdownEditorDropZone: /*#__PURE__*/css("position:relative;display:flex;flex-direction:column;", logicalCSS('min-height', minHeight), ";;label:euiMarkdownEditorDropZone;"),
|
|
30
|
-
isDragging: /*#__PURE__*/css(".euiMarkdownEditorFooter,.euiMarkdownEditorTextArea{background-color:",
|
|
31
|
-
isDraggingError: /*#__PURE__*/css(".euiMarkdownEditorFooter,.euiMarkdownEditorTextArea{background-color:",
|
|
32
|
-
hasError: /*#__PURE__*/css(".euiMarkdownEditorTextArea{--euiFormControlStateColor:", euiTheme.colors.danger, ";background-size:100% 100%;",
|
|
28
|
+
isDragging: /*#__PURE__*/css(".euiMarkdownEditorFooter,.euiMarkdownEditorTextArea{background-color:", euiTheme.colors.backgroundBasePrimary, "!important;};label:isDragging;"),
|
|
29
|
+
isDraggingError: /*#__PURE__*/css(".euiMarkdownEditorFooter,.euiMarkdownEditorTextArea{background-color:", euiTheme.colors.backgroundBaseDanger, "!important;};label:isDraggingError;"),
|
|
30
|
+
hasError: /*#__PURE__*/css(".euiMarkdownEditorTextArea{--euiFormControlStateColor:", euiTheme.colors.danger, ";background-size:100% 100%;", euiFormControlInvalidStyles(euiThemeContext), ";};label:hasError;"),
|
|
33
31
|
euiMarkdownEditorDropZone__input: _ref
|
|
34
32
|
};
|
|
35
33
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
2
|
-
var _excluded = ["className", "children", "initialFocus", "onClose", "maxWidth", "role", "style", "focusTrapProps", "aria-describedby"];
|
|
2
|
+
var _excluded = ["className", "children", "initialFocus", "onClose", "maxWidth", "role", "style", "focusTrapProps", "outsideClickCloses", "aria-describedby"];
|
|
3
3
|
function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
|
|
4
4
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
5
5
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
@@ -16,7 +16,7 @@ function _objectWithoutPropertiesLoose(r, e) { if (null == r) return {}; var t =
|
|
|
16
16
|
* Side Public License, v 1.
|
|
17
17
|
*/
|
|
18
18
|
|
|
19
|
-
import React from 'react';
|
|
19
|
+
import React, { useRef, useCallback } from 'react';
|
|
20
20
|
import PropTypes from "prop-types";
|
|
21
21
|
import classnames from 'classnames';
|
|
22
22
|
import { keys, useEuiTheme, useGeneratedHtmlId } from '../../services';
|
|
@@ -39,6 +39,8 @@ export var EuiModal = function EuiModal(_ref) {
|
|
|
39
39
|
role = _ref$role === void 0 ? 'dialog' : _ref$role,
|
|
40
40
|
style = _ref.style,
|
|
41
41
|
focusTrapProps = _ref.focusTrapProps,
|
|
42
|
+
_ref$outsideClickClos = _ref.outsideClickCloses,
|
|
43
|
+
outsideClickCloses = _ref$outsideClickClos === void 0 ? false : _ref$outsideClickClos,
|
|
42
44
|
_ariaDescribedBy = _ref['aria-describedby'],
|
|
43
45
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
44
46
|
var onKeyDown = function onKeyDown(event) {
|
|
@@ -50,6 +52,14 @@ export var EuiModal = function EuiModal(_ref) {
|
|
|
50
52
|
}
|
|
51
53
|
}
|
|
52
54
|
};
|
|
55
|
+
var maskRef = useRef(null);
|
|
56
|
+
var onClickOutside = useCallback(function (event) {
|
|
57
|
+
// The overlay mask is always present
|
|
58
|
+
if (outsideClickCloses === true && event.target === maskRef.current) {
|
|
59
|
+
onClose(event);
|
|
60
|
+
}
|
|
61
|
+
return undefined;
|
|
62
|
+
}, [onClose, outsideClickCloses]);
|
|
53
63
|
var newStyle = style;
|
|
54
64
|
if (typeof maxWidth !== 'boolean') {
|
|
55
65
|
newStyle = _objectSpread(_objectSpread({}, newStyle), {}, {
|
|
@@ -69,10 +79,13 @@ export var EuiModal = function EuiModal(_ref) {
|
|
|
69
79
|
token: "euiModal.screenReaderModalDialog",
|
|
70
80
|
default: "You are in a modal dialog. Press Escape or tap/click outside the dialog on the shadowed overlay to close."
|
|
71
81
|
})));
|
|
72
|
-
return ___EmotionJSX(EuiOverlayMask,
|
|
82
|
+
return ___EmotionJSX(EuiOverlayMask, {
|
|
83
|
+
maskRef: maskRef
|
|
84
|
+
}, ___EmotionJSX(EuiFocusTrap, _extends({}, focusTrapProps, {
|
|
73
85
|
initialFocus: initialFocus,
|
|
74
86
|
scrollLock: true,
|
|
75
|
-
preventScrollOnFocus: true
|
|
87
|
+
preventScrollOnFocus: true,
|
|
88
|
+
onClickOutside: onClickOutside
|
|
76
89
|
}), ___EmotionJSX("div", _extends({
|
|
77
90
|
css: cssStyles,
|
|
78
91
|
className: classes,
|
|
@@ -125,5 +138,10 @@ EuiModal.propTypes = {
|
|
|
125
138
|
* Object of props passed to EuiFocusTrap.
|
|
126
139
|
* `returnFocus` defines the return focus behavior and provides the possibility to check the available target element or opt out of the behavior in favor of manually returning focus
|
|
127
140
|
*/
|
|
128
|
-
focusTrapProps: PropTypes.any
|
|
141
|
+
focusTrapProps: PropTypes.any,
|
|
142
|
+
/**
|
|
143
|
+
* Whether clicking outside the modal should close it.
|
|
144
|
+
* @default false
|
|
145
|
+
*/
|
|
146
|
+
outsideClickCloses: PropTypes.bool
|
|
129
147
|
};
|