@kbach/react-native 1.0.0 → 1.1.1-beta.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/AGENTS.md CHANGED
@@ -124,6 +124,15 @@ engines does the work, chosen automatically:
124
124
  Resolution is memoized per `(classString, pressed, colorScheme, width,
125
125
  theme)`.
126
126
 
127
+ **Variant groups (1.1.1-beta.0):** `className="flex active:(bg-blue-6 opacity-50)"`
128
+ resolves as `active:bg-blue-6 active:opacity-50`, with no build step: every
129
+ engine expands groups before resolving (Rust's `groups.rs` on Android and Expo
130
+ Web; `src/jsEngine/groups.ts` on Expo Go / iOS, a port held to the same cases
131
+ as the Rust one by `groups.test.ts`, which reads
132
+ `core-engine/tests/variant-groups.json`; `jsEngine/parity.test.ts` compares the
133
+ two engines on grouped strings, light and dark, pressed or not). Root
134
+ AGENTS.md §8.2 has the syntax.
135
+
127
136
  ## 4. Modifiers on native
128
137
 
129
138
  Native has no selector/cascade engine. Two groups:
package/README.md CHANGED
@@ -161,6 +161,14 @@ import { Button, H1, Paragraph } from '@kbach/react-native';
161
161
  <Button className="px-4 py-2 rounded bg-blue-6" onPress={...}>Save</Button>
162
162
  ```
163
163
 
164
+ ## Variant groups
165
+
166
+ Write a variant once for several classes:
167
+ `className="flex active:(bg-blue-6 opacity-50)"` is
168
+ `active:bg-blue-6 active:opacity-50`. Groups nest (`dark:(p-4 active:p-2)`)
169
+ and need no setup: every engine expands them before resolving. This is Kbach's
170
+ own syntax, not Tailwind CSS's.
171
+
164
172
  ## What differs on native
165
173
 
166
174
  React Native has no CSS cascade, so a fixed subset of modifiers is
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  resolveClassName
3
- } from "./chunk-MUPEQJRT.mjs";
3
+ } from "./chunk-R7E5D3D6.mjs";
4
4
 
5
5
  // src/jsxRuntimeCoreWeb.ts
6
6
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  getTheme
3
- } from "./chunk-MUPEQJRT.mjs";
3
+ } from "./chunk-R7E5D3D6.mjs";
4
4
 
5
5
  // src/darkModeStore.ts
6
6
  import { Appearance } from "react-native";