@gitlab/ui 115.11.0 → 116.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 (50) hide show
  1. package/dist/components/base/filtered_search/filtered_search_suggestion.js +11 -5
  2. package/dist/components/dashboards/dashboard_layout/grid_layout/grid_layout.js +2 -2
  3. package/dist/components/dashboards/dashboard_panel/dashboard_panel.js +45 -3
  4. package/dist/components/index.js +1 -1
  5. package/dist/tailwind.css +1 -1
  6. package/dist/tailwind.css.map +1 -1
  7. package/dist/tokens/common_story_options.js +1 -6
  8. package/dist/tokens/tokens_story.js +3 -16
  9. package/package.json +5 -5
  10. package/src/components/base/filtered_search/filtered_search_suggestion.vue +32 -14
  11. package/src/components/dashboards/dashboard_layout/grid_layout/grid_layout.vue +2 -2
  12. package/src/components/dashboards/dashboard_panel/dashboard_panel.md +61 -13
  13. package/src/components/dashboards/dashboard_panel/dashboard_panel.vue +46 -3
  14. package/src/components/index.js +1 -1
  15. package/src/tokens/common_story_options.js +1 -9
  16. package/src/tokens/tokens_story.vue +2 -22
  17. package/src/components/base/form/form.md +0 -2
  18. package/src/components/base/form/form_character_count/form_character_count.md +0 -53
  19. package/src/components/base/form/form_combobox/form_combobox.md +0 -52
  20. package/src/components/base/form/form_date/form_date.md +0 -26
  21. package/src/components/base/form/form_fields/form_fields.md +0 -41
  22. package/src/components/base/form/form_group/form_group.md +0 -1
  23. package/src/components/base/form/form_input_group/form_input_group.md +0 -67
  24. package/src/components/base/form/input_group_text/input_group_text.md +0 -1
  25. package/src/components/charts/bar/bar.md +0 -3
  26. package/src/components/charts/chart/chart.md +0 -19
  27. package/src/components/charts/gauge/gauge.md +0 -8
  28. package/src/components/charts/heatmap/heatmap.md +0 -7
  29. package/src/components/charts/legend/legend.md +0 -16
  30. package/src/components/charts/line/line.md +0 -7
  31. package/src/components/charts/series_label/series_label.md +0 -1
  32. package/src/components/charts/shared/tooltip/tooltip.md +0 -3
  33. package/src/components/charts/single_stat/single_stat.md +0 -8
  34. package/src/components/charts/sparkline/sparkline.md +0 -8
  35. package/src/components/charts/stacked_column/stacked_column.md +0 -10
  36. package/src/components/regions/empty_state/empty_state.md +0 -4
  37. package/src/components/utilities/animated_number/animated_number.md +0 -6
  38. package/src/components/utilities/friendly_wrap/friendly_wrap.md +0 -66
  39. package/src/components/utilities/intersection_observer/intersection_observer.md +0 -16
  40. package/src/components/utilities/intersperse/intersperse.md +0 -90
  41. package/src/components/utilities/sprintf/sprintf.md +0 -243
  42. package/src/components/utilities/truncate/truncate.md +0 -14
  43. package/src/components/utilities/truncate_text/truncate_text.md +0 -26
  44. package/src/directives/hover_load/hover_load.md +0 -22
  45. package/src/directives/outside/outside.md +0 -140
  46. package/src/directives/resize_observer/resize_observer.md +0 -54
  47. package/src/directives/safe_html/safe_html.md +0 -58
  48. package/src/directives/safe_link/safe_link.md +0 -37
  49. package/src/internal/color_contrast/color_contrast.md +0 -8
  50. package/src/internal/color_contrast/color_contrast.vue +0 -52
@@ -21,62 +21,104 @@ export default {
21
21
  GlTruncate,
22
22
  },
