@gitlab/ui 96.3.0 → 97.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +21 -0
- package/dist/components/base/alert/alert.js +1 -1
- package/dist/components/base/avatar/avatar.js +4 -4
- package/dist/components/base/datepicker/datepicker.js +1 -1
- package/dist/components/base/drawer/drawer.js +1 -1
- package/dist/components/base/form/form_input/form_input.js +3 -3
- package/dist/components/base/form/form_select/form_select.js +3 -3
- package/dist/components/base/progress_bar/progress_bar.js +47 -5
- package/dist/components/base/toast/toast.js +1 -1
- package/dist/components/base/token/token.js +1 -1
- package/dist/index.css +1 -1
- package/dist/index.css.map +1 -1
- package/dist/utils/number_utils.js +9 -1
- package/dist/vendor/bootstrap-vue/src/constants/components.js +1 -3
- package/dist/vendor/bootstrap-vue/src/index.js +0 -2
- package/package.json +7 -7
- package/src/components/base/alert/alert.vue +1 -1
- package/src/components/base/avatar/avatar.vue +4 -4
- package/src/components/base/datepicker/datepicker.vue +1 -1
- package/src/components/base/drawer/drawer.vue +1 -1
- package/src/components/base/form/form_input/form_input.vue +3 -3
- package/src/components/base/form/form_select/form_select.vue +3 -3
- package/src/components/base/modal/modal.scss +1 -2
- package/src/components/base/progress_bar/progress_bar.md +25 -0
- package/src/components/base/progress_bar/progress_bar.scss +11 -0
- package/src/components/base/progress_bar/progress_bar.vue +54 -5
- package/src/components/base/toast/toast.js +1 -1
- package/src/components/base/token/token.vue +1 -1
- package/src/utils/number_utils.js +7 -0
- package/src/vendor/bootstrap-vue/package.json +3 -42
- package/src/vendor/bootstrap-vue/src/components/badge/README.md +2 -2
- package/src/vendor/bootstrap-vue/src/components/breadcrumb/README.md +2 -2
- package/src/vendor/bootstrap-vue/src/components/button/README.md +7 -9
- package/src/vendor/bootstrap-vue/src/components/button-group/README.md +0 -5
- package/src/vendor/bootstrap-vue/src/components/collapse/README.md +2 -2
- package/src/vendor/bootstrap-vue/src/components/dropdown/README.md +5 -5
- package/src/vendor/bootstrap-vue/src/components/form/README.md +21 -26
- package/src/vendor/bootstrap-vue/src/components/form-checkbox/README.md +6 -6
- package/src/vendor/bootstrap-vue/src/components/form-group/README.md +6 -4
- package/src/vendor/bootstrap-vue/src/components/form-input/README.md +4 -4
- package/src/vendor/bootstrap-vue/src/components/form-radio/README.md +1 -1
- package/src/vendor/bootstrap-vue/src/components/index.d.ts +0 -1
- package/src/vendor/bootstrap-vue/src/components/input-group/README.md +4 -9
- package/src/vendor/bootstrap-vue/src/components/layout/README.md +3 -3
- package/src/vendor/bootstrap-vue/src/components/link/README.md +1 -1
- package/src/vendor/bootstrap-vue/src/components/modal/README.md +2 -2
- package/src/vendor/bootstrap-vue/src/components/nav/README.md +13 -14
- package/src/vendor/bootstrap-vue/src/components/navbar/README.md +5 -6
- package/src/vendor/bootstrap-vue/src/components/popover/README.md +4 -4
- package/src/vendor/bootstrap-vue/src/components/table/README.md +5 -5
- package/src/vendor/bootstrap-vue/src/components/tabs/README.md +2 -2
- package/src/vendor/bootstrap-vue/src/components/toast/README.md +5 -5
- package/src/vendor/bootstrap-vue/src/components/tooltip/README.md +4 -4
- package/src/vendor/bootstrap-vue/src/constants/components.js +0 -2
- package/src/vendor/bootstrap-vue/src/directives/toggle/README.md +5 -6
- package/src/vendor/bootstrap-vue/src/directives/tooltip/README.md +2 -2
- package/src/vendor/bootstrap-vue/src/index.js +0 -4
- package/dist/vendor/bootstrap-vue/src/components/progress/index.js +0 -2
- package/dist/vendor/bootstrap-vue/src/components/progress/progress-bar.js +0 -128
- package/dist/vendor/bootstrap-vue/src/components/progress/progress.js +0 -56
- package/src/vendor/bootstrap-vue/nuxt/index.js +0 -164
- package/src/vendor/bootstrap-vue/nuxt/plugin.template.js +0 -29
- package/src/vendor/bootstrap-vue/src/components/progress/MODIFICATIONS.md +0 -23
- package/src/vendor/bootstrap-vue/src/components/progress/README.md +0 -363
- package/src/vendor/bootstrap-vue/src/components/progress/index.d.ts +0 -10
- package/src/vendor/bootstrap-vue/src/components/progress/index.js +0 -4
- package/src/vendor/bootstrap-vue/src/components/progress/package.json +0 -109
- package/src/vendor/bootstrap-vue/src/components/progress/progress-bar.js +0 -133
- package/src/vendor/bootstrap-vue/src/components/progress/progress-bar.spec.js +0 -270
- package/src/vendor/bootstrap-vue/src/components/progress/progress.js +0 -57
- package/src/vendor/bootstrap-vue/src/components/progress/progress.spec.js +0 -71
|
@@ -361,8 +361,8 @@ This will inform users of assistive technologies that the checkboxes are related
|
|
|
361
361
|
browser keyboard navigation.
|
|
362
362
|
|
|
363
363
|
Whenever using multiple checkboxes, it is recommended that the checkboxes be placed in a
|
|
364
|
-
[`<
|
|
365
|
-
of checkboxes. See examples above.
|
|
364
|
+
[`<gl-form-group>`](?path=/docs/base-form-form-group--docs) component to associate a label with the
|
|
365
|
+
entire group of checkboxes. See examples above.
|
|
366
366
|
|
|
367
367
|
## Button style checkboxes
|
|
368
368
|
|
|
@@ -376,8 +376,8 @@ are in the _checked_ state.
|
|
|
376
376
|
A single checkbox can be rendered with a button appearance by setting the prop `button` to `true`
|
|
377
377
|
|
|
378
378
|
Change the button variant by setting the `button-variant` prop to one of the standard Bootstrap
|
|
379
|
-
button variants (see [`<
|
|
380
|
-
variant is `secondary`.
|
|
379
|
+
button variants (see [`<gl-button>`](?path=/docs/base-button--docs) for supported variants). The
|
|
380
|
+
default variant is `secondary`.
|
|
381
381
|
|
|
382
382
|
```html
|
|
383
383
|
<template>
|
|
@@ -411,8 +411,8 @@ The `inline` prop has no effect on individual button-style checkboxes.
|
|
|
411
411
|
|
|
412
412
|
Render groups of checkboxes with the look of a button-group by setting the prop `buttons` on
|
|
413
413
|
`<b-form-checkbox-group>`. Change the button variant by setting the `button-variant` prop to one of
|
|
414
|
-
the standard Bootstrap button variants (see [`<
|
|
415
|
-
variants). The default `button-variant` is `secondary`.
|
|
414
|
+
the standard Bootstrap button variants (see [`<gl-button>`](?path=/docs/base-button--docs) for
|
|
415
|
+
supported variants). The default `button-variant` is `secondary`.
|
|
416
416
|
|
|
417
417
|
```html
|
|
418
418
|
<template>
|
|
@@ -84,7 +84,8 @@ occupy in the row via the `content-cols` and `content-cols-{breakpoint}` props.
|
|
|
84
84
|
When using both, the `label-cols` and `content-cols` props, make sure that the total amount of
|
|
85
85
|
columns doesn't exceed `12`.
|
|
86
86
|
|
|
87
|
-
See the [Layout and Grid System](/docs
|
|
87
|
+
See the [Layout and Grid System](?path=/docs/base-form-form-group--docs#how-it-works) docs for
|
|
88
|
+
further information.
|
|
88
89
|
|
|
89
90
|
| Prop | Description |
|
|
90
91
|
| ----------------- | ------------------------------------------------------------------------------------- |
|
|
@@ -165,7 +166,7 @@ Alignment has no effect if the `label-sr-only` prop is set.
|
|
|
165
166
|
|
|
166
167
|
Optional descriptive text which is always shown with the `.text-muted` class by setting the
|
|
167
168
|
`description` prop or using the named slot `description`. The description text is rendered using the
|
|
168
|
-
[`<b-form-text>`](
|
|
169
|
+
[`<b-form-text>`](?path=/docs/base-form-form--docs#helper-components) form sub-component.
|
|
169
170
|
|
|
170
171
|
## Nested form groups
|
|
171
172
|
|
|
@@ -281,7 +282,8 @@ Show optional invalid state feedback text to provide textual state feedback (htm
|
|
|
281
282
|
setting the prop `invalid-feedback` or using the named slot `invalid-feedback`.
|
|
282
283
|
|
|
283
284
|
Invalid feedback is rendered using the
|
|
284
|
-
[`<b-form-invalid-feedback>`](
|
|
285
|
+
[`<b-form-invalid-feedback>`](?path=/docs/base-form-form--docs#helper-components) form
|
|
286
|
+
sub-component.
|
|
285
287
|
|
|
286
288
|
### Valid feedback
|
|
287
289
|
|
|
@@ -289,7 +291,7 @@ Show optional valid state feedback text to provide textual state feedback (html
|
|
|
289
291
|
setting the prop `valid-feedback` or using the named slot `valid-feedback`.
|
|
290
292
|
|
|
291
293
|
Valid feedback is rendered using the
|
|
292
|
-
[`<b-form-valid-feedback>`](
|
|
294
|
+
[`<b-form-valid-feedback>`](?path=/docs/base-form-form--docs#helper-components) form sub-component.
|
|
293
295
|
|
|
294
296
|
### Feedback style
|
|
295
297
|
|
|
@@ -304,8 +304,8 @@ invalid), `true` (for valid), or `null` (no validation state).
|
|
|
304
304
|
<!-- b-form-input-states-feedback.vue -->
|
|
305
305
|
```
|
|
306
306
|
|
|
307
|
-
> **Tip:** Use the [`<
|
|
308
|
-
> generate markup similar to above.
|
|
307
|
+
> **Tip:** Use the [`<gl-form-group>`](?path=/docs/base-form-form-group--docs) component to
|
|
308
|
+
> automatically generate markup similar to above.
|
|
309
309
|
|
|
310
310
|
### Conveying contextual state to assistive technologies and colorblind users
|
|
311
311
|
|
|
@@ -463,8 +463,8 @@ chosen, or new values to be entered.
|
|
|
463
463
|
```
|
|
464
464
|
|
|
465
465
|
BootstrapVue provides the form helper component
|
|
466
|
-
[`<b-form-datalist>`](
|
|
467
|
-
from an array of options.
|
|
466
|
+
[`<b-form-datalist>`](?path=/docs/base-form-form--docs#datalist-helper) for quickly creating a
|
|
467
|
+
`<datalist>` from an array of options.
|
|
468
468
|
|
|
469
469
|
**Notes:**
|
|
470
470
|
|
|
@@ -345,7 +345,7 @@ BootstrapVue includes custom SCSS/CSS that adds support for sizing the custom ra
|
|
|
345
345
|
|
|
346
346
|
Render radios with the look of buttons by setting the prop `buttons` to `true` on
|
|
347
347
|
`<b-form-radio-group>`. Set the button variant by setting the `button-variant` prop to one of the
|
|
348
|
-
standard Bootstrap button variants (see [`<
|
|
348
|
+
standard Bootstrap button variants (see [`<gl-button>`](?path=/docs/base-button--docs) for supported
|
|
349
349
|
variants). The default `button-variant` is `secondary`.
|
|
350
350
|
|
|
351
351
|
The `buttons` prop has precedence over `plain`, and `button-variant` has no effect if `buttons` is
|
|
@@ -117,15 +117,10 @@ when you want to use on of [BootstrapVue's icons](/docs/icons).
|
|
|
117
117
|
|
|
118
118
|
The following are the form controls supported as the input-group's _main_ input element:
|
|
119
119
|
|
|
120
|
-
- [
|
|
121
|
-
- [
|
|
122
|
-
- [
|
|
123
|
-
- [
|
|
124
|
-
- [`<b-form-rating>`](/docs/components/form-rating)
|
|
125
|
-
- [`<b-form-tags>`](/docs/components/form-tags)
|
|
126
|
-
- [`<b-form-spinbutton>`](/docs/components/form-spinbutton)
|
|
127
|
-
- [`<b-form-datepicker>`](/docs/components/form-datepicker)
|
|
128
|
-
- [`<b-form-timepicker>`](/docs/components/form-timepicker)
|
|
120
|
+
- [form-input](?path=/docs/base-form-form-input--docs)
|
|
121
|
+
- [form-textarea](?path=/docs/base-form-form-textarea--docs)
|
|
122
|
+
- [form-select](?path=/docs/base-form-form-select--docs)
|
|
123
|
+
- [form-date](?path=/docs/base-form-form-date--docs)
|
|
129
124
|
|
|
130
125
|
**Notes:**
|
|
131
126
|
|
|
@@ -147,13 +147,13 @@ You can remove the margin from `<b-row>` and padding from `<b-col>` by setting t
|
|
|
147
147
|
on `<b-row>`.
|
|
148
148
|
|
|
149
149
|
Or, for compact margins (smaller gutters between columns), use the `<b-form-row>` component, which
|
|
150
|
-
is typically used when laying out [forms](
|
|
150
|
+
is typically used when laying out [forms](?path=/docs/base-form-form--docs).
|
|
151
151
|
|
|
152
152
|
## Columns `<b-col>`
|
|
153
153
|
|
|
154
154
|
`<b-col>` Must be placed inside a `<b-row>` component, or an element (such as a `<div>`) that has
|
|
155
|
-
the class `row` applied to it, or - in the case of [forms](
|
|
156
|
-
`<b-form-row>` component (to obtain columns with more compact margins).
|
|
155
|
+
the class `row` applied to it, or - in the case of [forms](?path=/docs/base-form-form--docs) -
|
|
156
|
+
inside a `<b-form-row>` component (to obtain columns with more compact margins).
|
|
157
157
|
|
|
158
158
|
## Grid options
|
|
159
159
|
|
|
@@ -19,7 +19,7 @@ By specifying a value in the `href` prop, a standard link (`<a>`) element will b
|
|
|
19
19
|
generate a `<router-link>` instead, specify the route location via the `to` prop.
|
|
20
20
|
|
|
21
21
|
Router links support various additional props. Refer to the
|
|
22
|
-
[Router support](/docs
|
|
22
|
+
[Router support](?path=/docs/base-link--docs#router-link-support) reference section for details.
|
|
23
23
|
|
|
24
24
|
If your app is running under [Nuxt.js](https://nuxtjs.org), the
|
|
25
25
|
[`<nuxt-link>`](https://nuxtjs.org/api/components-nuxt-link) component will be used instead of
|
|
@@ -898,8 +898,8 @@ emitted.
|
|
|
898
898
|
|
|
899
899
|
**Note:** The animation effect of this component is dependent on the `prefers-reduced-motion` media
|
|
900
900
|
query. See the
|
|
901
|
-
[reduced motion section of our accessibility documentation](/docs
|
|
902
|
-
additional details.
|
|
901
|
+
[reduced motion section of our accessibility documentation](?path=/docs/base-tooltip--docs#accessibility)
|
|
902
|
+
for additional details.
|
|
903
903
|
|
|
904
904
|
### Modal ARIA attributes
|
|
905
905
|
|
|
@@ -277,18 +277,18 @@ Use the `<b-nav-form>` child component to place an _inline_ form into the nav:
|
|
|
277
277
|
<!-- b-nav-form.vue -->
|
|
278
278
|
```
|
|
279
279
|
|
|
280
|
-
Refer to the [`<
|
|
281
|
-
details on placing form controls.
|
|
280
|
+
Refer to the [`<gl-form>` inline](?path=/docs/base-form-form--docs#inline-formm) documentation for
|
|
281
|
+
additional details on placing form controls.
|
|
282
282
|
|
|
283
283
|
## Tabbed local content support
|
|
284
284
|
|
|
285
|
-
See the [`<
|
|
286
|
-
(not suited for navigation).
|
|
285
|
+
See the [`<gl-tabs>`](?path=/docs/base-tabs--docs) component for creating tabbable panes of local
|
|
286
|
+
content (not suited for navigation).
|
|
287
287
|
|
|
288
288
|
## Card integration
|
|
289
289
|
|
|
290
|
-
Use a `<b-nav>` in a [`<
|
|
291
|
-
on `<b-nav>` and setting either the `pills` or `tabs` props:
|
|
290
|
+
Use a `<b-nav>` in a [`<gl-card>`](?path=/docs/base-card--docs) header, by enabling the
|
|
291
|
+
`card-header` prop on `<b-nav>` and setting either the `pills` or `tabs` props:
|
|
292
292
|
|
|
293
293
|
**Tabs style:**
|
|
294
294
|
|
|
@@ -453,9 +453,10 @@ generated.
|
|
|
453
453
|
|
|
454
454
|
Note that navigation bars, even if visually styled as tabs, should **not** be given
|
|
455
455
|
`role="tablist"`, `role="tab"` or `role="tabpanel"` attributes. These are only appropriate for
|
|
456
|
-
[tabbed interfaces](
|
|
457
|
-
the [WAI ARIA Authoring Practices](https://www.w3.org/TR/wai-aria-practices/#tabpanel).
|
|
458
|
-
[`<
|
|
456
|
+
[tabbed interfaces](?path=/docs/base-tabs--docs) that do not change the URL or `$route`, as
|
|
457
|
+
described in the [WAI ARIA Authoring Practices](https://www.w3.org/TR/wai-aria-practices/#tabpanel).
|
|
458
|
+
See [`<gl-tabs>`](?path=/docs/base-tabs--docs) for dynamic tabbed interfaces that are compliant with
|
|
459
|
+
WAI ARIA.
|
|
459
460
|
|
|
460
461
|
Tabbed interfaces should avoid using dropdown menus, as this causes both usability and accessibility
|
|
461
462
|
issues:
|
|
@@ -468,13 +469,11 @@ issues:
|
|
|
468
469
|
|
|
469
470
|
## See also
|
|
470
471
|
|
|
471
|
-
- [
|
|
472
|
+
- [tabs](?path=/docs/base-tabs--docs) to create tabbable panes of local content, even via dropdown
|
|
472
473
|
menus.
|
|
473
|
-
- [`<b-navbar>`](/docs/components/navbar) a wrapper that positions branding, navigation, and other
|
|
474
|
-
elements in a concise header.
|
|
475
474
|
- [`<b-dropdown>`](/docs/components/dropdown) for sub-components that you can place inside
|
|
476
475
|
`<b-nav-item-dropdown>`
|
|
477
|
-
- [Router Link Support reference](/docs
|
|
478
|
-
specific props available on `<b-nav-item>`
|
|
476
|
+
- [Router Link Support reference](?path=/docs/base-link--docs#router-link-support) for information
|
|
477
|
+
about router-link specific props available on `<b-nav-item>`
|
|
479
478
|
|
|
480
479
|
<!-- Component reference added automatically from component package.json -->
|
|
@@ -279,7 +279,7 @@ like `<b-navbar-brand>`, they'll automatically be aligned to the far right. Reve
|
|
|
279
279
|
will reverse the placement of the toggler.
|
|
280
280
|
|
|
281
281
|
See the first example on this page for reference, and also refer to
|
|
282
|
-
[`<
|
|
282
|
+
[`<gl-collapse>`](?path=/docs/base-collapse--docs) for details on the collapse component.
|
|
283
283
|
|
|
284
284
|
Internally, `<b-navbar-toggle>` uses the [`v-b-toggle` directive](/docs/directives/toggle).
|
|
285
285
|
|
|
@@ -322,12 +322,11 @@ Navbars are hidden by default when printing. Force them to be printed by setting
|
|
|
322
322
|
|
|
323
323
|
## See also
|
|
324
324
|
|
|
325
|
-
- [
|
|
325
|
+
- [collapse](?path=/docs/base-collapse--docs)
|
|
326
326
|
- [`v-b-toggle` directive](/docs/directives/toggle)
|
|
327
|
-
- [
|
|
328
|
-
aliases
|
|
327
|
+
- [nav](?path=/docs/base-nav--docs) for additional components and sub-component aliases
|
|
329
328
|
|
|
330
|
-
Refer to the [Router support](/docs
|
|
331
|
-
props.
|
|
329
|
+
Refer to the [Router support](?path=/docs/base-link--docs#router-link-support) reference page for
|
|
330
|
+
router-link specific props.
|
|
332
331
|
|
|
333
332
|
<!-- Component reference added automatically from component package.json -->
|
|
@@ -61,7 +61,7 @@ Twelve options are available for positioning: `top`, `topleft`, `topright`, `rig
|
|
|
61
61
|
`rightbottom`, `bottom`, `bottomleft`, `bottomright`, `left`, `lefttop`, and `leftbottom` aligned.
|
|
62
62
|
Positioning is relative to the trigger element.
|
|
63
63
|
|
|
64
|
-
<
|
|
64
|
+
<section class="bd-example bd-example-popover-static">
|
|
65
65
|
<div class="popover b-popover bs-popover-top bs-popover-top-docs">
|
|
66
66
|
<div class="arrow" style="left: calc(50% - 8px)"></div>
|
|
67
67
|
<h3 class="popover-header">Popover top</h3>
|
|
@@ -163,7 +163,7 @@ Positioning is relative to the trigger element.
|
|
|
163
163
|
</div>
|
|
164
164
|
|
|
165
165
|
<div class="clearfix"></div>
|
|
166
|
-
</
|
|
166
|
+
</section>
|
|
167
167
|
|
|
168
168
|
## Triggers
|
|
169
169
|
|
|
@@ -887,8 +887,8 @@ interacting with it (keeping focus inside the popover until it is closed by the
|
|
|
887
887
|
|
|
888
888
|
**Note:** The animation effect of this component is dependent on the `prefers-reduced-motion` media
|
|
889
889
|
query. See the
|
|
890
|
-
[reduced motion section of our accessibility documentation](/docs
|
|
891
|
-
additional details.
|
|
890
|
+
[reduced motion section of our accessibility documentation](?path=/docs/base-tooltip--docs#accessibility)
|
|
891
|
+
for additional details.
|
|
892
892
|
|
|
893
893
|
### Making popovers work for keyboard and assistive technology users
|
|
894
894
|
|
|
@@ -2168,7 +2168,7 @@ Setting the prop `filter` to null or an empty string will clear local items filt
|
|
|
2168
2168
|
### Debouncing filter criteria changes
|
|
2169
2169
|
|
|
2170
2170
|
<span class="badge badge-warning small">deprecated in v2.1.0</span> Use the `debounce` feature of
|
|
2171
|
-
[
|
|
2171
|
+
[form-input](?path=/docs/base-form-form-input--docst#debounce-support) instead.
|
|
2172
2172
|
|
|
2173
2173
|
If you have a text input tied to the `filter` prop of `<b-table>`, the filtering process will occur
|
|
2174
2174
|
for each character typed by the user. With large items datasets, this process can take a while and
|
|
@@ -2198,7 +2198,7 @@ at a time by setting the `per-page` prop to the maximum number of rows you would
|
|
|
2198
2198
|
use the `current-page` prop to specify which page to display (starting from page `1`). If you set
|
|
2199
2199
|
`current-page` to a value larger than the computed number of pages, then no rows will be shown.
|
|
2200
2200
|
|
|
2201
|
-
You can use the [`<
|
|
2201
|
+
You can use the [`<gl-pagination>`](?path=/docs/base-pagination--docs) component in conjunction with
|
|
2202
2202
|
`<b-table>` for providing control over pagination.
|
|
2203
2203
|
|
|
2204
2204
|
Setting `per-page` to `0` (default) will disable the local items pagination feature.
|
|
@@ -2415,9 +2415,9 @@ of records.
|
|
|
2415
2415
|
respective `no-provider-*` prop set to `true`).
|
|
2416
2416
|
- The `no-local-sorting` prop has no effect when `items` is a provider function.
|
|
2417
2417
|
- When using provider filtering, you may find that setting the
|
|
2418
|
-
[`debounce` prop on `<
|
|
2419
|
-
greater than `100` ms will help minimize the number of calls to your back end API as the
|
|
2420
|
-
types in the criteria.
|
|
2418
|
+
[`debounce` prop on `<gl-form-input>`](?path=/docs/base-form-form-input--docs#debounce-support) to
|
|
2419
|
+
a value greater than `100` ms will help minimize the number of calls to your back end API as the
|
|
2420
|
+
user types in the criteria.
|
|
2421
2421
|
|
|
2422
2422
|
### Force refreshing of table data
|
|
2423
2423
|
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
> cards internally, and provides full keyboard navigation control of the tabs.
|
|
5
5
|
|
|
6
6
|
For navigation based tabs (i.e. tabs that would change the URL), use the
|
|
7
|
-
[
|
|
7
|
+
[nav](?path=/docs/base-nav--docs) component instead.
|
|
8
8
|
|
|
9
9
|
## Basic usage
|
|
10
10
|
|
|
@@ -91,7 +91,7 @@ When `<b-tabs>` is in `card` mode, each `<b-tab>` sub-component will automatical
|
|
|
91
91
|
**Note:** Setting the `no-body` prop on `<b-tab>` will have no affect when `<b-tabs>` is not in
|
|
92
92
|
`card` mode (as the `card-body` class is only set when in `card` mode).
|
|
93
93
|
|
|
94
|
-
Refer to the [Cards documentation](
|
|
94
|
+
Refer to the [Cards documentation](?path=/docs/base-card--docs) for more details on card components.
|
|
95
95
|
|
|
96
96
|
## Pills variant
|
|
97
97
|
|
|
@@ -22,7 +22,7 @@ under the toast.
|
|
|
22
22
|
|
|
23
23
|
```html
|
|
24
24
|
<template>
|
|
25
|
-
<div class="p-3 bg-secondary
|
|
25
|
+
<div class="p-3 bg-secondary" style="min-height: 170px;">
|
|
26
26
|
<b-button class="mb-2" variant="primary" @click="$bvToast.show('example-toast')">
|
|
27
27
|
Show toast
|
|
28
28
|
</b-button>
|
|
@@ -36,8 +36,8 @@ under the toast.
|
|
|
36
36
|
```
|
|
37
37
|
|
|
38
38
|
**Note:** we are using the `static` prop in the above example to render the toast in-place in the
|
|
39
|
-
document, rather than transporting it to a `<b-toaster>` target container. And we have added
|
|
40
|
-
`bg-secondary`
|
|
39
|
+
document, rather than transporting it to a `<b-toaster>` target container. And we have added class
|
|
40
|
+
`bg-secondary` to the outer `<div>` for illustrative purposes of toast
|
|
41
41
|
transparency only.
|
|
42
42
|
|
|
43
43
|
### Toast features and notes
|
|
@@ -535,7 +535,7 @@ for generating more complex toast content:
|
|
|
535
535
|
In some cases you may need just a simple alert style message (i.e. cookie usage notifications,
|
|
536
536
|
etc.). In these cases it is usually better to use an fixed position alert instead of a toast, by
|
|
537
537
|
applying a few Bootstrap [utility classes](/docs/reference/utility-classes) and a small bit of
|
|
538
|
-
custom styling on a [`<
|
|
538
|
+
custom styling on a [`<gl-alert>`](?path=/docs/base-alert--docs) component:
|
|
539
539
|
|
|
540
540
|
```html
|
|
541
541
|
<template>
|
|
@@ -615,7 +615,7 @@ that can impact both people with and without disabilities. The following list, w
|
|
|
615
615
|
provides general guidelines when using toasts.
|
|
616
616
|
|
|
617
617
|
- If the information needed is important for the process, e.g. for a list of errors in a form, then
|
|
618
|
-
use the [`<
|
|
618
|
+
use the [`<gl-alert>`](?path=/docs/base-alert--docs) component instead of `<b-toast>`.
|
|
619
619
|
- `<b-toast>`, by default, sets the attributes `role` to `'alert'` and `aria-live` to `'assertive'`.
|
|
620
620
|
If it's an important message like an error, this default setting is appropriate, otherwise set the
|
|
621
621
|
prop `is-status` to `true` which will change the attributes `role` to `'status'` and `aria-live`
|
|
@@ -64,7 +64,7 @@ Twelve options are available for positioning: `top`, `topleft`, `topright`, `rig
|
|
|
64
64
|
`rightbottom`, `bottom`, `bottomleft`, `bottomright`, `left`, `lefttop`, and `leftbottom` aligned.
|
|
65
65
|
The default position is `top`. Positioning is relative to the trigger element.
|
|
66
66
|
|
|
67
|
-
<
|
|
67
|
+
<section class="bd-example bd-example-tooltip-static">
|
|
68
68
|
<div class="tooltip b-tooltip bs-tooltip-top bs-tooltip-top-docs" role="tooltip">
|
|
69
69
|
<div class="arrow" style="left: calc(50% - 6px)"></div>
|
|
70
70
|
<div class="tooltip-inner">Tooltip on the top</div>
|
|
@@ -113,7 +113,7 @@ The default position is `top`. Positioning is relative to the trigger element.
|
|
|
113
113
|
<div class="arrow" style="top: 0px"></div>
|
|
114
114
|
<div class="tooltip-inner">Tooltip on the leftbottom</div>
|
|
115
115
|
</div>
|
|
116
|
-
</
|
|
116
|
+
</section>
|
|
117
117
|
|
|
118
118
|
Refer to the [Tooltip directive](/docs/directives/tooltip/#positioning) documentation for live
|
|
119
119
|
examples of positioning.
|
|
@@ -553,7 +553,7 @@ with the auto generated ID of the tooltip.
|
|
|
553
553
|
|
|
554
554
|
**Note:** The animation effect of this component is dependent on the `prefers-reduced-motion` media
|
|
555
555
|
query. See the
|
|
556
|
-
[reduced motion section of our accessibility documentation](/docs
|
|
557
|
-
additional details.
|
|
556
|
+
[reduced motion section of our accessibility documentation](?path=/docs/base-tooltip--docs#accessibility)
|
|
557
|
+
for additional details.
|
|
558
558
|
|
|
559
559
|
<!-- Component reference added automatically from component package.json -->
|
|
@@ -44,8 +44,6 @@ export const NAME_NAVBAR_BRAND = 'BNavbarBrand'
|
|
|
44
44
|
export const NAME_NAV_ITEM = 'BNavItem'
|
|
45
45
|
export const NAME_NAV_ITEM_DROPDOWN = 'BNavItemDropdown'
|
|
46
46
|
export const NAME_POPOVER = 'BPopover'
|
|
47
|
-
export const NAME_PROGRESS = 'BProgress'
|
|
48
|
-
export const NAME_PROGRESS_BAR = 'BProgressBar'
|
|
49
47
|
export const NAME_TAB = 'BTab'
|
|
50
48
|
export const NAME_TABLE = 'BTable'
|
|
51
49
|
export const NAME_TABLE_CELL = 'BTableCell'
|
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
# Toggle
|
|
2
2
|
|
|
3
|
-
> `v-b-toggle` is a light-weight directive for toggling the visibility of collapses,
|
|
4
|
-
>
|
|
3
|
+
> `v-b-toggle` is a light-weight directive for toggling the visibility of collapses, and includes
|
|
4
|
+
> automated [WAI-ARIA accessibility](?path=/docs/base-tooltip--docs#accessibility) attribute
|
|
5
|
+
> handling.
|
|
5
6
|
|
|
6
7
|
## Overview
|
|
7
8
|
|
|
8
9
|
The `v-b-toggle` directive can be used on interactive elements, such as buttons and to toggle the
|
|
9
|
-
visibility state of the [`<
|
|
10
|
+
visibility state of the [`<gl-collapse>`](?path=/docs/base-collapse--docs) component.
|
|
10
11
|
|
|
11
12
|
Besides toggling the visibility of the target component, the directive automatically updates ARIA
|
|
12
13
|
accessibility attributes on the element it is applied to so that they reflect the visibility state
|
|
@@ -141,6 +142,4 @@ via `v-model`, other controls with `v-b-toggle` directive, or CSS visibility).
|
|
|
141
142
|
|
|
142
143
|
## See also
|
|
143
144
|
|
|
144
|
-
- [
|
|
145
|
-
- [`<b-navbar-toggle>`](/docs/components/navbar#b-navbar-toggle-and-b-collapse-is-nav) Navbar
|
|
146
|
-
hamburger toggle button (based on `v-b-toggle` directive)
|
|
145
|
+
- [collapse](?path=/docs/base-collapse--docs) Collapsible content with accordion support
|
|
@@ -515,7 +515,7 @@ disabled.
|
|
|
515
515
|
|
|
516
516
|
## See also
|
|
517
517
|
|
|
518
|
-
- [
|
|
519
|
-
- [
|
|
518
|
+
- [tooltip](?path=/docs/base-tooltip--docs)
|
|
519
|
+
- [popover](?path=/docs/base-popover--docs)
|
|
520
520
|
|
|
521
521
|
<!-- Directive reference section auto generated from directive package.json -->
|
|
@@ -135,10 +135,6 @@ export { BNavbarBrand } from './components/navbar/navbar-brand'
|
|
|
135
135
|
// export * from './components/popover'
|
|
136
136
|
export { BPopover } from './components/popover/popover'
|
|
137
137
|
|
|
138
|
-
// export * from './components/progress'
|
|
139
|
-
export { BProgress } from './components/progress/progress'
|
|
140
|
-
export { BProgressBar } from './components/progress/progress-bar'
|
|
141
|
-
|
|
142
138
|
// export * from './components/table'
|
|
143
139
|
export { BTable } from './components/table/table'
|
|
144
140
|
export { BTableLite } from './components/table/table-lite'
|
|
@@ -1,128 +0,0 @@
|
|
|
1
|
-
import { extend } from '../../vue';
|
|
2
|
-
import { NAME_PROGRESS_BAR } from '../../constants/components';
|
|
3
|
-
import { PROP_TYPE_BOOLEAN, PROP_TYPE_STRING, PROP_TYPE_NUMBER_STRING } from '../../constants/props';
|
|
4
|
-
import { htmlOrText } from '../../utils/html';
|
|
5
|
-
import { isBoolean } from '../../utils/inspect';
|
|
6
|
-
import { mathMax, mathPow } from '../../utils/math';
|
|
7
|
-
import { toFloat, toInteger, toFixed } from '../../utils/number';
|
|
8
|
-
import { makePropsConfigurable, makeProp } from '../../utils/props';
|
|
9
|
-
import { toString } from '../../utils/string';
|
|
10
|
-
import { normalizeSlotMixin } from '../../mixins/normalize-slot';
|
|
11
|
-
|
|
12
|
-
// --- Props ---
|
|
13
|
-
|
|
14
|
-
const props = makePropsConfigurable({
|
|
15
|
-
animated: makeProp(PROP_TYPE_BOOLEAN, null),
|
|
16
|
-
label: makeProp(PROP_TYPE_STRING),
|
|
17
|
-
labelHtml: makeProp(PROP_TYPE_STRING),
|
|
18
|
-
max: makeProp(PROP_TYPE_NUMBER_STRING, null),
|
|
19
|
-
precision: makeProp(PROP_TYPE_NUMBER_STRING, null),
|
|
20
|
-
showProgress: makeProp(PROP_TYPE_BOOLEAN, null),
|
|
21
|
-
showValue: makeProp(PROP_TYPE_BOOLEAN, null),
|
|
22
|
-
striped: makeProp(PROP_TYPE_BOOLEAN, null),
|
|
23
|
-
value: makeProp(PROP_TYPE_NUMBER_STRING, 0),
|
|
24
|
-
variant: makeProp(PROP_TYPE_STRING)
|
|
25
|
-
}, NAME_PROGRESS_BAR);
|
|
26
|
-
|
|
27
|
-
// --- Main component ---
|
|
28
|
-
|
|
29
|
-
// @vue/component
|
|
30
|
-
const BProgressBar = /*#__PURE__*/extend({
|
|
31
|
-
name: NAME_PROGRESS_BAR,
|
|
32
|
-
mixins: [normalizeSlotMixin],
|
|
33
|
-
inject: {
|
|
34
|
-
getBvProgress: {
|
|
35
|
-
default: /* istanbul ignore next */() => () => ({})
|
|
36
|
-
}
|
|
37
|
-
},
|
|
38
|
-
props,
|
|
39
|
-
computed: {
|
|
40
|
-
bvProgress() {
|
|
41
|
-
return this.getBvProgress();
|
|
42
|
-
},
|
|
43
|
-
progressBarClasses() {
|
|
44
|
-
const {
|
|
45
|
-
computedAnimated,
|
|
46
|
-
computedVariant
|
|
47
|
-
} = this;
|
|
48
|
-
return [computedVariant ? `bg-${computedVariant}` : '', this.computedStriped || computedAnimated ? 'progress-bar-striped' : '', computedAnimated ? 'progress-bar-animated' : ''];
|
|
49
|
-
},
|
|
50
|
-
progressBarStyles() {
|
|
51
|
-
return {
|
|
52
|
-
width: 100 * (this.computedValue / this.computedMax) + '%'
|
|
53
|
-
};
|
|
54
|
-
},
|
|
55
|
-
computedValue() {
|
|
56
|
-
return toFloat(this.value, 0);
|
|
57
|
-
},
|
|
58
|
-
computedMax() {
|
|
59
|
-
// Prefer our max over parent setting
|
|
60
|
-
// Default to `100` for invalid values (`-x`, `0`, `NaN`)
|
|
61
|
-
const max = toFloat(this.max) || toFloat(this.bvProgress.max, 0);
|
|
62
|
-
return max > 0 ? max : 100;
|
|
63
|
-
},
|
|
64
|
-
computedPrecision() {
|
|
65
|
-
// Prefer our precision over parent setting
|
|
66
|
-
// Default to `0` for invalid values (`-x`, `NaN`)
|
|
67
|
-
return mathMax(toInteger(this.precision, toInteger(this.bvProgress.precision, 0)), 0);
|
|
68
|
-
},
|
|
69
|
-
computedProgress() {
|
|
70
|
-
const precision = this.computedPrecision;
|
|
71
|
-
const p = mathPow(10, precision);
|
|
72
|
-
return toFixed(100 * p * this.computedValue / this.computedMax / p, precision);
|
|
73
|
-
},
|
|
74
|
-
computedVariant() {
|
|
75
|
-
// Prefer our variant over parent setting
|
|
76
|
-
return this.variant || this.bvProgress.variant;
|
|
77
|
-
},
|
|
78
|
-
computedStriped() {
|
|
79
|
-
// Prefer our striped over parent setting
|
|
80
|
-
return isBoolean(this.striped) ? this.striped : this.bvProgress.striped || false;
|
|
81
|
-
},
|
|
82
|
-
computedAnimated() {
|
|
83
|
-
// Prefer our animated over parent setting
|
|
84
|
-
return isBoolean(this.animated) ? this.animated : this.bvProgress.animated || false;
|
|
85
|
-
},
|
|
86
|
-
computedShowProgress() {
|
|
87
|
-
// Prefer our showProgress over parent setting
|
|
88
|
-
return isBoolean(this.showProgress) ? this.showProgress : this.bvProgress.showProgress || false;
|
|
89
|
-
},
|
|
90
|
-
computedShowValue() {
|
|
91
|
-
// Prefer our showValue over parent setting
|
|
92
|
-
return isBoolean(this.showValue) ? this.showValue : this.bvProgress.showValue || false;
|
|
93
|
-
}
|
|
94
|
-
},
|
|
95
|
-
render(h) {
|
|
96
|
-
const {
|
|
97
|
-
label,
|
|
98
|
-
labelHtml,
|
|
99
|
-
computedValue,
|
|
100
|
-
computedPrecision
|
|
101
|
-
} = this;
|
|
102
|
-
let $children;
|
|
103
|
-
let domProps = {};
|
|
104
|
-
if (this.hasNormalizedSlot()) {
|
|
105
|
-
$children = this.normalizeSlot();
|
|
106
|
-
} else if (label || labelHtml) {
|
|
107
|
-
domProps = htmlOrText(labelHtml, label);
|
|
108
|
-
} else if (this.computedShowProgress) {
|
|
109
|
-
$children = this.computedProgress;
|
|
110
|
-
} else if (this.computedShowValue) {
|
|
111
|
-
$children = toFixed(computedValue, computedPrecision);
|
|
112
|
-
}
|
|
113
|
-
return h('div', {
|
|
114
|
-
staticClass: 'progress-bar',
|
|
115
|
-
class: this.progressBarClasses,
|
|
116
|
-
style: this.progressBarStyles,
|
|
117
|
-
attrs: {
|
|
118
|
-
role: 'progressbar',
|
|
119
|
-
'aria-valuemin': '0',
|
|
120
|
-
'aria-valuemax': toString(this.computedMax),
|
|
121
|
-
'aria-valuenow': toFixed(computedValue, computedPrecision)
|
|
122
|
-
},
|
|
123
|
-
domProps
|
|
124
|
-
}, $children);
|
|
125
|
-
}
|
|
126
|
-
});
|
|
127
|
-
|
|
128
|
-
export { BProgressBar, props };
|