@elastic/eui 85.0.1 → 86.0.0-rc1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/eui_charts_theme.js +39 -18
- package/dist/eui_charts_theme.js.map +1 -1
- package/dist/eui_theme_dark.css +47 -90
- package/dist/eui_theme_dark.min.css +1 -1
- package/dist/eui_theme_light.css +47 -90
- package/dist/eui_theme_light.min.css +1 -1
- package/es/components/collapsible_nav_beta/collapsible_nav_beta.js +26 -0
- package/es/components/collapsible_nav_beta/collapsible_nav_beta.styles.js +16 -0
- package/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_accordion.js +202 -0
- package/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_accordion.styles.js +33 -0
- package/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.js +296 -0
- package/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.styles.js +58 -0
- package/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_link.js +93 -0
- package/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_link.styles.js +28 -0
- package/es/components/collapsible_nav_beta/collapsible_nav_item/index.js +9 -0
- package/es/components/collapsible_nav_beta/index.js +15 -0
- package/es/components/color_picker/saturation.js +2 -1
- package/es/components/combo_box/combo_box_input/combo_box_input.js +7 -1
- package/es/components/combo_box/combo_box_input/combo_box_pill.js +16 -4
- package/es/components/combo_box/combo_box_options_list/combo_box_option.js +4 -0
- package/es/components/combo_box/combo_box_options_list/combo_box_options_list.js +21 -3
- package/es/components/combo_box/combo_box_options_list/combo_box_title.js +1 -3
- package/es/components/datagrid/body/data_grid_body.js +7 -7
- package/es/components/datagrid/body/data_grid_body_custom.js +7 -7
- package/es/components/datagrid/body/data_grid_body_virtualized.js +7 -7
- package/es/components/datagrid/body/data_grid_cell.js +14 -13
- package/es/components/datagrid/body/header/data_grid_control_header_cell.js +2 -2
- package/es/components/datagrid/body/header/data_grid_header_cell.js +1 -1
- package/es/components/datagrid/body/header/data_grid_header_row.js +5 -5
- package/es/components/datagrid/controls/data_grid_toolbar.js +31 -26
- package/es/components/datagrid/controls/display_selector.js +2 -1
- package/es/components/datagrid/data_grid.js +7 -7
- package/es/components/datagrid/utils/in_memory.js +4 -4
- package/es/components/datagrid/utils/row_heights.js +4 -4
- package/es/components/date_picker/date_picker.js +1 -1
- package/es/components/drag_and_drop/drag_drop_context.js +1 -1
- package/es/components/drag_and_drop/draggable.js +2 -2
- package/es/components/drag_and_drop/droppable.js +1 -1
- package/es/components/drag_and_drop/index.js +3 -2
- package/es/components/error_boundary/error_boundary.js +1 -1
- package/es/components/filter_group/filter_select_item.js +31 -15
- package/es/components/filter_group/filter_select_item.styles.js +19 -0
- package/es/components/form/range/range_highlight.js +1 -0
- package/es/components/header/header_section/header_section_item_button.js +94 -0
- package/es/components/highlight/highlight.js +6 -6
- package/es/components/index.js +1 -0
- package/es/components/inline_edit/inline_edit_form.js +2 -53
- package/es/components/inner_text/index.js +1 -2
- package/es/components/markdown_editor/markdown_actions.js +1 -1
- package/es/components/markdown_editor/markdown_editor.js +2 -2
- package/es/components/markdown_editor/markdown_editor_text_area.js +10 -4
- package/es/components/modal/confirm_modal.js +11 -29
- package/es/components/outside_click_detector/outside_click_detector.js +10 -11
- package/es/components/page/page_template.js +8 -8
- package/es/components/popover/wrapping_popover.js +1 -9
- package/es/components/portal/portal.js +33 -24
- package/es/components/tabs/tabs.js +25 -0
- package/es/components/timeline/timeline_item_icon.js +3 -3
- package/es/components/tour/tour_step.js +11 -13
- package/es/services/color/eui_palettes.js +7 -1
- package/es/services/color/index.js +1 -1
- package/es/services/index.js +1 -1
- package/es/services/theme/provider.js +7 -0
- package/es/services/time/timer.js +3 -5
- package/es/test/index.d.ts +36 -0
- package/es/test/index.js +2 -1
- package/es/test/react_version.js +71 -0
- package/es/test/rtl/component_helpers.js +1 -1
- package/es/test/rtl/index.js +2 -1
- package/es/test/rtl/render_hook.js +23 -0
- package/es/themes/amsterdam/global_styling/variables/_states.js +13 -16
- package/eui.d.ts +1631 -909
- package/i18ntokens.json +190 -190
- package/lib/components/collapsible_nav_beta/collapsible_nav_beta.js +30 -0
- package/lib/components/collapsible_nav_beta/collapsible_nav_beta.styles.js +23 -0
- package/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_accordion.js +211 -0
- package/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_accordion.styles.js +40 -0
- package/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.js +304 -0
- package/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.styles.js +63 -0
- package/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_link.js +100 -0
- package/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_link.styles.js +35 -0
- package/lib/components/collapsible_nav_beta/collapsible_nav_item/index.js +12 -0
- package/lib/components/collapsible_nav_beta/index.js +19 -0
- package/lib/components/color_picker/saturation.js +2 -1
- package/lib/components/combo_box/combo_box_input/combo_box_input.js +7 -1
- package/lib/components/combo_box/combo_box_input/combo_box_pill.js +16 -4
- package/lib/components/combo_box/combo_box_options_list/combo_box_option.js +4 -0
- package/lib/components/combo_box/combo_box_options_list/combo_box_options_list.js +21 -3
- package/lib/components/combo_box/combo_box_options_list/combo_box_title.js +1 -3
- package/lib/components/datagrid/body/data_grid_body.js +7 -7
- package/lib/components/datagrid/body/data_grid_body_custom.js +7 -7
- package/lib/components/datagrid/body/data_grid_body_virtualized.js +7 -7
- package/lib/components/datagrid/body/data_grid_cell.js +14 -13
- package/lib/components/datagrid/body/header/data_grid_control_header_cell.js +2 -2
- package/lib/components/datagrid/body/header/data_grid_header_cell.js +1 -1
- package/lib/components/datagrid/body/header/data_grid_header_row.js +5 -5
- package/lib/components/datagrid/controls/data_grid_toolbar.js +41 -38
- package/lib/components/datagrid/controls/display_selector.js +2 -1
- package/lib/components/datagrid/data_grid.js +7 -7
- package/lib/components/datagrid/utils/in_memory.js +4 -4
- package/lib/components/datagrid/utils/row_heights.js +4 -4
- package/lib/components/date_picker/date_picker.js +1 -1
- package/lib/components/drag_and_drop/drag_drop_context.js +2 -2
- package/lib/components/drag_and_drop/draggable.js +3 -3
- package/lib/components/drag_and_drop/droppable.js +2 -2
- package/lib/components/error_boundary/error_boundary.js +1 -1
- package/lib/components/filter_group/filter_select_item.js +33 -17
- package/lib/components/filter_group/filter_select_item.styles.js +26 -0
- package/lib/components/form/range/range_highlight.js +1 -0
- package/lib/components/header/header_section/header_section_item_button.js +94 -0
- package/lib/components/highlight/highlight.js +6 -6
- package/lib/components/index.js +11 -0
- package/lib/components/inline_edit/inline_edit_form.js +2 -53
- package/lib/components/inner_text/index.js +1 -8
- package/lib/components/markdown_editor/markdown_actions.js +1 -1
- package/lib/components/markdown_editor/markdown_editor.js +2 -2
- package/lib/components/markdown_editor/markdown_editor_text_area.js +10 -4
- package/lib/components/modal/confirm_modal.js +10 -28
- package/lib/components/outside_click_detector/outside_click_detector.js +10 -11
- package/lib/components/page/page_template.js +8 -8
- package/lib/components/popover/wrapping_popover.js +1 -9
- package/lib/components/portal/portal.js +33 -24
- package/lib/components/tabs/tabs.js +25 -0
- package/lib/components/timeline/timeline_item_icon.js +6 -3
- package/lib/components/tour/tour_step.js +10 -12
- package/lib/services/color/eui_palettes.js +9 -2
- package/lib/services/color/index.js +7 -0
- package/lib/services/index.js +7 -0
- package/lib/services/theme/provider.js +10 -1
- package/lib/services/time/timer.js +3 -5
- package/lib/test/index.d.ts +36 -0
- package/lib/test/index.js +12 -0
- package/lib/test/react_version.js +84 -0
- package/lib/test/rtl/component_helpers.js +1 -1
- package/lib/test/rtl/index.js +13 -1
- package/lib/test/rtl/render_hook.js +29 -0
- package/lib/themes/amsterdam/global_styling/variables/_states.js +13 -16
- package/optimize/es/components/collapsible_nav_beta/collapsible_nav_beta.js +26 -0
- package/optimize/es/components/collapsible_nav_beta/collapsible_nav_beta.styles.js +16 -0
- package/optimize/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_accordion.js +113 -0
- package/optimize/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_accordion.styles.js +33 -0
- package/optimize/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.js +117 -0
- package/optimize/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.styles.js +55 -0
- package/optimize/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_link.js +59 -0
- package/optimize/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_link.styles.js +28 -0
- package/optimize/es/components/collapsible_nav_beta/collapsible_nav_item/index.js +9 -0
- package/optimize/es/components/collapsible_nav_beta/index.js +15 -0
- package/optimize/es/components/color_picker/saturation.js +2 -1
- package/optimize/es/components/combo_box/combo_box_input/combo_box_input.js +3 -1
- package/optimize/es/components/combo_box/combo_box_input/combo_box_pill.js +12 -4
- package/optimize/es/components/combo_box/combo_box_options_list/combo_box_options_list.js +9 -3
- package/optimize/es/components/datagrid/body/data_grid_cell.js +10 -9
- package/optimize/es/components/datagrid/controls/data_grid_toolbar.js +31 -26
- package/optimize/es/components/datagrid/controls/display_selector.js +2 -1
- package/optimize/es/components/datagrid/utils/in_memory.js +2 -2
- package/optimize/es/components/datagrid/utils/row_heights.js +4 -4
- package/optimize/es/components/date_picker/date_picker.js +1 -1
- package/optimize/es/components/drag_and_drop/drag_drop_context.js +1 -1
- package/optimize/es/components/drag_and_drop/draggable.js +2 -2
- package/optimize/es/components/drag_and_drop/droppable.js +1 -1
- package/optimize/es/components/drag_and_drop/index.js +3 -2
- package/optimize/es/components/error_boundary/error_boundary.js +1 -1
- package/optimize/es/components/filter_group/filter_select_item.js +30 -14
- package/optimize/es/components/filter_group/filter_select_item.styles.js +19 -0
- package/optimize/es/components/form/range/range_highlight.js +1 -0
- package/optimize/es/components/highlight/highlight.js +6 -6
- package/optimize/es/components/index.js +1 -0
- package/optimize/es/components/inline_edit/inline_edit_form.js +2 -1
- package/optimize/es/components/inner_text/index.js +1 -2
- package/optimize/es/components/markdown_editor/markdown_actions.js +1 -1
- package/optimize/es/components/markdown_editor/markdown_editor.js +2 -2
- package/optimize/es/components/markdown_editor/markdown_editor_text_area.js +10 -4
- package/optimize/es/components/modal/confirm_modal.js +11 -24
- package/optimize/es/components/outside_click_detector/outside_click_detector.js +10 -11
- package/optimize/es/components/popover/wrapping_popover.js +1 -9
- package/optimize/es/components/portal/portal.js +33 -25
- package/optimize/es/components/timeline/timeline_item_icon.js +3 -3
- package/optimize/es/components/tour/tour_step.js +11 -13
- package/optimize/es/services/color/eui_palettes.js +7 -1
- package/optimize/es/services/color/index.js +1 -1
- package/optimize/es/services/index.js +1 -1
- package/optimize/es/services/theme/provider.js +7 -0
- package/optimize/es/services/time/timer.js +3 -5
- package/optimize/es/test/index.d.ts +36 -0
- package/optimize/es/test/index.js +2 -1
- package/optimize/es/test/react_version.js +71 -0
- package/optimize/es/test/rtl/component_helpers.js +1 -1
- package/optimize/es/test/rtl/index.js +2 -1
- package/optimize/es/test/rtl/render_hook.js +23 -0
- package/optimize/es/themes/amsterdam/global_styling/variables/_states.js +13 -16
- package/optimize/lib/components/collapsible_nav_beta/collapsible_nav_beta.js +33 -0
- package/optimize/lib/components/collapsible_nav_beta/collapsible_nav_beta.styles.js +23 -0
- package/optimize/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_accordion.js +123 -0
- package/optimize/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_accordion.styles.js +40 -0
- package/optimize/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.js +124 -0
- package/optimize/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.styles.js +61 -0
- package/optimize/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_link.js +66 -0
- package/optimize/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_link.styles.js +35 -0
- package/optimize/lib/components/collapsible_nav_beta/collapsible_nav_item/index.js +12 -0
- package/optimize/lib/components/collapsible_nav_beta/index.js +19 -0
- package/optimize/lib/components/color_picker/saturation.js +2 -1
- package/optimize/lib/components/combo_box/combo_box_input/combo_box_input.js +3 -1
- package/optimize/lib/components/combo_box/combo_box_input/combo_box_pill.js +12 -4
- package/optimize/lib/components/combo_box/combo_box_options_list/combo_box_options_list.js +9 -3
- package/optimize/lib/components/datagrid/body/data_grid_cell.js +10 -9
- package/optimize/lib/components/datagrid/controls/data_grid_toolbar.js +36 -28
- package/optimize/lib/components/datagrid/controls/display_selector.js +2 -1
- package/optimize/lib/components/datagrid/utils/in_memory.js +2 -2
- package/optimize/lib/components/datagrid/utils/row_heights.js +4 -4
- package/optimize/lib/components/date_picker/date_picker.js +1 -1
- package/optimize/lib/components/drag_and_drop/drag_drop_context.js +2 -2
- package/optimize/lib/components/drag_and_drop/draggable.js +3 -3
- package/optimize/lib/components/drag_and_drop/droppable.js +2 -2
- package/optimize/lib/components/error_boundary/error_boundary.js +1 -1
- package/optimize/lib/components/filter_group/filter_select_item.js +32 -16
- package/optimize/lib/components/filter_group/filter_select_item.styles.js +26 -0
- package/optimize/lib/components/form/range/range_highlight.js +1 -0
- package/optimize/lib/components/highlight/highlight.js +6 -6
- package/optimize/lib/components/index.js +11 -0
- package/optimize/lib/components/inline_edit/inline_edit_form.js +2 -1
- package/optimize/lib/components/inner_text/index.js +1 -8
- package/optimize/lib/components/markdown_editor/markdown_actions.js +1 -1
- package/optimize/lib/components/markdown_editor/markdown_editor.js +2 -2
- package/optimize/lib/components/markdown_editor/markdown_editor_text_area.js +10 -4
- package/optimize/lib/components/modal/confirm_modal.js +10 -23
- package/optimize/lib/components/outside_click_detector/outside_click_detector.js +10 -11
- package/optimize/lib/components/popover/wrapping_popover.js +1 -9
- package/optimize/lib/components/portal/portal.js +33 -25
- package/optimize/lib/components/timeline/timeline_item_icon.js +6 -4
- package/optimize/lib/components/tour/tour_step.js +10 -12
- package/optimize/lib/services/color/eui_palettes.js +9 -2
- package/optimize/lib/services/color/index.js +7 -0
- package/optimize/lib/services/index.js +7 -0
- package/optimize/lib/services/theme/provider.js +10 -1
- package/optimize/lib/services/time/timer.js +3 -5
- package/optimize/lib/test/index.d.ts +36 -0
- package/optimize/lib/test/index.js +12 -0
- package/optimize/lib/test/react_version.js +84 -0
- package/optimize/lib/test/rtl/component_helpers.js +1 -1
- package/optimize/lib/test/rtl/index.js +13 -1
- package/optimize/lib/test/rtl/render_hook.js +29 -0
- package/optimize/lib/themes/amsterdam/global_styling/variables/_states.js +13 -16
- package/package.json +23 -16
- package/src/components/combo_box/combo_box_input/_combo_box_pill.scss +24 -3
- package/src/components/combo_box/combo_box_options_list/_combo_box_option.scss +34 -14
- package/src/components/index.scss +0 -1
- package/test-env/components/collapsible_nav_beta/collapsible_nav_beta.js +33 -0
- package/test-env/components/collapsible_nav_beta/collapsible_nav_beta.styles.js +23 -0
- package/test-env/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_accordion.js +208 -0
- package/test-env/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_accordion.styles.js +40 -0
- package/test-env/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.js +303 -0
- package/test-env/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.styles.js +61 -0
- package/test-env/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_link.js +96 -0
- package/test-env/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_link.styles.js +35 -0
- package/test-env/components/collapsible_nav_beta/collapsible_nav_item/index.js +12 -0
- package/test-env/components/collapsible_nav_beta/index.js +19 -0
- package/test-env/components/color_picker/saturation.js +2 -1
- package/test-env/components/combo_box/combo_box_input/combo_box_input.js +7 -1
- package/test-env/components/combo_box/combo_box_input/combo_box_pill.js +16 -4
- package/test-env/components/combo_box/combo_box_options_list/combo_box_option.js +4 -0
- package/test-env/components/combo_box/combo_box_options_list/combo_box_options_list.js +21 -3
- package/test-env/components/combo_box/combo_box_options_list/combo_box_title.js +1 -3
- package/test-env/components/datagrid/body/data_grid_body.js +7 -7
- package/test-env/components/datagrid/body/data_grid_body_custom.js +7 -7
- package/test-env/components/datagrid/body/data_grid_body_virtualized.js +7 -7
- package/test-env/components/datagrid/body/data_grid_cell.js +14 -13
- package/test-env/components/datagrid/body/header/data_grid_control_header_cell.js +2 -2
- package/test-env/components/datagrid/body/header/data_grid_header_cell.js +1 -1
- package/test-env/components/datagrid/body/header/data_grid_header_row.js +5 -5
- package/test-env/components/datagrid/controls/data_grid_toolbar.js +36 -28
- package/test-env/components/datagrid/controls/display_selector.js +2 -1
- package/test-env/components/datagrid/data_grid.js +7 -7
- package/test-env/components/datagrid/utils/in_memory.js +4 -4
- package/test-env/components/datagrid/utils/row_heights.js +4 -4
- package/test-env/components/date_picker/date_picker.js +1 -1
- package/test-env/components/drag_and_drop/drag_drop_context.js +2 -2
- package/test-env/components/drag_and_drop/draggable.js +3 -3
- package/test-env/components/drag_and_drop/droppable.js +2 -2
- package/test-env/components/error_boundary/error_boundary.js +1 -1
- package/test-env/components/filter_group/filter_select_item.js +33 -17
- package/test-env/components/filter_group/filter_select_item.styles.js +26 -0
- package/test-env/components/form/range/range_highlight.js +1 -0
- package/test-env/components/header/header_section/header_section_item_button.js +94 -0
- package/test-env/components/highlight/highlight.js +6 -6
- package/test-env/components/index.js +11 -0
- package/test-env/components/inline_edit/inline_edit_form.js +2 -53
- package/test-env/components/inner_text/index.js +1 -8
- package/test-env/components/markdown_editor/markdown_actions.js +1 -1
- package/test-env/components/markdown_editor/markdown_editor.js +2 -2
- package/test-env/components/markdown_editor/markdown_editor_text_area.js +10 -4
- package/test-env/components/modal/confirm_modal.js +10 -23
- package/test-env/components/outside_click_detector/outside_click_detector.js +10 -11
- package/test-env/components/page/page_template.js +8 -8
- package/test-env/components/popover/wrapping_popover.js +1 -9
- package/test-env/components/portal/portal.js +33 -25
- package/test-env/components/tabs/tabs.js +25 -0
- package/test-env/components/timeline/timeline_item_icon.js +6 -3
- package/test-env/components/tour/tour_step.js +10 -12
- package/test-env/services/color/eui_palettes.js +9 -2
- package/test-env/services/color/index.js +7 -0
- package/test-env/services/index.js +7 -0
- package/test-env/services/theme/provider.js +10 -1
- package/test-env/services/time/timer.js +3 -5
- package/test-env/test/index.js +12 -0
- package/test-env/test/react_version.js +84 -0
- package/test-env/test/rtl/component_helpers.js +1 -1
- package/test-env/test/rtl/index.js +13 -1
- package/test-env/test/rtl/render_hook.js +29 -0
- package/test-env/themes/amsterdam/global_styling/variables/_states.js +13 -16
- package/es/components/inner_text/render_to_text.js +0 -47
- package/lib/components/inner_text/render_to_text.js +0 -54
- package/optimize/es/components/inner_text/render_to_text.js +0 -42
- package/optimize/lib/components/inner_text/render_to_text.js +0 -52
- package/src/components/filter_group/_filter_select_item.scss +0 -43
- package/src/components/filter_group/_index.scss +0 -1
- package/test-env/components/inner_text/render_to_text.js +0 -52
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
|
|
3
|
+
* or more contributor license agreements. Licensed under the Elastic License
|
|
4
|
+
* 2.0 and the Server Side Public License, v 1; you may not use this file except
|
|
5
|
+
* in compliance with, at your election, the Elastic License 2.0 or the Server
|
|
6
|
+
* Side Public License, v 1.
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* NOTE: This is currently still a beta component, being exported for Kibana
|
|
11
|
+
* development usage. It is not yet fully documented or supported.
|
|
12
|
+
*/
|
|
13
|
+
|
|
14
|
+
export { EuiCollapsibleNavBeta } from './collapsible_nav_beta';
|
|
15
|
+
export { EuiCollapsibleNavItem } from './collapsible_nav_item';
|
|
@@ -20,10 +20,11 @@ import { isNil } from '../../services/predicate';
|
|
|
20
20
|
import { useEuiI18n } from '../i18n';
|
|
21
21
|
import { getEventPosition } from './utils';
|
|
22
22
|
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
23
|
+
var colorDefaultValue = [1, 0, 0];
|
|
23
24
|
export var EuiSaturation = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
24
25
|
var className = _ref.className,
|
|
25
26
|
_ref$color = _ref.color,
|
|
26
|
-
color = _ref$color === void 0 ?
|
|
27
|
+
color = _ref$color === void 0 ? colorDefaultValue : _ref$color,
|
|
27
28
|
_ref$dataTestSubj = _ref['data-test-subj'],
|
|
28
29
|
dataTestSubj = _ref$dataTestSubj === void 0 ? 'euiSaturation' : _ref$dataTestSubj,
|
|
29
30
|
hex = _ref.hex,
|
|
@@ -8,7 +8,7 @@ import _inherits from "@babel/runtime/helpers/inherits";
|
|
|
8
8
|
import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
|
|
9
9
|
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
10
10
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
11
|
-
var _excluded = ["key", "label", "color", "onClick"];
|
|
11
|
+
var _excluded = ["key", "label", "color", "onClick", "append", "prepend"];
|
|
12
12
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
13
13
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
14
14
|
/*
|
|
@@ -146,6 +146,8 @@ export var EuiComboBoxInput = /*#__PURE__*/function (_Component) {
|
|
|
146
146
|
label = option.label,
|
|
147
147
|
color = option.color,
|
|
148
148
|
onClick = option.onClick,
|
|
149
|
+
append = option.append,
|
|
150
|
+
prepend = option.prepend,
|
|
149
151
|
rest = _objectWithoutProperties(option, _excluded);
|
|
150
152
|
var pillOnClose = isDisabled || singleSelection || onClick ? undefined : onRemoveOption;
|
|
151
153
|
return ___EmotionJSX(EuiComboBoxPill, _extends({
|
|
@@ -64,6 +64,11 @@ export var EuiComboBoxPill = /*#__PURE__*/function (_Component) {
|
|
|
64
64
|
onClick: onClick,
|
|
65
65
|
onClickAriaLabel: onClickAriaLabel
|
|
66
66
|
} : {};
|
|
67
|
+
var content = ___EmotionJSX(React.Fragment, null, option.prepend && ___EmotionJSX("span", {
|
|
68
|
+
className: "euiComboBoxPill__prepend"
|
|
69
|
+
}, option.prepend), children, option.append && ___EmotionJSX("span", {
|
|
70
|
+
className: "euiComboBoxPill__append"
|
|
71
|
+
}, option.append));
|
|
67
72
|
if (onClose) {
|
|
68
73
|
return ___EmotionJSX(EuiI18n, {
|
|
69
74
|
token: "euiComboBoxPill.removeSelection",
|
|
@@ -75,24 +80,27 @@ export var EuiComboBoxPill = /*#__PURE__*/function (_Component) {
|
|
|
75
80
|
return ___EmotionJSX(EuiBadge, _extends({
|
|
76
81
|
className: classes,
|
|
77
82
|
color: color,
|
|
83
|
+
"data-test-subj": "euiComboBoxPill",
|
|
78
84
|
iconOnClick: _this2.onCloseButtonClick,
|
|
79
85
|
iconOnClickAriaLabel: removeSelection,
|
|
80
86
|
iconSide: "right",
|
|
81
87
|
iconType: "cross",
|
|
82
88
|
title: children
|
|
83
|
-
}, onClickProps, rest),
|
|
89
|
+
}, onClickProps, rest), content);
|
|
84
90
|
});
|
|
85
91
|
}
|
|
86
92
|
if (asPlainText) {
|
|
87
93
|
return ___EmotionJSX("span", _extends({
|
|
88
|
-
className: classes
|
|
89
|
-
|
|
94
|
+
className: classes,
|
|
95
|
+
"data-test-subj": "euiComboBoxPill"
|
|
96
|
+
}, rest), content);
|
|
90
97
|
}
|
|
91
98
|
return ___EmotionJSX(EuiBadge, _extends({
|
|
92
99
|
className: classes,
|
|
93
100
|
color: color,
|
|
101
|
+
"data-test-subj": "euiComboBoxPill",
|
|
94
102
|
title: children
|
|
95
|
-
}, rest, onClickProps),
|
|
103
|
+
}, rest, onClickProps), content);
|
|
96
104
|
}
|
|
97
105
|
}]);
|
|
98
106
|
return EuiComboBoxPill;
|
|
@@ -7,7 +7,7 @@ import _inherits from "@babel/runtime/helpers/inherits";
|
|
|
7
7
|
import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
|
|
8
8
|
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
9
9
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
10
|
-
var _excluded = ["key", "isGroupLabelOption", "label", "value"],
|
|
10
|
+
var _excluded = ["key", "isGroupLabelOption", "label", "value", "prepend", "append"],
|
|
11
11
|
_excluded2 = ["data-test-subj", "activeOptionIndex", "areAllOptionsSelected", "customOptionText", "fullWidth", "getSelectedOptionForSearchValue", "isCaseSensitive", "isLoading", "listRef", "matchingOptions", "onCloseList", "onCreateOption", "onOptionClick", "onOptionEnterKey", "onScroll", "optionRef", "options", "position", "renderOption", "rootId", "rowHeight", "scrollToIndex", "searchValue", "selectedOptions", "singleSelection", "updatePosition", "width", "delimiter", "zIndex", "style", "listboxAriaLabel"];
|
|
12
12
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
13
13
|
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
@@ -93,6 +93,8 @@ export var EuiComboBoxOptionsList = /*#__PURE__*/function (_Component) {
|
|
|
93
93
|
isGroupLabelOption = option.isGroupLabelOption,
|
|
94
94
|
label = option.label,
|
|
95
95
|
value = option.value,
|
|
96
|
+
prepend = option.prepend,
|
|
97
|
+
append = option.append,
|
|
96
98
|
rest = _objectWithoutProperties(option, _excluded);
|
|
97
99
|
var _this$props = _this.props,
|
|
98
100
|
singleSelection = _this$props.singleSelection,
|
|
@@ -131,13 +133,17 @@ export var EuiComboBoxOptionsList = /*#__PURE__*/function (_Component) {
|
|
|
131
133
|
title: label
|
|
132
134
|
}, rest), ___EmotionJSX("span", {
|
|
133
135
|
className: "euiComboBoxOption__contentWrapper"
|
|
134
|
-
},
|
|
136
|
+
}, prepend && ___EmotionJSX("span", {
|
|
137
|
+
className: "euiComboBoxOption__prepend"
|
|
138
|
+
}, prepend), renderOption ? ___EmotionJSX("span", {
|
|
135
139
|
className: OPTION_CONTENT_CLASSNAME
|
|
136
140
|
}, renderOption(option, searchValue, 'euiComboBoxOption__renderOption')) : ___EmotionJSX(EuiHighlight, {
|
|
137
141
|
search: searchValue,
|
|
138
142
|
strict: _this.props.isCaseSensitive,
|
|
139
143
|
className: OPTION_CONTENT_CLASSNAME
|
|
140
|
-
}, label),
|
|
144
|
+
}, label), append && ___EmotionJSX("span", {
|
|
145
|
+
className: "euiComboBoxOption__append"
|
|
146
|
+
}, append), optionIsFocused && !optionIsDisabled ? hitEnterBadge : null));
|
|
141
147
|
});
|
|
142
148
|
return _this;
|
|
143
149
|
}
|
|
@@ -314,15 +314,7 @@ export var EuiDataGridCell = /*#__PURE__*/function (_Component) {
|
|
|
314
314
|
}
|
|
315
315
|
});
|
|
316
316
|
return _this;
|
|
317
|
-
}
|
|
318
|
-
// the parent grid owns which cell is focused,
|
|
319
|
-
// but individual cells need to react to changes and also report that
|
|
320
|
-
// they are focused in response to user actions like clicking on the cell
|
|
321
|
-
// to avoid focus trap fighting, cells wait a tick after being clicked to allow
|
|
322
|
-
// any existing traps to disconnect before the cell reports the new focus state to the parent grid
|
|
323
|
-
// but because of this small delay, multiple cells could queue up focus and
|
|
324
|
-
// create an infinite loop as the cells activate->deactivate->...
|
|
325
|
-
// so we track the last timeout id and clear that request if superseded
|
|
317
|
+
}
|
|
326
318
|
_createClass(EuiDataGridCell, [{
|
|
327
319
|
key: "componentDidMount",
|
|
328
320
|
value: function componentDidMount() {
|
|
@@ -625,5 +617,14 @@ export var EuiDataGridCell = /*#__PURE__*/function (_Component) {
|
|
|
625
617
|
}]);
|
|
626
618
|
return EuiDataGridCell;
|
|
627
619
|
}(Component);
|
|
620
|
+
// focus tracking is split between the entire grid & individual cells,
|
|
621
|
+
// the parent grid owns which cell is focused,
|
|
622
|
+
// but individual cells need to react to changes and also report that
|
|
623
|
+
// they are focused in response to user actions like clicking on the cell
|
|
624
|
+
// to avoid focus trap fighting, cells wait a tick after being clicked to allow
|
|
625
|
+
// any existing traps to disconnect before the cell reports the new focus state to the parent grid
|
|
626
|
+
// but because of this small delay, multiple cells could queue up focus and
|
|
627
|
+
// create an infinite loop as the cells activate->deactivate->...
|
|
628
|
+
// so we track the last timeout id and clear that request if superseded
|
|
628
629
|
_defineProperty(EuiDataGridCell, "activeFocusTimeoutId", undefined);
|
|
629
630
|
_defineProperty(EuiDataGridCell, "contextType", DataGridFocusContext);
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import _typeof from "@babel/runtime/helpers/typeof";
|
|
1
2
|
/*
|
|
2
3
|
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
|
|
3
4
|
* or more contributor license agreements. Licensed under the Elastic License
|
|
@@ -6,7 +7,7 @@
|
|
|
6
7
|
* Side Public License, v 1.
|
|
7
8
|
*/
|
|
8
9
|
|
|
9
|
-
import React from 'react';
|
|
10
|
+
import React, { isValidElement } from 'react';
|
|
10
11
|
import { EuiScreenReaderOnly } from '../../accessibility';
|
|
11
12
|
import { IS_JEST_ENVIRONMENT } from '../../../utils';
|
|
12
13
|
|
|
@@ -58,40 +59,44 @@ export function checkOrDefaultToolBarDisplayOptions(arg, option) {
|
|
|
58
59
|
return true;
|
|
59
60
|
}
|
|
60
61
|
}
|
|
61
|
-
export function renderAdditionalControls(toolbarVisibility, position) {
|
|
62
|
-
var _additionalControlsOb;
|
|
62
|
+
export var renderAdditionalControls = function renderAdditionalControls(toolbarVisibility, position) {
|
|
63
63
|
if (typeof toolbarVisibility === 'boolean') return null;
|
|
64
64
|
var _ref2 = toolbarVisibility || {},
|
|
65
65
|
additionalControls = _ref2.additionalControls;
|
|
66
66
|
if (!additionalControls) return null;
|
|
67
67
|
|
|
68
|
-
//
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
68
|
+
// API backwards compatability: if the consumer passed a single ReactNode
|
|
69
|
+
// to `additionalControls`, default to the left append position.
|
|
70
|
+
if ( /*#__PURE__*/isValidElement(additionalControls) && position === 'left.append') {
|
|
71
|
+
return additionalControls;
|
|
72
|
+
}
|
|
73
|
+
if (_typeof(additionalControls) !== 'object') {
|
|
74
|
+
return null;
|
|
75
|
+
}
|
|
76
|
+
var handleLeftObjectConfig = function handleLeftObjectConfig(leftConfig) {
|
|
77
|
+
if (position === 'left.prepend') {
|
|
78
|
+
return leftConfig.prepend;
|
|
75
79
|
}
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
return leftPositionObj.prepend;
|
|
80
|
+
if (position === 'left.append') {
|
|
81
|
+
return leftConfig.append;
|
|
79
82
|
}
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
|
|
83
|
+
};
|
|
84
|
+
var handleObjectConfig = function handleObjectConfig(additionalControls) {
|
|
85
|
+
if (position === 'right') {
|
|
86
|
+
return additionalControls.right;
|
|
83
87
|
}
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
88
|
+
// API backwards compatability: If the consumer passed a single ReactNode
|
|
89
|
+
// to `additionalControls.left`, default to the left append position
|
|
90
|
+
if ( /*#__PURE__*/isValidElement(additionalControls.left) && position === 'left.append') {
|
|
91
|
+
return additionalControls.left;
|
|
87
92
|
}
|
|
88
|
-
if (
|
|
89
|
-
|
|
90
|
-
return additionalControls;
|
|
93
|
+
if (additionalControls.left && _typeof(additionalControls.left) === 'object') {
|
|
94
|
+
return handleLeftObjectConfig(additionalControls.left);
|
|
91
95
|
}
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
|
|
96
|
+
};
|
|
97
|
+
var rendered = handleObjectConfig(additionalControls);
|
|
98
|
+
return rendered || null;
|
|
99
|
+
};
|
|
95
100
|
|
|
96
101
|
/**
|
|
97
102
|
* Utility helper for selectors/controls that allow nested options
|
|
@@ -101,7 +106,7 @@ export function renderAdditionalControls(toolbarVisibility, position) {
|
|
|
101
106
|
export function getNestedObjectOptions(controlOption, objectKey) {
|
|
102
107
|
var _controlOption$object;
|
|
103
108
|
// If the config is a boolean, nested options follow that boolean
|
|
104
|
-
if (
|
|
109
|
+
if (typeof controlOption === 'boolean') return controlOption;
|
|
105
110
|
// If config is not defined, default to enabled
|
|
106
111
|
if (controlOption == null) return true;
|
|
107
112
|
// Otherwise, type should be an object of boolean values - dive into it and return the value
|
|
@@ -124,7 +124,8 @@ export var useDataGridDisplaySelector = function useDataGridDisplaySelector(show
|
|
|
124
124
|
setUserRowHeightsOptions(rowHeightsOptions);
|
|
125
125
|
}, [lineCount]);
|
|
126
126
|
var setLineCountHeight = useCallback(function (event) {
|
|
127
|
-
|
|
127
|
+
if (!event.currentTarget) return;
|
|
128
|
+
var newLineCount = Number(event.currentTarget.value);
|
|
128
129
|
if (newLineCount < 1) return; // Don't let users set a 0 or negative line count
|
|
129
130
|
|
|
130
131
|
setLineCount(newLineCount);
|
|
@@ -144,9 +144,9 @@ export var EuiDataGridInMemoryRenderer = function EuiDataGridInMemoryRenderer(_r
|
|
|
144
144
|
var cellDivs = documentFragment.childNodes[0].childNodes;
|
|
145
145
|
for (var i = 0; i < cellDivs.length; i++) {
|
|
146
146
|
var cellDiv = cellDivs[i];
|
|
147
|
-
var
|
|
147
|
+
var rowIndex = parseInt(cellDiv.getAttribute('data-dg-row'), 10);
|
|
148
148
|
var column = cellDiv.getAttribute('data-dg-column');
|
|
149
|
-
onCellRender(
|
|
149
|
+
onCellRender(rowIndex, column, getElementText(cellDiv));
|
|
150
150
|
}
|
|
151
151
|
// changes to documentFragment.children is reflected by `cells`
|
|
152
152
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
@@ -197,15 +197,15 @@ export var RowHeightVirtualizationUtils = /*#__PURE__*/function (_RowHeightUtils
|
|
|
197
197
|
var _this2;
|
|
198
198
|
_classCallCheck(this, RowHeightVirtualizationUtils);
|
|
199
199
|
_this2 = _super.call(this);
|
|
200
|
-
_this2.gridRef = gridRef;
|
|
201
|
-
_this2.outerGridElementRef = outerGridElementRef;
|
|
202
|
-
_this2.gridItemsRenderedRef = gridItemsRenderedRef;
|
|
203
|
-
_this2.rerenderGridBodyRef = rerenderGridBodyRef;
|
|
204
200
|
/**
|
|
205
201
|
* Virtualization workarounds for auto height rows
|
|
206
202
|
*/
|
|
207
203
|
_defineProperty(_assertThisInitialized(_this2), "timerId", void 0);
|
|
208
204
|
_defineProperty(_assertThisInitialized(_this2), "lastUpdatedRow", Infinity);
|
|
205
|
+
_this2.gridRef = gridRef;
|
|
206
|
+
_this2.outerGridElementRef = outerGridElementRef;
|
|
207
|
+
_this2.gridItemsRenderedRef = gridItemsRenderedRef;
|
|
208
|
+
_this2.rerenderGridBodyRef = rerenderGridBodyRef;
|
|
209
209
|
return _this2;
|
|
210
210
|
}
|
|
211
211
|
_createClass(RowHeightVirtualizationUtils, [{
|
|
@@ -135,7 +135,7 @@ export var EuiDatePicker = function EuiDatePicker(_ref) {
|
|
|
135
135
|
inputValidityRef = _useState2[0],
|
|
136
136
|
_setInputValidityRef = _useState2[1];
|
|
137
137
|
var setInputValidityRef = useCallback(function (ref) {
|
|
138
|
-
_setInputValidityRef(ref === null || ref === void 0 ? void 0 : ref.input);
|
|
138
|
+
_setInputValidityRef((ref === null || ref === void 0 ? void 0 : ref.input) || null);
|
|
139
139
|
}, []);
|
|
140
140
|
useEuiValidatableControl({
|
|
141
141
|
isInvalid: isInvalid,
|
|
@@ -11,7 +11,7 @@ var _excluded = ["onBeforeDragStart", "onDragStart", "onDragUpdate", "onDragEnd"
|
|
|
11
11
|
*/
|
|
12
12
|
|
|
13
13
|
import React, { useState, createContext } from 'react';
|
|
14
|
-
import { DragDropContext } from '
|
|
14
|
+
import { DragDropContext } from '@hello-pangea/dnd';
|
|
15
15
|
|
|
16
16
|
// export interface EuiDragDropContextProps extends DragDropContextProps {}
|
|
17
17
|
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
@@ -13,7 +13,7 @@ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { va
|
|
|
13
13
|
*/
|
|
14
14
|
|
|
15
15
|
import React, { Fragment, cloneElement, useContext } from 'react';
|
|
16
|
-
import { Draggable } from '
|
|
16
|
+
import { Draggable } from '@hello-pangea/dnd';
|
|
17
17
|
import classNames from 'classnames';
|
|
18
18
|
import { EuiDroppableContext } from './droppable';
|
|
19
19
|
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
@@ -62,7 +62,7 @@ export var EuiDraggable = function EuiDraggable(_ref) {
|
|
|
62
62
|
'euiDraggable__item--isDragging': snapshot.isDragging,
|
|
63
63
|
'euiDraggable__item--isDropAnimating': snapshot.isDropAnimating
|
|
64
64
|
});
|
|
65
|
-
var DraggableElement = typeof children === 'function' ? children(provided, snapshot, rubric) : children;
|
|
65
|
+
var DraggableElement = typeof children === 'function' ? children(provided, snapshot, rubric) : children;
|
|
66
66
|
return ___EmotionJSX(Fragment, null, ___EmotionJSX("div", _extends({}, provided.draggableProps, !customDragHandle ? provided.dragHandleProps : {}, {
|
|
67
67
|
ref: provided.innerRef,
|
|
68
68
|
"data-test-subj": dataTestSubj,
|
|
@@ -10,7 +10,7 @@ var _excluded = ["droppableId", "direction", "isDropDisabled", "children", "clas
|
|
|
10
10
|
*/
|
|
11
11
|
|
|
12
12
|
import React, { useContext } from 'react';
|
|
13
|
-
import { Droppable } from '
|
|
13
|
+
import { Droppable } from '@hello-pangea/dnd';
|
|
14
14
|
import classNames from 'classnames';
|
|
15
15
|
import { EuiDragDropContextContext } from './drag_drop_context';
|
|
16
16
|
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
@@ -11,5 +11,6 @@ export { EuiDraggable } from './draggable';
|
|
|
11
11
|
export { EuiDroppable } from './droppable';
|
|
12
12
|
export { euiDragDropCopy, euiDragDropMove, euiDragDropReorder } from './services';
|
|
13
13
|
|
|
14
|
-
// Interfaces in react-beautiful-dnd that EUI
|
|
15
|
-
// allows consumers to pull these from EUI
|
|
14
|
+
// Interfaces in @hello-pangea/dnd (a fork of react-beautiful-dnd) that EUI
|
|
15
|
+
// abstracts over allows consumers to pull these from EUI
|
|
16
|
+
// instead of @hello-pangea/dnd
|
|
@@ -49,7 +49,7 @@ export var EuiErrorBoundary = /*#__PURE__*/function (_Component) {
|
|
|
49
49
|
var message = error.message,
|
|
50
50
|
stack = error.stack;
|
|
51
51
|
var idx = (stack === null || stack === void 0 ? void 0 : stack.indexOf(message)) || -1;
|
|
52
|
-
var stackStr = idx > -1 ? stack === null || stack === void 0 ? void 0 : stack.
|
|
52
|
+
var stackStr = idx > -1 ? stack === null || stack === void 0 ? void 0 : stack.substring(idx + message.length + 1) : stack;
|
|
53
53
|
var errorMessage = "Error: ".concat(message, "\n").concat(stackStr);
|
|
54
54
|
this.setState({
|
|
55
55
|
hasError: true,
|
|
@@ -7,7 +7,7 @@ import _inherits from "@babel/runtime/helpers/inherits";
|
|
|
7
7
|
import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
|
|
8
8
|
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
9
9
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
10
|
-
var _excluded = ["children", "className", "disabled", "checked", "isFocused", "showIcons"];
|
|
10
|
+
var _excluded = ["theme", "children", "className", "disabled", "checked", "isFocused", "showIcons"];
|
|
11
11
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
12
12
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
13
13
|
/*
|
|
@@ -20,8 +20,10 @@ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Re
|
|
|
20
20
|
|
|
21
21
|
import React, { Component } from 'react';
|
|
22
22
|
import classNames from 'classnames';
|
|
23
|
+
import { withEuiTheme } from '../../services';
|
|
23
24
|
import { EuiFlexGroup, EuiFlexItem } from '../flex';
|
|
24
25
|
import { EuiIcon } from '../icon';
|
|
26
|
+
import { euiFilterSelectItemStyles } from './filter_select_item.styles';
|
|
25
27
|
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
26
28
|
var resolveIconAndColor = function resolveIconAndColor(checked) {
|
|
27
29
|
if (!checked) {
|
|
@@ -37,12 +39,19 @@ var resolveIconAndColor = function resolveIconAndColor(checked) {
|
|
|
37
39
|
color: 'text'
|
|
38
40
|
};
|
|
39
41
|
};
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
42
|
+
|
|
43
|
+
/**
|
|
44
|
+
* TODO: This component should removed in favor of EuiSelectable usage
|
|
45
|
+
* once EuiComboBox has been converted to dogfood EuiSelectable.
|
|
46
|
+
*
|
|
47
|
+
* @deprecated - Use EuiSelectable instead
|
|
48
|
+
*/
|
|
49
|
+
export var EuiFilterSelectItemClass = /*#__PURE__*/function (_Component) {
|
|
50
|
+
_inherits(EuiFilterSelectItemClass, _Component);
|
|
51
|
+
var _super = _createSuper(EuiFilterSelectItemClass);
|
|
52
|
+
function EuiFilterSelectItemClass() {
|
|
44
53
|
var _this;
|
|
45
|
-
_classCallCheck(this,
|
|
54
|
+
_classCallCheck(this, EuiFilterSelectItemClass);
|
|
46
55
|
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
47
56
|
args[_key] = arguments[_key];
|
|
48
57
|
}
|
|
@@ -61,11 +70,12 @@ export var EuiFilterSelectItem = /*#__PURE__*/function (_Component) {
|
|
|
61
70
|
});
|
|
62
71
|
return _this;
|
|
63
72
|
}
|
|
64
|
-
_createClass(
|
|
73
|
+
_createClass(EuiFilterSelectItemClass, [{
|
|
65
74
|
key: "render",
|
|
66
75
|
value: function render() {
|
|
67
76
|
var _this2 = this;
|
|
68
77
|
var _this$props = this.props,
|
|
78
|
+
theme = _this$props.theme,
|
|
69
79
|
children = _this$props.children,
|
|
70
80
|
className = _this$props.className,
|
|
71
81
|
disabled = _this$props.disabled,
|
|
@@ -73,9 +83,9 @@ export var EuiFilterSelectItem = /*#__PURE__*/function (_Component) {
|
|
|
73
83
|
isFocused = _this$props.isFocused,
|
|
74
84
|
showIcons = _this$props.showIcons,
|
|
75
85
|
rest = _objectWithoutProperties(_this$props, _excluded);
|
|
76
|
-
var
|
|
77
|
-
|
|
78
|
-
|
|
86
|
+
var styles = euiFilterSelectItemStyles(theme);
|
|
87
|
+
var cssStyles = [styles.euiFilterSelectItem, isFocused && styles.isFocused];
|
|
88
|
+
var classes = classNames('euiFilterSelectItem', className);
|
|
79
89
|
var iconNode;
|
|
80
90
|
if (showIcons) {
|
|
81
91
|
var _resolveIconAndColor = resolveIconAndColor(checked),
|
|
@@ -96,6 +106,7 @@ export var EuiFilterSelectItem = /*#__PURE__*/function (_Component) {
|
|
|
96
106
|
type: "button",
|
|
97
107
|
"aria-selected": isFocused,
|
|
98
108
|
className: classes,
|
|
109
|
+
css: cssStyles,
|
|
99
110
|
disabled: disabled,
|
|
100
111
|
"aria-disabled": disabled
|
|
101
112
|
}, rest), ___EmotionJSX(EuiFlexGroup, {
|
|
@@ -104,13 +115,18 @@ export var EuiFilterSelectItem = /*#__PURE__*/function (_Component) {
|
|
|
104
115
|
component: "span",
|
|
105
116
|
responsive: false
|
|
106
117
|
}, iconNode, ___EmotionJSX(EuiFlexItem, {
|
|
107
|
-
className: "euiFilterSelectItem__content",
|
|
118
|
+
className: "euiFilterSelectItem__content eui-textTruncate",
|
|
108
119
|
component: "span"
|
|
109
120
|
}, children)));
|
|
110
121
|
}
|
|
111
122
|
}]);
|
|
112
|
-
return
|
|
123
|
+
return EuiFilterSelectItemClass;
|
|
113
124
|
}(Component);
|
|
114
|
-
|
|
125
|
+
|
|
126
|
+
/**
|
|
127
|
+
* @deprecated - Use EuiSelectable instead
|
|
128
|
+
*/
|
|
129
|
+
_defineProperty(EuiFilterSelectItemClass, "defaultProps", {
|
|
115
130
|
showIcons: true
|
|
116
|
-
});
|
|
131
|
+
});
|
|
132
|
+
export var EuiFilterSelectItem = withEuiTheme(EuiFilterSelectItemClass);
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
|
|
3
|
+
* or more contributor license agreements. Licensed under the Elastic License
|
|
4
|
+
* 2.0 and the Server Side Public License, v 1; you may not use this file except
|
|
5
|
+
* in compliance with, at your election, the Elastic License 2.0 or the Server
|
|
6
|
+
* Side Public License, v 1.
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
import { css } from '@emotion/react';
|
|
10
|
+
import { transparentize } from '../../services';
|
|
11
|
+
import { logicalCSS, logicalShorthandCSS, logicalTextAlignCSS, euiFontSize } from '../../global_styling';
|
|
12
|
+
export var euiFilterSelectItemStyles = function euiFilterSelectItemStyles(euiThemeContext) {
|
|
13
|
+
var euiTheme = euiThemeContext.euiTheme;
|
|
14
|
+
var focusStyles = "\n color: ".concat(euiTheme.colors.primary, ";\n background-color: ").concat(euiTheme.focus.backgroundColor, ";\n outline-offset: -").concat(euiTheme.focus.width, ";\n text-decoration: underline;\n\n &:disabled {\n background-color: ").concat(transparentize(euiTheme.colors.disabled, 0.1), ";\n }\n ");
|
|
15
|
+
return {
|
|
16
|
+
euiFilterSelectItem: /*#__PURE__*/css("display:block;", logicalCSS('width', '100%'), " ", logicalShorthandCSS('padding', "".concat(euiTheme.size.xs, " ").concat(euiTheme.size.m)), " ", euiFontSize(euiThemeContext, 's'), " ", logicalTextAlignCSS('left'), " color:", euiTheme.colors.text, ";", logicalCSS('border-bottom', "".concat(euiTheme.border.width.thin, " solid ").concat(euiTheme.colors.lightestShade)), " &:hover{cursor:pointer;text-decoration:underline;}&:focus{", focusStyles, ";}&:disabled{cursor:not-allowed;text-decoration:none;color:", euiTheme.colors.disabledText, ";};label:euiFilterSelectItem;"),
|
|
17
|
+
isFocused: /*#__PURE__*/css(focusStyles, ";;label:isFocused;")
|
|
18
|
+
};
|
|
19
|
+
};
|
|
@@ -65,6 +65,7 @@ export var EuiRangeHighlight = function EuiRangeHighlight(_ref) {
|
|
|
65
65
|
css: cssStyles,
|
|
66
66
|
onClick: onClick
|
|
67
67
|
}, (levels && levels.length === 0 || !levels) && ___EmotionJSX("div", {
|
|
68
|
+
"data-test-subj": "euiRangeHighlightProgress",
|
|
68
69
|
className: "euiRangeHighlight__progress",
|
|
69
70
|
css: cssProgressStyles,
|
|
70
71
|
style: progressStyle
|
|
@@ -25,7 +25,7 @@ var highlight = function highlight(searchSubject, searchValue, isStrict, highlig
|
|
|
25
25
|
var end = chunk.end,
|
|
26
26
|
highlight = chunk.highlight,
|
|
27
27
|
start = chunk.start;
|
|
28
|
-
var value = searchSubject.
|
|
28
|
+
var value = searchSubject.substring(start, end);
|
|
29
29
|
if (highlight) {
|
|
30
30
|
return ___EmotionJSX(EuiMark, {
|
|
31
31
|
key: start,
|
|
@@ -41,12 +41,12 @@ var highlight = function highlight(searchSubject, searchValue, isStrict, highlig
|
|
|
41
41
|
if (indexOfMatch === -1) {
|
|
42
42
|
return searchSubject;
|
|
43
43
|
}
|
|
44
|
-
var preMatch = searchSubject.
|
|
45
|
-
var match = searchSubject.
|
|
46
|
-
var postMatch = searchSubject.
|
|
47
|
-
return ___EmotionJSX(Fragment, null, preMatch, ___EmotionJSX(EuiMark, {
|
|
44
|
+
var preMatch = searchSubject.substring(0, indexOfMatch);
|
|
45
|
+
var match = searchSubject.substring(indexOfMatch, indexOfMatch + searchValue.length);
|
|
46
|
+
var postMatch = searchSubject.substring(indexOfMatch + searchValue.length);
|
|
47
|
+
return ___EmotionJSX(Fragment, null, preMatch || undefined, ___EmotionJSX(EuiMark, {
|
|
48
48
|
hasScreenReaderHelpText: hasScreenReaderHelpText
|
|
49
|
-
}, match), postMatch);
|
|
49
|
+
}, match), postMatch || undefined);
|
|
50
50
|
};
|
|
51
51
|
var getHightlightWords = function getHightlightWords(searchSubject, searchValue, isStrict) {
|
|
52
52
|
var regex = new RegExp(searchValue, isStrict ? 'g' : 'gi');
|
|
@@ -20,6 +20,7 @@ export * from './call_out';
|
|
|
20
20
|
export * from './card';
|
|
21
21
|
export * from './code';
|
|
22
22
|
export * from './collapsible_nav';
|
|
23
|
+
export * from './collapsible_nav_beta';
|
|
23
24
|
export * from './color_picker';
|
|
24
25
|
export * from './combo_box';
|
|
25
26
|
export * from './comment_list';
|
|
@@ -258,7 +258,8 @@ export var EuiInlineEditForm = function EuiInlineEditForm(_ref) {
|
|
|
258
258
|
size: sizes.buttonSize,
|
|
259
259
|
"data-test-subj": "euiInlineReadModeButton",
|
|
260
260
|
disabled: isReadOnly,
|
|
261
|
-
css: readModeCssStyles
|
|
261
|
+
css: readModeCssStyles,
|
|
262
|
+
title: readModeValue || placeholder
|
|
262
263
|
}, readModeProps, {
|
|
263
264
|
buttonRef: setReadModeRefs,
|
|
264
265
|
"aria-describedby": classNames(readModeDescribedById, readModeProps === null || readModeProps === void 0 ? void 0 : readModeProps['aria-describedby']),
|
|
@@ -48,8 +48,8 @@ import { isPluginWithImmediateFormatting } from './markdown_types';
|
|
|
48
48
|
var MarkdownActions = /*#__PURE__*/function () {
|
|
49
49
|
function MarkdownActions(editorID, uiPlugins) {
|
|
50
50
|
_classCallCheck(this, MarkdownActions);
|
|
51
|
-
this.editorID = editorID;
|
|
52
51
|
_defineProperty(this, "styles", void 0);
|
|
52
|
+
this.editorID = editorID;
|
|
53
53
|
/**
|
|
54
54
|
* This object is in the format:
|
|
55
55
|
* [nameOfAction]: {[styles to apply]}
|
|
@@ -150,8 +150,8 @@ export var EuiMarkdownEditor = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
150
150
|
var isPreviewing = viewMode === MODE_VIEWING;
|
|
151
151
|
var isEditing = viewMode === MODE_EDITING;
|
|
152
152
|
var replaceNode = useCallback(function (position, next) {
|
|
153
|
-
var leading = value.
|
|
154
|
-
var trailing = value.
|
|
153
|
+
var leading = value.substring(0, position.start.offset);
|
|
154
|
+
var trailing = value.substring(position.end.offset);
|
|
155
155
|
_onChange("".concat(leading).concat(next).concat(trailing));
|
|
156
156
|
}, [value, _onChange]);
|
|
157
157
|
var contextValue = useMemo(function () {
|
|
@@ -29,13 +29,19 @@ export var EuiMarkdownEditorTextArea = /*#__PURE__*/forwardRef(function (_ref, r
|
|
|
29
29
|
var classes = classNames('euiMarkdownEditorTextArea', {
|
|
30
30
|
'euiMarkdownEditorTextArea-isReadOnly': readOnly
|
|
31
31
|
});
|
|
32
|
+
|
|
33
|
+
// Ignore invalid empty string style values
|
|
34
|
+
var style = {};
|
|
35
|
+
if (height !== '') {
|
|
36
|
+
style.height = height;
|
|
37
|
+
}
|
|
38
|
+
if (maxHeight !== '') {
|
|
39
|
+
style.maxHeight = maxHeight;
|
|
40
|
+
}
|
|
32
41
|
return ___EmotionJSX("textarea", _extends({
|
|
33
42
|
ref: ref,
|
|
34
43
|
"data-test-subj": "euiMarkdownEditorTextArea",
|
|
35
|
-
style:
|
|
36
|
-
height: height,
|
|
37
|
-
maxHeight: maxHeight
|
|
38
|
-
},
|
|
44
|
+
style: style,
|
|
39
45
|
className: classes
|
|
40
46
|
}, rest, {
|
|
41
47
|
rows: 6,
|