@podoba/tailwind 0.0.54 → 0.0.56

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 (2) hide show
  1. package/README.md +19 -14
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -1,21 +1,26 @@
1
1
  # @podoba/tailwind
2
2
 
3
- The shared Tailwind preset. Binds `@podoba/tokens` CSS custom properties to Tailwind's
4
- `theme.extend`, so `@podoba/react` primitives (and your app code) can use utilities like
5
- `bg-surface`, `text-fg-muted`, `text-heading2`, `rounded-panel`.
3
+ The shared Tailwind v4 theme. Binds `@podoba/tokens` CSS custom properties to Tailwind's
4
+ `@theme`, so `@podoba/react` primitives (and your app code) can use utilities like
5
+ `bg-surface`, `text-fg-muted`, `text-heading2`, `rounded-panel`. The theme is
6
+ `@theme inline`, so those utilities compile to `var(--color-surface)` and friends, never
7
+ to a copied value.
6
8
 
7
- ```ts
8
- // tailwind.config.ts in a consuming app
9
- import podobaPreset from "@podoba/tailwind";
9
+ It is a CSS file, not a JS preset, and needs Tailwind v4:
10
10
 
11
- export default {
12
- presets: [podobaPreset],
13
- content: ["./src/**/*.{ts,tsx}"], // you own your content globs
14
- };
11
+ ```css
12
+ /* app.css */
13
+ @import "tailwindcss";
14
+ @import "@podoba/tokens/variables.css";
15
+ @import "@podoba/tailwind";
16
+
17
+ @source "./**/*.{ts,tsx}"; /* you own your source globs */
18
+ @source "../node_modules/@podoba/react/src/**/*.{ts,tsx}";
15
19
  ```
16
20
 
17
- Also `import "@podoba/tokens/variables.css"` once at your app root so the `var(--…)`
18
- the preset points at actually resolve.
21
+ The theme is intentionally **content-less**. A theme that hardcodes source globs (as
22
+ `@app/ui` did, pointing at `../../apps/web`) breaks every other consumer.
19
23
 
20
- The preset is intentionally **content-less** — a preset that hardcodes `content` globs
21
- (as `@app/ui` did, pointing at `../../apps/web`) breaks every other consumer.
24
+ An app that does not run Tailwind at all does not need this package: it imports the
25
+ prebuilt `@podoba/react/styles.css` instead. See the
26
+ [`@podoba/react` README](../react/README.md) for both setups and why an app picks one.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@podoba/tailwind",
3
- "version": "0.0.54",
3
+ "version": "0.0.56",
4
4
  "type": "module",
5
5
  "description": "podoba Tailwind v4 theme — binds @podoba/tokens CSS custom properties to Tailwind's @theme. Import after `@import \"tailwindcss\"`.",
6
6
  "repository": {