@dynostack/react-grid 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/dist/styles.css CHANGED
@@ -15,10 +15,12 @@
15
15
  * • shadcn-compatible: token names match shadcn/ui's CSS variables exactly,
16
16
  * so if you already have shadcn (or any compatible theme) defined on
17
17
  * :root, *that* takes precedence and the grid blends in automatically.
18
+ * • Tailwind v4 utility classes (`bg-popover`, `text-foreground`, etc.)
19
+ * resolve automatically — see the @theme block below.
18
20
  *
19
21
  * Cascade design
20
22
  * --------------
21
- * All declarations below live inside the `dynostack-grid-defaults` cascade
23
+ * All variable values live inside the `dynostack-grid-defaults` cascade
22
24
  * layer. Any *unlayered* declaration in the consumer app (which is where
23
25
  * shadcn and most app CSS lives) automatically wins, regardless of import
24
26
  * order. This makes import order non-fragile — you cannot accidentally
@@ -31,6 +33,54 @@
31
33
  * <lowest priority>
32
34
  */
33
35
 
36
+ /* ─── Tailwind v4 token registration ──────────────────────────────────
37
+ * Tells Tailwind v4 to generate `bg-popover`, `text-foreground`,
38
+ * `border-border`, `rounded-lg`, etc. utility classes that resolve to our
39
+ * CSS variables. Without this, the bundled `className` strings inside the
40
+ * grid have no corresponding CSS rules in zero-config v4 projects, and
41
+ * overlays render with transparent backgrounds.
42
+ *
43
+ * Must be declared at the top level — Tailwind v4 processes `@theme`
44
+ * before cascade layers apply, and `@theme` inside `@layer` is not valid.
45
+ *
46
+ * Safe across stacks:
47
+ * • Tailwind v4 → consumed normally, utilities generated.
48
+ * • Tailwind v3 → unknown at-rule, silently ignored. (v3 users still
49
+ * need to map semantic colors in tailwind.config.js;
50
+ * see README → Tailwind setup.)
51
+ * • Non-Tailwind → unknown at-rule, ignored.
52
+ * • shadcn consumer with their own @theme block → declarations merge.
53
+ * Since we use the same shadcn token names, the values are identical
54
+ * and there is no conflict.
55
+ * ─────────────────────────────────────────────────────────────────────── */
56
+ @theme inline {
57
+ --color-background: var(--background);
58
+ --color-foreground: var(--foreground);
59
+ --color-card: var(--card);
60
+ --color-card-foreground: var(--card-foreground);
61
+ --color-popover: var(--popover);
62
+ --color-popover-foreground: var(--popover-foreground);
63
+ --color-primary: var(--primary);
64
+ --color-primary-foreground: var(--primary-foreground);
65
+ --color-secondary: var(--secondary);
66
+ --color-secondary-foreground: var(--secondary-foreground);
67
+ --color-muted: var(--muted);
68
+ --color-muted-foreground: var(--muted-foreground);
69
+ --color-accent: var(--accent);
70
+ --color-accent-foreground: var(--accent-foreground);
71
+ --color-destructive: var(--destructive);
72
+ --color-destructive-foreground: var(--destructive-foreground);
73
+ --color-border: var(--border);
74
+ --color-input: var(--input);
75
+ --color-ring: var(--ring);
76
+
77
+ --radius-sm: calc(var(--radius) * 0.6);
78
+ --radius-md: calc(var(--radius) * 0.8);
79
+ --radius-lg: var(--radius);
80
+ --radius-xl: calc(var(--radius) * 1.4);
81
+ --radius-2xl: calc(var(--radius) * 1.8);
82
+ }
83
+
34
84
  @layer dynostack-grid-defaults {
35
85
  :root {
36
86
  color-scheme: light;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dynostack/react-grid",
3
- "version": "0.2.0",
3
+ "version": "0.3.1",
4
4
  "description": "Enterprise-grade React DataGrid on TanStack + Radix + Tailwind, with operator-driven filters, inline editing, column pinning/resizing/reordering, CSV/Excel export, and full theme + i18n customization.",
5
5
  "license": "Apache-2.0",
6
6
  "author": "wanted-coder-vijay <drop.at.vijay@gmail.com>",
@@ -17,7 +17,7 @@
17
17
  },
18
18
  "type": "module",
19
19
  "sideEffects": [
20
- "**/*.css"
20
+ "**/*.css"
21
21
  ],
22
22
  "main": "./dist/index.cjs",
23
23
  "module": "./dist/index.js",