@gitlab/ui 132.0.1 → 132.0.2
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/charts.js +13 -0
- package/dist/components/base/accordion/accordion.js +69 -0
- package/dist/components/base/accordion/accordion_item.js +160 -0
- package/dist/components/base/accordion/constants.js +3 -0
- package/dist/components/base/alert/alert.js +263 -0
- package/dist/components/base/animated_icon/animated_chevron_down_up_icon.js +45 -0
- package/dist/components/base/animated_icon/animated_chevron_lg_down_up_icon.js +45 -0
- package/dist/components/base/animated_icon/animated_chevron_lg_right_down_icon.js +45 -0
- package/dist/components/base/animated_icon/animated_chevron_right_down_icon.js +45 -0
- package/dist/components/base/animated_icon/animated_duo_chat_icon.js +45 -0
- package/dist/components/base/animated_icon/animated_loader_icon.js +45 -0
- package/dist/components/base/animated_icon/animated_notifications_icon.js +45 -0
- package/dist/components/base/animated_icon/animated_sidebar_icon.js +45 -0
- package/dist/components/base/animated_icon/animated_smile_icon.js +45 -0
- package/dist/components/base/animated_icon/animated_sort_icon.js +45 -0
- package/dist/components/base/animated_icon/animated_star_icon.js +45 -0
- package/dist/components/base/animated_icon/animated_todo_icon.js +45 -0
- package/dist/components/base/animated_icon/animated_upload_icon.js +45 -0
- package/dist/components/base/animated_icon/base_animated_icon.js +77 -0
- package/dist/components/base/attribute_list/attribute_list.js +100 -0
- package/dist/components/base/avatar/avatar.js +175 -0
- package/dist/components/base/avatar/utils.js +17 -0
- package/dist/components/base/avatar_labeled/avatar_labeled.js +198 -0
- package/dist/components/base/avatar_link/avatar_link.js +47 -0
- package/dist/components/base/avatars_inline/avatars_inline.js +139 -0
- package/dist/components/base/badge/badge.js +197 -0
- package/dist/components/base/banner/banner.js +149 -0
- package/dist/components/base/breadcrumb/breadcrumb.js +282 -0
- package/dist/components/base/breadcrumb/breadcrumb_item.js +96 -0
- package/dist/components/base/broadcast_message/broadcast_message.js +113 -0
- package/dist/components/base/broadcast_message/constants.js +5 -0
- package/dist/components/base/button/button.js +419 -0
- package/dist/components/base/button_group/button_group.js +53 -0
- package/dist/components/base/card/card.js +69 -0
- package/dist/components/base/collapse/collapse.js +163 -0
- package/dist/components/base/color_mode_toggle/color_mode_toggle.js +92 -0
- package/dist/components/base/datepicker/datepicker.js +475 -0
- package/dist/components/base/daterange_picker/daterange_picker.js +394 -0
- package/dist/components/base/drawer/drawer.js +156 -0
- package/dist/components/base/dropdown/dropdown.js +330 -0
- package/dist/components/base/dropdown/dropdown_divider.js +48 -0
- package/dist/components/base/dropdown/dropdown_form.js +48 -0
- package/dist/components/base/dropdown/dropdown_item.js +175 -0
- package/dist/components/base/dropdown/dropdown_section_header.js +48 -0
- package/dist/components/base/dropdown/dropdown_text.js +48 -0
- package/dist/components/base/filtered_search/common_story_options.js +14 -0
- package/dist/components/base/filtered_search/filtered_search.js +428 -0
- package/dist/components/base/filtered_search/filtered_search_suggestion.js +95 -0
- package/dist/components/base/filtered_search/filtered_search_suggestion_list.js +139 -0
- package/dist/components/base/filtered_search/filtered_search_term.js +217 -0
- package/dist/components/base/filtered_search/filtered_search_token.js +383 -0
- package/dist/components/base/filtered_search/filtered_search_token_segment.js +444 -0
- package/dist/components/base/filtered_search/filtered_search_utils.js +241 -0
- package/dist/components/base/form/form.js +43 -0
- package/dist/components/base/form/form_character_count/form_character_count.js +107 -0
- package/dist/components/base/form/form_checkbox/form_checkbox.js +342 -0
- package/dist/components/base/form/form_checkbox/form_checkbox_group.js +188 -0
- package/dist/components/base/form/form_combobox/constants.js +55 -0
- package/dist/components/base/form/form_combobox/form_combobox.js +239 -0
- package/dist/components/base/form/form_date/form_date.js +143 -0
- package/dist/components/base/form/form_fields/form_field_validator.js +93 -0
- package/dist/components/base/form/form_fields/form_fields.js +289 -0
- package/dist/components/base/form/form_fields/form_fields_loop.js +75 -0
- package/dist/components/base/form/form_fields/mappers.js +13 -0
- package/dist/components/base/form/form_fields/validators.js +48 -0
- package/dist/components/base/form/form_group/form_group.js +119 -0
- package/dist/components/base/form/form_input/form_input.js +695 -0
- package/dist/components/base/form/form_input_group/form_input_group.js +120 -0
- package/dist/components/base/form/form_input_group/form_input_group_mixin.js +41 -0
- package/dist/components/base/form/form_radio/form_radio.js +259 -0
- package/dist/components/base/form/form_radio_group/form_radio_group.js +189 -0
- package/dist/components/base/form/form_select/constants.js +12 -0
- package/dist/components/base/form/form_select/form_select.js +96 -0
- package/dist/components/base/form/form_textarea/form_textarea.js +166 -0
- package/dist/components/base/form/input_group_text/input_group_text.js +43 -0
- package/dist/components/base/icon/icon.js +113 -0
- package/dist/components/base/illustration/illustration.js +80 -0
- package/dist/components/base/infinite_scroll/infinite_scroll.js +196 -0
- package/dist/components/base/keyset_pagination/keyset_pagination.js +152 -0
- package/dist/components/base/label/label.js +174 -0
- package/dist/components/base/link/link.js +330 -0
- package/dist/components/base/loading_icon/loading_icon.js +120 -0
- package/dist/components/base/markdown/markdown.js +50 -0
- package/dist/components/base/modal/modal.js +259 -0
- package/dist/components/base/new_dropdowns/base_dropdown/base_dropdown.js +716 -0
- package/dist/components/base/new_dropdowns/base_dropdown/constants.js +5 -0
- package/dist/components/base/new_dropdowns/base_dropdown/dropdown_container.js +32 -0
- package/dist/components/base/new_dropdowns/constants.js +24 -0
- package/dist/components/base/new_dropdowns/disclosure/constants.js +8 -0
- package/dist/components/base/new_dropdowns/disclosure/disclosure_dropdown.js +400 -0
- package/dist/components/base/new_dropdowns/disclosure/disclosure_dropdown_group.js +112 -0
- package/dist/components/base/new_dropdowns/disclosure/disclosure_dropdown_item.js +196 -0
- package/dist/components/base/new_dropdowns/disclosure/mock_data.js +168 -0
- package/dist/components/base/new_dropdowns/disclosure/utils.js +84 -0
- package/dist/components/base/new_dropdowns/listbox/listbox.js +997 -0
- package/dist/components/base/new_dropdowns/listbox/listbox_group.js +58 -0
- package/dist/components/base/new_dropdowns/listbox/listbox_item.js +112 -0
- package/dist/components/base/new_dropdowns/listbox/listbox_search_input.js +94 -0
- package/dist/components/base/new_dropdowns/listbox/mock_data.js +131 -0
- package/dist/components/base/new_dropdowns/listbox/utils.js +33 -0
- package/dist/components/base/pagination/pagination.js +397 -0
- package/dist/components/base/path/data.js +34 -0
- package/dist/components/base/path/path.js +177 -0
- package/dist/components/base/popover/popover.js +142 -0
- package/dist/components/base/progress_bar/progress_bar.js +117 -0
- package/dist/components/base/search_box_by_click/search_box_by_click.js +245 -0
- package/dist/components/base/search_box_by_type/search_box_by_type.js +187 -0
- package/dist/components/base/segmented_control/segmented_control.js +73 -0
- package/dist/components/base/skeleton_loader/skeleton_loader.js +232 -0
- package/dist/components/base/sorting/sorting.js +180 -0
- package/dist/components/base/table/constants.js +5 -0
- package/dist/components/base/table/table.js +187 -0
- package/dist/components/base/table_lite/table_lite.js +80 -0
- package/dist/components/base/tabs/constants.js +3 -0
- package/dist/components/base/tabs/tab/tab.js +113 -0
- package/dist/components/base/tabs/tabs/scrollable_tabs.js +162 -0
- package/dist/components/base/tabs/tabs/tabs.js +223 -0
- package/dist/components/base/toast/index.js +66 -0
- package/dist/components/base/toast/toast.js +125 -0
- package/dist/components/base/toast/toaster.js +87 -0
- package/dist/components/base/toggle/toggle.js +178 -0
- package/dist/components/base/token/token.js +97 -0
- package/dist/components/base/token_selector/helpers.js +5 -0
- package/dist/components/base/token_selector/token_container.js +160 -0
- package/dist/components/base/token_selector/token_selector.js +454 -0
- package/dist/components/base/token_selector/token_selector_dropdown.js +223 -0
- package/dist/components/base/tooltip/tooltip.js +54 -0
- package/dist/components/charts/area/area.js +329 -0
- package/dist/components/charts/bar/bar.js +207 -0
- package/dist/components/charts/chart/chart.js +215 -0
- package/dist/components/charts/column/column.js +221 -0
- package/dist/components/charts/discrete_scatter/discrete_scatter.js +199 -0
- package/dist/components/charts/gauge/gauge.js +205 -0
- package/dist/components/charts/heatmap/heatmap.js +299 -0
- package/dist/components/charts/heatmap/index.js +2 -0
- package/dist/components/charts/legend/legend.js +245 -0
- package/dist/components/charts/line/line.js +340 -0
- package/dist/components/charts/series_label/series_label.js +101 -0
- package/dist/components/charts/shared/tooltip/tooltip.js +369 -0
- package/dist/components/charts/shared/tooltip/tooltip_default_format/tooltip_default_format.js +53 -0
- package/dist/components/charts/single_stat/single_stat.js +164 -0
- package/dist/components/charts/sparkline/sparkline.js +299 -0
- package/dist/components/charts/stacked_column/stacked_column.js +380 -0
- package/dist/components/dashboards/dashboard_layout/dashboard_layout.js +125 -0
- package/dist/components/dashboards/dashboard_layout/grid_layout/grid_layout.js +326 -0
- package/dist/components/dashboards/dashboard_layout/validators.js +14 -0
- package/dist/components/dashboards/dashboard_panel/dashboard_panel.js +236 -0
- package/dist/components/dashboards/mock_data.js +49 -0
- package/dist/components/experimental/experiment_badge/constants.js +4 -0
- package/dist/components/experimental/experiment_badge/experiment_badge.js +102 -0
- package/dist/components/extended/multi_step_form_template/multi_step_form_template.js +87 -0
- package/dist/components/index.js +107 -0
- package/dist/components/mixins/button_mixin.js +11 -0
- package/dist/components/mixins/safe_link_mixin.js +30 -0
- package/dist/components/mixins/tooltip_mixin.js +21 -0
- package/dist/components/regions/dashboard_skeleton/dashboard_skeleton.js +53 -0
- package/dist/components/regions/empty_state/empty_state.js +181 -0
- package/dist/components/shared_components/clear_icon_button/clear_icon_button.js +64 -0
- package/dist/components/shared_components/clipboard_button/clipboard_button.js +100 -0
- package/dist/components/shared_components/close_button/close_button.js +55 -0
- package/dist/components/utilities/animated_number/animated_number.js +131 -0
- package/dist/components/utilities/friendly_wrap/friendly_wrap.js +75 -0
- package/dist/components/utilities/intersection_observer/intersection_observer.js +88 -0
- package/dist/components/utilities/intersperse/intersperse.js +104 -0
- package/dist/components/utilities/sprintf/sprintf.js +171 -0
- package/dist/components/utilities/truncate/constants.js +8 -0
- package/dist/components/utilities/truncate/truncate.js +154 -0
- package/dist/components/utilities/truncate_text/constants.js +7 -0
- package/dist/components/utilities/truncate_text/truncate_text.js +146 -0
- package/dist/config.js +53 -0
- package/dist/directives/hover_load/hover_load.js +45 -0
- package/dist/directives/index.js +8 -0
- package/dist/directives/modal.js +1 -0
- package/dist/directives/outside/outside.js +149 -0
- package/dist/directives/resize_observer/resize_observer.js +58 -0
- package/dist/directives/safe_html/constants.js +6 -0
- package/dist/directives/safe_html/safe_html.js +39 -0
- package/dist/directives/safe_link/mock_data.js +10 -0
- package/dist/directives/safe_link/safe_link.js +67 -0
- package/dist/directives/tooltip/container.js +7 -0
- package/dist/directives/tooltip/tooltip.js +18 -0
- package/dist/index.css +7 -0
- package/dist/index.css.map +1 -0
- package/dist/index.js +2 -0
- package/dist/tailwind.css +2 -0
- package/dist/tailwind.css.map +1 -0
- package/dist/tokens/build/js/tokens.dark.js +1410 -0
- package/dist/tokens/build/js/tokens.js +1410 -0
- package/dist/tokens/common_story_options.js +29 -0
- package/dist/tokens/tokens_story.js +76 -0
- package/dist/utils/breakpoints.js +20 -0
- package/dist/utils/charts/config.js +616 -0
- package/dist/utils/charts/constants.js +69 -0
- package/dist/utils/charts/mock_data.js +191 -0
- package/dist/utils/charts/story_config.js +24 -0
- package/dist/utils/charts/theme.js +200 -0
- package/dist/utils/charts/utils.js +54 -0
- package/dist/utils/constants.js +331 -0
- package/dist/utils/data_utils.js +19 -0
- package/dist/utils/datetime_utility.js +61 -0
- package/dist/utils/equality_utils.js +84 -0
- package/dist/utils/form_options_utils.js +46 -0
- package/dist/utils/i18n.js +65 -0
- package/dist/utils/is_slot_empty.js +34 -0
- package/dist/utils/number_utils.js +132 -0
- package/dist/utils/play_utils.js +11 -0
- package/dist/utils/set_utils.js +25 -0
- package/dist/utils/stories_constants.js +29 -0
- package/dist/utils/stories_utils.js +62 -0
- package/dist/utils/story_decorators/container.js +19 -0
- package/dist/utils/string_utils.js +69 -0
- package/dist/utils/svgs/svg_paths.js +7 -0
- package/dist/utils/test_utils.js +33 -0
- package/dist/utils/use_fake_date.js +29 -0
- package/dist/utils/use_mock_intersection_observer.js +105 -0
- package/dist/utils/utils.js +205 -0
- package/dist/utils/vue_utils.js +57 -0
- package/dist/utils.js +5 -0
- package/dist/vendor/bootstrap-vue/src/bv-config.js +8 -0
- package/dist/vendor/bootstrap-vue/src/components/button/button-close.js +81 -0
- package/dist/vendor/bootstrap-vue/src/components/button/button.js +204 -0
- package/dist/vendor/bootstrap-vue/src/components/button/index.js +2 -0
- package/dist/vendor/bootstrap-vue/src/components/dropdown/dropdown-divider.js +41 -0
- package/dist/vendor/bootstrap-vue/src/components/dropdown/dropdown-form.js +52 -0
- package/dist/vendor/bootstrap-vue/src/components/dropdown/dropdown-group.js +75 -0
- package/dist/vendor/bootstrap-vue/src/components/dropdown/dropdown-header.js +52 -0
- package/dist/vendor/bootstrap-vue/src/components/dropdown/dropdown-item-button.js +85 -0
- package/dist/vendor/bootstrap-vue/src/components/dropdown/dropdown-item.js +97 -0
- package/dist/vendor/bootstrap-vue/src/components/dropdown/dropdown-text.js +60 -0
- package/dist/vendor/bootstrap-vue/src/components/dropdown/dropdown.js +270 -0
- package/dist/vendor/bootstrap-vue/src/components/dropdown/index.js +8 -0
- package/dist/vendor/bootstrap-vue/src/components/form/form-invalid-feedback.js +53 -0
- package/dist/vendor/bootstrap-vue/src/components/form/form-text.js +55 -0
- package/dist/vendor/bootstrap-vue/src/components/form/form-valid-feedback.js +53 -0
- package/dist/vendor/bootstrap-vue/src/components/form/form.js +56 -0
- package/dist/vendor/bootstrap-vue/src/components/form/index.js +4 -0
- package/dist/vendor/bootstrap-vue/src/components/form-group/form-group.js +347 -0
- package/dist/vendor/bootstrap-vue/src/components/form-group/index.js +1 -0
- package/dist/vendor/bootstrap-vue/src/components/form-select/form-select-option-group.js +54 -0
- package/dist/vendor/bootstrap-vue/src/components/form-select/form-select-option.js +41 -0
- package/dist/vendor/bootstrap-vue/src/components/form-select/form-select.js +143 -0
- package/dist/vendor/bootstrap-vue/src/components/form-select/helpers/mixin-options.js +56 -0
- package/dist/vendor/bootstrap-vue/src/components/form-select/index.js +3 -0
- package/dist/vendor/bootstrap-vue/src/components/form-textarea/form-textarea.js +217 -0
- package/dist/vendor/bootstrap-vue/src/components/form-textarea/index.js +1 -0
- package/dist/vendor/bootstrap-vue/src/components/layout/col.js +155 -0
- package/dist/vendor/bootstrap-vue/src/components/layout/form-row.js +34 -0
- package/dist/vendor/bootstrap-vue/src/components/layout/index.js +2 -0
- package/dist/vendor/bootstrap-vue/src/components/link/index.js +1 -0
- package/dist/vendor/bootstrap-vue/src/components/link/link.js +283 -0
- package/dist/vendor/bootstrap-vue/src/components/modal/helpers/bv-modal-event.class.js +21 -0
- package/dist/vendor/bootstrap-vue/src/components/modal/helpers/modal-manager.js +212 -0
- package/dist/vendor/bootstrap-vue/src/components/modal/index.js +1 -0
- package/dist/vendor/bootstrap-vue/src/components/modal/modal.js +1059 -0
- package/dist/vendor/bootstrap-vue/src/components/popover/helpers/bv-popover-template.js +55 -0
- package/dist/vendor/bootstrap-vue/src/components/popover/helpers/bv-popover.js +31 -0
- package/dist/vendor/bootstrap-vue/src/components/popover/index.js +1 -0
- package/dist/vendor/bootstrap-vue/src/components/popover/popover.js +49 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/constants.js +22 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/default-sort-compare.js +64 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/filter-event.js +40 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-bottom-row.js +43 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-busy.js +83 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-caption.js +50 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-colgroup.js +32 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-empty.js +82 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-filtering.js +292 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-items.js +154 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-pagination.js +44 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-provider.js +191 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-selectable.js +213 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-sorting.js +274 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-stacked.js +39 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-table-renderer.js +186 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-tbody-row.js +338 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-tbody.js +243 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-tfoot.js +50 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-thead.js +218 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-top-row.js +42 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/normalize-fields.js +86 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/sanitize-row.js +31 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/stringify-record-values.js +11 -0
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/text-selection-active.js +14 -0
- package/dist/vendor/bootstrap-vue/src/components/table/index.js +9 -0
- package/dist/vendor/bootstrap-vue/src/components/table/table-lite.js +51 -0
- package/dist/vendor/bootstrap-vue/src/components/table/table-simple.js +44 -0
- package/dist/vendor/bootstrap-vue/src/components/table/table.js +67 -0
- package/dist/vendor/bootstrap-vue/src/components/table/tbody.js +116 -0
- package/dist/vendor/bootstrap-vue/src/components/table/td.js +204 -0
- package/dist/vendor/bootstrap-vue/src/components/table/tfoot.js +96 -0
- package/dist/vendor/bootstrap-vue/src/components/table/th.js +26 -0
- package/dist/vendor/bootstrap-vue/src/components/table/thead.js +99 -0
- package/dist/vendor/bootstrap-vue/src/components/table/tr.js +121 -0
- package/dist/vendor/bootstrap-vue/src/components/tabs/index.js +2 -0
- package/dist/vendor/bootstrap-vue/src/components/tabs/tab.js +238 -0
- package/dist/vendor/bootstrap-vue/src/components/tabs/tabs.js +690 -0
- package/dist/vendor/bootstrap-vue/src/components/tooltip/helpers/bv-popper.js +251 -0
- package/dist/vendor/bootstrap-vue/src/components/tooltip/helpers/bv-tooltip-template.js +118 -0
- package/dist/vendor/bootstrap-vue/src/components/tooltip/helpers/bv-tooltip.js +932 -0
- package/dist/vendor/bootstrap-vue/src/components/tooltip/index.js +1 -0
- package/dist/vendor/bootstrap-vue/src/components/tooltip/tooltip.js +337 -0
- package/dist/vendor/bootstrap-vue/src/components/transition/bv-transition.js +103 -0
- package/dist/vendor/bootstrap-vue/src/components/transporter/transporter.js +205 -0
- package/dist/vendor/bootstrap-vue/src/constants/components.js +55 -0
- package/dist/vendor/bootstrap-vue/src/constants/config.js +11 -0
- package/dist/vendor/bootstrap-vue/src/constants/env.js +36 -0
- package/dist/vendor/bootstrap-vue/src/constants/events.js +56 -0
- package/dist/vendor/bootstrap-vue/src/constants/key-codes.js +11 -0
- package/dist/vendor/bootstrap-vue/src/constants/popper.js +10 -0
- package/dist/vendor/bootstrap-vue/src/constants/props.js +24 -0
- package/dist/vendor/bootstrap-vue/src/constants/regex.js +35 -0
- package/dist/vendor/bootstrap-vue/src/constants/safe-types.js +15 -0
- package/dist/vendor/bootstrap-vue/src/constants/slots.js +36 -0
- package/dist/vendor/bootstrap-vue/src/directives/modal/index.js +1 -0
- package/dist/vendor/bootstrap-vue/src/directives/modal/modal.js +112 -0
- package/dist/vendor/bootstrap-vue/src/directives/tooltip/index.js +1 -0
- package/dist/vendor/bootstrap-vue/src/directives/tooltip/tooltip.js +267 -0
- package/dist/vendor/bootstrap-vue/src/directives/visible/index.js +1 -0
- package/dist/vendor/bootstrap-vue/src/directives/visible/visible.js +187 -0
- package/dist/vendor/bootstrap-vue/src/mixins/attrs.js +5 -0
- package/dist/vendor/bootstrap-vue/src/mixins/click-out.js +54 -0
- package/dist/vendor/bootstrap-vue/src/mixins/dropdown.js +470 -0
- package/dist/vendor/bootstrap-vue/src/mixins/focus-in.js +46 -0
- package/dist/vendor/bootstrap-vue/src/mixins/form-control.js +73 -0
- package/dist/vendor/bootstrap-vue/src/mixins/form-custom.js +26 -0
- package/dist/vendor/bootstrap-vue/src/mixins/form-options.js +91 -0
- package/dist/vendor/bootstrap-vue/src/mixins/form-selection.js +62 -0
- package/dist/vendor/bootstrap-vue/src/mixins/form-size.js +26 -0
- package/dist/vendor/bootstrap-vue/src/mixins/form-state.js +50 -0
- package/dist/vendor/bootstrap-vue/src/mixins/form-text.js +293 -0
- package/dist/vendor/bootstrap-vue/src/mixins/form-validity.js +50 -0
- package/dist/vendor/bootstrap-vue/src/mixins/has-listener.js +29 -0
- package/dist/vendor/bootstrap-vue/src/mixins/id.js +57 -0
- package/dist/vendor/bootstrap-vue/src/mixins/listen-on-document.js +62 -0
- package/dist/vendor/bootstrap-vue/src/mixins/listen-on-root.js +120 -0
- package/dist/vendor/bootstrap-vue/src/mixins/listen-on-window.js +62 -0
- package/dist/vendor/bootstrap-vue/src/mixins/listeners.js +25 -0
- package/dist/vendor/bootstrap-vue/src/mixins/model.js +10 -0
- package/dist/vendor/bootstrap-vue/src/mixins/normalize-slot.js +30 -0
- package/dist/vendor/bootstrap-vue/src/mixins/scoped-style.js +18 -0
- package/dist/vendor/bootstrap-vue/src/mixins/use-parent.js +14 -0
- package/dist/vendor/bootstrap-vue/src/utils/array.js +27 -0
- package/dist/vendor/bootstrap-vue/src/utils/bv-event.class.js +60 -0
- package/dist/vendor/bootstrap-vue/src/utils/cache.js +60 -0
- package/dist/vendor/bootstrap-vue/src/utils/clone-deep.js +18 -0
- package/dist/vendor/bootstrap-vue/src/utils/config-set.js +86 -0
- package/dist/vendor/bootstrap-vue/src/utils/config.js +71 -0
- package/dist/vendor/bootstrap-vue/src/utils/create-new-child-component.js +133 -0
- package/dist/vendor/bootstrap-vue/src/utils/css-escape.js +70 -0
- package/dist/vendor/bootstrap-vue/src/utils/dom.js +298 -0
- package/dist/vendor/bootstrap-vue/src/utils/element-to-vue-instance-registry.js +28 -0
- package/dist/vendor/bootstrap-vue/src/utils/env.js +16 -0
- package/dist/vendor/bootstrap-vue/src/utils/events.js +78 -0
- package/dist/vendor/bootstrap-vue/src/utils/get-event-root.js +5 -0
- package/dist/vendor/bootstrap-vue/src/utils/get-instance-from-directive.js +3 -0
- package/dist/vendor/bootstrap-vue/src/utils/get-scope-id.js +9 -0
- package/dist/vendor/bootstrap-vue/src/utils/get.js +63 -0
- package/dist/vendor/bootstrap-vue/src/utils/html.js +16 -0
- package/dist/vendor/bootstrap-vue/src/utils/identity.js +3 -0
- package/dist/vendor/bootstrap-vue/src/utils/inspect.js +35 -0
- package/dist/vendor/bootstrap-vue/src/utils/locale.js +18 -0
- package/dist/vendor/bootstrap-vue/src/utils/loose-equal.js +59 -0
- package/dist/vendor/bootstrap-vue/src/utils/loose-index-of.js +13 -0
- package/dist/vendor/bootstrap-vue/src/utils/math.js +9 -0
- package/dist/vendor/bootstrap-vue/src/utils/memoize.js +14 -0
- package/dist/vendor/bootstrap-vue/src/utils/model.js +33 -0
- package/dist/vendor/bootstrap-vue/src/utils/noop.js +3 -0
- package/dist/vendor/bootstrap-vue/src/utils/normalize-slot.js +51 -0
- package/dist/vendor/bootstrap-vue/src/utils/number.js +23 -0
- package/dist/vendor/bootstrap-vue/src/utils/object.js +72 -0
- package/dist/vendor/bootstrap-vue/src/utils/observe-dom.js +76 -0
- package/dist/vendor/bootstrap-vue/src/utils/on-instance-destroy.js +22 -0
- package/dist/vendor/bootstrap-vue/src/utils/plugins.js +124 -0
- package/dist/vendor/bootstrap-vue/src/utils/props.js +67 -0
- package/dist/vendor/bootstrap-vue/src/utils/router.js +150 -0
- package/dist/vendor/bootstrap-vue/src/utils/safe-vue-instance.js +14 -0
- package/dist/vendor/bootstrap-vue/src/utils/stable-sort.js +28 -0
- package/dist/vendor/bootstrap-vue/src/utils/string.js +47 -0
- package/dist/vendor/bootstrap-vue/src/utils/stringify-object-values.js +31 -0
- package/dist/vendor/bootstrap-vue/src/utils/warn.js +45 -0
- package/dist/vendor/bootstrap-vue/src/vue.js +55 -0
- package/package.json +4 -3
- package/src/vendor/bootstrap-vue/src/components/dropdown/dropdown.js +2 -2
- package/src/vendor/bootstrap-vue/src/components/form-group/form-group.js +2 -2
- package/src/vendor/bootstrap-vue/src/components/layout/col.js +2 -2
- package/src/vendor/bootstrap-vue/src/components/modal/modal.js +2 -2
- package/src/vendor/bootstrap-vue/src/components/tabs/tabs.js +2 -2
- package/src/vendor/bootstrap-vue/src/components/tooltip/helpers/bv-tooltip.js +8 -9
- package/src/vendor/bootstrap-vue/src/mixins/listen-on-document.js +1 -2
- package/src/vendor/bootstrap-vue/src/mixins/listen-on-root.js +1 -2
- package/src/vendor/bootstrap-vue/src/mixins/listen-on-window.js +1 -2
- package/src/vendor/bootstrap-vue/src/utils/array.js +0 -1
- package/src/vendor/bootstrap-vue/src/utils/locale.js +1 -2
|
@@ -0,0 +1,236 @@
|
|
|
1
|
+
import { isObject, uniqueId } from 'lodash-es';
|
|
2
|
+
import GlDisclosureDropdown from '../../base/new_dropdowns/disclosure/disclosure_dropdown';
|
|
3
|
+
import GlIcon from '../../base/icon/icon';
|
|
4
|
+
import GlLoadingIcon from '../../base/loading_icon/loading_icon';
|
|
5
|
+
import GlPopover from '../../base/popover/popover';
|
|
6
|
+
import GlSprintf from '../../utilities/sprintf/sprintf';
|
|
7
|
+
import GlLink from '../../base/link/link';
|
|
8
|
+
import GlTruncate from '../../utilities/truncate/truncate';
|
|
9
|
+
import __vue_normalize__ from 'vue-runtime-helpers/dist/normalize-component.js';
|
|
10
|
+
|
|
11
|
+
var script = {
|
|
12
|
+
name: 'GlDashboardPanel',
|
|
13
|
+
components: {
|
|
14
|
+
GlDisclosureDropdown,
|
|
15
|
+
GlLoadingIcon,
|
|
16
|
+
GlIcon,
|
|
17
|
+
GlPopover,
|
|
18
|
+
GlSprintf,
|
|
19
|
+
GlLink,
|
|
20
|
+
GlTruncate
|
|
21
|
+
},
|
|
22
|
+
props: {
|
|
23
|
+
/**
|
|
24
|
+
* CSS classes to apply to the panel container.
|
|
25
|
+
*/
|
|
26
|
+
containerClass: {
|
|
27
|
+
type: String,
|
|
28
|
+
required: false,
|
|
29
|
+
default: ''
|
|
30
|
+
},
|
|
31
|
+
/**
|
|
32
|
+
* Additional CSS classes to apply to the `#body` slot container.
|
|
33
|
+
*/
|
|
34
|
+
bodyContentClass: {
|
|
35
|
+
type: String,
|
|
36
|
+
required: false,
|
|
37
|
+
default: ''
|
|
38
|
+
},
|
|
39
|
+
/**
|
|
40
|
+
* Used to set the color of the panel border.
|
|
41
|
+
*/
|
|
42
|
+
borderColorClass: {
|
|
43
|
+
type: String,
|
|
44
|
+
required: false,
|
|
45
|
+
default: ''
|
|
46
|
+
},
|
|
47
|
+
/**
|
|
48
|
+
* The string to render as the panel title.
|
|
49
|
+
*/
|
|
50
|
+
title: {
|
|
51
|
+
type: String,
|
|
52
|
+
required: false,
|
|
53
|
+
default: ''
|
|
54
|
+
},
|
|
55
|
+
/**
|
|
56
|
+
* The name of the icon to render next to the panel title.
|
|
57
|
+
*/
|
|
58
|
+
titleIcon: {
|
|
59
|
+
type: String,
|
|
60
|
+
required: false,
|
|
61
|
+
default: ''
|
|
62
|
+
},
|
|
63
|
+
/**
|
|
64
|
+
* The CSS classes to apply to the title icon.
|
|
65
|
+
*/
|
|
66
|
+
titleIconClass: {
|
|
67
|
+
type: String,
|
|
68
|
+
required: false,
|
|
69
|
+
default: ''
|
|
70
|
+
},
|
|
71
|
+
/**
|
|
72
|
+
* Configuration object for the title popover. Expected structure:
|
|
73
|
+
* **Deprecated:** Use slots `#info-popover-content` and `#info-popover-title` instead.
|
|
74
|
+
*
|
|
75
|
+
* - `description`: The popover text content with interpolation placeholders.
|
|
76
|
+
* Uses `%{linkStart}` and `%{linkEnd}` as markers for where a link should be inserted.
|
|
77
|
+
*
|
|
78
|
+
* - `descriptionLink`: The optional URL that will be used for the link portion
|
|
79
|
+
* of the description text between the linkStart and linkEnd markers.
|
|
80
|
+
*
|
|
81
|
+
* @deprecated Use slots `#info-popover-content` and `#info-popover-title` instead.
|
|
82
|
+
*/
|
|
83
|
+
titlePopover: {
|
|
84
|
+
type: Object,
|
|
85
|
+
required: false,
|
|
86
|
+
default: () => ({})
|
|
87
|
+
},
|
|
88
|
+
/**
|
|
89
|
+
* CSS classes to apply to the title popover (gets passed to the `css-classes` prop of the `GlPopover` component).
|
|
90
|
+
*/
|
|
91
|
+
titlePopoverClasses: {
|
|
92
|
+
type: [Array, String, Object],
|
|
93
|
+
required: false,
|
|
94
|
+
default: ''
|
|
95
|
+
},
|
|
96
|
+
/**
|
|
97
|
+
* The string to render as the panel subtitle.
|
|
98
|
+
*/
|
|
99
|
+
subtitle: {
|
|
100
|
+
type: String,
|
|
101
|
+
required: false,
|
|
102
|
+
default: ''
|
|
103
|
+
},
|
|
104
|
+
/**
|
|
105
|
+
* Set to `true` to show the loading state.
|
|
106
|
+
*/
|
|
107
|
+
loading: {
|
|
108
|
+
type: Boolean,
|
|
109
|
+
required: false,
|
|
110
|
+
default: false
|
|
111
|
+
},
|
|
112
|
+
/**
|
|
113
|
+
* Set to `true` for long-running operations.
|
|
114
|
+
*/
|
|
115
|
+
loadingDelayed: {
|
|
116
|
+
type: Boolean,
|
|
117
|
+
required: false,
|
|
118
|
+
default: false
|
|
119
|
+
},
|
|
120
|
+
/**
|
|
121
|
+
* The string to render while loading is delayed.
|
|
122
|
+
*/
|
|
123
|
+
loadingDelayedText: {
|
|
124
|
+
type: String,
|
|
125
|
+
required: false,
|
|
126
|
+
default: ''
|
|
127
|
+
},
|
|
128
|
+
/**
|
|
129
|
+
* Array of `GlDisclosureDropdown` items to display in the dropdown.
|
|
130
|
+
*/
|
|
131
|
+
actions: {
|
|
132
|
+
type: Array,
|
|
133
|
+
required: false,
|
|
134
|
+
default: () => [],
|
|
135
|
+
validator: actions => actions.every(a => isObject(a))
|
|
136
|
+
},
|
|
137
|
+
/**
|
|
138
|
+
* The toggle text for the `GlDisclosureDropdown` dropdown.
|
|
139
|
+
*/
|
|
140
|
+
actionsToggleText: {
|
|
141
|
+
type: String,
|
|
142
|
+
required: false,
|
|
143
|
+
default: ''
|
|
144
|
+
}
|
|
145
|
+
},
|
|
146
|
+
data() {
|
|
147
|
+
return {
|
|
148
|
+
panelId: uniqueId('gl-dashboard-panel-id-'),
|
|
149
|
+
titlePopoverId: uniqueId('gl-dashboard-panel-title-popover-id-')
|
|
150
|
+
};
|
|
151
|
+
},
|
|
152
|
+
computed: {
|
|
153
|
+
borderClass() {
|
|
154
|
+
var _this$borderColorClas;
|
|
155
|
+
if (((_this$borderColorClas = this.borderColorClass) === null || _this$borderColorClas === void 0 ? void 0 : _this$borderColorClas.length) > 0) {
|
|
156
|
+
return `gl-border-t-2 gl-border-t-solid ${this.borderColorClass}`;
|
|
157
|
+
}
|
|
158
|
+
return '';
|
|
159
|
+
},
|
|
160
|
+
containerClasses() {
|
|
161
|
+
return `${this.containerClass} ${this.borderClass}`;
|
|
162
|
+
},
|
|
163
|
+
bodyClasses() {
|
|
164
|
+
return this.loading ? 'gl-flex gl-flex-wrap gl-content-center gl-text-center gl-flex-grow' : `gl-grow gl-overflow-y-auto gl-overflow-x-hidden ${this.bodyContentClass}`;
|
|
165
|
+
},
|
|
166
|
+
hasTitleIcon() {
|
|
167
|
+
return Boolean(this.titleIcon);
|
|
168
|
+
},
|
|
169
|
+
hasTitle() {
|
|
170
|
+
return Boolean(this.title);
|
|
171
|
+
},
|
|
172
|
+
hasInfoPopoverContentSlot() {
|
|
173
|
+
return Boolean(this.$scopedSlots['info-popover-content']);
|
|
174
|
+
},
|
|
175
|
+
hasInfoPopoverTitleSlot() {
|
|
176
|
+
return Boolean(this.$scopedSlots['info-popover-title']);
|
|
177
|
+
},
|
|
178
|
+
hasTitlePopover() {
|
|
179
|
+
var _this$titlePopover;
|
|
180
|
+
return Boolean((_this$titlePopover = this.titlePopover) === null || _this$titlePopover === void 0 ? void 0 : _this$titlePopover.description) || this.hasInfoPopoverContentSlot || this.hasInfoPopoverTitleSlot;
|
|
181
|
+
},
|
|
182
|
+
hasTitlePopoverLink() {
|
|
183
|
+
var _this$titlePopover2;
|
|
184
|
+
return Boolean((_this$titlePopover2 = this.titlePopover) === null || _this$titlePopover2 === void 0 ? void 0 : _this$titlePopover2.descriptionLink);
|
|
185
|
+
},
|
|
186
|
+
shouldShowActions() {
|
|
187
|
+
var _this$actions;
|
|
188
|
+
return ((_this$actions = this.actions) === null || _this$actions === void 0 ? void 0 : _this$actions.length) > 0;
|
|
189
|
+
},
|
|
190
|
+
isLoadingDelayed() {
|
|
191
|
+
return this.loadingDelayed && Boolean(this.loadingDelayedText);
|
|
192
|
+
}
|
|
193
|
+
}
|
|
194
|
+
};
|
|
195
|
+
|
|
196
|
+
/* script */
|
|
197
|
+
const __vue_script__ = script;
|
|
198
|
+
|
|
199
|
+
/* template */
|
|
200
|
+
var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"gl-border gl-h-full gl-rounded-lg gl-bg-default gl-p-5",class:_vm.containerClasses,attrs:{"id":_vm.panelId}},[_c('div',{staticClass:"gl-flex gl-h-full gl-flex-col"},[_c('div',{staticClass:"gl-mb-3 gl-flex gl-items-start gl-justify-between",attrs:{"data-testid":"panel-title"}},[_c('div',{staticClass:"gl-flex gl-items-center gl-gap-2 gl-overflow-hidden"},[(_vm.hasTitleIcon)?_c('gl-icon',{class:_vm.titleIconClass,attrs:{"name":_vm.titleIcon,"data-testid":"panel-title-icon"}}):_vm._e(),_vm._v(" "),_c('div',{staticClass:"gl-min-w-0"},[_c('div',{staticClass:"gl-flex gl-items-center gl-gap-2"},[(_vm.hasTitle)?_c('gl-truncate',{staticClass:"gl-min-w-0 gl-font-bold gl-text-default",attrs:{"text":_vm.title,"with-tooltip":""}}):_vm._e(),_vm._v(" "),(_vm.hasTitlePopover)?[_c('gl-icon',{staticClass:"gl-min-w-5",attrs:{"id":_vm.titlePopoverId,"data-testid":"panel-title-popover-icon","name":"information-o","variant":"info"}}),_vm._v(" "),_c('gl-popover',{attrs:{"data-testid":"panel-title-popover","boundary":"viewport","target":_vm.titlePopoverId,"css-classes":_vm.titlePopoverClasses},scopedSlots:_vm._u([(_vm.hasInfoPopoverTitleSlot)?{key:"title",fn:function(){return [_vm._t("info-popover-title")]},proxy:true}:null],null,true)},[_vm._v(" "),(_vm.hasInfoPopoverContentSlot)?[_vm._t("info-popover-content")]:_vm._e(),_vm._v(" "),(!_vm.hasInfoPopoverContentSlot)?[(_vm.hasTitlePopoverLink)?_c('gl-sprintf',{attrs:{"message":_vm.titlePopover.description},scopedSlots:_vm._u([{key:"link",fn:function(ref){
|
|
201
|
+
var content = ref.content;
|
|
202
|
+
return [_c('gl-link',{staticClass:"gl-text-sm",attrs:{"href":_vm.titlePopover.descriptionLink}},[_vm._v(_vm._s(content))])]}}],null,false,3051540671)}):[_vm._v(" "+_vm._s(_vm.titlePopover.description)+" ")]]:_vm._e()],2)]:_vm._e()],2),_vm._v(" "),(_vm.subtitle)?_c('p',{staticClass:"gl-mb-0 gl-mt-1 gl-text-sm gl-text-subtle",attrs:{"data-testid":"panel-subtitle"}},[_vm._v("\n "+_vm._s(_vm.subtitle)+"\n ")]):_vm._e()])],1),_vm._v(" "),(_vm.shouldShowActions || _vm.$scopedSlots.filters)?_c('div',{staticClass:"gl-flex gl-flex-col gl-items-end gl-gap-2",attrs:{"data-testid":"panel-actions-filters-container"}},[(_vm.shouldShowActions)?_c('gl-disclosure-dropdown',{attrs:{"items":_vm.actions,"icon":"ellipsis_v","toggle-text":_vm.actionsToggleText,"text-sr-only":"","no-caret":"","placement":"bottom-end","fluid-width":"","toggle-class":"gl-ml-1","category":"tertiary","positioning-strategy":"fixed","size":"small"},on:{"shown":function($event){return _vm.$emit('dropdownOpen')},"hidden":function($event){return _vm.$emit('dropdownClosed')}},scopedSlots:_vm._u([{key:"list-item",fn:function(ref){
|
|
203
|
+
var item = ref.item;
|
|
204
|
+
return [_c('span',[_vm._v(_vm._s(item.text))])]}}],null,false,3418607560)}):_vm._e(),_vm._v(" "),(_vm.$scopedSlots.filters)?_c('div',{staticClass:"gl-flex gl-items-center gl-justify-end",attrs:{"data-testid":"panel-filters-container"}},[_vm._t("filters")],2):_vm._e()],1):_vm._e()]),_vm._v(" "),_c('div',{class:_vm.bodyClasses},[(_vm.loading)?[_c('gl-loading-icon',{staticClass:"gl-min-h-8 gl-w-full",attrs:{"size":"lg"}}),_vm._v(" "),(_vm.isLoadingDelayed)?_c('div',{staticClass:"gl-w-full gl-text-subtle",attrs:{"data-testId":"panel-loading-delayed-indicator"}},[_vm._v("\n "+_vm._s(_vm.loadingDelayedText)+"\n ")]):_vm._e()]:_vm._t("body")],2),_vm._v(" "),_vm._t("alert-message",null,{"panelId":_vm.panelId})],2)])};
|
|
205
|
+
var __vue_staticRenderFns__ = [];
|
|
206
|
+
|
|
207
|
+
/* style */
|
|
208
|
+
const __vue_inject_styles__ = undefined;
|
|
209
|
+
/* scoped */
|
|
210
|
+
const __vue_scope_id__ = undefined;
|
|
211
|
+
/* module identifier */
|
|
212
|
+
const __vue_module_identifier__ = undefined;
|
|
213
|
+
/* functional template */
|
|
214
|
+
const __vue_is_functional_template__ = false;
|
|
215
|
+
/* style inject */
|
|
216
|
+
|
|
217
|
+
/* style inject SSR */
|
|
218
|
+
|
|
219
|
+
/* style inject shadow dom */
|
|
220
|
+
|
|
221
|
+
|
|
222
|
+
|
|
223
|
+
const __vue_component__ = /*#__PURE__*/__vue_normalize__(
|
|
224
|
+
{ render: __vue_render__, staticRenderFns: __vue_staticRenderFns__ },
|
|
225
|
+
__vue_inject_styles__,
|
|
226
|
+
__vue_script__,
|
|
227
|
+
__vue_scope_id__,
|
|
228
|
+
__vue_is_functional_template__,
|
|
229
|
+
__vue_module_identifier__,
|
|
230
|
+
false,
|
|
231
|
+
undefined,
|
|
232
|
+
undefined,
|
|
233
|
+
undefined
|
|
234
|
+
);
|
|
235
|
+
|
|
236
|
+
export { __vue_component__ as default };
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { uniqueId } from 'lodash-es';
|
|
2
|
+
|
|
3
|
+
const getUniquePanelId = () => uniqueId('panel-');
|
|
4
|
+
const dashboard = {
|
|
5
|
+
id: 'analytics_overview',
|
|
6
|
+
slug: 'analytics_overview',
|
|
7
|
+
title: 'Analytics Overview',
|
|
8
|
+
description: 'This is a dashboard',
|
|
9
|
+
userDefined: true,
|
|
10
|
+
panels: [{
|
|
11
|
+
title: 'Test A',
|
|
12
|
+
gridAttributes: {
|
|
13
|
+
width: 3,
|
|
14
|
+
height: 3,
|
|
15
|
+
xPos: 0,
|
|
16
|
+
yPos: 0
|
|
17
|
+
},
|
|
18
|
+
id: getUniquePanelId()
|
|
19
|
+
}, {
|
|
20
|
+
title: 'Test B',
|
|
21
|
+
gridAttributes: {
|
|
22
|
+
width: 2,
|
|
23
|
+
height: 4,
|
|
24
|
+
xPos: 1,
|
|
25
|
+
yPos: 1,
|
|
26
|
+
minHeight: 2,
|
|
27
|
+
minWidth: 2
|
|
28
|
+
},
|
|
29
|
+
id: getUniquePanelId()
|
|
30
|
+
}],
|
|
31
|
+
status: null,
|
|
32
|
+
errors: null
|
|
33
|
+
};
|
|
34
|
+
const mockPanel = {
|
|
35
|
+
title: 'Test A',
|
|
36
|
+
gridAttributes: {
|
|
37
|
+
width: 1,
|
|
38
|
+
height: 2,
|
|
39
|
+
xPos: 0,
|
|
40
|
+
yPos: 3,
|
|
41
|
+
minWidth: 1,
|
|
42
|
+
minHeight: 2,
|
|
43
|
+
maxWidth: 1,
|
|
44
|
+
maxHeight: 2
|
|
45
|
+
},
|
|
46
|
+
id: getUniquePanelId()
|
|
47
|
+
};
|
|
48
|
+
|
|
49
|
+
export { dashboard, getUniquePanelId, mockPanel };
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
import { uniqueId } from 'lodash-es';
|
|
2
|
+
import GlBadge from '../../base/badge/badge';
|
|
3
|
+
import GlLink from '../../base/link/link';
|
|
4
|
+
import GlPopover from '../../base/popover/popover';
|
|
5
|
+
import GlSprintf from '../../utilities/sprintf/sprintf';
|
|
6
|
+
import { badgeTypeValidator } from './constants';
|
|
7
|
+
import __vue_normalize__ from 'vue-runtime-helpers/dist/normalize-component.js';
|
|
8
|
+
|
|
9
|
+
const i18n = {
|
|
10
|
+
experiment: {
|
|
11
|
+
BADGE: 'Experiment',
|
|
12
|
+
HELP_PAGE_URL: 'https://docs.gitlab.com/policy/development_stages_support/#experiment',
|
|
13
|
+
POPOVER_TITLE: "What's an experiment?",
|
|
14
|
+
POPOVER_CONTENT: 'An %{linkStart}experiment%{linkEnd} is not yet production-ready, but is released for initial testing and feedback during development.%{line-breakStart}Experiments:%{line-breakEnd} %{bullets}',
|
|
15
|
+
POPOVER_BULLETS: ['Might be unstable or cause data loss.', 'Are not supported and might not be documented.', 'Could be changed or removed at any time.']
|
|
16
|
+
},
|
|
17
|
+
beta: {
|
|
18
|
+
BADGE: 'Beta',
|
|
19
|
+
HELP_PAGE_URL: 'https://docs.gitlab.com/policy/development_stages_support/#beta',
|
|
20
|
+
POPOVER_TITLE: "What's a beta?",
|
|
21
|
+
POPOVER_CONTENT: "A %{linkStart}beta%{linkEnd} feature is not yet production-ready, but is ready for testing and unlikely to change significantly before it's released.%{line-breakStart}Beta features:%{line-breakEnd} %{bullets}",
|
|
22
|
+
POPOVER_BULLETS: ['Have a low risk of data loss, but might still be unstable.', 'Are supported on a commercially-reasonable effort basis.', 'Have a near complete user experience.']
|
|
23
|
+
}
|
|
24
|
+
};
|
|
25
|
+
var script = {
|
|
26
|
+
name: 'GlExperimentBadge',
|
|
27
|
+
components: {
|
|
28
|
+
GlBadge,
|
|
29
|
+
GlPopover,
|
|
30
|
+
GlSprintf,
|
|
31
|
+
GlLink
|
|
32
|
+
},
|
|
33
|
+
props: {
|
|
34
|
+
/**
|
|
35
|
+
* The placement of the popover in relation to the button.
|
|
36
|
+
*/
|
|
37
|
+
popoverPlacement: {
|
|
38
|
+
type: String,
|
|
39
|
+
required: false,
|
|
40
|
+
default: 'bottom'
|
|
41
|
+
},
|
|
42
|
+
/**
|
|
43
|
+
* The type of the badge. Can be 'experiment' or 'beta'.
|
|
44
|
+
*/
|
|
45
|
+
type: {
|
|
46
|
+
type: String,
|
|
47
|
+
required: false,
|
|
48
|
+
default: 'experiment',
|
|
49
|
+
validator: badgeTypeValidator
|
|
50
|
+
}
|
|
51
|
+
},
|
|
52
|
+
computed: {
|
|
53
|
+
activeType() {
|
|
54
|
+
return i18n[this.type];
|
|
55
|
+
}
|
|
56
|
+
},
|
|
57
|
+
created() {
|
|
58
|
+
this.triggerId = uniqueId('experiment-badge-');
|
|
59
|
+
}
|
|
60
|
+
};
|
|
61
|
+
|
|
62
|
+
/* script */
|
|
63
|
+
const __vue_script__ = script;
|
|
64
|
+
|
|
65
|
+
/* template */
|
|
66
|
+
var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('gl-badge',{ref:"badge",staticClass:"gl-mx-4 hover:gl-cursor-pointer",attrs:{"id":_vm.triggerId,"href":"#","variant":"neutral"}},[_c('span',[_vm._v(_vm._s(_vm.activeType.BADGE))]),_vm._v(" "),_c('gl-popover',{attrs:{"triggers":"hover focus click","show-close-button":"","placement":_vm.popoverPlacement,"target":_vm.triggerId,"css-classes":"!gl-z-9999","title":_vm.activeType.POPOVER_TITLE}},[_c('gl-sprintf',{attrs:{"message":_vm.activeType.POPOVER_CONTENT},scopedSlots:_vm._u([{key:"link",fn:function(ref){
|
|
67
|
+
var content = ref.content;
|
|
68
|
+
return [_c('gl-link',{staticClass:"!gl-text-sm",attrs:{"href":_vm.activeType.HELP_PAGE_URL,"target":"_blank"}},[_vm._v("\n "+_vm._s(content))])]}},{key:"bullets",fn:function(){return [_c('ul',{staticClass:"gl-mb-0 gl-pl-5"},_vm._l((_vm.activeType.POPOVER_BULLETS),function(item,i){return _c('li',{key:("li-" + i)},[_vm._v("\n "+_vm._s(item)+"\n ")])}),0)]},proxy:true},{key:"line-break",fn:function(ref){
|
|
69
|
+
var content = ref.content;
|
|
70
|
+
return [_c('span',{staticClass:"gl-mb-0 gl-mt-5 gl-block"},[_vm._v(_vm._s(content))])]}}])})],1)],1)};
|
|
71
|
+
var __vue_staticRenderFns__ = [];
|
|
72
|
+
|
|
73
|
+
/* style */
|
|
74
|
+
const __vue_inject_styles__ = undefined;
|
|
75
|
+
/* scoped */
|
|
76
|
+
const __vue_scope_id__ = undefined;
|
|
77
|
+
/* module identifier */
|
|
78
|
+
const __vue_module_identifier__ = undefined;
|
|
79
|
+
/* functional template */
|
|
80
|
+
const __vue_is_functional_template__ = false;
|
|
81
|
+
/* style inject */
|
|
82
|
+
|
|
83
|
+
/* style inject SSR */
|
|
84
|
+
|
|
85
|
+
/* style inject shadow dom */
|
|
86
|
+
|
|
87
|
+
|
|
88
|
+
|
|
89
|
+
const __vue_component__ = /*#__PURE__*/__vue_normalize__(
|
|
90
|
+
{ render: __vue_render__, staticRenderFns: __vue_staticRenderFns__ },
|
|
91
|
+
__vue_inject_styles__,
|
|
92
|
+
__vue_script__,
|
|
93
|
+
__vue_scope_id__,
|
|
94
|
+
__vue_is_functional_template__,
|
|
95
|
+
__vue_module_identifier__,
|
|
96
|
+
false,
|
|
97
|
+
undefined,
|
|
98
|
+
undefined,
|
|
99
|
+
undefined
|
|
100
|
+
);
|
|
101
|
+
|
|
102
|
+
export { __vue_component__ as default, i18n };
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
import { translate } from '../../../utils/i18n';
|
|
2
|
+
import __vue_normalize__ from 'vue-runtime-helpers/dist/normalize-component.js';
|
|
3
|
+
|
|
4
|
+
var script = {
|
|
5
|
+
name: 'GlMultiStepFormTemplate',
|
|
6
|
+
props: {
|
|
7
|
+
/**
|
|
8
|
+
* The tile of the form. Should not be specific to the current step.
|
|
9
|
+
*/
|
|
10
|
+
title: {
|
|
11
|
+
type: String,
|
|
12
|
+
required: true
|
|
13
|
+
},
|
|
14
|
+
/**
|
|
15
|
+
* The number of the current step. If a non-zero number is passed, then the current step number will be shown at the top of the form.
|
|
16
|
+
*/
|
|
17
|
+
currentStep: {
|
|
18
|
+
type: Number,
|
|
19
|
+
required: false,
|
|
20
|
+
default: null
|
|
21
|
+
},
|
|
22
|
+
/**
|
|
23
|
+
* The total number of steps. If a non-zero number is passed to this prop and a non-zero number is passed to the `currentStep` prop, then they will be formatted together at the top of the form. In English, this will appear as `Step n of x` where n is the current step and x is the step total.
|
|
24
|
+
*/
|
|
25
|
+
stepsTotal: {
|
|
26
|
+
type: Number,
|
|
27
|
+
required: false,
|
|
28
|
+
default: null
|
|
29
|
+
},
|
|
30
|
+
/**
|
|
31
|
+
* Optional override to the semantic element used for the form title's heading tag. Defaults to `h1` but should be adjusted in usage to prevent unexpected heading level changes in the DOM.
|
|
32
|
+
*/
|
|
33
|
+
headingTag: {
|
|
34
|
+
type: String,
|
|
35
|
+
required: false,
|
|
36
|
+
default: 'h1'
|
|
37
|
+
}
|
|
38
|
+
},
|
|
39
|
+
computed: {
|
|
40
|
+
stepMessage() {
|
|
41
|
+
return this.stepsTotal ? translate('GlMultiStepFormTemplate.stepXofY', 'Step %{currentStep} of %{stepsTotal}', {
|
|
42
|
+
currentStep: this.currentStep,
|
|
43
|
+
stepsTotal: this.stepsTotal
|
|
44
|
+
}) : translate('GlMultiStepFormTemplate.stepX', 'Step %{currentStep}', {
|
|
45
|
+
currentStep: this.currentStep
|
|
46
|
+
});
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
};
|
|
50
|
+
|
|
51
|
+
/* script */
|
|
52
|
+
const __vue_script__ = script;
|
|
53
|
+
|
|
54
|
+
/* template */
|
|
55
|
+
var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"gl-mx-auto gl-max-w-80 gl-pt-8"},[_c(_vm.headingTag,{tag:"component",staticClass:"gl-heading-1 gl-mb-3 gl-mt-0 gl-text-center",attrs:{"data-testid":"multi-step-form-title"}},[_vm._v("\n "+_vm._s(_vm.title)+"\n ")]),_vm._v(" "),(_vm.currentStep)?_c('p',{staticClass:"gl-m-0 gl-text-center",attrs:{"data-testid":"multi-step-form-steps"}},[_vm._v("\n "+_vm._s(_vm.stepMessage)+"\n ")]):_vm._e(),_vm._v(" "),_c('div',{staticClass:"gl-mt-7",attrs:{"data-testid":"multi-step-form-content"}},[_vm._t("default")],2),_vm._v(" "),(_vm.$scopedSlots.back || _vm.$scopedSlots.next)?_c('div',{staticClass:"gl-mt-6 gl-flex gl-justify-center gl-gap-3",attrs:{"data-testid":"multi-step-form-action"}},[_vm._t("back"),_vm._v(" "),_vm._t("next")],2):_vm._e(),_vm._v(" "),(_vm.$scopedSlots.footer)?_c('div',{staticClass:"gl-mt-7",attrs:{"data-testid":"multi-step-form-footer"}},[_vm._t("footer")],2):_vm._e()],1)};
|
|
56
|
+
var __vue_staticRenderFns__ = [];
|
|
57
|
+
|
|
58
|
+
/* style */
|
|
59
|
+
const __vue_inject_styles__ = undefined;
|
|
60
|
+
/* scoped */
|
|
61
|
+
const __vue_scope_id__ = undefined;
|
|
62
|
+
/* module identifier */
|
|
63
|
+
const __vue_module_identifier__ = undefined;
|
|
64
|
+
/* functional template */
|
|
65
|
+
const __vue_is_functional_template__ = false;
|
|
66
|
+
/* style inject */
|
|
67
|
+
|
|
68
|
+
/* style inject SSR */
|
|
69
|
+
|
|
70
|
+
/* style inject shadow dom */
|
|
71
|
+
|
|
72
|
+
|
|
73
|
+
|
|
74
|
+
const __vue_component__ = /*#__PURE__*/__vue_normalize__(
|
|
75
|
+
{ render: __vue_render__, staticRenderFns: __vue_staticRenderFns__ },
|
|
76
|
+
__vue_inject_styles__,
|
|
77
|
+
__vue_script__,
|
|
78
|
+
__vue_scope_id__,
|
|
79
|
+
__vue_is_functional_template__,
|
|
80
|
+
__vue_module_identifier__,
|
|
81
|
+
false,
|
|
82
|
+
undefined,
|
|
83
|
+
undefined,
|
|
84
|
+
undefined
|
|
85
|
+
);
|
|
86
|
+
|
|
87
|
+
export { __vue_component__ as default };
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
export { default as GlTableLite } from './base/table_lite/table_lite';
|
|
2
|
+
export { default as GlDropdownForm } from './base/dropdown/dropdown_form';
|
|
3
|
+
export { default as GlKeysetPagination } from './base/keyset_pagination/keyset_pagination';
|
|
4
|
+
export { default as GlInputGroupText } from './base/form/input_group_text/input_group_text';
|
|
5
|
+
export { default as GlFormCombobox } from './base/form/form_combobox/form_combobox';
|
|
6
|
+
export { default as GlTokenSelector } from './base/token_selector/token_selector';
|
|
7
|
+
export { default as GlMarkdown } from './base/markdown/markdown';
|
|
8
|
+
export { default as GlDeprecatedLink, default as GlLink } from './base/link/link';
|
|
9
|
+
export { default as GlIcon } from './base/icon/icon';
|
|
10
|
+
export { default as GlIllustration } from './base/illustration/illustration';
|
|
11
|
+
export { default as GlAnimatedChevronRightDownIcon } from './base/animated_icon/animated_chevron_right_down_icon';
|
|
12
|
+
export { default as GlAnimatedChevronLgRightDownIcon } from './base/animated_icon/animated_chevron_lg_right_down_icon';
|
|
13
|
+
export { default as GlAnimatedChevronDownUpIcon } from './base/animated_icon/animated_chevron_down_up_icon';
|
|
14
|
+
export { default as GlAnimatedChevronLgDownUpIcon } from './base/animated_icon/animated_chevron_lg_down_up_icon';
|
|
15
|
+
export { default as GlAnimatedDuoChatIcon } from './base/animated_icon/animated_duo_chat_icon';
|
|
16
|
+
export { default as GlAnimatedLoaderIcon } from './base/animated_icon/animated_loader_icon';
|
|
17
|
+
export { default as GlAnimatedNotificationIcon } from './base/animated_icon/animated_notifications_icon';
|
|
18
|
+
export { default as GlAnimatedSidebarIcon } from './base/animated_icon/animated_sidebar_icon';
|
|
19
|
+
export { default as GlAnimatedSmileIcon } from './base/animated_icon/animated_smile_icon';
|
|
20
|
+
export { default as GlAnimatedSortIcon } from './base/animated_icon/animated_sort_icon';
|
|
21
|
+
export { default as GlAnimatedStarIcon } from './base/animated_icon/animated_star_icon';
|
|
22
|
+
export { default as GlAnimatedTodoIcon } from './base/animated_icon/animated_todo_icon';
|
|
23
|
+
export { default as GlAnimatedUploadIcon } from './base/animated_icon/animated_upload_icon';
|
|
24
|
+
export { default as GlAttributeList } from './base/attribute_list/attribute_list';
|
|
25
|
+
export { default as GlLoadingIcon } from './base/loading_icon/loading_icon';
|
|
26
|
+
export { default as GlModal } from './base/modal/modal';
|
|
27
|
+
export { default as GlPagination } from './base/pagination/pagination';
|
|
28
|
+
export { default as GlPopover } from './base/popover/popover';
|
|
29
|
+
export { default as GlProgressBar } from './base/progress_bar/progress_bar';
|
|
30
|
+
export { default as GlToken } from './base/token/token';
|
|
31
|
+
export { default as GlBadge } from './base/badge/badge';
|
|
32
|
+
export { default as GlBanner } from './base/banner/banner';
|
|
33
|
+
export { default as GlButton } from './base/button/button';
|
|
34
|
+
export { default as GlTooltip } from './base/tooltip/tooltip';
|
|
35
|
+
export { default as GlToast } from './base/toast';
|
|
36
|
+
export { default as GlDashboardSkeleton } from './regions/dashboard_skeleton/dashboard_skeleton';
|
|
37
|
+
export { default as GlEmptyState } from './regions/empty_state/empty_state';
|
|
38
|
+
export { default as GlForm } from './base/form/form';
|
|
39
|
+
export { default as GlFormCharacterCount } from './base/form/form_character_count/form_character_count';
|
|
40
|
+
export { default as GlFormDate } from './base/form/form_date/form_date';
|
|
41
|
+
export { default as GlFormInput } from './base/form/form_input/form_input';
|
|
42
|
+
export { default as GlFormInputGroup } from './base/form/form_input_group/form_input_group';
|
|
43
|
+
export { default as GlFormRadio } from './base/form/form_radio/form_radio';
|
|
44
|
+
export { default as GlFormRadioGroup } from './base/form/form_radio_group/form_radio_group';
|
|
45
|
+
export { default as GlFormSelect } from './base/form/form_select/form_select';
|
|
46
|
+
export { default as GlFormTextarea } from './base/form/form_textarea/form_textarea';
|
|
47
|
+
export { default as GlFormGroup } from './base/form/form_group/form_group';
|
|
48
|
+
export { default as GlFormFields } from './base/form/form_fields/form_fields';
|
|
49
|
+
export { default as GlSearchBoxByType } from './base/search_box_by_type/search_box_by_type';
|
|
50
|
+
export { default as GlSearchBoxByClick } from './base/search_box_by_click/search_box_by_click';
|
|
51
|
+
export { default as GlDropdownItem } from './base/dropdown/dropdown_item';
|
|
52
|
+
export { default as GlDropdownSectionHeader } from './base/dropdown/dropdown_section_header';
|
|
53
|
+
export { default as GlDropdownDivider } from './base/dropdown/dropdown_divider';
|
|
54
|
+
export { default as GlDropdownText } from './base/dropdown/dropdown_text';
|
|
55
|
+
export { default as GlDropdown } from './base/dropdown/dropdown';
|
|
56
|
+
export { default as GlCollapsibleListbox } from './base/new_dropdowns/listbox/listbox';
|
|
57
|
+
export { default as GlListboxItem } from './base/new_dropdowns/listbox/listbox_item';
|
|
58
|
+
export { default as GlDisclosureDropdown } from './base/new_dropdowns/disclosure/disclosure_dropdown';
|
|
59
|
+
export { default as GlDisclosureDropdownItem } from './base/new_dropdowns/disclosure/disclosure_dropdown_item';
|
|
60
|
+
export { default as GlDisclosureDropdownGroup } from './base/new_dropdowns/disclosure/disclosure_dropdown_group';
|
|
61
|
+
export { default as GlPath } from './base/path/path';
|
|
62
|
+
export { default as GlTable } from './base/table/table';
|
|
63
|
+
export { default as GlBreadcrumb } from './base/breadcrumb/breadcrumb';
|
|
64
|
+
export { default as GlScrollableTabs } from './base/tabs/tabs/scrollable_tabs';
|
|
65
|
+
export { default as GlTabs } from './base/tabs/tabs/tabs';
|
|
66
|
+
export { default as GlTab } from './base/tabs/tab/tab';
|
|
67
|
+
export { default as GlButtonGroup } from './base/button_group/button_group';
|
|
68
|
+
export { default as GlFormCheckbox } from './base/form/form_checkbox/form_checkbox';
|
|
69
|
+
export { default as GlFormCheckboxGroup } from './base/form/form_checkbox/form_checkbox_group';
|
|
70
|
+
export { default as GlAvatar } from './base/avatar/avatar';
|
|
71
|
+
export { default as GlAvatarsInline } from './base/avatars_inline/avatars_inline';
|
|
72
|
+
export { default as GlAvatarLabeled } from './base/avatar_labeled/avatar_labeled';
|
|
73
|
+
export { default as GlAvatarLink } from './base/avatar_link/avatar_link';
|
|
74
|
+
export { default as GlLabel } from './base/label/label';
|
|
75
|
+
export { default as GlDatepicker } from './base/datepicker/datepicker';
|
|
76
|
+
export { default as GlDaterangePicker } from './base/daterange_picker/daterange_picker';
|
|
77
|
+
export { default as GlToggle } from './base/toggle/toggle';
|
|
78
|
+
export { default as GlColorModeToggle } from './base/color_mode_toggle/color_mode_toggle';
|
|
79
|
+
export { default as GlSorting } from './base/sorting/sorting';
|
|
80
|
+
export { default as GlInfiniteScroll } from './base/infinite_scroll/infinite_scroll';
|
|
81
|
+
export { default as GlAlert } from './base/alert/alert';
|
|
82
|
+
export { default as GlSegmentedControl } from './base/segmented_control/segmented_control';
|
|
83
|
+
export { default as GlSkeletonLoader } from './base/skeleton_loader/skeleton_loader';
|
|
84
|
+
export { default as GlDrawer } from './base/drawer/drawer';
|
|
85
|
+
export { default as GlCard } from './base/card/card';
|
|
86
|
+
export { default as GlFilteredSearchSuggestion } from './base/filtered_search/filtered_search_suggestion';
|
|
87
|
+
export { default as GlFilteredSearchSuggestionList } from './base/filtered_search/filtered_search_suggestion_list';
|
|
88
|
+
export { default as GlFilteredSearchTerm } from './base/filtered_search/filtered_search_term';
|
|
89
|
+
export { default as GlFilteredSearchToken } from './base/filtered_search/filtered_search_token';
|
|
90
|
+
export { default as GlFilteredSearchTokenSegment } from './base/filtered_search/filtered_search_token_segment';
|
|
91
|
+
export { default as GlFilteredSearch } from './base/filtered_search/filtered_search';
|
|
92
|
+
export { default as GlBroadcastMessage } from './base/broadcast_message/broadcast_message';
|
|
93
|
+
export { default as GlCollapse } from './base/collapse/collapse';
|
|
94
|
+
export { default as GlAccordion } from './base/accordion/accordion';
|
|
95
|
+
export { default as GlAccordionItem } from './base/accordion/accordion_item';
|
|
96
|
+
export { default as GlDashboardLayout } from './dashboards/dashboard_layout/dashboard_layout';
|
|
97
|
+
export { default as GlDashboardPanel } from './dashboards/dashboard_panel/dashboard_panel';
|
|
98
|
+
export { default as GlExperimentBadge } from './experimental/experiment_badge/experiment_badge';
|
|
99
|
+
export { default as GlClipboardButton } from './shared_components/clipboard_button/clipboard_button';
|
|
100
|
+
export { default as GlAnimatedNumber } from './utilities/animated_number/animated_number';
|
|
101
|
+
export { default as GlFriendlyWrap } from './utilities/friendly_wrap/friendly_wrap';
|
|
102
|
+
export { default as GlIntersectionObserver } from './utilities/intersection_observer/intersection_observer';
|
|
103
|
+
export { default as GlIntersperse } from './utilities/intersperse/intersperse';
|
|
104
|
+
export { default as GlSprintf } from './utilities/sprintf/sprintf';
|
|
105
|
+
export { default as GlTruncate } from './utilities/truncate/truncate';
|
|
106
|
+
export { default as GlTruncateText } from './utilities/truncate_text/truncate_text';
|
|
107
|
+
export { default as GlMultiStepFormTemplate } from './extended/multi_step_form_template/multi_step_form_template';
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { SafeLinkDirective } from '../../directives/safe_link/safe_link';
|
|
2
|
+
|
|
3
|
+
const SafeLinkMixin = {
|
|
4
|
+
directives: {
|
|
5
|
+
SafeLink: SafeLinkDirective
|
|
6
|
+
},
|
|
7
|
+
props: {
|
|
8
|
+
isUnsafeLink: {
|
|
9
|
+
type: Boolean,
|
|
10
|
+
required: false,
|
|
11
|
+
default: false
|
|
12
|
+
},
|
|
13
|
+
// This prevents bootstrap-vue from setting target="_self"
|
|
14
|
+
// when target attribute is not present
|
|
15
|
+
target: {
|
|
16
|
+
type: String,
|
|
17
|
+
required: false,
|
|
18
|
+
default: null
|
|
19
|
+
}
|
|
20
|
+
},
|
|
21
|
+
computed: {
|
|
22
|
+
safeLinkConfig() {
|
|
23
|
+
return {
|
|
24
|
+
skipSanitization: this.isUnsafeLink
|
|
25
|
+
};
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
};
|
|
29
|
+
|
|
30
|
+
export { SafeLinkMixin };
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { tooltipActionEvents } from '../../utils/constants';
|
|
2
|
+
|
|
3
|
+
// eslint-disable-next-line import/no-default-export
|
|
4
|
+
var tooltip_mixin = tooltipRefName => ({
|
|
5
|
+
mounted() {
|
|
6
|
+
/**
|
|
7
|
+
* Pass through the events to programmatically open, close, enable
|
|
8
|
+
* and disable a tooltip or a popover.
|
|
9
|
+
*
|
|
10
|
+
* References
|
|
11
|
+
* https://bootstrap-vue.org/docs/components/popover#programmatically-show-and-hide-popover
|
|
12
|
+
* https://bootstrap-vue.org/docs/components/tooltip#programmatically-show-and-hide-tooltip
|
|
13
|
+
*/
|
|
14
|
+
tooltipActionEvents.forEach(event => this.$on(event, () => this.$refs[tooltipRefName][event]()));
|
|
15
|
+
},
|
|
16
|
+
beforeDestroy() {
|
|
17
|
+
tooltipActionEvents.forEach(event => this.$off(event));
|
|
18
|
+
}
|
|
19
|
+
});
|
|
20
|
+
|
|
21
|
+
export { tooltip_mixin as default };
|