@nxgt/material-vue 0.37.1 → 0.38.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 +80 -0
- package/README.md +1 -0
- package/dist/{Button-CurFF4Zt.js → Button-5UyKA-x_.js} +1 -1
- package/dist/{HoverCardTrigger-jCXl6TrX.js → HoverCardTrigger-CmCDiTn8.js} +2 -2
- package/dist/{camera-CYwiFuGE.js → camera-BWzF8sOW.js} +4 -4
- package/dist/components/base.css +3 -1
- package/dist/{components--v_k8diD.js → components-B_s5oxUp.js} +11816 -11302
- package/dist/components.js +8 -8
- package/dist/composables.js +2 -2
- package/dist/dnd.js +1 -1
- package/dist/{form-scope-B2oJ5fHr.js → form-scope-UzoU38db.js} +1 -1
- package/dist/{i18n-provider-B2q6vp6H.js → i18n-provider-BEvjls8b.js} +1 -1
- package/dist/i18n.js +4 -4
- package/dist/{icon-button-CIUc1bEp.js → icon-button-DhqJE6Ej.js} +1 -1
- package/dist/lib/components/ui/feedback/banner/banner.vue.d.ts +1 -1
- package/dist/lib/components/ui/fields/contacts/consts.d.ts +1 -1
- package/dist/lib/components/ui/fields/index.d.ts +1 -0
- package/dist/lib/components/ui/fields/repeatable-group/index.d.ts +4 -0
- package/dist/lib/components/ui/fields/repeatable-group/partials/repeatable-group-footer.vue.d.ts +14 -0
- package/dist/lib/components/ui/fields/repeatable-group/partials/repeatable-group-row.vue.d.ts +33 -0
- package/dist/lib/components/ui/fields/repeatable-group/repeatable-group-classes.d.ts +33 -0
- package/dist/lib/components/ui/fields/repeatable-group/repeatable-group-form-field.vue.d.ts +44 -0
- package/dist/lib/components/ui/fields/repeatable-group/repeatable-group-names.d.ts +16 -0
- package/dist/lib/components/ui/fields/repeatable-group/repeatable-group.vue.d.ts +69 -0
- package/dist/lib/components/ui/fields/repeatable-group/use-repeatable-group.d.ts +39 -0
- package/dist/lib/components/ui/fields/search-field/search-field.vue.d.ts +10 -1
- package/dist/lib/components/ui/media/stx-player/stx-player-extras.vue.d.ts +1 -1
- package/dist/lib/components/ui/overlays/command/CommandItem.vue.d.ts +10 -3
- package/dist/lib/components/ui/overlays/command/CommandList.vue.d.ts +4 -2
- package/dist/lib/components/ui/primitives/typography/typography.variants.d.ts +1 -0
- package/dist/lib/components/ui/primitives/typography/typography.vue.d.ts +2 -0
- package/dist/lib/components/ui/selection/checkbox-group/checkbox-group.vue.d.ts +2 -0
- package/dist/lib/components/ui/selection/option-count/option-count.vue.d.ts +25 -0
- package/dist/lib/components/ui/selection/option-count/use-option-count-text.d.ts +10 -0
- package/dist/lib/components/ui/selection/radio-group/radio-group-field.vue.d.ts +2 -0
- package/dist/lib/components/ui/selection/select-chip-field/select-chip-field.vue.d.ts +11 -0
- package/dist/lib/components/ui/selection/sortable-list/sortable-list.vue.d.ts +1 -1
- package/dist/lib/components/ui/selection/transfer-list/transfer-list.vue.d.ts +1 -1
- package/dist/lib/i18n/resources/en/en.d.ts +14 -0
- package/dist/lib/i18n/resources/en/material.json.d.ts +14 -0
- package/dist/lib/i18n/resources/fr/fr.d.ts +14 -0
- package/dist/lib/i18n/resources/fr/material.json.d.ts +14 -0
- package/dist/lib/i18n/resources/resources.d.ts +28 -0
- package/dist/lib/i18n/translator.d.ts +1 -1
- package/dist/lib/nuxt/component-names.d.ts +1 -1
- package/dist/lib.js +1 -1
- package/dist/main.js +17 -17
- package/dist/map.js +4 -4
- package/dist/material-vue.css +1 -1
- package/dist/{pdf-outline-sidebar-DJJ-ARco.js → pdf-outline-sidebar-BsePJlTi.js} +2 -2
- package/dist/{pdf-page-CRt6KXdJ.js → pdf-page-Ct313mNF.js} +1 -1
- package/dist/{pdf-page-list-BgCp5Asx.js → pdf-page-list-JrRo2BeU.js} +2 -2
- package/dist/{pdf-reader-BGxqEx8O.js → pdf-reader-tABBZMbZ.js} +8 -8
- package/dist/{pdf-sidebar-Cvtuomgp.js → pdf-sidebar-Caw9rzU-.js} +3 -3
- package/dist/{pdf-thumbnail-sidebar-CeWPs7o7.js → pdf-thumbnail-sidebar-ZybLeUG7.js} +3 -3
- package/dist/{pdf-toolbar-BtXcyEpd.js → pdf-toolbar-BM8Sz_JN.js} +4 -4
- package/dist/pdf.js +2 -2
- package/dist/{print-format.utils-keJqahvw.js → print-format.utils-CQFIVeUA.js} +2 -2
- package/dist/{sortable-provider-DMu8DL2z.js → sortable-provider-CKkWYijj.js} +2 -2
- package/dist/{stored-language-dtksFoGO.js → stored-language-CvOHC8AD.js} +24 -0
- package/dist/{stx-player-nDsDyvc-.js → stx-player-CsVKbwFk.js} +5 -5
- package/dist/{translator-DqiGrSH_.js → translator-k1rKIgC7.js} +1 -1
- package/dist/{use-heading-spy-BZ7ctGZ5.js → use-heading-spy-D-ipoQwl.js} +1 -1
- package/dist/{use-material-translation-DRB6oPdF.js → use-material-translation-1FdRx9I7.js} +3 -3
- package/docs/components/README.md +1 -1
- package/docs/components/form-fields.md +146 -0
- package/docs/components/overlays-and-menus.md +2 -0
- package/docs/components/primitives.md +3 -1
- package/docs/components/selection-and-choice.md +28 -4
- package/docs/guides/forms.md +34 -0
- package/docs/previews/form-fields-repeatablegroup.webp +0 -0
- package/docs/roadmap.md +7 -0
- package/docs/troubleshooting.md +43 -0
- package/lib/components/base.css +3 -1
- package/lib/nuxt/component-names.ts +2 -0
- package/package.json +2 -2
package/docs/troubleshooting.md
CHANGED
|
@@ -51,6 +51,7 @@ words in your error.
|
|
|
51
51
|
- [The app shell's page scrolls instead of its content, or a full-height screen collapses](#the-app-shells-page-scrolls-instead-of-its-content-or-a-full-height-screen-collapses)
|
|
52
52
|
- [A test finds a new heading or a second `main`, or no longer finds a title in a `div`](#a-test-finds-a-new-heading-or-a-second-main-or-no-longer-finds-a-title-in-a-div)
|
|
53
53
|
- [`[data-test="typogaphy"]` finds nothing](#data-testtypogaphy-finds-nothing)
|
|
54
|
+
- [Long text in `Typography` no longer scrolls](#long-text-in-typography-no-longer-scrolls)
|
|
54
55
|
- [A `class` on `ActivityLayout` now styles the whole shell](#a-class-on-activitylayout-now-styles-the-whole-shell)
|
|
55
56
|
- [A test no longer finds a calendar day by its number](#a-test-no-longer-finds-a-calendar-day-by-its-number)
|
|
56
57
|
- [A `QRCode`'s `aria-label` is no longer on its wrapper](#a-qrcodes-aria-label-is-no-longer-on-its-wrapper)
|
|
@@ -97,6 +98,7 @@ words in your error.
|
|
|
97
98
|
- [A failed submit does not focus the first invalid field](#a-failed-submit-does-not-focus-the-first-invalid-field)
|
|
98
99
|
- [A test that finds a chip by `aria-selected` or `getByRole('option')` no longer finds it](#a-test-that-finds-a-chip-by-aria-selected-or-getbyroleoption-no-longer-finds-it)
|
|
99
100
|
- [The `ref` of a `SelectChipField` focuses nothing](#the-ref-of-a-selectchipfield-focuses-nothing)
|
|
101
|
+
- [The focus does not move to a new row of a `RepeatableGroupFormField`](#the-focus-does-not-move-to-a-new-row-of-a-repeatablegroupformfield)
|
|
100
102
|
- [A multi-step form reopens at a later step](#a-multi-step-form-reopens-at-a-later-step)
|
|
101
103
|
- [The form could not be loaded.](#the-form-could-not-be-loaded)
|
|
102
104
|
|
|
@@ -836,6 +838,26 @@ with its own `<main>` passes `content-as="div"`.
|
|
|
836
838
|
**Fix:** select `[data-test="typography"]` — or better, the text or the role
|
|
837
839
|
the user sees.
|
|
838
840
|
|
|
841
|
+
### Long text in `Typography` no longer scrolls
|
|
842
|
+
|
|
843
|
+
**When:** after upgrading, a `Typography` with a fixed height or width used to
|
|
844
|
+
scroll its overflowing text; it now overflows its box (or `truncate` and
|
|
845
|
+
`line-clamp-*` are the only things that clip it).
|
|
846
|
+
**Why:** `Typography` always carried `overflow-auto`, which made every block
|
|
847
|
+
`Typography` a scroll region: Firefox counted a subpixel overflow, and axe
|
|
848
|
+
reported `scrollable-region-focusable`. It sets no `overflow` now, so it is no
|
|
849
|
+
longer a block formatting context (its margins can collapse with its
|
|
850
|
+
neighbours'), and a text flex or grid item no longer has the zero minimum width a scroll container has.
|
|
851
|
+
**Fix:** where you want scrolling, wrap the text in an element that owns it,
|
|
852
|
+
focusable and named so keyboard users can scroll it; where you want a flex
|
|
853
|
+
item to shrink, give it `min-w-0`:
|
|
854
|
+
|
|
855
|
+
```vue
|
|
856
|
+
<div class="max-h-40 overflow-auto" tabindex="0" aria-label="Release notes">
|
|
857
|
+
<Typography>{{ longText }}</Typography>
|
|
858
|
+
</div>
|
|
859
|
+
```
|
|
860
|
+
|
|
839
861
|
### A `class` on `ActivityLayout` now styles the whole shell
|
|
840
862
|
|
|
841
863
|
**When:** after upgrading, the classes passed to `<ActivityLayout class="…">`
|
|
@@ -1974,6 +1996,27 @@ yourself.
|
|
|
1974
1996
|
field.value?.$el.querySelector<HTMLElement>('[aria-pressed="true"], button')?.focus();
|
|
1975
1997
|
```
|
|
1976
1998
|
|
|
1999
|
+
### The focus does not move to a new row of a `RepeatableGroupFormField`
|
|
2000
|
+
|
|
2001
|
+
**When:** a row is added to a `RepeatableGroupFormField` by your own code (a
|
|
2002
|
+
second "Add" button, a "Duplicate" action) through vee-validate's
|
|
2003
|
+
`useFieldArray` `push`, `prepend` or `insert` on the same `name`, and the focus
|
|
2004
|
+
stays where it was, with nothing announced.
|
|
2005
|
+
**Why:** the group moves the focus and announces the change only after its
|
|
2006
|
+
own buttons (the new row's first field, a removed row's neighbour, a move
|
|
2007
|
+
button). A row added from outside is a value change it renders, not an action
|
|
2008
|
+
it took.
|
|
2009
|
+
**Fix:** let the group's Add button add rows (`new-row` is what it pushes).
|
|
2010
|
+
When your own code must add one, move the focus yourself once the row has
|
|
2011
|
+
rendered:
|
|
2012
|
+
|
|
2013
|
+
```ts
|
|
2014
|
+
const { push } = useFieldArray('periods');
|
|
2015
|
+
push({ name: '' });
|
|
2016
|
+
await nextTick();
|
|
2017
|
+
document.querySelector<HTMLElement>('[data-slot="repeatable-group-row"]:last-child input')?.focus();
|
|
2018
|
+
```
|
|
2019
|
+
|
|
1977
2020
|
### A multi-step form reopens at a later step
|
|
1978
2021
|
|
|
1979
2022
|
**When:** a wizard built on `defineStepFormStore` opens at the step (and with
|
package/lib/components/base.css
CHANGED
|
@@ -55,7 +55,9 @@
|
|
|
55
55
|
font-size: var(--text-xs);
|
|
56
56
|
font-weight: var(--font-weight-medium);
|
|
57
57
|
}
|
|
58
|
-
a:
|
|
58
|
+
/* A sidebar entry is a link styled as a menu entry: the prose link style
|
|
59
|
+
(underline, info tint on hover and focus) must not reach it (#566). */
|
|
60
|
+
a:not(:has(> button)):not([data-slot="sidebar-menu-item"]) {
|
|
59
61
|
@apply focus:underline underline-offset-4 hover:underline cursor-pointer;
|
|
60
62
|
@apply text-info [&_svg]:data-[slot=icon]:text-info hover:bg-info/10 active:bg-info/5 focus:bg-info/15;
|
|
61
63
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nxgt/material-vue",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.38.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"bugs": {
|
|
6
6
|
"email": "stevegires@gmail.com"
|
|
@@ -124,7 +124,7 @@
|
|
|
124
124
|
"docs:previews": "vitest run --project previews"
|
|
125
125
|
},
|
|
126
126
|
"dependencies": {
|
|
127
|
-
"@nxgt/material-core": "^0.
|
|
127
|
+
"@nxgt/material-core": "^0.11.0",
|
|
128
128
|
"@floating-ui/dom": "^1.8.0",
|
|
129
129
|
"@fortawesome/fontawesome-common-types": "7.3.1",
|
|
130
130
|
"@lucide/vue": "^1.45.0",
|