@gitlab/ui 134.8.0 → 135.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (152) hide show
  1. package/dist/components/base/animated_icon/base_animated_icon.js +3 -0
  2. package/dist/components/base/color_mode_toggle/color_mode_toggle.js +11 -1
  3. package/dist/components/base/filtered_search/filtered_search.js +9 -0
  4. package/dist/components/base/filtered_search/filtered_search_suggestion.js +3 -0
  5. package/dist/components/base/filtered_search/filtered_search_term.js +9 -0
  6. package/dist/components/base/filtered_search/filtered_search_token.js +15 -0
  7. package/dist/components/base/filtered_search/filtered_search_token_segment.js +27 -0
  8. package/dist/components/base/form/form_combobox/form_combobox.js +18 -0
  9. package/dist/components/base/form/form_date/form_date.js +18 -0
  10. package/dist/components/base/form/form_fields/form_field_validator.js +9 -0
  11. package/dist/components/base/form/form_fields/form_fields_loop.js +3 -0
  12. package/dist/components/base/markdown/markdown.js +3 -0
  13. package/dist/components/base/new_dropdowns/base_dropdown/base_dropdown.js +54 -0
  14. package/dist/components/base/new_dropdowns/disclosure/disclosure_dropdown_item.js +3 -0
  15. package/dist/components/base/new_dropdowns/listbox/listbox.js +4 -1
  16. package/dist/components/base/new_dropdowns/listbox/listbox_group.js +6 -0
  17. package/dist/components/base/new_dropdowns/listbox/listbox_item.js +15 -0
  18. package/dist/components/base/search_box_by_click/search_box_by_click.js +6 -0
  19. package/dist/components/base/segmented_control/segmented_control.js +6 -0
  20. package/dist/components/base/table_lite/table_lite.js +9 -0
  21. package/dist/components/base/tabs/tab/tab.js +3 -0
  22. package/dist/components/base/tabs/tabs/tabs.js +21 -0
  23. package/dist/components/base/toast/toast.js +12 -0
  24. package/dist/components/base/toggle/toggle.js +3 -0
  25. package/dist/components/base/token_selector/token_container.js +12 -0
  26. package/dist/components/base/token_selector/token_selector_dropdown.js +27 -0
  27. package/dist/components/charts/area/area.js +36 -0
  28. package/dist/components/charts/bar/bar.js +15 -0
  29. package/dist/components/charts/chart/chart.js +7 -1
  30. package/dist/components/charts/column/column.js +24 -0
  31. package/dist/components/charts/discrete_scatter/discrete_scatter.js +21 -0
  32. package/dist/components/charts/gauge/gauge.js +21 -0
  33. package/dist/components/charts/heatmap/heatmap.js +33 -0
  34. package/dist/components/charts/legend/legend.js +15 -0
  35. package/dist/components/charts/line/line.js +33 -0
  36. package/dist/components/charts/series_label/series_label.js +6 -0
  37. package/dist/components/charts/shared/tooltip/tooltip.js +6 -0
  38. package/dist/components/charts/shared/tooltip/tooltip_default_format/tooltip_default_format.js +3 -0
  39. package/dist/components/charts/single_stat/single_stat.js +30 -0
  40. package/dist/components/charts/stacked_column/stacked_column.js +55 -0
  41. package/dist/components/regions/empty_state/empty_state.js +3 -0
  42. package/dist/components/shared_components/clear_icon_button/clear_icon_button.js +6 -0
  43. package/dist/components/shared_components/close_button/close_button.js +3 -0
  44. package/dist/components/utilities/animated_number/animated_number.js +9 -0
  45. package/dist/components/utilities/intersperse/intersperse.js +6 -0
  46. package/dist/index.css +2 -2
  47. package/dist/index.css.map +1 -1
  48. package/dist/tailwind.css +1 -1
  49. package/dist/tailwind.css.map +1 -1
  50. package/dist/tokens/build/js/tokens.dark.js +3 -3
  51. package/dist/tokens/build/js/tokens.js +3 -3
  52. package/dist/tokens/tokens_story.js +3 -0
  53. package/package.json +8 -7
  54. package/src/components/base/animated_icon/base_animated_icon.vue +3 -0
  55. package/src/components/base/avatar_link/avatar_link.scss +2 -2
  56. package/src/components/base/badge/badge.scss +3 -3
  57. package/src/components/base/breadcrumb/breadcrumb.scss +2 -2
  58. package/src/components/base/button/button.scss +15 -15
  59. package/src/components/base/button_group/button_group.scss +1 -1
  60. package/src/components/base/color_mode_toggle/color_mode_toggle.vue +11 -0
  61. package/src/components/base/datepicker/datepicker.scss +1 -1
  62. package/src/components/base/dropdown/dropdown_item.scss +3 -3
  63. package/src/components/base/filtered_search/filtered_search.vue +9 -0
  64. package/src/components/base/filtered_search/filtered_search_suggestion.vue +3 -0
  65. package/src/components/base/filtered_search/filtered_search_term.vue +9 -0
  66. package/src/components/base/filtered_search/filtered_search_token.vue +15 -0
  67. package/src/components/base/filtered_search/filtered_search_token_segment.vue +27 -0
  68. package/src/components/base/form/form_checkbox/form_checkbox.scss +9 -7
  69. package/src/components/base/form/form_combobox/form_combobox.scss +4 -4
  70. package/src/components/base/form/form_combobox/form_combobox.vue +18 -0
  71. package/src/components/base/form/form_date/form_date.vue +18 -0
  72. package/src/components/base/form/form_fields/form_field_validator.vue +9 -0
  73. package/src/components/base/form/form_fields/form_fields_loop.vue +3 -0
  74. package/src/components/base/form/form_input/form_input.scss +2 -2
  75. package/src/components/base/form/form_select/form_select.scss +3 -3
  76. package/src/components/base/icon/icon.figma.batch.ts +26 -0
  77. package/src/components/base/label/label.scss +9 -9
  78. package/src/components/base/link/link.scss +11 -11
  79. package/src/components/base/markdown/markdown.vue +3 -0
  80. package/src/components/base/nav_item/nav_item.scss +5 -5
  81. package/src/components/base/new_dropdowns/base_dropdown/base_dropdown.vue +54 -0
  82. package/src/components/base/new_dropdowns/disclosure/disclosure_dropdown_item.vue +3 -0
  83. package/src/components/base/new_dropdowns/dropdown.scss +2 -2
  84. package/src/components/base/new_dropdowns/dropdown_item.scss +9 -9
  85. package/src/components/base/new_dropdowns/listbox/listbox.scss +1 -1
  86. package/src/components/base/new_dropdowns/listbox/listbox.vue +5 -2
  87. package/src/components/base/new_dropdowns/listbox/listbox_group.vue +6 -0
  88. package/src/components/base/new_dropdowns/listbox/listbox_item.vue +15 -0
  89. package/src/components/base/pagination/pagination.scss +3 -2
  90. package/src/components/base/path/path.scss +3 -3
  91. package/src/components/base/search_box_by_click/search_box_by_click.vue +6 -0
  92. package/src/components/base/search_box_by_type/search_box_by_type.scss +1 -1
  93. package/src/components/base/segmented_control/segmented_control.vue +6 -0
  94. package/src/components/base/table_lite/table_lite.vue +9 -0
  95. package/src/components/base/tabs/tab/tab.vue +3 -0
  96. package/src/components/base/tabs/tabs/tabs.scss +3 -3
  97. package/src/components/base/tabs/tabs/tabs.vue +21 -0
  98. package/src/components/base/toast/toast.vue +12 -0
  99. package/src/components/base/toggle/toggle.scss +4 -4
  100. package/src/components/base/toggle/toggle.vue +3 -0
  101. package/src/components/base/token_selector/token_container.vue +12 -0
  102. package/src/components/base/token_selector/token_selector.scss +1 -1
  103. package/src/components/base/token_selector/token_selector_dropdown.vue +27 -0
  104. package/src/components/charts/area/area.vue +36 -0
  105. package/src/components/charts/bar/bar.vue +15 -0
  106. package/src/components/charts/chart/chart.vue +7 -1
  107. package/src/components/charts/column/column.vue +24 -0
  108. package/src/components/charts/discrete_scatter/discrete_scatter.vue +21 -0
  109. package/src/components/charts/gauge/gauge.vue +21 -0
  110. package/src/components/charts/heatmap/heatmap.vue +33 -0
  111. package/src/components/charts/legend/legend.vue +15 -0
  112. package/src/components/charts/line/line.vue +33 -0
  113. package/src/components/charts/series_label/series_label.vue +6 -0
  114. package/src/components/charts/shared/tooltip/tooltip.vue +6 -0
  115. package/src/components/charts/shared/tooltip/tooltip_default_format/tooltip_default_format.vue +3 -0
  116. package/src/components/charts/single_stat/single_stat.vue +30 -0
  117. package/src/components/charts/stacked_column/stacked_column.vue +55 -0
  118. package/src/components/regions/empty_state/empty_state.vue +3 -0
  119. package/src/components/shared_components/clear_icon_button/clear_icon_button.scss +1 -1
  120. package/src/components/shared_components/clear_icon_button/clear_icon_button.vue +6 -0
  121. package/src/components/shared_components/close_button/close_button.vue +3 -0
  122. package/src/components/utilities/animated_number/animated_number.vue +9 -0
  123. package/src/components/utilities/intersperse/intersperse.vue +6 -0
  124. package/src/scss/mixins.scss +1 -1
  125. package/src/tokens/build/css/tokens.css +3 -3
  126. package/src/tokens/build/css/tokens.dark.css +3 -3
  127. package/src/tokens/build/figma/mode.dark.json +37 -20
  128. package/src/tokens/build/figma/mode.json +37 -20
  129. package/src/tokens/build/js/tokens.dark.js +3 -3
  130. package/src/tokens/build/js/tokens.js +3 -3
  131. package/src/tokens/build/json/tokens.dark.json +74 -40
  132. package/src/tokens/build/json/tokens.json +74 -40
  133. package/src/tokens/build/scss/_tokens.dark.scss +3 -3
  134. package/src/tokens/build/scss/_tokens.scss +3 -3
  135. package/src/tokens/contextual/toggle.tokens.json +37 -20
  136. package/src/tokens/tokens_story.vue +3 -0
  137. package/src/utils/string_utils.js +1 -1
  138. package/src/vendor/bootstrap/scss/_button-group.scss +1 -1
  139. package/src/vendor/bootstrap/scss/_buttons.scss +3 -3
  140. package/src/vendor/bootstrap/scss/_custom-forms.scss +5 -5
  141. package/src/vendor/bootstrap/scss/_forms.scss +2 -2
  142. package/src/vendor/bootstrap/scss/_input-group.scss +5 -5
  143. package/src/vendor/bootstrap/scss/_pagination.scss +1 -1
  144. package/src/vendor/bootstrap/scss/mixins/_badge.scss +1 -1
  145. package/src/vendor/bootstrap/scss/mixins/_buttons.scss +5 -5
  146. package/src/vendor/bootstrap/scss/mixins/_forms.scss +5 -5
  147. package/src/vendor/bootstrap/scss/mixins/_hover.scss +3 -3
  148. package/src/vendor/bootstrap/scss/mixins/_screen-reader.scss +1 -1
  149. package/src/vendor/bootstrap-vue/src/_utilities.scss +1 -1
  150. package/src/vendor/bootstrap-vue/src/components/dropdown/_dropdown-form.scss +2 -2
  151. package/src/vendor/bootstrap-vue/src/components/dropdown/_dropdown.scss +1 -1
  152. package/tailwind.defaults.js +5 -5
