@nxgt/material-vue 0.2.0 → 0.3.1
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/README.md +40 -27
- package/dist/{camera-6qqJBfXA.js → camera-MRgEC7pl.js} +1 -1
- package/dist/{components-Cd9cMyAH.js → components-Cbdud8WI.js} +5689 -5686
- package/dist/components.js +1 -1
- package/dist/lib/lib/components/ui/barecode/barecode-options.d.ts +6 -2
- package/dist/lib/lib/nuxt/module.d.ts +0 -5
- package/dist/main.js +1 -1
- package/dist/material-vue.css +1 -1
- package/dist/{pdf-outline-sidebar-DhZqpRoO.js → pdf-outline-sidebar-h9_YREnD.js} +1 -1
- package/dist/{pdf-page-list-CqRIdpm7.js → pdf-page-list-61J-y1Jy.js} +2 -2
- package/dist/{pdf-page-DzmRPuT_.js → pdf-page-rGTgfSly.js} +1 -1
- package/dist/{pdf-reader-C0UXHO0I.js → pdf-reader-CtkJSAzA.js} +5 -5
- package/dist/{pdf-sidebar-BPfizuMa.js → pdf-sidebar-Qo-cHfYv.js} +3 -3
- package/dist/{pdf-thumbnail-sidebar-Ca3LhKTL.js → pdf-thumbnail-sidebar-CojlsV6q.js} +2 -2
- package/dist/{pdf-toolbar-B8YdJxDq.js → pdf-toolbar-UbBVdrBX.js} +1 -1
- package/dist/{stx-player-BUFJQ9Ym.js → stx-player-Cl3bspwE.js} +1 -1
- package/dist/styles.css +2 -1
- package/lib/nuxt/module.ts +15 -31
- package/lib/styles.css +2 -1
- package/package.json +2 -2
- package/dist/lib/lib/nuxt/inject-css.d.ts +0 -10
- package/lib/nuxt/inject-css.test.ts +0 -41
- package/lib/nuxt/inject-css.ts +0 -24
package/README.md
CHANGED
|
@@ -5,49 +5,62 @@ drag-and-drop, i18n, and `Icon`. Tailwind CSS v4 + shadcn-vue (Reka UI).
|
|
|
5
5
|
|
|
6
6
|
This package is the Vue mirror of [`@nxgt/material`](https://github.com/softistx/nxgt-material).
|
|
7
7
|
|
|
8
|
-
##
|
|
8
|
+
## Styles
|
|
9
9
|
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
modules: ['@nxgt/material-vue/nuxt'],
|
|
13
|
-
css: ['~/assets/css/main.css'],
|
|
14
|
-
nxgtMaterial: {
|
|
15
|
-
// prefix: 'Nxgt',
|
|
16
|
-
// css: true,
|
|
17
|
-
},
|
|
18
|
-
});
|
|
19
|
-
```
|
|
10
|
+
Import the stylesheet **explicitly**, in your Tailwind v4 entry, right after
|
|
11
|
+
`@import "tailwindcss"`:
|
|
20
12
|
|
|
21
13
|
```css
|
|
22
|
-
/* app/assets/css/main.css
|
|
14
|
+
/* app/assets/css/main.css */
|
|
23
15
|
@import "tailwindcss";
|
|
16
|
+
@import "@nxgt/material-vue/styles.css";
|
|
24
17
|
```
|
|
25
18
|
|
|
26
|
-
|
|
19
|
+
Nothing injects it for you, on purpose:
|
|
27
20
|
|
|
28
|
-
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
-
|
|
33
|
-
|
|
21
|
+
- Tailwind v4 builds **one** `@theme` from a single CSS graph. `@theme` /
|
|
22
|
+
`@utility` only apply when `styles.css` is imported in the same file as
|
|
23
|
+
`@import "tailwindcss"`; a second stylesheet (for example another Nuxt
|
|
24
|
+
`css[]` entry) starts a second pipeline, and the tokens never reach the app.
|
|
25
|
+
- Tailwind CSS IntelliSense reads the theme from that entry file. An explicit
|
|
26
|
+
import lets it autocomplete the library tokens (`bg-primary`,
|
|
27
|
+
`text-error-foreground`, `rounded-lg`, …) in your templates.
|
|
28
|
+
|
|
29
|
+
Tailwind v4 does not scan `node_modules`. `styles.css` already declares
|
|
30
|
+
`@source "../dist"`, so the utilities used inside the components are generated
|
|
31
|
+
by your build: no extra `@source` needed.
|
|
32
|
+
|
|
33
|
+
### Stylesheets
|
|
34
34
|
|
|
35
|
-
|
|
35
|
+
| Import | What is in it |
|
|
36
|
+
| --- | --- |
|
|
37
|
+
| `@import "@nxgt/material-vue/styles.css"` | source Tailwind v4 tokens, `@theme`, `@utility`: **this** is what a Tailwind app imports |
|
|
38
|
+
| `@import "@nxgt/material-vue"` | `style` condition of the root export → `dist/material-vue.css`: compiled, self-contained CSS (tokens + every utility the components use), for apps without Tailwind |
|
|
36
39
|
|
|
37
|
-
|
|
40
|
+
Do not import both in the same app.
|
|
41
|
+
|
|
42
|
+
## Nuxt
|
|
38
43
|
|
|
39
44
|
```ts
|
|
40
45
|
export default defineNuxtConfig({
|
|
41
46
|
modules: ['@nxgt/material-vue/nuxt'],
|
|
42
|
-
|
|
47
|
+
css: ['~/assets/css/main.css'], // imports styles.css, see above
|
|
48
|
+
vite: { plugins: [tailwindcss()] },
|
|
49
|
+
nxgtMaterial: {
|
|
50
|
+
// prefix: 'Nxgt',
|
|
51
|
+
},
|
|
43
52
|
});
|
|
44
53
|
```
|
|
45
54
|
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
55
|
+
The module:
|
|
56
|
+
|
|
57
|
+
- Auto-imports components and composables
|
|
58
|
+
- Installs Pinia when the host app has none
|
|
59
|
+
- Pre-bundles CommonJS dependencies (`jsbarcode`) for Vite
|
|
60
|
+
|
|
61
|
+
It does **not** add the stylesheet: import it yourself as shown in
|
|
62
|
+
[Styles](#styles).
|
|
50
63
|
|
|
51
64
|
## Status
|
|
52
65
|
|
|
53
|
-
Published on npm. Pin a version in the consumer (`^0.
|
|
66
|
+
Published on npm. Pin a version in the consumer (`^0.2.0`).
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Dl as e, Tl as t, wl as n } from "./components-
|
|
1
|
+
import { Dl as e, Tl as t, wl as n } from "./components-Cbdud8WI.js";
|
|
2
2
|
import { t as r } from "./utils-Cy-ByIEo.js";
|
|
3
3
|
import { r as i, t as a } from "./icon-button-Ghucx7Ah.js";
|
|
4
4
|
import { n as o } from "./i18n-DXZMN9FA.js";
|