@vsreact/core 0.0.16 → 0.0.18

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 CHANGED
@@ -30,6 +30,15 @@ wheel / double-click-reset, automation-safe begin/set/end gestures.
30
30
 
31
31
  ## Install
32
32
 
33
+ Starting fresh? The scaffolder gives you a complete plugin project —
34
+ CMake, C++, and a React UI — in one command:
35
+
36
+ ```sh
37
+ bun create vsreact my-plugin # or: npm create vsreact@latest my-plugin
38
+ ```
39
+
40
+ Adding to an existing plugin:
41
+
33
42
  ```sh
34
43
  bun add @vsreact/core # or npm / yarn / pnpm
35
44
  ```
package/dist/index.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  import "./runtime";
2
2
  import "./bridge";
3
3
  /** The SDK version — stamp it on support dumps and analytics. */
4
- export declare const VERSION = "0.0.16";
4
+ export declare const VERSION = "0.0.18";
5
5
  export { View, Text, Image, TextInput, NativeView } from "./primitives";
6
6
  export type { CommonProps, TextProps, ImageProps, TextInputProps, NativeViewProps, } from "./primitives";
7
7
  export { render, unmount } from "./render";
package/dist/index.js CHANGED
@@ -3,7 +3,7 @@
3
3
  import "./runtime";
4
4
  import "./bridge";
5
5
  /** The SDK version — stamp it on support dumps and analytics. */
6
- export const VERSION = "0.0.16";
6
+ export const VERSION = "0.0.18";
7
7
  export { View, Text, Image, TextInput, NativeView } from "./primitives";
8
8
  export { render, unmount } from "./render";
9
9
  export { native } from "./native";
package/dist/tw.js CHANGED
@@ -240,6 +240,15 @@ function resolveClass(cls) {
240
240
  const n = Number(rest);
241
241
  return Number.isFinite(n) ? { lineHeight: n * 4 } : undefined;
242
242
  }
243
+ case "tracking": {
244
+ // Named scale lives in staticClasses; arbitrary is px: tracking-[3].
245
+ if (rest.startsWith("[")) {
246
+ const spacing = parseLength(rest);
247
+ if (typeof spacing === "number")
248
+ return { letterSpacing: negate(spacing) };
249
+ }
250
+ return undefined;
251
+ }
243
252
  case "flex": {
244
253
  const n = Number(rest);
245
254
  return Number.isFinite(n) ? { flex: n } : undefined;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vsreact/core",
3
- "version": "0.0.16",
3
+ "version": "0.0.18",
4
4
  "description": "Write React. Ship native VST. A React renderer for JUCE audio plugins — QuickJS + Yoga + juce::Graphics, no webview.",
5
5
  "keywords": [
6
6
  "react",
package/src/index.ts CHANGED
@@ -4,7 +4,7 @@ import "./runtime";
4
4
  import "./bridge";
5
5
 
6
6
  /** The SDK version — stamp it on support dumps and analytics. */
7
- export const VERSION = "0.0.16";
7
+ export const VERSION = "0.0.18";
8
8
 
9
9
  export { View, Text, Image, TextInput, NativeView } from "./primitives";
10
10
  export type {
package/src/tw.test.ts CHANGED
@@ -155,3 +155,15 @@ describe("negative spacing", () => {
155
155
  expect(tw("-left-1/2").style).toEqual({ left: "-50%" });
156
156
  });
157
157
  });
158
+
159
+ describe("arbitrary letter spacing", () => {
160
+ test("tracking-[n] is px", () => {
161
+ expect(tw("tracking-[3]").style).toEqual({ letterSpacing: 3 });
162
+ expect(tw("tracking-[1.5]").style).toEqual({ letterSpacing: 1.5 });
163
+ expect(tw("-tracking-[2]").style).toEqual({ letterSpacing: -2 });
164
+ });
165
+
166
+ test("named scale still wins", () => {
167
+ expect(tw("tracking-widest").style).toEqual({ letterSpacing: 1.6 });
168
+ });
169
+ });
package/src/tw.ts CHANGED
@@ -246,6 +246,14 @@ function resolveClass(cls: string): Style | undefined {
246
246
  const n = Number(rest);
247
247
  return Number.isFinite(n) ? { lineHeight: n * 4 } : undefined;
248
248
  }
249
+ case "tracking": {
250
+ // Named scale lives in staticClasses; arbitrary is px: tracking-[3].
251
+ if (rest.startsWith("[")) {
252
+ const spacing = parseLength(rest);
253
+ if (typeof spacing === "number") return { letterSpacing: negate(spacing) };
254
+ }
255
+ return undefined;
256
+ }
249
257
  case "flex": {
250
258
  const n = Number(rest);
251
259
  return Number.isFinite(n) ? { flex: n } : undefined;