@@ -23,7 +23,7 @@
23
23
  }
24
24
  }
25
25
 
26
- &:not(.disabled):focus {
26
+ &:not(.disabled):focus-visible {
27
27
  .gl-new-dropdown-item-content {
28
28
  color: var(--gl-dropdown-option-text-color-focus);
29
29
  background-color: var(--gl-dropdown-option-background-color-unselected-focus);
@@ -31,7 +31,7 @@
31
31
  }
32
32
 
33
33
  &:not(.disabled):active,
34
- &:not(.disabled):focus:active {
34
+ &:not(.disabled):focus-visible:active {
35
35
  .gl-new-dropdown-item-content {
36
36
  color: var(--gl-dropdown-option-text-color-active);
37
37
  background-color: var(--gl-dropdown-option-background-color-unselected-active);
@@ -59,7 +59,7 @@
59
59
  }
60
60
  }
61
61
 
62
- &:not(.disabled):focus {
62
+ &:not(.disabled):focus-visible {
63
63
  .gl-new-dropdown-item-content {
64
64
  background-color: var(--gl-dropdown-option-background-color-selected-focus);
65
65
  }
@@ -70,7 +70,7 @@
70
70
  }
71
71
 
72
72
  &:not(.disabled):active,
73
- &:not(.disabled):focus:active {
73
+ &:not(.disabled):focus-visible:active {
74
74
  .gl-new-dropdown-item-content {
75
75
  background-color: var(--gl-dropdown-option-background-color-selected-active);
76
76
  }
@@ -86,14 +86,14 @@
86
86
  }
87
87
 
88
88
  &:not(.disabled):active,
89
- &:not(.disabled):focus,
90
- &:not(.disabled):focus:active {
89
+ &:not(.disabled):focus-visible,
90
+ &:not(.disabled):focus-visible:active {
91
91
  .gl-new-dropdown-item-content {
92
92
  @include gl-focus($inset: true);
93
93
  }
94
94
  }
95
95
 
96
- &:focus {
96
+ &:focus-visible {
97
97
  .gl-new-dropdown-item-content {
98
98
  z-index: 1;
99
99
  }
@@ -180,7 +180,7 @@
180
180
  }
181
181
  }
182
182
 
183
- &:focus {
183
+ &:focus-visible {
184
184
  .gl-new-dropdown-item-content {
185
185
  color: var(--gl-action-danger-foreground-color-focus);
186
186
  background-color: var(--gl-action-danger-background-color-focus);
@@ -188,7 +188,7 @@
188
188
  }
189
189
 
190
190
  &:active,
191
- &:focus:active {
191
+ &:focus-visible:active {
192
192
  .gl-new-dropdown-item-content {
193
193
  color: var(--gl-action-danger-foreground-color-active);
194
194
  background-color: var(--gl-action-danger-background-color-active);
@@ -17,7 +17,7 @@ $clear-button-size: 24px;
17
17
  @apply gl-text-default;
18
18
  background-color: var(--gl-dropdown-search-background-color);
19
19
 
20
- &:focus {
20
+ &:focus-visible {
21
21
  @include gl-focus($inset: true);
22
22
  }
23
23
 
@@ -380,6 +380,9 @@ export default {
380
380
  required: false,
381
381
  default: false,
382
382
  },
383
+ /**
384
+ * Screen-reader-only label for results count.
385
+ */
383
386
  srOnlyResultsLabel: {
384
387
  type: Function,
385
388
  required: false,
@@ -1065,7 +1068,7 @@ export default {
1065
1068
  <gl-button
1066
1069
  v-if="showResetButton"
1067
1070
  category="tertiary"
1068
- class="!gl-m-0 !gl-w-auto gl-max-w-1/2 gl-flex-shrink-0 gl-text-ellipsis !gl-px-2 !gl-text-sm focus:!gl-focus-inset"
1071
+ class="!gl-m-0 !gl-w-auto gl-max-w-1/2 gl-flex-shrink-0 gl-text-ellipsis !gl-px-2 !gl-text-sm focus-visible:!gl-focus-inset"
1069
1072
  size="small"
1070
1073
  data-testid="listbox-reset-button"
1071
1074
  @click="onResetButtonClicked"
@@ -1075,7 +1078,7 @@ export default {
1075
1078
  <gl-button
1076
1079
  v-if="showSelectAllButton"
1077
1080
  category="tertiary"
1078
- class="!gl-m-0 !gl-w-auto gl-max-w-1/2 gl-flex-shrink-0 gl-text-ellipsis !gl-px-2 !gl-text-sm focus:!gl-focus-inset"
1081
+ class="!gl-m-0 !gl-w-auto gl-max-w-1/2 gl-flex-shrink-0 gl-text-ellipsis !gl-px-2 !gl-text-sm focus-visible:!gl-focus-inset"
1079
1082
  size="small"
1080
1083
  data-testid="listbox-select-all-button"
1081
1084
  @click="onSelectAllButtonClicked"
@@ -4,10 +4,16 @@ import { uniqueId } from 'lodash-es';
4
4
  export default {
5
5
  name: 'GlListboxGroup',
6
6
  props: {
7
+ /**
8
+ * The display name of the listbox group.
9
+ */
7
10
  name: {
8
11
  type: String,
9
12
  required: true,
10
13
  },
14
+ /**
15
+ * When true, visually hides the group name while keeping it accessible to screen readers.
16
+ */
11
17
  textSrOnly: {
12
18
  type: Boolean,
13
19
  required: false,
@@ -9,26 +9,41 @@ export default {
9
9
  GlIcon,
10
10
  },
11
11
  props: {
12
+ /**
13
+ * When true, marks the item as selected.
14
+ */
12
15
  isSelected: {
13
16
  type: Boolean,
14
17
  default: false,
15
18
  required: false,
16
19
  },
20
+ /**
21
+ * When true, marks the item as focused.
22
+ */
17
23
  isFocused: {
18
24
  type: Boolean,
19
25
  default: false,
20
26
  required: false,
21
27
  },
28
+ /**
29
+ * When true, centers the check icon.
30
+ */
22
31
  isCheckCentered: {
23
32
  type: Boolean,
24
33
  required: false,
25
34
  default: false,
26
35
  },
36
+ /**
37
+ * When true, highlights the item.
38
+ */
27
39
  isHighlighted: {
28
40
  type: Boolean,
29
41
  default: false,
30
42
  required: false,
31
43
  },
44
+ /**
45
+ * When true, disables the item.
46
+ */
32
47
  isDisabled: {
33
48
  type: Boolean,
34
49
  default: false,
@@ -5,6 +5,7 @@
5
5
  ul {
6
6
  border-radius: var(--gl-action-border-radius);
7
7
  @apply gl-flex;
8
+ @apply gl-m-0;
8
9
  @apply gl-pl-0;
9
10
  @apply gl-list-none;
10
11
  }
@@ -37,8 +38,8 @@
37
38
  @apply gl-no-underline;
38
39
  }
39
40
 
40
- &:focus,
41
- &:active:focus {
41
+ &:focus-visible,
42
+ &:active:focus-visible {
42
43
  @apply gl-no-underline;
43
44
  @apply gl-focus;
44
45
  }
@@ -91,7 +91,7 @@ $path-chevron-right-margin: px-to-rem(14px);
91
91
  color: var(--gl-action-neutral-foreground-color-hover);
92
92
  }
93
93
 
94
- &:focus {
94
+ &:focus-visible {
95
95
  background-color: var(--gl-action-neutral-background-color-focus);
96
96
  color: var(--gl-action-neutral-foreground-color-focus);
97
97
  }
@@ -102,8 +102,8 @@ $path-chevron-right-margin: px-to-rem(14px);
102
102
  }
103
103
 
104
104
  &:active,
105
- &:focus,
106
- &:focus:active {
105
+ &:focus-visible,
106
+ &:focus-visible:active {
107
107
  // Custom focus to account for path shape
108
108
  box-shadow:
109
109
  5px -3px 0 -2px var(--gl-focus-ring-inner-color),
@@ -47,6 +47,9 @@ export default {
47
47
  required: false,
48
48
  default: 'Search',
49
49
  },
50
+ /**
51
+ * When true, shows a clear button to reset the search.
52
+ */
50
53
  clearable: {
51
54
  type: Boolean,
52
55
  required: false,
@@ -92,6 +95,9 @@ export default {
92
95
  required: false,
93
96
  default: 'Clear recent searches',
94
97
  },
98
+ /**
99
+ * Text displayed when there are no recent searches.
100
+ */
95
101
  noRecentSearchesText: {
96
102
  type: String,
97
103
  required: false,
@@ -47,7 +47,7 @@ $gl-search-box-by-type-input-padding: 3.5 * $grid-size;
47
47
  border-radius: 0;
48
48
  padding-right: calc(#{$gl-spacing-scale-6} + #{$gl-spacing-scale-2});
49
49
 
50
- &:not(.form-control-plaintext):focus {
50
+ &:not(.form-control-plaintext):focus-visible {
51
51
  @include gl-focus($inset: true);
52
52
  }
53
53
 
@@ -24,11 +24,17 @@ export default {
24
24
  GlButton,
25
25
  },
26
26
  props: {
27
+ /**
28
+ * Array of option objects for the segmented control.
29
+ */
27
30
  options: {
28
31
  type: Array,
29
32
  required: true,
30
33
  validator: validateOptionsProp,
31
34
  },
35
+ /**
36
+ * The currently selected value.
37
+ */
32
38
  value: {
33
39
  type: [String, Number, Boolean],
34
40
  required: true,
@@ -10,6 +10,9 @@ export default {
10
10
  },
11
11
  inheritAttrs: false,
12
12
  props: {
13
+ /**
14
+ * Additional CSS classes to apply to the table element.
15
+ */
13
16
  tableClass,
14
17
  /**
15
18
  * Array of items displayed in the table as rows.
@@ -19,11 +22,17 @@ export default {
19
22
  required: false,
20
23
  default: () => [],
21
24
  },
25
+ /**
26
+ * Array of field definitions for table columns.
27
+ */
22
28
  fields: {
23
29
  type: Array,
24
30
  required: false,
25
31
  default: null,
26
32
  },
33
+ /**
34
+ * When true, makes the table header sticky.
35
+ */
27
36
  stickyHeader: {
28
37
  type: Boolean,
29
38
  default: false,
@@ -14,6 +14,9 @@ export default {
14
14
  },
15
15
  inheritAttrs: false,
16
16
  props: {
17
+ /**
18
+ * Additional CSS classes to apply to the tab title link.
19
+ */
17
20
  titleLinkClass: {
18
21
  type: [String, Array, Object],
19
22
  required: false,
@@ -48,7 +48,7 @@
48
48
  translate: 0;
49
49
  }
50
50
 
51
- &:focus {
51
+ &:focus-visible {
52
52
  @apply gl-rounded-default;
53
53
  }
54
54
 
@@ -80,8 +80,8 @@
80
80
  z-index: 1;
81
81
 
82
82
  &:active,
83
- &:focus,
84
- &:focus:active {
83
+ &:focus-visible,
84
+ &:focus-visible:active {
85
85
  @include gl-focus($color: var(--gl-action-neutral-border-color-active));
86
86
 
87
87
  .gl-scrollable-tabs-nav & {
@@ -14,34 +14,52 @@ export default {
14
14
  },
15
15
  inheritAttrs: false,
16
16
  props: {
17
+ /**
18
+ * Configuration for the primary action button in the tabs.
19
+ */
17
20
  actionPrimary: {
18
21
  type: Object,
19
22
  required: false,
20
23
  default: null,
21
24
  validator: (obj) => validatorHelper(obj),
22
25
  },
26
+ /**
27
+ * Configuration for the secondary action button in the tabs.
28
+ */
23
29
  actionSecondary: {
24
30
  type: Object,
25
31
  required: false,
26
32
  default: null,
27
33
  validator: (obj) => validatorHelper(obj),
28
34
  },
35
+ /**
36
+ * Configuration for the tertiary action button in the tabs.
37
+ */
29
38
  actionTertiary: {
30
39
  type: Object,
31
40
  required: false,
32
41
  default: null,
33
42
  validator: (obj) => validatorHelper(obj),
34
43
  },
44
+ /**
45
+ * Additional CSS classes to apply to the tab content area.
46
+ */
35
47
  contentClass: {
36
48
  type: [String, Array, Object],
37
49
  required: false,
38
50
  default: null,
39
51
  },
52
+ /**
53
+ * Additional CSS classes to apply to the tab navigation.
54
+ */
40
55
  navClass: {
41
56
  type: [String, Array, Object],
42
57
  required: false,
43
58
  default: null,
44
59
  },
60
+ /**
61
+ * When true, makes the tabs stretch to fill the available width.
62
+ */
45
63
  justified: {
46
64
  type: Boolean,
47
65
  required: false,
@@ -63,6 +81,9 @@ export default {
63
81
  required: false,
64
82
  default: 'tab',
65
83
  },
84
+ /**
85
+ * The currently active tab value.
86
+ */
66
87
  value: {
67
88
  type: Number,
68
89
  required: false,
@@ -11,19 +11,31 @@ export default {
11
11
  CloseButton,
12
12
  },
13
13
  props: {
14
+ /**
15
+ * Unique identifier for the toast notification.
16
+ */
14
17
  toastId: {
15
18
  type: String,
16
19
  required: true,
17
20
  },
21
+ /**
22
+ * The message text to display in the toast.
23
+ */
18
24
  message: {
19
25
  type: String,
20
26
  required: true,
21
27
  },
28
+ /**
29
+ * Action button configuration for the toast.
30
+ */
22
31
  action: {
23
32
  type: Object,
24
33
  required: false,
25
34
  default: null,
26
35
  },
36
+ /**
37
+ * Delay in milliseconds before auto-hiding the toast.
38
+ */
27
39
  autoHideDelay: {
28
40
  type: Number,
29
41
  required: false,
@@ -100,7 +100,7 @@ $toggle-height: 2.5 * $grid-size;
100
100
  }
101
101
  }
102
102
 
103
- &:focus {
103
+ &:focus-visible {
104
104
  color: var(--gl-toggle-switch-icon-color-unchecked-focus);
105
105
  background-color: var(--gl-toggle-switch-track-color-unchecked-focus);
106
106
  @include gl-focus($color: var(--gl-action-neutral-border-color-focus), $important: true);
@@ -167,7 +167,7 @@ $toggle-height: 2.5 * $grid-size;
167
167
  box-shadow: inset 0 0 0 $gl-border-size-1 var(--gl-action-neutral-border-color-hover);
168
168
  }
169
169
 
170
- &:focus {
170
+ &:focus-visible {
171
171
  color: var(--gl-toggle-switch-icon-color-checked-focus);
172
172
  background-color: var(--gl-toggle-switch-track-color-checked-focus);
173
173
  @include gl-focus($color: var(--gl-action-neutral-border-color-focus), $important: true);
@@ -214,8 +214,8 @@ $toggle-height: 2.5 * $grid-size;
214
214
  }
215
215
 
216
216
  &:active,
217
- &:focus,
218
- &:focus:active {
217
+ &:focus-visible,
218
+ &:focus-visible:active {
219
219
  @include gl-focus($color: var(--gl-action-disabled-border-color), $important: true);
220
220
  }
221
221
  }
@@ -18,6 +18,9 @@ export default {
18
18
  event: 'change',
19
19
  },
20
20
  props: {
21
+ /**
22
+ * The name attribute for the hidden input element.
23
+ */
21
24
  name: {
22
25
  type: String,
23
26
  required: false,
@@ -7,21 +7,33 @@ export default {
7
7
  name: 'GlTokenContainer',
8
8
  components: { GlToken, GlButton },
9
9
  props: {
10
+ /**
11
+ * Array of token objects to display.
12
+ */
10
13
  tokens: {
11
14
  type: Array,
12
15
  // All tokens need to have an `id` key
13
16
  validator: tokensValidator,
14
17
  required: true,
15
18
  },
19
+ /**
20
+ * Function to register focus handling on tokens.
21
+ */
16
22
  registerFocusOnToken: {
17
23
  type: Function,
18
24
  required: true,
19
25
  },
26
+ /**
27
+ * When true, renders tokens in a non-interactive view-only mode.
28
+ */
20
29
  viewOnly: {
21
30
  type: Boolean,
22
31
  required: false,
23
32
  default: false,
24
33
  },
34
+ /**
35
+ * When true, shows a button to clear all tokens.
36
+ */
25
37
  showClearAllButton: {
26
38
  type: Boolean,
27
39
  required: false,
@@ -14,7 +14,7 @@
14
14
  }
15
15
  }
16
16
 
17
- .gl-token-selector-token-container:focus .gl-token {
17
+ .gl-token-selector-token-container:focus-visible .gl-token {
18
18
  background-color: var(--gl-token-selector-token-container-token-background-color-focus);
19
19
  @apply gl-focus;
20
20
  }
@@ -7,42 +7,69 @@ export default {
7
7
  name: 'GlTokenSelectorDropdown',
8
8
  components: { GlDropdownItem },
9
9
  props: {
10
+ /**
11
+ * When true, shows the dropdown.
12
+ */
10
13
  show: {
11
14
  type: Boolean,
12
15
  required: true,
13
16
  },
17
+ /**
18
+ * Additional CSS classes for the dropdown menu.
19
+ */
14
20
  menuClass: {
15
21
  type: [String, Array, Object],
16
22
  required: false,
17
23
  default: '',
18
24
  },
25
+ /**
26
+ * When true, shows a loading state in the dropdown.
27
+ */
19
28
  loading: {
20
29
  type: Boolean,
21
30
  required: false,
22
31
  default: false,
23
32
  },
33
+ /**
34
+ * Array of items to display in the dropdown.
35
+ */
24
36
  dropdownItems: {
25
37
  type: Array,
26
38
  // All items need to have an `id` key
27
39
  validator: tokensValidator,
28
40
  required: true,
29
41
  },
42
+ /**
43
+ * Current text in the search input.
44
+ */
30
45
  inputText: {
31
46
  type: String,
32
47
  required: true,
33
48
  },
49
+ /**
50
+ * When true, allows user-defined tokens to be added.
51
+ */
34
52
  userDefinedTokenCanBeAdded: {
35
53
  type: Boolean,
36
54
  required: true,
37
55
  },
56
+ /**
57
+ * Unique identifier for the component.
58
+ */
38
59
  componentId: {
39
60
  type: String,
40
61
  required: true,
41
62
  },
63
+ /**
64
+ * Function to register event handlers for the dropdown.
65
+ */
42
66
  registerDropdownEventHandlers: {
43
67
  type: Function,
44
68
  required: true,
45
69
  },
70
+ /**
71
+ * Function to register reset of focused dropdown item.
72
+ */
46
73
  registerResetFocusedDropdownItem: {
47
74
  type: Function,
48
75
  required: true,
@@ -51,30 +51,48 @@ export default {
51
51
  },
52
52
  inheritAttrs: false,
53
53
  props: {
54
+ /**
55
+ * The chart data series to render.
56
+ */
54
57
  data: {
55
58
  type: Array,
56
59
  required: true,
57
60
  },
61
+ /**
62
+ * Additional ECharts option overrides.
63
+ */
58
64
  option: {
59
65
  type: Object,
60
66
  required: false,
61
67
  default: () => ({}),
62
68
  },
69
+ /**
70
+ * Array of threshold line configurations.
71
+ */
63
72
  thresholds: {
64
73
  type: Array,
65
74
  required: false,
66
75
  default: () => [],
67
76
  },
77
+ /**
78
+ * Array of annotation configurations.
79
+ */
68
80
  annotations: {
69
81
  type: Array,
70
82
  required: false,
71
83
  default: () => [],
72
84
  },
85
+ /**
86
+ * When true, includes average and maximum values in the legend.
87
+ */
73
88
  includeLegendAvgMax: {
74
89
  type: Boolean,
75
90
  required: false,
76
91
  default: true,
77
92
  },
93
+ /**
94
+ * Custom function to format annotation tooltip text.
95
+ */
78
96
  formatAnnotationsTooltipText: {
79
97
  type: Function,
80
98
  required: false,
@@ -91,26 +109,41 @@ export default {
91
109
  required: false,
92
110
  default: null,
93
111
  },
112
+ /**
113
+ * Custom text for the average value in the legend.
114
+ */
94
115
  legendAverageText: {
95
116
  type: String,
96
117
  required: false,
97
118
  default: LEGEND_AVERAGE_TEXT,
98
119
  },
120
+ /**
121
+ * Custom text for the maximum value in the legend.
122
+ */
99
123
  legendMaxText: {
100
124
  type: String,
101
125
  required: false,
102
126
  default: LEGEND_MAX_TEXT,
103
127
  },
128
+ /**
129
+ * Custom text for the minimum value in the legend.
130
+ */
104
131
  legendMinText: {
105
132
  type: String,
106
133
  required: false,
107
134
  default: LEGEND_MIN_TEXT,
108
135
  },
136
+ /**
137
+ * Custom text for the current value in the legend.
138
+ */
109
139
  legendCurrentText: {
110
140
  type: String,
111
141
  required: false,
112
142
  default: LEGEND_CURRENT_TEXT,
113
143
  },
144
+ /**
145
+ * Layout configuration for the legend.
146
+ */
114
147
  legendLayout: {
115
148
  type: String,
116
149
  required: false,
@@ -127,6 +160,9 @@ export default {
127
160
  required: false,
128
161
  default: null,
129
162
  },
163
+ /**
164
+ * Series information for the legend.
165
+ */
130
166
  legendSeriesInfo: {
131
167
  type: Array,
132
168
  required: false,