@elastic/eui 107.0.1 → 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.styles.js +1 -3
- package/es/components/badge/notification_badge/badge_notification.styles.js +2 -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/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/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/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 +19 -2102
- 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/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/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/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/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.styles.js +1 -3
- package/optimize/es/components/badge/notification_badge/badge_notification.styles.js +2 -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/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/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/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.styles.js +1 -3
- package/optimize/lib/components/badge/notification_badge/badge_notification.styles.js +2 -4
- 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/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/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/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 +5 -6
- 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/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/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/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/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/package/eui.d.ts +0 -33359
- 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
|
@@ -5,7 +5,6 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.euiFilterButtonWrapperStyles = exports.euiFilterButtonStyles = exports.euiFilterButtonDisplay = exports.euiFilterButtonChildStyles = void 0;
|
|
7
7
|
var _react = require("@emotion/react");
|
|
8
|
-
var _services = require("../../services");
|
|
9
8
|
var _global_styling = require("../../global_styling");
|
|
10
9
|
var _supports = require("../../global_styling/functions/supports");
|
|
11
10
|
var _form = require("../form/form.styles");
|
|
@@ -18,15 +17,14 @@ function _EMOTION_STRINGIFIED_CSS_ERROR__() { return "You have tried to stringif
|
|
|
18
17
|
*/
|
|
19
18
|
var euiFilterButtonDisplay = exports.euiFilterButtonDisplay = function euiFilterButtonDisplay(euiThemeContext) {
|
|
20
19
|
var euiTheme = euiThemeContext.euiTheme;
|
|
21
|
-
var isRefreshVariant = (0, _services.isEuiThemeRefreshVariant)(euiThemeContext, 'buttonVariant');
|
|
22
20
|
return {
|
|
23
21
|
flex: '1 1 auto',
|
|
24
22
|
minInlineSize: (0, _global_styling.mathWithUnits)(euiTheme.size.base, function (x) {
|
|
25
|
-
return x *
|
|
23
|
+
return x * 2.75;
|
|
26
24
|
})
|
|
27
25
|
};
|
|
28
26
|
};
|
|
29
|
-
var
|
|
27
|
+
var _ref4 = process.env.NODE_ENV === "production" ? {
|
|
30
28
|
name: "jkp921-noGrow",
|
|
31
29
|
styles: "flex-grow:0;label:noGrow;"
|
|
32
30
|
} : {
|
|
@@ -36,46 +34,30 @@ var _ref3 = process.env.NODE_ENV === "production" ? {
|
|
|
36
34
|
};
|
|
37
35
|
var euiFilterButtonStyles = exports.euiFilterButtonStyles = function euiFilterButtonStyles(euiThemeContext) {
|
|
38
36
|
var euiTheme = euiThemeContext.euiTheme;
|
|
39
|
-
var isRefreshVariant = (0, _services.isEuiThemeRefreshVariant)(euiThemeContext, 'buttonVariant');
|
|
40
|
-
var _euiFormVariables = (0, _form.euiFormVariables)(euiThemeContext),
|
|
41
|
-
controlHeight = _euiFormVariables.controlHeight,
|
|
42
|
-
borderColor = _euiFormVariables.borderColor;
|
|
43
37
|
var selectedSelector = '.euiFilterButton-isSelected';
|
|
44
|
-
var
|
|
45
|
-
|
|
46
|
-
// Pseudo elements create borders without affecting width. We also prefer them
|
|
47
|
-
// over box-shadow for Windows high contrast theme compatibility
|
|
48
|
-
var leftBorder = "\n &::before {\n content: '';\n position: absolute;\n ".concat((0, _global_styling.logicalCSS)('right', '100%'), "\n ").concat((0, _global_styling.logicalCSS)('vertical', 0), "\n ").concat((0, _global_styling.logicalCSS)('border-left', border), "\n }\n ");
|
|
49
|
-
// Bottom borders are needed for responsive flex-wrap behavior
|
|
50
|
-
var bottomBorder = "\n &::after {\n content: '';\n position: absolute;\n ".concat((0, _global_styling.logicalCSS)('top', '100%'), "\n ").concat((0, _global_styling.logicalCSS)('horizontal', 0), "\n ").concat((0, _global_styling.logicalCSS)('border-bottom', border), "\n }\n ");
|
|
51
|
-
var buttonStyles = isRefreshVariant ? "\n ".concat((0, _global_styling.logicalCSS)('width', '100%'), "\n\n &:not(").concat(selectedSelector, ") {\n &:hover,\n &:active {\n .euiFilterButton__notification[class*=\"subdued\"] {\n background-color: ").concat(euiTheme.components.filterButtonBadgeBackgroundHover, "\n }\n }\n }\n ") : "\n ".concat((0, _global_styling.logicalCSS)('height', controlHeight), "\n border-radius: 0;\n ").concat(leftBorder, "\n ").concat(bottomBorder, "\n\n /* :not(:disabled) specificity needed to override EuiButtonEmpty styles */\n &:hover:not(:disabled),\n &:focus:not(:disabled) {\n /* Remove underline from whole button so notifications don't get the underline */\n text-decoration: none;\n\n .euiFilterButton__text {\n /* And put it only on the actual text part */\n text-decoration: underline;\n }\n }\n ");
|
|
52
|
-
var toggleTypeStyles = isRefreshVariant ? "\n ".concat(euiFilterButtonDisplay(euiThemeContext), ";\n\n ").concat((0, _global_styling.highContrastModeStyles)(euiThemeContext, {
|
|
53
|
-
forced: "\n &:is(".concat(selectedSelector, ") {\n ").concat((0, _global_styling.preventForcedColors)(euiThemeContext), "\n color: ").concat(euiTheme.colors.emptyShade, ";\n background-color: ").concat(euiTheme.colors.fullShade, ";\n }\n ")
|
|
54
|
-
}), "\n ") : "\n font-weight: ".concat(euiTheme.font.weight.medium, ";\n padding: 0;\n\n &:is(").concat(selectedSelector, ") {\n color: ").concat((0, _global_styling.euiButtonEmptyColor)(euiThemeContext, 'text').color, ";\n background-color: transparent;\n font-weight: ").concat(euiTheme.font.weight.bold, ";\n }\n ");
|
|
55
|
-
var withNextSelector = isRefreshVariant ? '& + .euiFilterButton__wrapper' : '.euiFilterButton__wrapper:has(&) + .euiFilterButton__wrapper';
|
|
56
|
-
// handles display of borders between buttons
|
|
57
|
-
var withNextStyles = isRefreshVariant ? "\n &::before {\n border: none;\n }\n\n ".concat((0, _supports.cssSupportsHasWithNextSibling)("\n &:has(+ :not(&)) {\n ".concat((0, _global_styling.logicalCSS)('padding-right', '0'), "\n }\n ")), "\n ") : "\n .euiFilterButton {\n &::before {\n border: none;\n }\n }\n ";
|
|
38
|
+
var withNextSelector = '& + .euiFilterButton__wrapper';
|
|
58
39
|
return {
|
|
59
|
-
euiFilterButton: /*#__PURE__*/(0, _react.css)(
|
|
40
|
+
euiFilterButton: /*#__PURE__*/(0, _react.css)("position:relative;", (0, _global_styling.logicalCSS)('width', '100%'), " &:not(", selectedSelector, "){&:hover,&:active{.euiFilterButton__notification[class*='subdued']{background-color:", euiTheme.components.filterButtonBadgeBackgroundHover, ";}}};label:euiFilterButton;"),
|
|
60
41
|
buttonType: {
|
|
61
|
-
default: /*#__PURE__*/(0, _react.css)(
|
|
62
|
-
toggle: /*#__PURE__*/(0, _react.css)("&:focus-visible{outline-offset:", (0, _global_styling.mathWithUnits)(euiTheme.focus.width, function (x) {
|
|
63
|
-
return
|
|
64
|
-
}), ";}",
|
|
42
|
+
default: /*#__PURE__*/(0, _react.css)("border-radius:0;&:focus-visible{z-index:1;outline-offset:-", euiTheme.border.width.thick, ";border-radius:", euiTheme.border.radius.small, ";transition:none;};label:default;"),
|
|
43
|
+
toggle: /*#__PURE__*/(0, _react.css)(euiFilterButtonDisplay(euiThemeContext), " &:focus-visible{outline-offset:", (0, _global_styling.mathWithUnits)(euiTheme.focus.width, function (x) {
|
|
44
|
+
return x / 2;
|
|
45
|
+
}), ";}", (0, _global_styling.highContrastModeStyles)(euiThemeContext, {
|
|
46
|
+
forced: "\n &:is(".concat(selectedSelector, ") {\n ").concat((0, _global_styling.preventForcedColors)(euiThemeContext), "\n color: ").concat(euiTheme.colors.emptyShade, ";\n background-color: ").concat(euiTheme.colors.fullShade, ";\n }\n ")
|
|
47
|
+
}), ";;label:toggle;")
|
|
65
48
|
},
|
|
66
|
-
withNext: /*#__PURE__*/(0, _react.css)(withNextSelector, "{", (0, _global_styling.logicalCSS)('margin-left', "-".concat(euiTheme.size.xs)),
|
|
67
|
-
noGrow:
|
|
49
|
+
withNext: /*#__PURE__*/(0, _react.css)(withNextSelector, "{", (0, _supports.cssSupportsHasWithNextSibling)("\n &:has(+ :not(&)) {\n ".concat((0, _global_styling.logicalCSS)('padding-right', '0'), "\n }\n ")), ";", (0, _global_styling.logicalCSS)('margin-left', "-".concat(euiTheme.size.xs)), "&::before{border:none;}};label:withNext;"),
|
|
50
|
+
noGrow: _ref4,
|
|
68
51
|
hasNotification: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('min-width', (0, _global_styling.mathWithUnits)(euiTheme.size.base, function (x) {
|
|
69
52
|
return x * 6;
|
|
70
53
|
})), ";;label:hasNotification;"),
|
|
71
|
-
hasActiveFilters: /*#__PURE__*/(0, _react.css)("font-weight:",
|
|
54
|
+
hasActiveFilters: /*#__PURE__*/(0, _react.css)("font-weight:", euiTheme.font.weight.medium, ";;label:hasActiveFilters;")
|
|
72
55
|
};
|
|
73
56
|
};
|
|
74
57
|
var euiFilterButtonWrapperStyles = exports.euiFilterButtonWrapperStyles = function euiFilterButtonWrapperStyles(euiThemeContext) {
|
|
75
58
|
var euiTheme = euiThemeContext.euiTheme;
|
|
76
|
-
var
|
|
77
|
-
|
|
78
|
-
borderColor = _euiFormVariables2.borderColor;
|
|
59
|
+
var _euiFormVariables = (0, _form.euiFormVariables)(euiThemeContext),
|
|
60
|
+
borderColor = _euiFormVariables.borderColor;
|
|
79
61
|
var border = "".concat(euiTheme.border.width.thin, " solid ").concat(borderColor);
|
|
80
62
|
|
|
81
63
|
// Pseudo elements create borders without affecting width. We also prefer them
|
|
@@ -84,8 +66,8 @@ var euiFilterButtonWrapperStyles = exports.euiFilterButtonWrapperStyles = functi
|
|
|
84
66
|
// Bottom borders are needed for responsive flex-wrap behavior
|
|
85
67
|
var bottomBorder = "\n &::after {\n content: '';\n position: absolute;\n inset: 0;\n ".concat((0, _global_styling.logicalCSS)('border-bottom', border), "\n pointer-events: none;\n }\n ");
|
|
86
68
|
return {
|
|
87
|
-
wrapper: /*#__PURE__*/(0, _react.css)(euiFilterButtonDisplay(euiThemeContext), " position:relative;display:flex;align-items:center;",
|
|
88
|
-
hasToggle: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('padding-horizontal',
|
|
69
|
+
wrapper: /*#__PURE__*/(0, _react.css)(euiFilterButtonDisplay(euiThemeContext), " position:relative;display:flex;align-items:center;", leftBorder, " ", bottomBorder, " ", (0, _global_styling.logicalCSS)('padding-vertical', euiTheme.border.width.thin), ";;label:wrapper;"),
|
|
70
|
+
hasToggle: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('padding-horizontal', euiTheme.border.width.thin), (0, _supports.cssSupportsHasWithNextSibling)("\n &:not([class*=\"withNext\"]):has(+ :not(&)) {\n ".concat((0, _global_styling.logicalCSS)('padding-right', '0'), "\n }\n ")), ";;label:hasToggle;")
|
|
89
71
|
};
|
|
90
72
|
};
|
|
91
73
|
var _ref = process.env.NODE_ENV === "production" ? {
|
|
@@ -104,18 +86,25 @@ var _ref2 = process.env.NODE_ENV === "production" ? {
|
|
|
104
86
|
styles: "cursor:inherit;forced-color-adjust:auto;&{transition:none;};label:euiFilterButton__notification;",
|
|
105
87
|
toString: _EMOTION_STRINGIFIED_CSS_ERROR__
|
|
106
88
|
};
|
|
89
|
+
var _ref3 = process.env.NODE_ENV === "production" ? {
|
|
90
|
+
name: "kc7mgj-euiFilterButton__content",
|
|
91
|
+
styles: ".euiThemeProvider{display:inline-flex;};label:euiFilterButton__content;"
|
|
92
|
+
} : {
|
|
93
|
+
name: "kc7mgj-euiFilterButton__content",
|
|
94
|
+
styles: ".euiThemeProvider{display:inline-flex;};label:euiFilterButton__content;",
|
|
95
|
+
toString: _EMOTION_STRINGIFIED_CSS_ERROR__
|
|
96
|
+
};
|
|
107
97
|
var euiFilterButtonChildStyles = exports.euiFilterButtonChildStyles = function euiFilterButtonChildStyles(euiThemeContext) {
|
|
108
98
|
var euiTheme = euiThemeContext.euiTheme;
|
|
109
|
-
var isRefreshVariant = (0, _services.isEuiThemeRefreshVariant)(euiThemeContext, 'buttonVariant');
|
|
110
99
|
return {
|
|
111
100
|
content: {
|
|
112
|
-
euiFilterButton__content:
|
|
101
|
+
euiFilterButton__content: _ref3,
|
|
113
102
|
hasIcon: /*#__PURE__*/(0, _react.css)("&>.euiIcon:last-child{", (0, _global_styling.logicalCSS)('margin-left', 'auto'), ";};label:hasIcon;")
|
|
114
103
|
},
|
|
115
104
|
text: {
|
|
116
105
|
euiFilterButton__text: /*#__PURE__*/(0, _react.css)((0, _global_styling.euiTextShift)('bold', 'data-text', euiTheme), " ", (0, _global_styling.euiTextTruncate)(), ";;label:euiFilterButton__text;"),
|
|
117
106
|
hasNotification: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('min-width', (0, _global_styling.mathWithUnits)(euiTheme.size.base, function (x) {
|
|
118
|
-
return x *
|
|
107
|
+
return x * 2;
|
|
119
108
|
})), ";;label:hasNotification;")
|
|
120
109
|
},
|
|
121
110
|
notification: {
|
|
@@ -5,9 +5,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.euiFilterGroupStyles = void 0;
|
|
7
7
|
var _react = require("@emotion/react");
|
|
8
|
-
var _services = require("../../services");
|
|
9
8
|
var _global_styling = require("../../global_styling");
|
|
10
|
-
var _high_contrast = require("../../global_styling/functions/high_contrast");
|
|
11
9
|
var _form = require("../form/form.styles");
|
|
12
10
|
var _filter_button = require("./filter_button.styles");
|
|
13
11
|
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)."; } /*
|
|
@@ -27,31 +25,23 @@ var _ref = process.env.NODE_ENV === "production" ? {
|
|
|
27
25
|
};
|
|
28
26
|
var euiFilterGroupStyles = exports.euiFilterGroupStyles = function euiFilterGroupStyles(euiThemeContext) {
|
|
29
27
|
var euiTheme = euiThemeContext.euiTheme;
|
|
30
|
-
var isRefreshVariant = (0, _services.isEuiThemeRefreshVariant)(euiThemeContext, 'buttonVariant');
|
|
31
28
|
var _euiFormVariables = (0, _form.euiFormVariables)(euiThemeContext),
|
|
32
29
|
backgroundColor = _euiFormVariables.backgroundColor,
|
|
33
|
-
borderColor = _euiFormVariables.borderColor,
|
|
34
|
-
controlBorderRadius = _euiFormVariables.controlBorderRadius,
|
|
35
30
|
controlHeight = _euiFormVariables.controlHeight,
|
|
36
|
-
controlCompressedBorderRadius = _euiFormVariables.controlCompressedBorderRadius,
|
|
37
31
|
controlCompressedHeight = _euiFormVariables.controlCompressedHeight;
|
|
38
|
-
var borderRadius =
|
|
39
|
-
var borderRadiusCompressed =
|
|
40
|
-
var borderStyle = isRefreshVariant ? "\n /* Adds the border on a pseudo element to prevent height differences between wrapper and buttons.\n Uses ::after to ensure overlap and prevents blocking by setting pointer-events: none */\n &::after {\n content: '';\n position: absolute;\n inset: 0;\n border: ".concat(euiTheme.border.width.thin, " solid ").concat(euiTheme.colors.borderBasePlain, ";\n border-radius: inherit;\n pointer-events: none;\n }\n ") : "\n ".concat((0, _high_contrast.highContrastModeStyles)(euiThemeContext, {
|
|
41
|
-
none: "box-shadow: inset 0 0 0 ".concat(euiTheme.border.width.thin, " ").concat(borderColor, ";"),
|
|
42
|
-
forced: "border: ".concat(euiTheme.border.thin, ";")
|
|
43
|
-
}), "\n ");
|
|
32
|
+
var borderRadius = euiTheme.border.radius.small;
|
|
33
|
+
var borderRadiusCompressed = euiTheme.border.radius.small;
|
|
44
34
|
return {
|
|
45
|
-
euiFilterGroup: /*#__PURE__*/(0, _react.css)(
|
|
35
|
+
euiFilterGroup: /*#__PURE__*/(0, _react.css)("position:relative;display:inline-flex;", (0, _global_styling.logicalCSS)('max-width', '100%'), " overflow:hidden;background-color:", backgroundColor, ";&::after{content:'';position:absolute;inset:0;border:", euiTheme.border.width.thin, " solid ", euiTheme.colors.borderBasePlain, ";border-radius:inherit;pointer-events:none;}>*:not(.euiFilterButton__wrapper, .euiFilterButton){", (0, _filter_button.euiFilterButtonDisplay)(euiThemeContext), ";}.euiPopover>.euiFilterButton{", (0, _global_styling.logicalCSS)('width', '100%'), ";}", (0, _global_styling.euiBreakpoint)(euiThemeContext, ['xs', 's']), "{flex-wrap:wrap;}", (0, _global_styling.euiBreakpoint)(euiThemeContext, ['xs']), "{display:flex;.euiPopover:focus-within{z-index:1;}.euiFilterButton__wrapper{flex-grow:1;}};label:euiFilterGroup;"),
|
|
46
36
|
fullWidth: _ref,
|
|
47
|
-
uncompressed: /*#__PURE__*/(0, _react.css)("border-radius:", borderRadius, ";.euiFilterButton__wrapper{", (0, _global_styling.logicalCSS)('height', controlHeight), ";}.euiFilterButton{", (0, _global_styling.logicalCSS)('height', controlHeight), ";}
|
|
37
|
+
uncompressed: /*#__PURE__*/(0, _react.css)("border-radius:", borderRadius, ";.euiFilterButton__wrapper{", (0, _global_styling.logicalCSS)('height', controlHeight), ";}.euiFilterButton{", (0, _global_styling.logicalCSS)('height', controlHeight), ";}.euiFilterButton-isToggle{", (0, _global_styling.logicalCSS)('height', (0, _global_styling.mathWithUnits)([controlHeight, euiTheme.size.xxs], function (x, y) {
|
|
48
38
|
return x - 3 * y;
|
|
49
|
-
})), "
|
|
50
|
-
compressed: /*#__PURE__*/(0, _react.css)("border-radius:", borderRadiusCompressed, "
|
|
39
|
+
})), ";};label:uncompressed;"),
|
|
40
|
+
compressed: /*#__PURE__*/(0, _react.css)("border-radius:", borderRadiusCompressed, ";.euiFilterButton{", (0, _global_styling.logicalCSS)('height', (0, _global_styling.mathWithUnits)([controlCompressedHeight, euiTheme.border.width.thin], function (x, y) {
|
|
51
41
|
return x - 2 * y;
|
|
52
|
-
})
|
|
42
|
+
})), ";}.euiFilterButton-isToggle{", (0, _global_styling.logicalCSS)('height', (0, _global_styling.mathWithUnits)([controlCompressedHeight, euiTheme.size.xxs], function (x, y) {
|
|
53
43
|
return x - 3 * y;
|
|
54
|
-
})), "
|
|
44
|
+
})), ";};label:compressed;"),
|
|
55
45
|
/**
|
|
56
46
|
* Not used in EuiFilterGroup directly, but used by EuiSearchBar and consumers
|
|
57
47
|
* A fixed width is required because of the shift in widths that can be caused
|
|
@@ -61,15 +51,4 @@ var euiFilterGroupStyles = exports.euiFilterGroupStyles = function euiFilterGrou
|
|
|
61
51
|
return x * 18;
|
|
62
52
|
})), ";;label:euiFilterGroup__popoverPanel;")
|
|
63
53
|
};
|
|
64
|
-
};
|
|
65
|
-
|
|
66
|
-
/**
|
|
67
|
-
* Small util for manually rounding the borders of the first and last EuiFilterButtons
|
|
68
|
-
* - this makes their focus rings appear nicely instead of being cutt off.
|
|
69
|
-
* 2nd selector accounts for EuiFilterButtons nested within popover/tooltip wrappers.
|
|
70
|
-
*
|
|
71
|
-
* NOTE: Do not use `logicalShorthandCSS()` here, as that will cause single buttons to not be rounded
|
|
72
|
-
*/
|
|
73
|
-
var buttonChildrenBorderRadii = function buttonChildrenBorderRadii(radiusSize) {
|
|
74
|
-
return "\n > :first-child,\n > :first-child .euiFilterButton {\n ".concat((0, _global_styling.logicalCSS)('border-top-left-radius', radiusSize), "\n ").concat((0, _global_styling.logicalCSS)('border-bottom-left-radius', radiusSize), "\n }\n\n > :last-child,\n > :last-child .euiFilterButton {\n ").concat((0, _global_styling.logicalCSS)('border-top-right-radius', radiusSize), "\n ").concat((0, _global_styling.logicalCSS)('border-bottom-right-radius', radiusSize), "\n }\n");
|
|
75
54
|
};
|
|
@@ -5,7 +5,6 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.euiFieldNumberStyles = void 0;
|
|
7
7
|
var _react = require("@emotion/react");
|
|
8
|
-
var _services = require("../../../services");
|
|
9
8
|
var _form = require("../form.styles");
|
|
10
9
|
/*
|
|
11
10
|
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
|
|
@@ -17,11 +16,9 @@ var _form = require("../form.styles");
|
|
|
17
16
|
|
|
18
17
|
var euiFieldNumberStyles = exports.euiFieldNumberStyles = function euiFieldNumberStyles(euiThemeContext) {
|
|
19
18
|
var colorMode = euiThemeContext.colorMode;
|
|
20
|
-
var isRefreshVariant = (0, _services.isEuiThemeRefreshVariant)(euiThemeContext, 'formVariant');
|
|
21
19
|
var formStyles = (0, _form.euiFormControlStyles)(euiThemeContext);
|
|
22
|
-
var invalidStyles = isRefreshVariant ? "\n &:is(:invalid, [aria-invalid='true']):not(\n .euiFormControlLayoutDelimited__input, :focus\n ) {\n ".concat(formStyles.invalid, "\n }\n ") : "\n /* Account for native validity detection as well via [aria-invalid=\"true\"] */\n &:is(:invalid, [aria-invalid='true']) {\n ".concat(formStyles.invalid, "\n }\n ");
|
|
23
20
|
return {
|
|
24
|
-
euiFieldNumber: /*#__PURE__*/(0, _react.css)(formStyles.shared, "color-scheme:", colorMode === 'DARK' ? 'dark' : 'light', "
|
|
21
|
+
euiFieldNumber: /*#__PURE__*/(0, _react.css)(formStyles.shared, "color-scheme:", colorMode === 'DARK' ? 'dark' : 'light', ";&:is(:invalid, [aria-invalid='true']):not(\n .euiFormControlLayoutDelimited__input,\n :focus\n ){", formStyles.invalid, ";}&:focus{", formStyles.focus, ";}&:disabled{", formStyles.disabled, ";}&[readOnly]{", formStyles.readOnly, ";}&:autofill{", formStyles.autoFill, ";};label:euiFieldNumber;"),
|
|
25
22
|
// Skip the css() on the default height to avoid generating a className
|
|
26
23
|
uncompressed: formStyles.uncompressed,
|
|
27
24
|
compressed: /*#__PURE__*/(0, _react.css)(formStyles.compressed, ";label:compressed;"),
|
|
@@ -5,7 +5,6 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.euiFieldTextStyles = void 0;
|
|
7
7
|
var _react = require("@emotion/react");
|
|
8
|
-
var _services = require("../../../services");
|
|
9
8
|
var _form = require("../form.styles");
|
|
10
9
|
/*
|
|
11
10
|
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
|
|
@@ -16,11 +15,9 @@ var _form = require("../form.styles");
|
|
|
16
15
|
*/
|
|
17
16
|
|
|
18
17
|
var euiFieldTextStyles = exports.euiFieldTextStyles = function euiFieldTextStyles(euiThemeContext) {
|
|
19
|
-
var isRefreshVariant = (0, _services.isEuiThemeRefreshVariant)(euiThemeContext, 'formVariant');
|
|
20
18
|
var formStyles = (0, _form.euiFormControlStyles)(euiThemeContext);
|
|
21
|
-
var invalidStyles = isRefreshVariant ? "\n &:is(:invalid, [aria-invalid='true']):not(\n .euiFormControlLayoutDelimited__input, :focus\n ) {\n ".concat(formStyles.invalid, "\n }\n ") : "\n &:is(:invalid){\n ".concat(formStyles.invalid, "\n }\n ");
|
|
22
19
|
return {
|
|
23
|
-
euiFieldText: /*#__PURE__*/(0, _react.css)(formStyles.shared, " ",
|
|
20
|
+
euiFieldText: /*#__PURE__*/(0, _react.css)(formStyles.shared, " &:is(:invalid, [aria-invalid='true']):not(\n .euiFormControlLayoutDelimited__input, :focus\n ){", formStyles.invalid, ";}&:focus{", formStyles.focus, ";}&[readOnly]{", formStyles.readOnly, ";}&:disabled{", formStyles.disabled, ";}&:autofill{", formStyles.autoFill, ";};label:euiFieldText;"),
|
|
24
21
|
// Skip the css() on the default height to avoid generating a className
|
|
25
22
|
uncompressed: formStyles.uncompressed,
|
|
26
23
|
compressed: /*#__PURE__*/(0, _react.css)(formStyles.compressed, ";label:compressed;"),
|
|
@@ -109,117 +109,112 @@ var EuiFilePickerClass = exports.EuiFilePickerClass = /*#__PURE__*/function (_Co
|
|
|
109
109
|
var _this2 = this;
|
|
110
110
|
var _ref = this.context,
|
|
111
111
|
defaultFullWidth = _ref.defaultFullWidth;
|
|
112
|
-
return (0, _react2.jsx)(
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
112
|
+
return (0, _react2.jsx)(_i18n.EuiI18n, {
|
|
113
|
+
token: "euiFilePicker.removeSelectedAriaLabel",
|
|
114
|
+
default: "Remove selected files"
|
|
115
|
+
}, function (removeSelectedAriaLabel) {
|
|
116
|
+
var _this2$props = _this2.props,
|
|
117
|
+
stylesMemoizer = _this2$props.stylesMemoizer,
|
|
118
|
+
id = _this2$props.id,
|
|
119
|
+
name = _this2$props.name,
|
|
120
|
+
initialPromptText = _this2$props.initialPromptText,
|
|
121
|
+
className = _this2$props.className,
|
|
122
|
+
disabled = _this2$props.disabled,
|
|
123
|
+
compressed = _this2$props.compressed,
|
|
124
|
+
onChange = _this2$props.onChange,
|
|
125
|
+
isInvalid = _this2$props.isInvalid,
|
|
126
|
+
_this2$props$fullWidt = _this2$props.fullWidth,
|
|
127
|
+
fullWidth = _this2$props$fullWidt === void 0 ? defaultFullWidth : _this2$props$fullWidt,
|
|
128
|
+
isLoading = _this2$props.isLoading,
|
|
129
|
+
display = _this2$props.display,
|
|
130
|
+
rest = (0, _objectWithoutProperties2.default)(_this2$props, _excluded);
|
|
131
|
+
var promptId = "".concat(id || _this2.generatedId, "-filePicker__prompt");
|
|
132
|
+
var isOverridingInitialPrompt = _this2.state.promptText != null;
|
|
133
|
+
var normalFormControl = display === 'default';
|
|
134
|
+
var classes = (0, _classnames.default)('euiFilePicker', {
|
|
135
|
+
'euiFilePicker-isDroppingFile': _this2.state.isHoveringDrop,
|
|
136
|
+
'euiFilePicker-isInvalid': isInvalid,
|
|
137
|
+
'euiFilePicker-isLoading': isLoading,
|
|
138
|
+
'euiFilePicker-hasFiles': isOverridingInitialPrompt
|
|
139
|
+
}, className);
|
|
140
|
+
var styles = stylesMemoizer(_file_picker.euiFilePickerStyles);
|
|
141
|
+
var cssStyles = [styles.euiFilePicker, fullWidth ? styles.fullWidth : styles.formWidth, _this2.state.isHoveringDrop && styles.isDroppingFile, isInvalid && !disabled && styles.invalid, isOverridingInitialPrompt && !disabled && styles.hasFiles, isLoading && styles.loading];
|
|
142
|
+
var inputStyles = [styles.input.euiFilePicker__input, !normalFormControl && !disabled && styles.input.largeInteractive];
|
|
143
|
+
var promptStyles = [styles.euiFilePicker__prompt, disabled && styles.disabled].concat((0, _toConsumableArray2.default)(normalFormControl ? [compressed ? styles.compressed : styles.uncompressed] : [styles.large.large, compressed ? styles.large.compressed : styles.large.uncompressed]));
|
|
144
|
+
var iconStyles = [styles.icon.euiFilePicker__icon].concat((0, _toConsumableArray2.default)(normalFormControl ? [styles.icon.normal, compressed ? styles.icon.compresssed : styles.icon.uncompressed] : [styles.icon.large]));
|
|
145
|
+
var rightIconStyles = normalFormControl ? [styles.rightIcon.euiFilePicker__rightIcon, compressed ? styles.rightIcon.compressed : styles.rightIcon.uncompressed] : undefined;
|
|
146
|
+
var clearButton;
|
|
147
|
+
if (isLoading && normalFormControl) {
|
|
148
|
+
// Override clear button with loading spinner if it is in loading state
|
|
149
|
+
clearButton = (0, _react2.jsx)(_loading.EuiLoadingSpinner, {
|
|
150
|
+
css: rightIconStyles,
|
|
151
|
+
className: "euiFilePicker__loadingSpinner",
|
|
152
|
+
size: compressed ? 's' : 'm'
|
|
153
|
+
});
|
|
154
|
+
} else if (isOverridingInitialPrompt && !disabled) {
|
|
155
|
+
if (normalFormControl) {
|
|
156
|
+
clearButton = (0, _react2.jsx)(_form_control_layout_clear_button.EuiFormControlLayoutClearButton, {
|
|
157
|
+
"aria-label": removeSelectedAriaLabel,
|
|
158
|
+
css: [styles.euiFilePicker__clearButton, rightIconStyles, ";label:clearButton;"],
|
|
159
|
+
className: "euiFilePicker__clearButton",
|
|
160
|
+
onClick: _this2.removeFiles,
|
|
154
161
|
size: compressed ? 's' : 'm'
|
|
155
162
|
});
|
|
156
|
-
} else if (isOverridingInitialPrompt && !disabled) {
|
|
157
|
-
if (normalFormControl) {
|
|
158
|
-
clearButton = (0, _react2.jsx)(_form_control_layout_clear_button.EuiFormControlLayoutClearButton, {
|
|
159
|
-
"aria-label": removeSelectedAriaLabel,
|
|
160
|
-
css: [styles.euiFilePicker__clearButton, rightIconStyles, ";label:clearButton;"],
|
|
161
|
-
className: "euiFilePicker__clearButton",
|
|
162
|
-
onClick: _this2.removeFiles,
|
|
163
|
-
size: compressed ? 's' : 'm'
|
|
164
|
-
});
|
|
165
|
-
} else {
|
|
166
|
-
clearButton = (0, _react2.jsx)(_button.EuiButtonEmpty, {
|
|
167
|
-
"aria-label": removeSelectedAriaLabel,
|
|
168
|
-
css: styles.euiFilePicker__clearButton,
|
|
169
|
-
className: "euiFilePicker__clearButton",
|
|
170
|
-
size: "xs",
|
|
171
|
-
onClick: _this2.removeFiles
|
|
172
|
-
}, (0, _react2.jsx)(_i18n.EuiI18n, {
|
|
173
|
-
token: "euiFilePicker.removeSelected",
|
|
174
|
-
default: "Remove"
|
|
175
|
-
}));
|
|
176
|
-
}
|
|
177
163
|
} else {
|
|
178
|
-
clearButton =
|
|
164
|
+
clearButton = (0, _react2.jsx)(_button.EuiButtonEmpty, {
|
|
165
|
+
"aria-label": removeSelectedAriaLabel,
|
|
166
|
+
css: styles.euiFilePicker__clearButton,
|
|
167
|
+
className: "euiFilePicker__clearButton",
|
|
168
|
+
size: "xs",
|
|
169
|
+
onClick: _this2.removeFiles
|
|
170
|
+
}, (0, _react2.jsx)(_i18n.EuiI18n, {
|
|
171
|
+
token: "euiFilePicker.removeSelected",
|
|
172
|
+
default: "Remove"
|
|
173
|
+
}));
|
|
179
174
|
}
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
var iconColor = isInvalid ? 'danger' : disabled ? isRefreshVariant ? 'disabled' : 'subdued' : isRefreshVariant ? 'text' : 'primary';
|
|
188
|
-
return (0, _react2.jsx)("div", {
|
|
189
|
-
css: cssStyles,
|
|
190
|
-
className: classes
|
|
191
|
-
}, (0, _react2.jsx)(_validatable_control.EuiValidatableControl, {
|
|
192
|
-
isInvalid: isInvalid
|
|
193
|
-
}, (0, _react2.jsx)("input", (0, _extends2.default)({
|
|
194
|
-
type: "file",
|
|
195
|
-
id: id,
|
|
196
|
-
name: name,
|
|
197
|
-
css: inputStyles,
|
|
198
|
-
className: "euiFilePicker__input",
|
|
199
|
-
onChange: _this2.handleChange,
|
|
200
|
-
ref: function ref(input) {
|
|
201
|
-
_this2.fileInput = input;
|
|
202
|
-
},
|
|
203
|
-
onDragOver: _this2.showDrop,
|
|
204
|
-
onDragLeave: _this2.hideDrop,
|
|
205
|
-
onDrop: _this2.hideDrop,
|
|
206
|
-
disabled: disabled,
|
|
207
|
-
"aria-describedby": promptId
|
|
208
|
-
}, rest))), (0, _react2.jsx)("div", {
|
|
209
|
-
css: promptStyles,
|
|
210
|
-
className: "euiFilePicker__prompt",
|
|
211
|
-
id: promptId
|
|
212
|
-
}, (0, _react2.jsx)(_icon.EuiIcon, {
|
|
213
|
-
css: iconStyles,
|
|
214
|
-
className: "euiFilePicker__icon",
|
|
215
|
-
color: iconColor,
|
|
216
|
-
type: isInvalid ? 'alert' : isRefreshVariant && disabled ? 'minusInCircle' : 'importAction',
|
|
217
|
-
size: normalFormControl ? 'm' : 'l',
|
|
218
|
-
"aria-hidden": "true"
|
|
219
|
-
}), (0, _react2.jsx)("span", {
|
|
220
|
-
className: "euiFilePicker__promptText"
|
|
221
|
-
}, _this2.state.promptText || initialPromptText), clearButton, loader));
|
|
175
|
+
} else {
|
|
176
|
+
clearButton = null;
|
|
177
|
+
}
|
|
178
|
+
var loader = !normalFormControl && isLoading && (0, _react2.jsx)(_progress.EuiProgress, {
|
|
179
|
+
size: "xs",
|
|
180
|
+
color: "accent",
|
|
181
|
+
position: "absolute"
|
|
222
182
|
});
|
|
183
|
+
var iconColor = isInvalid ? 'danger' : disabled ? 'disabled' : 'text';
|
|
184
|
+
return (0, _react2.jsx)("div", {
|
|
185
|
+
css: cssStyles,
|
|
186
|
+
className: classes
|
|
187
|
+
}, (0, _react2.jsx)(_validatable_control.EuiValidatableControl, {
|
|
188
|
+
isInvalid: isInvalid
|
|
189
|
+
}, (0, _react2.jsx)("input", (0, _extends2.default)({
|
|
190
|
+
type: "file",
|
|
191
|
+
id: id,
|
|
192
|
+
name: name,
|
|
193
|
+
css: inputStyles,
|
|
194
|
+
className: "euiFilePicker__input",
|
|
195
|
+
onChange: _this2.handleChange,
|
|
196
|
+
ref: function ref(input) {
|
|
197
|
+
_this2.fileInput = input;
|
|
198
|
+
},
|
|
199
|
+
onDragOver: _this2.showDrop,
|
|
200
|
+
onDragLeave: _this2.hideDrop,
|
|
201
|
+
onDrop: _this2.hideDrop,
|
|
202
|
+
disabled: disabled,
|
|
203
|
+
"aria-describedby": promptId
|
|
204
|
+
}, rest))), (0, _react2.jsx)("div", {
|
|
205
|
+
css: promptStyles,
|
|
206
|
+
className: "euiFilePicker__prompt",
|
|
207
|
+
id: promptId
|
|
208
|
+
}, (0, _react2.jsx)(_icon.EuiIcon, {
|
|
209
|
+
css: iconStyles,
|
|
210
|
+
className: "euiFilePicker__icon",
|
|
211
|
+
color: iconColor,
|
|
212
|
+
type: isInvalid ? 'alert' : disabled ? 'minusInCircle' : 'importAction',
|
|
213
|
+
size: normalFormControl ? 'm' : 'l',
|
|
214
|
+
"aria-hidden": "true"
|
|
215
|
+
}), (0, _react2.jsx)("span", {
|
|
216
|
+
className: "euiFilePicker__promptText"
|
|
217
|
+
}, _this2.state.promptText || initialPromptText), clearButton, loader));
|
|
223
218
|
});
|
|
224
219
|
}
|
|
225
220
|
}]);
|
|
@@ -5,7 +5,6 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.euiFilePickerStyles = void 0;
|
|
7
7
|
var _react = require("@emotion/react");
|
|
8
|
-
var _services = require("../../../services");
|
|
9
8
|
var _global_styling = require("../../../global_styling");
|
|
10
9
|
var _form = require("../form.styles");
|
|
11
10
|
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)."; } /*
|
|
@@ -42,17 +41,16 @@ var _ref3 = process.env.NODE_ENV === "production" ? {
|
|
|
42
41
|
var euiFilePickerStyles = exports.euiFilePickerStyles = function euiFilePickerStyles(euiThemeContext) {
|
|
43
42
|
var euiTheme = euiThemeContext.euiTheme,
|
|
44
43
|
highContrastMode = euiThemeContext.highContrastMode;
|
|
45
|
-
var isRefreshVariant = (0, _services.isEuiThemeRefreshVariant)(euiThemeContext, 'formVariant');
|
|
46
44
|
var formStyles = (0, _form.euiFormControlStyles)(euiThemeContext);
|
|
47
45
|
var formVariables = (0, _form.euiFormVariables)(euiThemeContext);
|
|
48
46
|
var _euiFontSize = (0, _global_styling.euiFontSize)(euiThemeContext, 's'),
|
|
49
47
|
fontSize = _euiFontSize.fontSize,
|
|
50
48
|
lineHeight = _euiFontSize.lineHeight;
|
|
51
49
|
return {
|
|
52
|
-
euiFilePicker: /*#__PURE__*/(0, _react.css)("--euiFormControlLeftIconsCount:1;position:relative;border-radius:", formVariables.controlBorderRadius, ";&:has(input:focus){--euiFormControlStateColor:", formVariables.borderFocused, ";}&:hover{--euiFormControlStateColor:", highContrastMode ? euiTheme.border.color : formVariables.borderHovered, ";--euiFormControlStateStyle:
|
|
50
|
+
euiFilePicker: /*#__PURE__*/(0, _react.css)("--euiFormControlLeftIconsCount:1;position:relative;border-radius:", formVariables.controlBorderRadius, ";&:has(input:focus){--euiFormControlStateColor:", formVariables.borderFocused, ";}&:hover{--euiFormControlStateColor:", highContrastMode ? euiTheme.border.color : formVariables.borderHovered, ";--euiFormControlStateStyle:solid;}&:focus-within{", (0, _global_styling.highContrastModeStyles)(euiThemeContext, {
|
|
53
51
|
forced: "\n ".concat((0, _form.euiFormControlShowBackgroundLine)(euiThemeContext, formVariables.borderFocused), "\n ")
|
|
54
52
|
}), ";};label:euiFilePicker;"),
|
|
55
|
-
isDroppingFile: /*#__PURE__*/(0, _react.css)("--euiFormControlStateColor:",
|
|
53
|
+
isDroppingFile: /*#__PURE__*/(0, _react.css)("--euiFormControlStateColor:", euiTheme.colors.borderStrongSuccess, ";--euiFormControlStateStyle:", highContrastMode === 'forced' ? 'solid' : 'dashed', ";background-color:", euiTheme.components.forms.backgroundDropping, ";;label:isDroppingFile;"),
|
|
56
54
|
invalid: /*#__PURE__*/(0, _react.css)("--euiFormControlStateColor:", formVariables.borderInvalid, ";&:hover{--euiFormControlStateColor:", formVariables.borderInvalidHovered, ";}", (0, _global_styling.highContrastModeStyles)(euiThemeContext, {
|
|
57
55
|
forced: "\n ".concat((0, _form.euiFormControlShowBackgroundLine)(euiThemeContext, formVariables.borderInvalid), "\n ")
|
|
58
56
|
}), ";;label:invalid;"),
|
|
@@ -64,11 +62,11 @@ var euiFilePickerStyles = exports.euiFilePickerStyles = function euiFilePickerSt
|
|
|
64
62
|
// The input is an invisible dropzone / button
|
|
65
63
|
input: {
|
|
66
64
|
euiFilePicker__input: _ref3,
|
|
67
|
-
largeInteractive: /*#__PURE__*/(0, _react.css)("&:hover,&:focus,.euiFilePicker-isDroppingFile &{&+.euiFilePicker__prompt{.euiFilePicker__promptText{
|
|
65
|
+
largeInteractive: /*#__PURE__*/(0, _react.css)("&:hover,&:focus,.euiFilePicker-isDroppingFile &{&+.euiFilePicker__prompt{.euiFilePicker__promptText{", (0, _global_styling.highContrastModeStyles)(euiThemeContext, {
|
|
68
66
|
forced: "\n text-decoration: underline;\n "
|
|
69
|
-
}), ";}.euiFilePicker__icon{transform:scale(
|
|
67
|
+
}), ";}.euiFilePicker__icon{transform:scale(1.05);}}};label:largeInteractive;")
|
|
70
68
|
},
|
|
71
|
-
euiFilePicker__prompt: /*#__PURE__*/(0, _react.css)("pointer-events:none;font-size:", fontSize, ";line-height:1;", (0, _global_styling.euiTextTruncate)(), " color:", euiTheme.colors.textParagraph, ";border:",
|
|
69
|
+
euiFilePicker__prompt: /*#__PURE__*/(0, _react.css)("pointer-events:none;font-size:", fontSize, ";line-height:1;", (0, _global_styling.euiTextTruncate)(), " color:", euiTheme.colors.textParagraph, ";border:", euiTheme.border.width.thin, " var(--euiFormControlStateStyle, dashed) var(--euiFormControlStateColor, ", formVariables.borderColor, ");", _global_styling.euiCanAnimate, "{transition:border-color ", euiTheme.animation.fast, " ease-in,background-color ", euiTheme.animation.fast, " ease-in;};label:euiFilePicker__prompt;"),
|
|
72
70
|
disabled: /*#__PURE__*/(0, _react.css)(formStyles.disabled, ";label:disabled;"),
|
|
73
71
|
// Skip the css() on the default height to avoid generating a className
|
|
74
72
|
uncompressed: formStyles.uncompressed,
|