23
23
  props: {
24
+ /**
25
+ * CSS classes to apply to the panel container.
26
+ */
24
27
  containerClass: {
25
28
  type: String,
26
29
  required: false,
27
30
  default: '',
28
31
  },
32
+ /**
33
+ * Additional CSS classes to apply to the `#body` slot container.
34
+ */
29
35
  bodyContentClass: {
30
36
  type: String,
31
37
  required: false,
32
38
  default: '',
33
39
  },
40
+ /**
41
+ * Used to set the color of the panel border.
42
+ */
34
43
  borderColorClass: {
35
44
  type: String,
36
45
  required: false,
37
46
  default: '',
38
47
  },
48
+ /**
49
+ * The string to render as the panel title.
50
+ */
39
51
  title: {
40
52
  type: String,
41
53
  required: false,
42
54
  default: '',
43
55
  },
56
+ /**
57
+ * The name of the icon to render next to the panel title.
58
+ */
44
59
  titleIcon: {
45
60
  type: String,
46
61
  required: false,
47
62
  default: '',
48
63
  },
64
+ /**
65
+ * The CSS classes to apply to the title icon.
66
+ */
49
67
  titleIconClass: {
50
68
  type: String,
51
69
  required: false,
52
70
  default: '',
53
71
  },
72
+ /**
73
+ * Configuration object for the title popover. Expected structure:
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
+ */
54
81
  titlePopover: {
55
82
  type: Object,
56
83
  required: false,
57
84
  default: () => ({}),
58
85
  },
86
+ /**
87
+ * Set to `true` to show the loading state.
88
+ */
59
89
  loading: {
60
90
  type: Boolean,
61
91
  required: false,
62
92
  default: false,
63
93
  },
94
+ /**
95
+ * Set to `true` for long-running operations.
96
+ */
64
97
  loadingDelayed: {
65
98
  type: Boolean,
66
99
  required: false,
67
100
  default: false,
68
101
  },
102
+ /**
103
+ * The string to render while loading is delayed.
104
+ */
69
105
  loadingDelayedText: {
70
106
  type: String,
71
107
  required: false,
72
108
  default: '',
73
109
  },
110
+ /**
111
+ * Array of `GlDisclosureDropdown` items to display in the dropdown.
112
+ */
74
113
  actions: {
75
114
  type: Array,
76
115
  required: false,
77
116
  default: () => [],
78
117
  validator: (actions) => actions.every((a) => isObject(a)),
79
118
  },
119
+ /**
120
+ * The toggle text for the `GlDisclosureDropdown` dropdown.
121
+ */
80
122
  actionsToggleText: {
81
123
  type: String,
82
124
  required: false,
@@ -130,7 +172,7 @@ export default {
130
172
  <template>
131
173
  <div
132
174
  :id="panelId"
133
- class="gl-border gl-h-full !gl-overflow-visible gl-rounded-base gl-bg-white gl-p-4"
175
+ class="gl-border gl-h-full !gl-overflow-visible gl-rounded-lg gl-bg-white gl-p-5"
134
176
  :class="containerClasses"
135
177
  >
136
178
  <div class="gl-flex gl-h-full gl-flex-col">
@@ -138,7 +180,7 @@ export default {
138
180
  <div class="gl-flex gl-items-center gl-overflow-hidden gl-pb-3">
139
181
  <gl-icon
140
182
  v-if="hasTitleIcon"
141
- class="gl-mr-1"
183
+ class="gl-mr-2"
142
184
  :class="titleIconClass"
143
185
  :name="titleIcon"
144
186
  data-testid="panel-title-icon"
@@ -195,11 +237,12 @@ export default {
195
237
  toggle-class="gl-ml-1"
196
238
  category="tertiary"
197
239
  positioning-strategy="fixed"
240
+ size="small"
198
241
  @shown="$emit('dropdownOpen')"
199
242
  @hidden="$emit('dropdownClosed')"
200
243
  >
201
244
  <template #list-item="{ item }">
202
- <span> <gl-icon :name="item.icon" /> {{ item.text }}</span>
245
+ <span>{{ item.text }}</span>
203
246
  </template>
204
247
  </gl-disclosure-dropdown>
205
248
 
@@ -9,7 +9,6 @@ export { default as GlNav } from './base/nav/nav.vue';
9
9
  export { default as GlNavItem } from './base/nav/nav_item.vue';
10
10
  export { default as GlFormCheckboxTree } from './base/form/form_checkbox_tree/form_checkbox_tree.vue';
11
11
  export { default as GlMarkdown } from './base/markdown/markdown.vue';
12
- export { default as GlIntersectionObserver } from './utilities/intersection_observer/intersection_observer.vue';
13
12
  export { default as GlLink, default as GlDeprecatedLink } from './base/link/link.vue';
14
13
  export { default as GlIcon } from './base/icon/icon.vue';
15
14
  export { default as GlAnimatedChevronRightDownIcon } from './base/animated_icon/animated_chevron_right_down_icon.vue';
@@ -108,6 +107,7 @@ export { default as GlExperimentBadge } from './experimental/experiment_badge/ex
108
107
  // Utilities
109
108
  export { default as GlAnimatedNumber } from './utilities/animated_number/animated_number.vue';
110
109
  export { default as GlFriendlyWrap } from './utilities/friendly_wrap/friendly_wrap.vue';
110
+ export { default as GlIntersectionObserver } from './utilities/intersection_observer/intersection_observer.vue';
111
111
  export { default as GlIntersperse } from './utilities/intersperse/intersperse.vue';
112
112
  export { default as GlSprintf } from './utilities/sprintf/sprintf.vue';
113
113
  export { default as GlTruncate } from './utilities/truncate/truncate.vue';
@@ -1,11 +1,6 @@
1
- import { WHITE, GRAY_950 } from './build/js/tokens';
2
1
  import TokensStory from './tokens_story.vue';
3
2
 
4
- export const createDesignTokenStory = ({
5
- tokens = {},
6
- isBackgroundColorStory = true,
7
- containerClass = '',
8
- } = {}) => {
3
+ export const createDesignTokenStory = ({ tokens = {}, containerClass = '' } = {}) => {
9
4
  const Story = (args, { argTypes }) => ({
10
5
  props: Object.keys(argTypes),
11
6
  components: {
@@ -13,9 +8,6 @@ export const createDesignTokenStory = ({
13
8
  },
14
9
  provide: {
15
10
  containerClass,
16
- isBackgroundColorStory,
17
- lightBackground: WHITE,
18
- darkBackground: GRAY_950,
19
11
  },
20
12
  template: `<tokens-story v-bind="$props" />`,
21
13
  });
@@ -2,18 +2,16 @@
2
2
  import { colorFromBackground } from '../utils/utils';
3
3
  import { GlTooltipDirective } from '../directives/tooltip/tooltip';
4
4
  import GlBadge from '../components/base/badge/badge.vue';
5
- import GlColorContrast from '../internal/color_contrast/color_contrast.vue';
6
5
 
7
6
  export default {
8
7
  name: 'TokensStory',
9
8
  components: {
10
9
  GlBadge,
11
- GlColorContrast,
12
10
  },
13
11
  directives: {
14
12
  GlTooltip: GlTooltipDirective,
15
13
  },
16
- inject: ['isBackgroundColorStory', 'lightBackground', 'darkBackground', 'containerClass'],
14
+ inject: ['containerClass'],
17
15
  props: {
18
16
  tokens: {
19
17
  type: Object,
@@ -30,7 +28,6 @@ export default {
30
28
  },
31
29
  getClasses(value) {
32
30
  if (!this.isHex(value)) return '';
33
- if (!this.isBackgroundColorStory) return '';
34
31
 
35
32
  const textColorVariant = colorFromBackground(value, 4.5);
36
33
  return {
@@ -38,13 +35,6 @@ export default {
38
35
  'gl-text-neutral-0': textColorVariant === 'light',
39
36
  };
40
37
  },
41
- getStyle(value) {
42
- if (this.isBackgroundColorStory) {
43
- return { backgroundColor: value };
44
- }
45
-
46
- return { color: value };
47
- },
48
38
  },
49
39
  };
50
40
  </script>
@@ -57,7 +47,7 @@ export default {
57
47
  :key="token.name"
58
48
  class="gl-flex gl-flex-wrap gl-items-center gl-justify-between gl-gap-3 gl-p-3"
59
49
  :class="getClasses(token.$value)"
60
- :style="getStyle(token.$value)"
50
+ :style="{ backgroundColor: token.$value }"
61
51
  >
62
52
  <code v-gl-tooltip :title="token.comment" class="gl-text-inherit">
63
53
  {{ getTokenName(token) }}
@@ -67,16 +57,6 @@ export default {
67
57
  Deprecated
68
58
  </gl-badge>
69
59
  <code class="gl-text-inherit">{{ token.$value }}</code>
70
- <gl-color-contrast
71
- v-if="isHex(token.$value)"
72
- :foreground="token.$value"
73
- :background="darkBackground"
74
- />
75
- <gl-color-contrast
76
- v-if="isHex(token.$value)"
77
- :foreground="token.$value"
78
- :background="lightBackground"
79
- />
80
60
  </div>
81
61
  </li>
82
62
  </ul>
@@ -1,2 +0,0 @@
1
- A wrapper element for `gl-form-*` input elements. Supports `@submit` and `@reset` events.
2
- To disable native HTML validation pass the `novalidate` attribute.
@@ -1,53 +0,0 @@
1
- ## Usage
2
-
3
- `GlFormCharacterCount` can be used to add a character count to an input.
4
- If you are using `GlFormTextarea` on its own see [with character count example](https://design.gitlab.com/storybook?path=/story/base-form-form-textarea--with-character-count).
5
- If you are wrapping your input, such as in a markdown component, and need the character
6
- count separate from the input, use `GlFormCharacterCount`.
7
-
8
- ## Example
9
-
10
- ```html
11
- <script>
12
- import { GlFormCharacterCount, GlFormInput, GlFormGroup } from '@gitlab/ui'
13
-
14
- export default {
15
- inputId: 'form-input-with-character-count',
16
- countTextId: 'character-count-text',
17
- limit: 100,
18
- components: { GlFormCharacterCount, GlFormInput, GlFormGroup },
19
- data() {
20
- return {
21
- value: '',
22
- }
23
- },
24
- methods: {
25
- remainingCountText(count) {
26
- return n__('%d character remaining.', '%d characters remaining.', count)
27
- },
28
- overLimitText(count) {
29
- return n__('%d character over limit.', '%d characters over limit.', count);
30
- },
31
- },
32
- }
33
- <script>
34
-
35
- <template>
36
- <gl-form-group label="Form input with character count" :label-for="$options.inputId">
37
- <gl-form-input
38
- v-model="value"
39
- :id="$options.inputId"
40
- :value="value"
41
- :aria-describedby="$options.countTextId"
42
- />
43
- <gl-form-character-count
44
- :value="value"
45
- :limit="$options.limit"
46
- :count-text-id="$options.countTextId"
47
- >
48
- <template #remaining-count-text="{ count }">{{ remainingCountText(count) }}</template>
49
- <template #over-limit-text="{ count }">{{ overLimitText(count) }}</template>
50
- </gl-form-character-count>
51
- </gl-form-group>
52
- <template>
53
- ```
@@ -1,52 +0,0 @@
1
- Use this component to add a [`FormInput`](/?path=/story/base-form-form-input--default) component
2
- with synchronous autocomplete dropdown. It behaves as follows:
3
-
4
- - Typing matches tokens; dropdown disappears when there is no match
5
- - Up and down arrows navigate the dropdown
6
- - Enter selects keyboard-highlighted item; clicking overrides this
7
- - Esc closes dropdown when it is open, clears field when it is not
8
- - Browser/native autocomplete dropdown hidden when ours is open, shows when it is not
9
- - Tab selects current entered text and moves to next field
10
-
11
- This behavior based on
12
- [this w3c pattern](https://www.w3.org/TR/wai-aria-practices/examples/combobox/aria1.1pattern/listbox-combo.html)
13
- and [this accessible combobox example](https://alligator.io/vuejs/vue-a11y-autocomplete/).
14
-
15
- ## Usage
16
-
17
- The combobox accepts an array of string tokens, a `v-model`, and label text. Internally, it generates
18
- unique element IDs so multiple can be used on one page without clashing.
19
-
20
- On selection it sets the input value to the selected string and emits a `value-selected` event for
21
- consumption by parent components.
22
-
23
- ```html
24
- <gl-form-combobox
25
- v-model="inputVal"
26
- :token-list="tokens"
27
- label-text="Combobox Label"
28
- />
29
- ```
30
-
31
- It does not have a loading state nor does it accept tokens other than strings. It allows for one
32
- selected value.
33
-
34
- ### What if I need to load the options asynchronously?
35
-
36
- You may want to look at [`GlSearchBoxByType`] or [`GlSearchBoxByClick`].
37
-
38
- ### What if I need multiple options?
39
-
40
- The [`GlTokenSelector`] may be what you need. Alternately, [`GlFilteredSearch`] will let you search
41
- and include tokens.
42
-
43
- ## Edge cases
44
-
45
- The algorithm to match tokens with the input is very naive. If you need to use the component with a
46
- very large list of matches, you may want to update the implementation or use one of the search
47
- inputs, like [`GlSearchBoxByType`], [`GlSearchBoxByClick`], or [`GlFilteredSearch`].
48
-
49
- [`GlSearchBoxByType`]: https://design.gitlab.com/storybook?path=/story/base-search-box-by-type--default
50
- [`GlSearchBoxByClick`]: https://design.gitlab.com/storybook?path=/story/base-search-box-by-click--default
51
- [`GlTokenSelector`]: https://design.gitlab.com/storybook?path=/story/base-token-selector--default
52
- [`GlFilteredSearch`]: https://design.gitlab.com/storybook?path=/story/base-filtered-search--default
@@ -1,26 +0,0 @@
1
- `GlFormDate` allows users to choose and input a date using a keyboard by by using
2
- browser implemented calendar controls, where available.
3
-
4
- `GlFormDate` extends `<input type="date">` with an `<output>` for audible announcement
5
- of selected date, in full format, by screen-readers.
6
-
7
- ## Usage
8
-
9
- On `change` the value is emitted in `YYYY-MM-DD` format.
10
-
11
- ## Accessibility
12
-
13
- `GlFormDate` is a form `<input>` and should have an accessible name using a `<label>`.
14
-
15
- `GlFormGroup` can be used to label `GlFormDate`.
16
-
17
- ```html
18
- <gl-form-group
19
- label="Enter date"
20
- label-for="input-id"
21
- >
22
- <gl-form-date
23
- id="input-id"
24
- />
25
- </gl-form-group>
26
- ```
@@ -1,41 +0,0 @@
1
- ## Usage
2
-
3
- `GlFormFields` provides form builder functionality for ease of building simple
4
- forms out of other GitLab UI form components.
5
-
6
- For a code example, look at the story. It covers usage of `mapValue`, `validators`,
7
- custom form elements, and `inputAttrs`.
8
-
9
- ## Fields type
10
-
11
- Each value of `fields` prop is expected to be a `FieldDefinition`. See below for the shape of this type:
12
-
13
- ```ts
14
- interface FieldDefinition<TValue> {
15
- // Label text to show for this field.
16
- label: string;
17
-
18
- // Collection of validator functions
19
- validators?: Array<(value: TValue) => string | undefined>;
20
-
21
- // Function that maps the inputted string value to the field's actual value
22
- // (e.g. a Number).
23
- mapValue?: (input: string) => TValue;
24
-
25
- // Properties that are passed to the actual input for this field.
26
- inputAttrs?: {};
27
-
28
- // Properties that are passed to the group wrapping this field.
29
- groupAttrs?: {};
30
- }
31
- ```
32
-
33
- ## Slots
34
-
35
- | Name | Description |
36
- | ------ | ------ |
37
- | `input(<fieldName>)` | Used to render components other than `GlFormInput`. |
38
- | `group(<fieldName>)-label` | Used for `label` slot on `GlFormGroup` of a specific field. |
39
- | `group(<fieldName>)-description` | Used for `description` slot on `GlFormGroup` of a specific field. |
40
- | `group(<fieldName>)-label-description` | Used for `label-description` slot on `GlFormGroup` of a specific field. |
41
- | `after(<fieldName>)` | Used to render content after `GlFormGroup` of a specific field. |
@@ -1 +0,0 @@
1
- Form group adds structure to forms.
@@ -1,67 +0,0 @@
1
- The `GlFormInputGroup` component allows one to build more advanced text
2
- input fields than generic `GlFormInput` when one needs that flexibility.
3
- Basic usage of the component:
4
-
5
- ```html
6
- <div>
7
- <gl-form-input-group>
8
- <template #prepend>
9
- <!-- Content to prepend your text input field -->
10
- </template>
11
- <template #append>
12
- <!-- Content to append your text input field -->
13
- </template>
14
- </gl-form-input-group>
15
- </div>
16
- ```
17
-
18
- One can use any other component (custom or `<gl-*>`) in both slots or
19
- not to use the slots at all. In the latter, the component will fallback
20
- to simple `GlFormInput`.
21
-
22
- ## Predefined options
23
-
24
- Sometimes custom text input from the user isn't desired. Instead, the
25
- user should pick one of the predefined options that will automatically
26
- populate the input field. Typically, such cases will also include an
27
- actionable button (like **Copy**) put into the `append` slot.
28
-
29
- To achieve this effect, the `GlFormInputGroup` component accepts an
30
- array of options in the form of `predefinedOptions` param. For example:
31
-
32
- ```javascript
33
- const optionValues = [
34
- { name: 'Option #1', value: 'Option #1 is selected!' },
35
- { name: 'Option #2', value: 'Option #2 is selected!' },
36
- ];
37
- ...
38
- <gl-form-input-group :predefined-options="optionValues" />
39
- ```
40
-
41
- This will tell `GlFormInputGroup` to render a dropdown in the `prepend`
42
- slot with all of the supplied options' `name`s. When one of the options
43
- is selected, the input field is automatically populated with the
44
- option's `value`. Check the "Examples" section below for "With
45
- predefined options" example.
46
-
47
- ### Pro tips
48
-
49
- Read some useful tips below about specific usage of the component.
50
-
51
- ### Readonly input
52
-
53
- Often you want to make sure user doesn't mess up the predefined content
54
- pasted into the input field. In this case, you can set `readonly`
55
- param to `true`. You can play with `Readonly` knob on the right.
56
-
57
- ### Preselect the text to copy
58
-
59
- If you set the `readonly` param on the `GlFormInputGroup` component,
60
- users will still be able to manually select the text and copy it.
61
- However, it's more user-friendly to preselect the text for the users if
62
- they click anywhere in the input field. This can be achieved by setting
63
- the `select-on-click` param to `true`. You can play with
64
- `Select text on click` knob on the right. Even better, try enabling
65
- `Readonly`, `Select text on click`, and `Switch to predefined input`
66
- altogether. And, probably, remove `Prepend text`. Or leave it. It's your
67
- call. :)
@@ -1 +0,0 @@
1
- GlInputGroupText components are used to add text to an input group.
@@ -1,3 +0,0 @@
1
- A bar chart is similar to a column chart where the the length of bars represents the data value.
2
- Although alike, they are cannot be interchangeably used. Bar charts are good for displaying large
3
- number of categories on the y-axis.
@@ -1,19 +0,0 @@
1
- ### ECharts Wrapper
2
-
3
- The chart component is a Vue component wrapper around [Apache ECharts](https://echarts.apache.org/en/api.html#echarts).
4
- The chart component accepts width and height props in order to allow the user to make it responsive.
5
-
6
- > Note: When implementing a chart type that does not already have a GitLab UI component, you can use
7
- > this component alonside the [ECharts options](https://echarts.apache.org/en/api.html#echarts) to
8
- > build your chart. Each type of chart should still follow the general guidelines in the
9
- > [pajamas documentation](https://design.gitlab.com/data-visualization/charts).
10
-
11
- ### EChart Lifecycle
12
-
13
- This component emits the following events during the ECharts lifecycle:
14
-
15
- - `created`: emitted after calling `echarts.init`
16
- - `updated`: emitted after calling `echarts.setOption`
17
-
18
- In all cases, the event payload is the
19
- [echart instance](https://echarts.apache.org/en/api.html#echartsInstance).
@@ -1,8 +0,0 @@
1
- Some layout problems can be encountered with this component. Specifically, when the gauge chart's
2
- axis labels or detail text have larger widths, they can overlap with the chart elements.
3
-
4
- Also, when the containing element of the gauge chart has either of a small calculated `width` and
5
- `height`, its axis width could become bulkier in relation to other chart elements. This is because
6
- at this time [eCharts only allows for setting the axis line width in absolute units](https://echarts.apache.org/en/option.html#series-gauge.axisLine.lineStyle.width).
7
-
8
- This issue is to be addressed by [https://gitlab.com/gitlab-org/gitlab-ui/-/issues/916](https://gitlab.com/gitlab-org/gitlab-ui/-/issues/916).
@@ -1,7 +0,0 @@
1
- ## Heatmaps
2
-
3
- **Note** This component uses `<gl-legend>`, which should allow a user to click on any data point(s)
4
- in the legend and make the corresponding data point(s) on the chart rendered disappear.
5
- _See [area chart](https://design.gitlab.com/storybook?path=/story/charts-area-chart--default)
6
- for an example_ For this particular chart, there is a [known issue](https://gitlab.com/gitlab-org/gitlab-ui/issues/352)
7
- with the functionality of the legend, where clicking on it does nothing.
@@ -1,16 +0,0 @@
1
- ## Disabling Legends
2
-
3
- By default, to prevent the chart from disappearing, all legends can't be toggled off – the last
4
- active legend will be disabled. To manually disable a legend, pass it the
5
- `disabled` property in `seriesInfo`:
6
-
7
- ```js
8
- seriesInfo = [
9
- {
10
- name: 'Example Legend',
11
- color: 'blue',
12
- disabled: true,
13
- type: 'line'
14
- }
15
- ]
16
- ```
@@ -1,7 +0,0 @@
1
- This is a basic line chart.
2
-
3
- ### Implementation Details
4
-
5
- This component wraps the GitLab UI `chart` component, which in turn wraps the ECharts component.
6
-
7
- See the [chart](./?path=/story/charts-chart--default) component for more info.
@@ -1 +0,0 @@
1
- Displays chart data series name as a label for chart legend, tooltip, etc.
@@ -1,3 +0,0 @@
1
- ### ECharts custom tooltip
2
-
3
- Uses GitLab UI's `popover` component in lieu of echart's tooltip.
@@ -1,8 +0,0 @@
1
- The single stat component is used to show a single value. The color of the meta icon / badge is
2
- determined by the **variant** prop, which can be one of "success", "warning", "danger", "info",
3
- "neutral" or "muted" (default).
4
-
5
- #### Hover state
6
-
7
- You can make the component focusable by adding a `tabindex=0` attribute to it. This will also apply
8
- a hover state to the component.
@@ -1,8 +0,0 @@
1
-
2
- This is a basic sparkline chart.
3
-
4
- ### Implementation Details
5
-
6
- This component wraps the GitLab UI `chart` component, which in turn wraps the ECharts component.
7
-
8
- See the [chart](./?path=/story/charts-chart--default) component for more info.
@@ -1,10 +0,0 @@
1
- The `presentation` property allows you to change between a stacked and tiled presentation style. It
2
- is only setup to accept `stacked` or `tiled` as values, the default value is `stacked`.
3
-
4
- The `stacked` presentation allows to view multiple series of the same stack as a single column,
5
- while `tiled` presents the information in multiple columns for each series of a stack.
6
-
7
- `groupBy` is a property that defines how the data is going to be grouped by for each of the series
8
- that the `data` property provides. For example if the `data` property has a total of 3 series, with
9
- 7 elements each, `groupBy` could use a 7 element array to show 7 stacked bars or 7 groups of bars
10
- depending on the preference set by the `presentation` property.
@@ -1,4 +0,0 @@
1
- ### Buttons
2
-
3
- You can either have a primary button, a secondary button, or both.
4
- Buttons require both text a link in order for the button to render.
@@ -1,6 +0,0 @@
1
- Animated numbers provide a signifier that values are being changed.
2
-
3
- ## Usage
4
-
5
- The animated number component can be used with or without decimal places. Decimal places will
6
- not be rounded if chosen to be omitted.