create-octane-xplat 0.9.0 → 0.10.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.
@@ -25,9 +25,13 @@ patchedDependencies:
25
25
  # ownership, read tracking, and local signal hooks; JSX prop lowering and __methodDep
26
26
  # already ship upstream. Routes uncaught universal event-handler errors to onUncaughtError
27
27
  # when configured. Pins instance signal/query declarations to their declaring owner so
28
- # child reads and event handlers share one request. Also allows async and generator
29
- # helpers that are not components in universal compiler modules, while preserving errors
30
- # when those functions are used as components (octanejs/octane#1469).
28
+ # child reads and event handlers share one request. Makes universal useImperativeHandle
29
+ # honor optional refs, ref replacement, nested ref arrays, and callback cleanup. Also
30
+ # allows async and generator helpers that are not components in universal compiler
31
+ # modules, while preserving errors when those functions are used as components
32
+ # (octanejs/octane#1469). Adds renderer-owned Children.toArray/map for transparent
33
+ # deferred JSX groups, plan ranges/slots and arrays, preserving keyed wrapper identity
34
+ # while leaving scoped owners intact.
31
35
  octane@0.6.3: node_modules/.pnpm-config/@octane-xplat/patches/patches/octane@0.6.3.patch
32
36
  # FlexboxLayout getChildMeasureSpec subtracts the child's own padding where AOSP subtracts
33
37
  # parent padding + child margins — a column-stretched row re-measurement clamps padded
@@ -65,12 +69,16 @@ patchedDependencies:
65
69
  # beside the universal one (hooks crash on boot, octane-xplat#3) — an onResolve plugin
66
70
  # redirects `octane` → `octane/universal/native`. tsconfig-paths and the generated
67
71
  # build-time checker moduleSuffixes also need the `.mobile` tier for iOS/Android/visionOS
68
- # so `.mobile` leaves resolve under mapped imports and `ns build`.
72
+ # so `.mobile` leaves resolve under mapped imports and `ns build`. Served `/node_modules/`
73
+ # tails now also scan pnpm's `.pnpm` store and `link:`/`file:`/`portal:` dep roots — a
74
+ # linked package's transitive deps (e.g. @iconify/utils under @octane-xplat/icons) resolve
75
+ # nowhere else and 404 the dev session.
69
76
  "@nativescript/vite@8.0.17": node_modules/.pnpm-config/@octane-xplat/patches/patches/@nativescript__vite@8.0.17.patch
70
77
  # Driver setProp skips `undefined` writes — NativeScript native setters coerce it (e.g.
71
78
  # editable → ios.userInteractionEnabled = NO), leaving dead UI that still has its JS
72
- # listeners. Advertises the implemented visibility capability so committed suspense bodies
73
- # can be retained while pending.
79
+ # listeners. Aligns intrinsic ref types with Octane callback cleanup and nested arrays
80
+ # with optional entries. Advertises the implemented visibility capability so committed
81
+ # suspense bodies can be retained while pending.
74
82
  "@nativescript-community/octane@0.2.4": node_modules/.pnpm-config/@octane-xplat/patches/patches/@nativescript-community__octane@0.2.4.patch
75
83
  # octaneServerStrategy's SCRIPT_FILE_RE only covers [jt]sx? — .tsrx edits never emit the
76
84
  # deferred ns:hmr-delta broadcast, so component HMR silently never reaches the device.
@@ -94,5 +102,11 @@ patchedDependencies:
94
102
  # unreachable. Adds a module-local process declaration for typecheck and merges the
95
103
  # Context.ts definitions into Context.tsrx.
96
104
  "@octanejs/tiptap@0.0.51": node_modules/.pnpm-config/@octane-xplat/patches/patches/@octanejs__tiptap@0.0.51.patch
105
+ # @lexical/link declares a /\p{L}\p{N}/u URL matcher as a regex literal at module scope;
106
+ # NativeScript's embedded V8 builds without ICU, so the literal throws SyntaxError at
107
+ # parse time and poisons the whole bundle (any bundled app importing @lexical/link dies on
108
+ # boot). Same fix as linkifyjs: try/catch new RegExp with an ASCII-range fallback — the
109
+ # matcher only feeds autolink, which native doesn't use.
110
+ "@lexical/link@0.51.0": node_modules/.pnpm-config/@octane-xplat/patches/patches/@lexical__link@0.51.0.patch
97
111
  configDependencies:
98
- "@octane-xplat/patches": 0.9.0
112
+ "@octane-xplat/patches": 0.10.0
@@ -1,5 +1,5 @@
1
1
  import { useState } from 'octane';
2
- import { View, Row, Text, Pressable, ScrollView, useColorScheme } from '@octane-xplat/ui';
2
+ import { View, HStack, Text, Pressable, ScrollableArea, useColorScheme } from '@octane-xplat/ui';
3
3
  import { storage } from '@octane-xplat/platform';
4
4
 
5
5
  const FEATURES = [
@@ -27,15 +27,15 @@ export function App() @{
27
27
  <Text className="title">octane-xplat</Text>
28
28
  <Text className="muted">one codebase — web · iOS · android</Text>
29
29
 
30
- <Row className="counter">
30
+ <HStack className="counter">
31
31
  <Pressable className="btn" onPress={() => setCount(count - 1)}><Text>−</Text></Pressable>
32
32
  <Text className="count">{count}</Text>
33
33
  <Pressable className="btn" onPress={() => setCount(count + 1)}><Text>+</Text></Pressable>
34
- </Row>
34
+ </HStack>
35
35
 
36
- <ScrollView>
36
+ <ScrollableArea>
37
37
  {FEATURES.map((f) => <Text className="chip">{f}</Text>)}
38
- </ScrollView>
38
+ </ScrollableArea>
39
39
 
40
40
  <Pressable className="link" onPress={() => {
41
41
  const next = !dark;
@@ -1,7 +1,21 @@
1
- /* App chrome — everything here is inside the web∩native CSS grammar
2
- * (see docs/css-support-matrix.md in the framework repo). Design tokens
3
- * (--color-*) come from @octane-xplat/ui/theme/tokens.css; .dark re-themes
4
- * the same vars — no JS color values anywhere. */
1
+ /* This starter leaves the optional UI chrome stylesheet out. Define this
2
+ * app's palette here; the required tokens.css supplies layout structure. */
3
+
4
+ :root,
5
+ .ns-root {
6
+ --color-primary: #171717;
7
+ --color-onprimary: #fafafa;
8
+ --color-surface: #ffffff;
9
+ --color-text: #0a0a0a;
10
+ }
11
+
12
+ .dark,
13
+ .ns-dark {
14
+ --color-primary: #ededed;
15
+ --color-onprimary: #171717;
16
+ --color-surface: #0a0a0a;
17
+ --color-text: #ededed;
18
+ }
5
19
 
6
20
  body {
7
21
  margin: 0;
@@ -9,10 +23,12 @@ body {
9
23
  background-color: var(--color-surface);
10
24
  }
11
25
 
12
- /* System-dark before JS mounts — no white flash. Same values tokens.css
13
- * sets under .dark; .app.light below is the manual override back. */
26
+ /* System-dark before JS mounts — no white flash. .app.light below is the
27
+ * manual override back. */
14
28
  @media (prefers-color-scheme: dark) {
15
29
  :root {
30
+ --color-primary: #ededed;
31
+ --color-onprimary: #171717;
16
32
  --color-surface: #0f172a;
17
33
  --color-text: #f8fafc;
18
34
  }
@@ -23,6 +39,8 @@ body {
23
39
 
24
40
  /* Manual light override when the system is dark (JS adds .light). */
25
41
  .app.light {
42
+ --color-primary: #171717;
43
+ --color-onprimary: #fafafa;
26
44
  --color-surface: #ffffff;
27
45
  --color-text: #111827;
28
46
  }
@@ -3,6 +3,7 @@ import { xplatNative } from '@octane-xplat/cli/vite'
3
3
 
4
4
  // The shared preset owns the renderer rules, octane→universal/native alias,
5
5
  // suffix extension chain, deps-bundle plugin exclusions, the HMR watchdog,
6
- // and the px→dip CSS rewrite. App-specific additions go through the second
7
- // argument's `extra` (or mergeConfig).
6
+ // the px→dip CSS rewrite, and fs.allow widening for link:/file: dep roots.
7
+ // App-specific additions go through the second argument's `extra` (or
8
+ // mergeConfig).
8
9
  export default defineConfig(({ mode }) => xplatNative(mode))