@marwes-ui/react 1.0.3 → 1.0.4
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 +17 -0
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -378,6 +378,23 @@ By default Marwes keeps theme state scoped to the provider element. If your app
|
|
|
378
378
|
|
|
379
379
|
Use one global-target provider per app shell. If multiple providers target `html` or `body`, deciding which provider owns that global element is app-owned behavior.
|
|
380
380
|
|
|
381
|
+
### Tailwind And shadcn Compatibility
|
|
382
|
+
|
|
383
|
+
Marwes is compatible with Tailwind and shadcn-style dark variants through `target="html" attribute="class"`. App-owned Tailwind tokens can also reference Marwes `--mw-*` variables when rendered inside the provider subtree.
|
|
384
|
+
|
|
385
|
+
```tsx
|
|
386
|
+
<MarwesProvider
|
|
387
|
+
defaultPreference="system"
|
|
388
|
+
storageKey="marwes-theme"
|
|
389
|
+
target="html"
|
|
390
|
+
attribute="class"
|
|
391
|
+
>
|
|
392
|
+
<AppShell />
|
|
393
|
+
</MarwesProvider>
|
|
394
|
+
```
|
|
395
|
+
|
|
396
|
+
Read the [Tailwind and shadcn integration guide](https://github.com/niklas-westman/marwes/blob/main/docs/guides/tailwind-shadcn-integration.md) for Tailwind v3/v4 examples, token mapping, provider-scoped variable limits, and the SSR no-flash boundary.
|
|
397
|
+
|
|
381
398
|
For a simple brand pass, override shared values once and let Marwes fill the rest. If your product needs different brand colors in light and dark mode, control `mode` and switch between two small `ThemeInput` override objects:
|
|
382
399
|
|
|
383
400
|
```tsx
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@marwes-ui/react",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.4",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -20,8 +20,8 @@
|
|
|
20
20
|
"dist"
|
|
21
21
|
],
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@marwes-ui/core": "1.0.
|
|
24
|
-
"@marwes-ui/presets": "1.0.
|
|
23
|
+
"@marwes-ui/core": "1.0.4",
|
|
24
|
+
"@marwes-ui/presets": "1.0.4"
|
|
25
25
|
},
|
|
26
26
|
"peerDependencies": {
|
|
27
27
|
"react": ">=18",
|