@legendapp/spark 0.0.1 → 0.0.3

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 (141) hide show
  1. package/native.d.cts +6 -3
  2. package/package.json +36 -28
  3. package/patches/dependencies.json +252 -0
  4. package/patches/expo-application@55.0.19.patch +54 -0
  5. package/patches/expo-blur@55.0.18.patch +130 -0
  6. package/patches/expo-device@55.0.21.patch +149 -0
  7. package/patches/expo-font@55.0.8.patch +55 -0
  8. package/patches/expo-glass-effect@55.0.11.patch +304 -0
  9. package/patches/expo-haptics@55.0.18.patch +54 -0
  10. package/patches/expo-image-manipulator@55.0.21.patch +312 -0
  11. package/patches/expo-image-picker@55.0.24.patch +327 -0
  12. package/patches/expo-image@55.0.11.patch +158 -0
  13. package/patches/expo-keep-awake@55.0.8.patch +41 -0
  14. package/patches/expo-localization@55.0.19.patch +32 -0
  15. package/patches/expo-location@55.1.15.patch +190 -0
  16. package/patches/expo-symbols@55.0.9.patch +286 -0
  17. package/patches/expo-system-ui@55.0.22.patch +61 -0
  18. package/patches/expo-web-browser@55.0.20.patch +13 -0
  19. package/patches/react-native-app-logs@0.3.1.patch +20 -0
  20. package/patches/react-native-blurhash@2.1.3.patch +318 -0
  21. package/patches/react-native-community-blur@4.4.1.patch +415 -0
  22. package/patches/react-native-community-datetimepicker@9.2.2.patch +320 -0
  23. package/patches/react-native-enriched-markdown@1.1.1.patch +141 -10
  24. package/patches/react-native-fast-image@10.9.9.patch +131 -0
  25. package/patches/react-native-graph@1.4.0.patch +157 -0
  26. package/patches/react-native-keyboard-controller@1.22.9.patch +16 -0
  27. package/patches/react-native-masked-view-masked-view@0.3.2.patch +140 -0
  28. package/patches/react-native-mmkv@4.3.2.patch +40 -0
  29. package/patches/react-native-nitro-fetch@1.9.0.patch +130 -0
  30. package/patches/react-native-nitro-zxing@0.3.0.patch +13 -0
  31. package/patches/react-native-quick-base64@3.0.1.patch +13 -0
  32. package/patches/react-native-quick-crypto@1.1.9.patch +31 -0
  33. package/patches/react-native-release-profiler@0.4.5.patch +37 -0
  34. package/patches/react-native-screen-corner-radius@0.2.3.patch +13 -0
  35. package/patches/react-native-screens@4.23.0.patch +160 -0
  36. package/patches/react-native-svg@15.15.3.patch +31 -0
  37. package/patches/react-native-unistyles@3.6.0.patch +203 -0
  38. package/patches/react-native-worklets-core@1.6.3.patch +13 -0
  39. package/patches/react-navigation-native-stack@7.21.0.patch +16 -0
  40. package/patches/sentry-react-native@8.32.0.patch +76 -0
  41. package/skills/spark/UPGRADING.md +122 -3
  42. package/vendor/node_modules/@legendapp/spark-ai/package.json +5 -5
  43. package/vendor/node_modules/@legendapp/spark-audio/package.json +5 -5
  44. package/vendor/node_modules/@legendapp/spark-audio/src/index.macos.ts +1 -0
  45. package/vendor/node_modules/@legendapp/spark-auth-session/package.json +6 -6
  46. package/vendor/node_modules/@legendapp/spark-auth-session/src/index.macos.ts +1 -0
  47. package/vendor/node_modules/@legendapp/spark-cli/dist/add-desktop.js +2 -2
  48. package/vendor/node_modules/@legendapp/spark-cli/dist/build.js +17 -5
  49. package/vendor/node_modules/@legendapp/spark-cli/dist/cli-arguments.js +4 -2
  50. package/vendor/node_modules/@legendapp/spark-cli/dist/create.js +8 -4
  51. package/vendor/node_modules/@legendapp/spark-cli/dist/dependency-pins.js +45 -1
  52. package/vendor/node_modules/@legendapp/spark-cli/dist/dev.js +15 -3
  53. package/vendor/node_modules/@legendapp/spark-cli/dist/examples.js +2 -2
  54. package/vendor/node_modules/@legendapp/spark-cli/dist/expo-dev-patch.cjs +3 -3
  55. package/vendor/node_modules/@legendapp/spark-cli/dist/expo-dev-preload.cjs +3 -0
  56. package/vendor/node_modules/@legendapp/spark-cli/dist/index.js +26 -7
  57. package/vendor/node_modules/@legendapp/spark-cli/dist/metro.cjs +3 -1
  58. package/vendor/node_modules/@legendapp/spark-cli/dist/migration-helpers.cjs +20 -5
  59. package/vendor/node_modules/@legendapp/spark-cli/dist/migration-helpers.d.cts +1 -0
  60. package/vendor/node_modules/@legendapp/spark-cli/dist/migrations.cjs +10 -2
  61. package/vendor/node_modules/@legendapp/spark-cli/dist/native-patch-preflight.js +3 -3
  62. package/vendor/node_modules/@legendapp/spark-cli/dist/project.js +28 -10
  63. package/vendor/node_modules/@legendapp/spark-cli/dist/release-runner-root.js +108 -0
  64. package/vendor/node_modules/@legendapp/spark-cli/dist/release.json +13 -13
  65. package/vendor/node_modules/@legendapp/spark-cli/dist/runtime-input-cache.js +140 -0
  66. package/vendor/node_modules/@legendapp/spark-cli/dist/watchman.js +12 -0
  67. package/vendor/node_modules/@legendapp/spark-cli/dist/windows-geometry.js +2 -2
  68. package/vendor/node_modules/@legendapp/spark-cli/dist/windows.js +1 -1
  69. package/vendor/node_modules/@legendapp/spark-cli/package.json +3 -3
  70. package/vendor/node_modules/@legendapp/spark-cli/templates/blank-typescript/desktop.config.json +1 -1
  71. package/vendor/node_modules/@legendapp/spark-cli/templates/blank-typescript/package.json +27 -25
  72. package/vendor/node_modules/@legendapp/spark-cli/templates/universal/desktop.config.json +1 -1
  73. package/vendor/node_modules/@legendapp/spark-cli/templates/universal/package.json +35 -33
  74. package/vendor/node_modules/@legendapp/spark-cli/templates/windows/package.json +29 -27
  75. package/vendor/node_modules/@legendapp/spark-clipboard/package.json +5 -5
  76. package/vendor/node_modules/@legendapp/spark-clipboard/src/index.macos.ts +1 -0
  77. package/vendor/node_modules/@legendapp/spark-codex/package.json +4 -4
  78. package/vendor/node_modules/@legendapp/spark-commands/package.json +7 -7
  79. package/vendor/node_modules/@legendapp/spark-context-menu/package.json +4 -4
  80. package/vendor/node_modules/@legendapp/spark-desktop-app/macos/SparkDesktop.mm +7 -2
  81. package/vendor/node_modules/@legendapp/spark-desktop-app/macos/SparkTestDriver.mm +64 -2
  82. package/vendor/node_modules/@legendapp/spark-desktop-app/package.json +3 -3
  83. package/vendor/node_modules/@legendapp/spark-desktop-config/accessibility-state.cjs +2 -2
  84. package/vendor/node_modules/@legendapp/spark-desktop-config/app.plugin.cjs +12 -0
  85. package/vendor/node_modules/@legendapp/spark-desktop-config/autolinking.cjs +7 -6
  86. package/vendor/node_modules/@legendapp/spark-desktop-config/config.d.cts +1 -1
  87. package/vendor/node_modules/@legendapp/spark-desktop-config/fabric-lifecycle.cjs +1 -1
  88. package/vendor/node_modules/@legendapp/spark-desktop-config/keyboard-events.cjs +2 -2
  89. package/vendor/node_modules/@legendapp/spark-desktop-config/macos-host.cjs +39 -0
  90. package/vendor/node_modules/@legendapp/spark-desktop-config/native-patches.cjs +73 -20
  91. package/vendor/node_modules/@legendapp/spark-desktop-config/native-patches.d.cts +2 -1
  92. package/vendor/node_modules/@legendapp/spark-desktop-config/package.json +8 -6
  93. package/vendor/node_modules/@legendapp/spark-desktop-config/rtl-scroll-view.cjs +2 -2
  94. package/vendor/node_modules/@legendapp/spark-desktop-config/rtl-text-alignment.cjs +2 -2
  95. package/vendor/node_modules/@legendapp/spark-desktop-config/rtl-text-input-alignment.cjs +2 -2
  96. package/vendor/node_modules/@legendapp/spark-desktop-config/text-input-accessibility.cjs +2 -2
  97. package/vendor/node_modules/@legendapp/spark-desktop-host/macos/AppDelegate.h +6 -0
  98. package/vendor/node_modules/@legendapp/spark-desktop-host/macos/Main.storyboard +684 -0
  99. package/vendor/node_modules/@legendapp/spark-desktop-host/macos/main.m +5 -0
  100. package/vendor/node_modules/@legendapp/spark-desktop-host/package.json +3 -2
  101. package/vendor/node_modules/@legendapp/spark-desktop-links/package.json +5 -5
  102. package/vendor/node_modules/@legendapp/spark-desktop-links/src/index.macos.ts +1 -0
  103. package/vendor/node_modules/@legendapp/spark-desktop-shortcuts/package.json +4 -4
  104. package/vendor/node_modules/@legendapp/spark-desktop-windows/macos/window-manager/RNWindowManager.mm +68 -17
  105. package/vendor/node_modules/@legendapp/spark-desktop-windows/package.json +5 -5
  106. package/vendor/node_modules/@legendapp/spark-desktop-windows/src/macos-adapter.ts +2 -1
  107. package/vendor/node_modules/@legendapp/spark-documents/package.json +9 -9
  108. package/vendor/node_modules/@legendapp/spark-drag-drop/package.json +4 -4
  109. package/vendor/node_modules/@legendapp/spark-file-dialog/package.json +4 -4
  110. package/vendor/node_modules/@legendapp/spark-file-system/macos/RNDesktopFileSystem.mm +14 -5
  111. package/vendor/node_modules/@legendapp/spark-file-system/package.json +4 -4
  112. package/vendor/node_modules/@legendapp/spark-file-system/src/index.ts +1 -1
  113. package/vendor/node_modules/@legendapp/spark-global-shortcuts/package.json +4 -4
  114. package/vendor/node_modules/@legendapp/spark-html/package.json +4 -4
  115. package/vendor/node_modules/@legendapp/spark-markdown/package.json +4 -4
  116. package/vendor/node_modules/@legendapp/spark-message-dialog/package.json +4 -4
  117. package/vendor/node_modules/@legendapp/spark-native-menu/package.json +4 -4
  118. package/vendor/node_modules/@legendapp/spark-notifications/package.json +4 -4
  119. package/vendor/node_modules/@legendapp/spark-processes/macos/RNDesktopProcesses.mm +110 -19
  120. package/vendor/node_modules/@legendapp/spark-processes/package.json +4 -4
  121. package/vendor/node_modules/@legendapp/spark-processes/src/index.ts +17 -3
  122. package/vendor/node_modules/@legendapp/spark-processes/src/types.ts +6 -0
  123. package/vendor/node_modules/@legendapp/spark-rich-text/package.json +4 -4
  124. package/vendor/node_modules/@legendapp/spark-secure-storage/package.json +5 -5
  125. package/vendor/node_modules/@legendapp/spark-secure-storage/src/index.macos.ts +1 -0
  126. package/vendor/node_modules/@legendapp/spark-settings/package.json +3 -3
  127. package/vendor/node_modules/@legendapp/spark-settings-ui/package.json +6 -6
  128. package/vendor/node_modules/@legendapp/spark-sqlite/package.json +12 -5
  129. package/vendor/node_modules/@legendapp/spark-system/package.json +4 -4
  130. package/vendor/node_modules/@legendapp/spark-tray/package.json +4 -4
  131. package/vendor/node_modules/@legendapp/spark-ui/macos/appkit-split-view/RNSidebarSplitViewComponent.mm +82 -18
  132. package/vendor/node_modules/@legendapp/spark-ui/package.json +6 -6
  133. package/vendor/node_modules/@legendapp/spark-ui/src/appkit-split-view/SidebarSplitViewNativeComponent.ts +4 -0
  134. package/vendor/node_modules/@legendapp/spark-ui/src/appkit-split-view/index.tsx +11 -9
  135. package/vendor/node_modules/@legendapp/spark-ui/src/index.android.tsx +20 -10
  136. package/vendor/node_modules/@legendapp/spark-ui/src/index.ios.tsx +15 -10
  137. package/vendor/node_modules/@legendapp/spark-ui/src/index.macos.tsx +1 -0
  138. package/vendor/node_modules/@legendapp/spark-updates/package.json +4 -4
  139. package/vendor/node_modules/@legendapp/spark-webview/package.json +11 -4
  140. package/vendor/node_modules/@legendapp/spark-window-options/package.json +1 -1
  141. package/camera.ts +0 -13
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "spark-template-universal",
3
- "version": "0.0.1",
3
+ "version": "0.0.3",
4
4
  "private": true,
5
5
  "main": "index.ts",
6
6
  "scripts": {
@@ -17,50 +17,50 @@
17
17
  "postinstall": "node node_modules/@legendapp/spark/init-template.cjs"
18
18
  },
19
19
  "dependencies": {
20
- "expo": "54.0.37",
20
+ "expo": "55.0.32",
21
21
  "expo-desktop": "1.0.6",
22
22
  "expo-desktop-prebuild-config": "1.1.3",
23
23
  "expo-desktop-config-plugins": "1.3.2",
24
- "expo-desktop-metro-config": "54.81.3",
25
- "expo-desktop-template-bare-minimum": "54.81.6",
26
- "react": "19.1.4",
27
- "react-native": "0.81.6",
28
- "react-native-macos": "0.81.7",
24
+ "expo-desktop-metro-config": "55.83.3",
25
+ "expo-desktop-template-bare-minimum": "55.83.10",
26
+ "react": "19.2.0",
27
+ "react-native": "0.83.10",
28
+ "react-native-macos": "0.83.0",
29
29
  "@react-native-community/cli": "20.1.3",
30
30
  "typescript": "5.9.3",
31
- "@types/react": "19.1.10",
32
- "react-native-windows": "0.81.35",
33
- "expo-desktop-modules-core": "54.0.14",
34
- "expo-desktop-stubs": "54.0.15",
35
- "@expo/ui": "0.2.0-beta.9",
36
- "expo-dev-client": "6.0.21",
37
- "expo-clipboard": "8.0.8",
38
- "expo-secure-store": "15.0.8",
39
- "expo-linking": "8.0.12",
40
- "react-dom": "19.1.4",
31
+ "@types/react": "19.2.18",
32
+ "react-native-windows": "0.83.2",
33
+ "expo-desktop-modules-core": "55.0.2",
34
+ "expo-desktop-stubs": "55.0.2",
35
+ "@expo/ui": "55.0.17",
36
+ "expo-dev-client": "55.0.41",
37
+ "expo-clipboard": "55.0.17",
38
+ "expo-secure-store": "55.0.18",
39
+ "expo-linking": "55.0.17",
40
+ "react-dom": "19.2.0",
41
41
  "react-native-web": "0.21.0",
42
42
  "uniwind": "1.6.3",
43
43
  "tailwindcss": "4.2.4",
44
- "@legendapp/spark": "0.0.1"
44
+ "@legendapp/spark": "0.0.3"
45
45
  },
46
46
  "overrides": {
47
- "expo": "54.0.37",
48
- "@expo/cli": "54.0.27",
47
+ "expo": "55.0.32",
48
+ "@expo/cli": "55.0.37",
49
49
  "react-native-nitro-modules": "0.37.0",
50
50
  "react-native-webview": "16.0.0",
51
51
  "@op-engineering/op-sqlite": "18.2.1",
52
- "expo-asset": "12.0.13",
53
- "expo-constants": "18.0.14",
54
- "expo-file-system": "19.0.24",
55
- "expo-font": "14.0.12",
56
- "expo-keep-awake": "15.0.8",
57
- "expo-modules-core": "3.0.30",
58
- "expo-desktop-modules-core": "54.0.14",
59
- "expo-desktop-stubs": "54.0.15",
60
- "react": "19.1.4",
61
- "react-native": "0.81.6",
62
- "react-native-macos": "0.81.7",
63
- "react-native-windows": "0.81.35",
52
+ "expo-asset": "55.0.20",
53
+ "expo-constants": "55.0.17",
54
+ "expo-file-system": "55.0.26",
55
+ "expo-font": "55.0.8",
56
+ "expo-keep-awake": "55.0.8",
57
+ "expo-modules-core": "55.0.27",
58
+ "expo-desktop-modules-core": "55.0.2",
59
+ "expo-desktop-stubs": "55.0.2",
60
+ "react": "19.2.0",
61
+ "react-native": "0.83.10",
62
+ "react-native-macos": "0.83.0",
63
+ "react-native-windows": "0.83.2",
64
64
  "postcss": "8.5.31",
65
65
  "dompurify": "3.4.17",
66
66
  "@tiptap/core": "3.32.0",
@@ -85,7 +85,9 @@
85
85
  "@tiptap/extension-bubble-menu": "3.32.0",
86
86
  "@tiptap/extension-floating-menu": "3.32.0",
87
87
  "fast-xml-parser": "5.11.2",
88
- "react-dom": "19.1.4"
88
+ "react-dom": "19.2.0",
89
+ "react-native-enriched-markdown": "1.1.1",
90
+ "react-native-enriched-html": "1.1.1"
89
91
  },
90
92
  "expo": {
91
93
  "install": {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "spark-template-windows",
3
- "version": "0.0.1",
3
+ "version": "0.0.3",
4
4
  "private": true,
5
5
  "main": "index.ts",
6
6
  "scripts": {
@@ -13,41 +13,41 @@
13
13
  "postinstall": "node node_modules/@legendapp/spark/init-template.cjs"
14
14
  },
15
15
  "dependencies": {
16
- "expo": "54.0.37",
16
+ "expo": "55.0.32",
17
17
  "expo-desktop": "1.0.6",
18
18
  "expo-desktop-prebuild-config": "1.1.3",
19
19
  "expo-desktop-config-plugins": "1.3.2",
20
- "expo-desktop-metro-config": "54.81.3",
21
- "expo-desktop-template-bare-minimum": "54.81.6",
22
- "react": "19.1.4",
23
- "react-dom": "19.1.4",
24
- "react-native": "0.81.6",
20
+ "expo-desktop-metro-config": "55.83.3",
21
+ "expo-desktop-template-bare-minimum": "55.83.10",
22
+ "react": "19.2.0",
23
+ "react-dom": "19.2.0",
24
+ "react-native": "0.83.10",
25
25
  "@react-native-community/cli": "20.1.3",
26
26
  "typescript": "5.9.3",
27
- "@types/react": "19.1.10",
28
- "react-native-windows": "0.81.35",
29
- "expo-desktop-modules-core": "54.0.14",
30
- "expo-desktop-stubs": "54.0.15",
31
- "@legendapp/spark": "0.0.1"
27
+ "@types/react": "19.2.18",
28
+ "react-native-windows": "0.83.2",
29
+ "expo-desktop-modules-core": "55.0.2",
30
+ "expo-desktop-stubs": "55.0.2",
31
+ "@legendapp/spark": "0.0.3"
32
32
  },
33
33
  "overrides": {
34
- "expo": "54.0.37",
35
- "@expo/cli": "54.0.27",
34
+ "expo": "55.0.32",
35
+ "@expo/cli": "55.0.37",
36
36
  "react-native-nitro-modules": "0.37.0",
37
37
  "react-native-webview": "16.0.0",
38
38
  "@op-engineering/op-sqlite": "18.2.1",
39
- "expo-asset": "12.0.13",
40
- "expo-constants": "18.0.14",
41
- "expo-file-system": "19.0.24",
42
- "expo-font": "14.0.12",
43
- "expo-keep-awake": "15.0.8",
44
- "expo-modules-core": "3.0.30",
45
- "expo-desktop-modules-core": "54.0.14",
46
- "expo-desktop-stubs": "54.0.15",
47
- "react": "19.1.4",
48
- "react-native": "0.81.6",
49
- "react-native-macos": "0.81.7",
50
- "react-native-windows": "0.81.35",
39
+ "expo-asset": "55.0.20",
40
+ "expo-constants": "55.0.17",
41
+ "expo-file-system": "55.0.26",
42
+ "expo-font": "55.0.8",
43
+ "expo-keep-awake": "55.0.8",
44
+ "expo-modules-core": "55.0.27",
45
+ "expo-desktop-modules-core": "55.0.2",
46
+ "expo-desktop-stubs": "55.0.2",
47
+ "react": "19.2.0",
48
+ "react-native": "0.83.10",
49
+ "react-native-macos": "0.83.0",
50
+ "react-native-windows": "0.83.2",
51
51
  "postcss": "8.5.31",
52
52
  "dompurify": "3.4.17",
53
53
  "@tiptap/core": "3.32.0",
@@ -72,7 +72,9 @@
72
72
  "@tiptap/extension-bubble-menu": "3.32.0",
73
73
  "@tiptap/extension-floating-menu": "3.32.0",
74
74
  "fast-xml-parser": "5.11.2",
75
- "react-dom": "19.1.4"
75
+ "react-dom": "19.2.0",
76
+ "react-native-enriched-markdown": "1.1.1",
77
+ "react-native-enriched-html": "1.1.1"
76
78
  },
77
79
  "expo": {
78
80
  "install": {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@legendapp/spark-clipboard",
3
- "version": "0.0.1",
3
+ "version": "0.0.3",
4
4
  "license": "MIT",
5
5
  "main": "src/index",
6
6
  "react-native": "src/index",
@@ -12,9 +12,9 @@
12
12
  "windows"
13
13
  ],
14
14
  "peerDependencies": {
15
- "react": "^19.1.0",
16
- "react-native": "0.81.6",
17
- "expo-clipboard": "~8.0.8"
15
+ "react": "^19.2.0",
16
+ "react-native": "0.83.10",
17
+ "expo-clipboard": "~55.0.17"
18
18
  },
19
19
  "codegenConfig": {
20
20
  "name": "RNDesktopClipboardSpec",
@@ -41,7 +41,7 @@
41
41
  ]
42
42
  },
43
43
  "dependencies": {
44
- "@legendapp/spark-desktop-app": "0.0.1"
44
+ "@legendapp/spark-desktop-app": "0.0.3"
45
45
  },
46
46
  "peerDependenciesMeta": {
47
47
  "expo-clipboard": {
@@ -0,0 +1 @@
1
+ export * from "./desktop";
@@ -1,16 +1,16 @@
1
1
  {
2
2
  "name": "@legendapp/spark-codex",
3
- "version": "0.0.1",
3
+ "version": "0.0.3",
4
4
  "private": true,
5
5
  "main": "src/index.ts",
6
6
  "react-native": "src/index.ts",
7
7
  "peerDependencies": {
8
- "react": "^19.1.0",
9
- "react-native": "0.81.6"
8
+ "react": "^19.2.0",
9
+ "react-native": "0.83.10"
10
10
  },
11
11
  "license": "MIT",
12
12
  "dependencies": {
13
- "@legendapp/spark-desktop-app": "0.0.1",
13
+ "@legendapp/spark-desktop-app": "0.0.3",
14
14
  "react-native-nitro-modules": "0.37.0"
15
15
  },
16
16
  "files": [
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@legendapp/spark-commands",
3
- "version": "0.0.1",
3
+ "version": "0.0.3",
4
4
  "private": true,
5
5
  "license": "MIT",
6
6
  "main": "src/index.tsx",
@@ -8,14 +8,14 @@
8
8
  "src"
9
9
  ],
10
10
  "dependencies": {
11
- "@legendapp/spark-ui": "0.0.1",
12
- "@legendapp/spark-desktop-shortcuts": "0.0.1",
13
- "@legendapp/spark-settings": "0.0.1",
11
+ "@legendapp/spark-ui": "0.0.3",
12
+ "@legendapp/spark-desktop-shortcuts": "0.0.3",
13
+ "@legendapp/spark-settings": "0.0.3",
14
14
  "@legendapp/state": "^3.0.0-beta.42",
15
- "@legendapp/spark-desktop-app": "0.0.1"
15
+ "@legendapp/spark-desktop-app": "0.0.3"
16
16
  },
17
17
  "peerDependencies": {
18
- "react": "^19.1.0",
19
- "react-native": "0.81.6"
18
+ "react": "^19.2.0",
19
+ "react-native": "0.83.10"
20
20
  }
21
21
  }
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@legendapp/spark-context-menu",
3
- "version": "0.0.1",
3
+ "version": "0.0.3",
4
4
  "license": "MIT",
5
5
  "main": "src/index.ts",
6
6
  "react-native": "src/index.ts",
@@ -12,8 +12,8 @@
12
12
  "react-native.config.js"
13
13
  ],
14
14
  "peerDependencies": {
15
- "react": "^19.1.0",
16
- "react-native": "0.81.6"
15
+ "react": "^19.2.0",
16
+ "react-native": "0.83.10"
17
17
  },
18
18
  "codegenConfig": {
19
19
  "name": "RNContextMenuSpec",
@@ -41,7 +41,7 @@
41
41
  ]
42
42
  },
43
43
  "dependencies": {
44
- "@legendapp/spark-desktop-app": "0.0.1"
44
+ "@legendapp/spark-desktop-app": "0.0.3"
45
45
  },
46
46
  "private": true
47
47
  }
@@ -34,7 +34,12 @@ NSDictionary *SparkContext(void) {
34
34
  NSString *runtimePath = [bundle pathForResource:@"spark-runtime" ofType:@"json"];
35
35
  NSData *data = runtimePath ? [NSData dataWithContentsOfFile:runtimePath] : nil;
36
36
  id rawRuntime = data ? [NSJSONSerialization JSONObjectWithData:data options:0 error:nil] : nil;
37
- NSDictionary *runtime = [rawRuntime isKindOfClass:NSDictionary.class] ? rawRuntime : @{};
37
+ #if DEBUG
38
+ NSString *defaultMode = @"dev";
39
+ #else
40
+ NSString *defaultMode = @"release";
41
+ #endif
42
+ NSDictionary *runtime = [rawRuntime isKindOfClass:NSDictionary.class] ? rawRuntime : @{ @"mode": defaultMode, @"modules": @{} };
38
43
  NSString *project = [bundle objectForInfoDictionaryKey:@"SparkProjectIdentifier"] ?: bundle.bundleIdentifier;
39
44
  NSString *version = [bundle objectForInfoDictionaryKey:@"CFBundleShortVersionString"] ?: @"0.0.0";
40
45
  NSString *name = [bundle objectForInfoDictionaryKey:@"CFBundleDisplayName"] ?: [bundle objectForInfoDictionaryKey:@"CFBundleName"];
@@ -48,7 +53,7 @@ NSDictionary *SparkContext(void) {
48
53
  #endif
49
54
  context = @{ @"projectId": project ?: @"desktop.app", @"name": name ?: @"Desktop App",
50
55
  @"version": version,
51
- @"runtime": runtime ?: @{}, @"launchArguments": NSProcessInfo.processInfo.arguments };
56
+ @"runtime": runtime, @"launchArguments": NSProcessInfo.processInfo.arguments };
52
57
  });
53
58
  return context;
54
59
  }
@@ -1,4 +1,5 @@
1
1
  #import "SparkTestDriver.h"
2
+ #import <CoreGraphics/CoreGraphics.h>
2
3
  #import <QuartzCore/QuartzCore.h>
3
4
  #include <atomic>
4
5
  #include <fcntl.h>
@@ -17,6 +18,8 @@ static int directoryFD = -1, listenFD = -1;
17
18
  static NSString *socketPath;
18
19
  static NSData *token;
19
20
  static id activity;
21
+ static NSMutableArray<dispatch_block_t> *pointerRestores;
22
+ static NSInteger pointerEventNumber = 0;
20
23
  static std::atomic<bool> authenticated{false};
21
24
  static CFTimeInterval lastMount = 0;
22
25
  static const CFTimeInterval SparkSettleInterval = 0.1;
@@ -30,7 +33,7 @@ static void SparkDriverTerminate(void) { ending = YES; [NSApp terminate:nil]; }
30
33
  BOOL SparkTestDriverActive(void) { return active; }
31
34
  BOOL SparkTestDriverEnding(void) { return ending; }
32
35
  void SparkTestDriverDidMount(void) { lastMount = CACurrentMediaTime(); }
33
- static NSArray<NSString *> *const SparkBuiltInCommands = @[@"ping", @"navigate", @"openFile", @"waitFor", @"setAppAppearance", @"capture", @"quit"];
36
+ static NSArray<NSString *> *const SparkBuiltInCommands = @[@"ping", @"navigate", @"openFile", @"waitFor", @"setAppAppearance", @"capture", @"pointerEvents", @"restorePointer", @"quit"];
34
37
  static NSMutableDictionary<NSString *, SparkTestDriverHandler> *SparkModuleCommands(void) {
35
38
  static NSMutableDictionary *commands;
36
39
  static dispatch_once_t once;
@@ -228,6 +231,63 @@ static void SparkOpenURL(NSURL *url, NSDictionary *request, SparkDriverReply rep
228
231
  reply(@{ @"ok": @YES });
229
232
  });
230
233
  }
234
+ static void SparkRestorePointer(void) {
235
+ for (dispatch_block_t restore in pointerRestores.reverseObjectEnumerator) restore();
236
+ pointerRestores = nil;
237
+ }
238
+ static void SparkPreparePointer(NSWindow *window, NSNumber *x, NSNumber *y, SparkDriverReply reply) {
239
+ if (!pointerRestores) {
240
+ pointerRestores = [NSMutableArray new];
241
+ NSApplicationActivationPolicy policy = NSApp.activationPolicy;
242
+ NSRunningApplication *previous = NSWorkspace.sharedWorkspace.frontmostApplication;
243
+ [pointerRestores addObject:[^{
244
+ [NSApp setActivationPolicy:policy];
245
+ if (previous.processIdentifier != getpid()) [previous activateWithOptions:0];
246
+ } copy]];
247
+ if (policy == NSApplicationActivationPolicyProhibited) [NSApp setActivationPolicy:NSApplicationActivationPolicyRegular];
248
+ }
249
+ // Pointer input opts into foreground clicks; ordinary driver windows stay hidden.
250
+ if (!window.isVisible) {
251
+ NSWindowAnimationBehavior animation = window.animationBehavior;
252
+ [pointerRestores addObject:[^{ [window orderOut:nil]; window.animationBehavior = animation; } copy]];
253
+ window.animationBehavior = NSWindowAnimationBehaviorNone;
254
+ }
255
+ [window makeKeyAndOrderFront:nil];
256
+ if (!NSApp.isActive) [NSApp activateIgnoringOtherApps:YES];
257
+ [window layoutIfNeeded];
258
+ NSView *root = SparkFrameView(window);
259
+ if ([x doubleValue] < 0 || [y doubleValue] < 0 || [x doubleValue] >= NSWidth(root.bounds) || [y doubleValue] >= NSHeight(root.bounds)) {
260
+ reply(SparkFailure(@"E_INVALID_ARGUMENT", @"pointerEvents expects x,y inside the captured window frame (top-left points)")); return;
261
+ }
262
+ NSPoint local = NSMakePoint(NSMinX(root.bounds) + [x doubleValue], root.isFlipped ? NSMinY(root.bounds) + [y doubleValue] : NSMaxY(root.bounds) - [y doubleValue]);
263
+ NSPoint windowPoint = [root convertPoint:local toView:nil];
264
+ NSMutableArray<NSString *> *events = [NSMutableArray new];
265
+ NSTimeInterval now = NSProcessInfo.processInfo.systemUptime;
266
+ NSInteger eventNumber = ++pointerEventNumber;
267
+ for (NSUInteger i = 0; i < 2; i++) {
268
+ NSEvent *event = [NSEvent mouseEventWithType:i == 0 ? NSEventTypeLeftMouseDown : NSEventTypeLeftMouseUp location:windowPoint modifierFlags:0 timestamp:now + i * 0.05 windowNumber:window.windowNumber context:nil eventNumber:eventNumber clickCount:1 pressure:i == 0 ? 1 : 0];
269
+ NSData *data = event.CGEvent ? CFBridgingRelease(CGEventCreateData(NULL, event.CGEvent)) : nil;
270
+ if (!data) { reply(SparkFailure(@"E_EVENT", @"Could not encode mouse events for the target window")); return; }
271
+ [events addObject:[data base64EncodedStringWithOptions:0]];
272
+ }
273
+ reply(@{ @"ok": @YES, @"pid": @(getpid()), @"down": events[0], @"up": events[1] });
274
+ }
275
+ static void SparkPointerEvents(NSDictionary *request, SparkDriverReply reply) {
276
+ NSString *failure = nil;
277
+ NSWindow *window = SparkResolveWindow(request[@"window"], &failure);
278
+ if (!window) { reply(SparkFailure(@"E_NO_WINDOW", failure)); return; }
279
+ id x = request[@"x"], y = request[@"y"];
280
+ if (![x isKindOfClass:NSNumber.class] || ![y isKindOfClass:NSNumber.class] ||
281
+ !isfinite([x doubleValue]) || !isfinite([y doubleValue])) {
282
+ reply(SparkFailure(@"E_INVALID_ARGUMENT", @"pointerEvents expects finite x,y")); return;
283
+ }
284
+ // Gesture recognizers attach after their views mount; do not click mid-mount. A zero timeout skips the wait.
285
+ NSTimeInterval timeout = SparkTimeout(request[@"timeoutMs"], 5);
286
+ SparkWaitUntil(timeout, ^{ return (BOOL)(timeout == 0 || SparkSettled()); }, ^(BOOL settled) {
287
+ if (!settled) { reply(SparkFailure(@"E_NOT_SETTLED", @"The UI kept mounting changes until the timeout")); return; }
288
+ SparkPreparePointer(window, x, y, reply);
289
+ });
290
+ }
231
291
  static void SparkExecute(NSDictionary *request, SparkDriverReply reply) {
232
292
  NSString *command = request[@"command"];
233
293
  if ([command isEqual:@"ping"]) reply(@{ @"ok": @YES });
@@ -261,6 +321,8 @@ static void SparkExecute(NSDictionary *request, SparkDriverReply reply) {
261
321
  }
262
322
  else if ([command isEqual:@"setAppAppearance"]) SparkSetAppearance(request, reply);
263
323
  else if ([command isEqual:@"capture"]) SparkCapture(request, reply);
324
+ else if ([command isEqual:@"pointerEvents"]) SparkPointerEvents(request, reply);
325
+ else if ([command isEqual:@"restorePointer"]) { SparkRestorePointer(); reply(@{ @"ok": @YES }); }
264
326
  else if ([command isKindOfClass:NSString.class] && SparkModuleCommands()[command]) SparkModuleCommands()[command](request, reply);
265
327
  else reply(SparkFailure(@"E_UNKNOWN_COMMAND", [NSString stringWithFormat:@"Unknown command %@", command]));
266
328
  }
@@ -318,7 +380,7 @@ static void SparkServe(void) {
318
380
  }
319
381
  close(listenFD);
320
382
  unlink(socketPath.fileSystemRepresentation);
321
- dispatch_async(dispatch_get_main_queue(), ^{ SparkDriverTerminate(); });
383
+ dispatch_async(dispatch_get_main_queue(), ^{ SparkRestorePointer(); SparkDriverTerminate(); });
322
384
  }
323
385
 
324
386
  BOOL SparkTestDriverStart(void) {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@legendapp/spark-desktop-app",
3
- "version": "0.0.1",
3
+ "version": "0.0.3",
4
4
  "license": "MIT",
5
5
  "main": "src/index",
6
6
  "react-native": "src/index",
@@ -12,8 +12,8 @@
12
12
  "cpp"
13
13
  ],
14
14
  "peerDependencies": {
15
- "react": "^19.1.0",
16
- "react-native": "0.81.6"
15
+ "react": "^19.2.0",
16
+ "react-native": "0.83.10"
17
17
  },
18
18
  "codegenConfig": {
19
19
  "name": "RNDesktopAppSpec",
@@ -1,4 +1,4 @@
1
- // RN macOS 0.81.7 Fabric applies accessibilityState only on iOS: RCTViewComponentView's accessibilityState block is
1
+ // RN macOS 0.83.0 Fabric applies accessibilityState only on iOS: RCTViewComponentView's accessibilityState block is
2
2
  // inside #if !TARGET_OS_OSX, so a disabled Pressable with an accessibilityRole reports itself enabled to VoiceOver and a
3
3
  // selected one unselected. A view whose accessibility traits never changed (no accessibilityRole) reported
4
4
  // isAccessibilityEnabled NO, as a plain NSView does, enabled or not. The patch answers both from the view's current
@@ -38,7 +38,7 @@ function patchAccessibilityStateSource(source) {
38
38
  function installAccessibilityStatePatch(root) {
39
39
  const manifest = require.resolve("react-native-macos/package.json", { paths: [root] });
40
40
  const version = JSON.parse(fs.readFileSync(manifest, "utf8")).version;
41
- if (version !== "0.81.7") throw new Error(`spark's accessibility state patch requires react-native-macos@0.81.7; found ${version}.`);
41
+ if (version !== "0.83.0") throw new Error(`spark's accessibility state patch requires react-native-macos@0.83.0; found ${version}.`);
42
42
  const target = path.join(path.dirname(manifest), file);
43
43
  const source = fs.readFileSync(target, "utf8"), patched = patchAccessibilityStateSource(source);
44
44
  if (source !== patched) {
@@ -8,6 +8,8 @@ const {
8
8
  withEntitlementsPlist,
9
9
  withXcodeProject,
10
10
  } = require("expo-desktop-config-plugins");
11
+ const { withMod } = require("@expo/config-plugins");
12
+ const { installHostFiles, installHostProject } = require("./macos-host.cjs");
11
13
  const { identity } = require("./identity.cjs");
12
14
  const { resolveEntitlements } = require("./entitlements.cjs");
13
15
  const { version: sparkVersion } = require("@legendapp/spark/package.json");
@@ -33,6 +35,15 @@ module.exports = function withSparkDesktop(config) {
33
35
  mod.modResults = resolveEntitlements({ macos: { entitlements: declaredEntitlements } }, packages);
34
36
  return mod;
35
37
  });
38
+ // Expo Desktop 55's template hosts React Native in a SwiftUI App; Spark keeps its AppKit host.
39
+ config = withMod(config, { platform: "macos", mod: "dangerous", action: (mod) => {
40
+ installHostFiles(mod.modRequest.platformProjectRoot);
41
+ return mod;
42
+ } });
43
+ config = withXcodeProject(config, (mod) => {
44
+ installHostProject(mod.modResults);
45
+ return mod;
46
+ });
36
47
  config = withAppDelegate(config, (mod) => {
37
48
  // Own this adapter; application customizations belong in configuration/plugins.
38
49
  mod.modResults.contents = fs.readFileSync(
@@ -56,6 +67,7 @@ module.exports = function withSparkDesktop(config) {
56
67
  if (!(key in generated)) delete mod.modResults[key];
57
68
  Object.assign(mod.modResults, generated);
58
69
  mod.modResults.SparkFrameworkVersion = sparkVersion;
70
+ mod.modResults.NSMainStoryboardFile = "Main";
59
71
  mod.modResults.NSAppTransportSecurity = { NSAllowsLocalNetworking: true };
60
72
  return mod;
61
73
  });
@@ -1,4 +1,4 @@
1
- // Expo 54's file scanner ignores Bun file: dependencies' symlinked podspecs.
1
+ // Expo's file scanner ignores Bun file: dependencies' symlinked podspecs.
2
2
  const fs = require("node:fs");
3
3
  const path = require("node:path");
4
4
  const before = ` return (await fs_1.default.promises.readdir(targetPath, { withFileTypes: true }))
@@ -22,7 +22,7 @@ function patchAutolinkingSource(source) {
22
22
  function installAutolinkingPatch(root) {
23
23
  const manifest = require.resolve("expo-modules-autolinking/package.json", { paths: [root] });
24
24
  const version = JSON.parse(fs.readFileSync(manifest, "utf8")).version;
25
- if (version !== "3.0.27") throw new Error(`spark's autolinking patch requires expo-modules-autolinking@3.0.27; found ${version}.`);
25
+ if (version !== "55.0.28") throw new Error(`spark's autolinking patch requires expo-modules-autolinking@55.0.28; found ${version}.`);
26
26
  const file = path.join(path.dirname(manifest), "build/utils.js");
27
27
  const source = fs.readFileSync(file, "utf8");
28
28
  const patched = patchAutolinkingSource(source);
@@ -32,11 +32,12 @@ function installAutolinkingPatch(root) {
32
32
  fs.renameSync(temporary, file); // Do not modify package-cache hardlinks.
33
33
  }
34
34
  }
35
- // Expo autolinking ignores an app-level `ios: null` override when the package's own
36
- // react-native.config.js declares iOS, so pass the native selection's exclusions to its CLI.
35
+ // Packages such as Codex declare iOS for the desktop autolinker in their own
36
+ // react-native.config.js, so pass the native selection's exclusions to its CLI.
37
37
  function excludeNativeModules(podfile, excluded) {
38
- const call = /use_native_modules!\(config_command(?: \+ \[[^\]]*\])?\)/;
38
+ const call = /use_native_modules!\(config_command(?: \+ \[[^\]]*\])*\)/;
39
39
  if (!call.test(podfile)) throw new Error("The macOS Podfile no longer calls use_native_modules!(config_command); review spark's native selection.");
40
- return podfile.replace(call, `use_native_modules!(config_command + ${JSON.stringify(excluded.flatMap(name => ["--exclude", name]))})`);
40
+ // RN writes the filtered codegen input beneath sourceDir; Expo's iOS default points at the wrong tree.
41
+ return podfile.replace(call, `use_native_modules!(config_command + ["--source-dir", __dir__] + ${JSON.stringify(excluded.flatMap(name => ["--exclude", name]))})`);
41
42
  }
42
43
  module.exports = { patchAutolinkingSource, installAutolinkingPatch, excludeNativeModules };
@@ -1,4 +1,4 @@
1
- import type { ExpoConfig } from "@expo/config-types";
1
+ import type { ExpoConfig } from "expo/config";
2
2
  import type { WindowConfiguration } from "@legendapp/spark-window-options";
3
3
  export type { WindowConfiguration } from "@legendapp/spark-window-options";
4
4
  export type SparkPlatform = "macos" | "windows" | "ios" | "android" | "web";
@@ -112,7 +112,7 @@ function patchSurface(source) {
112
112
  function installSurfaceLifecyclePatch(root) {
113
113
  const manifest = require.resolve("react-native-macos/package.json", { paths: [root] });
114
114
  const version = JSON.parse(fs.readFileSync(manifest, "utf8")).version;
115
- if (version !== "0.81.7") throw new Error(`spark's Fabric lifecycle patch requires react-native-macos@0.81.7; found ${version}.`);
115
+ if (version !== "0.83.0") throw new Error(`spark's Fabric lifecycle patch requires react-native-macos@0.83.0; found ${version}.`);
116
116
  const file = path.join(path.dirname(manifest), "React/Fabric/Surface/RCTFabricSurface.mm");
117
117
  const before = fs.readFileSync(file, "utf8"), after = patchSurface(before);
118
118
  if (before !== after) {
@@ -1,4 +1,4 @@
1
- // RN macOS 0.81.7 legacy views embedded in Fabric can have no React tag.
1
+ // RN macOS 0.83.0 legacy views embedded in Fabric can have no React tag.
2
2
  const fs = require("node:fs");
3
3
  const path = require("node:path");
4
4
  const replacements = {
@@ -28,7 +28,7 @@ function patchKeyboardSource(file, source) {
28
28
  function installKeyboardEventsPatch(root) {
29
29
  const manifest = require.resolve("react-native-macos/package.json", { paths: [root] });
30
30
  const version = JSON.parse(fs.readFileSync(manifest, "utf8")).version;
31
- if (version !== "0.81.7") throw new Error(`spark's keyboard patch requires react-native-macos@0.81.7; found ${version}.`);
31
+ if (version !== "0.83.0") throw new Error(`spark's keyboard patch requires react-native-macos@0.83.0; found ${version}.`);
32
32
  // Validate all targets before changing either file.
33
33
  const changes = Object.keys(replacements).map(relative => {
34
34
  const file = path.join(path.dirname(manifest), relative);
@@ -0,0 +1,39 @@
1
+ // Expo Desktop 55's template hosts React Native in a SwiftUI App. Spark keeps its AppKit
2
+ // host: AppDelegate.mm replaces the Swift delegate, with main.m and the menu storyboard.
3
+ const fs = require("node:fs");
4
+ const path = require("node:path");
5
+ const { IOSConfig } = require("@expo/config-plugins");
6
+
7
+ function installHostFiles(platformRoot) {
8
+ for (const swift of fs.readdirSync(platformRoot).map((name) => path.join(platformRoot, name, "AppDelegate.swift")).filter((file) => fs.existsSync(file))) {
9
+ for (const name of ["AppDelegate.h", "main.m", "Main.storyboard"])
10
+ fs.copyFileSync(require.resolve(`@legendapp/spark-desktop-host/macos/${name}`), path.join(path.dirname(swift), name));
11
+ // Upstream AppDelegate mods expect an Objective-C delegate; Spark's withAppDelegate owns its final contents.
12
+ fs.copyFileSync(require.resolve("@legendapp/spark-desktop-host/AppDelegate.mm"), path.join(path.dirname(swift), "AppDelegate.mm"));
13
+ fs.rmSync(swift);
14
+ }
15
+ }
16
+
17
+ function installHostProject(project) {
18
+ const objects = project.hash.project.objects, references = project.pbxFileReferenceSection(), builds = project.pbxBuildFileSection();
19
+ const key = Object.keys(references).find((id) => references[id].path === "AppDelegate.swift");
20
+ if (!key) return project;
21
+ Object.assign(references[key], { path: "AppDelegate.mm", lastKnownFileType: "sourcecode.cpp.objcpp" });
22
+ references[`${key}_comment`] = "AppDelegate.mm";
23
+ const build = Object.keys(builds).find((id) => builds[id].fileRef === key);
24
+ Object.assign(builds[build], { fileRef_comment: "AppDelegate.mm" });
25
+ builds[`${build}_comment`] = "AppDelegate.mm in Sources";
26
+ const group = Object.values(objects.PBXGroup).find((entry) => entry.children?.some((child) => child.value === key));
27
+ group.children.find((child) => child.value === key).comment = "AppDelegate.mm";
28
+ for (const phase of Object.values(objects.PBXSourcesBuildPhase)) for (const file of phase.files ?? []) if (file.value === build) file.comment = "AppDelegate.mm in Sources";
29
+ // The template also has an iOS target; add the host to the target that compiled the Swift delegate.
30
+ const targetUuid = Object.keys(objects.PBXNativeTarget).find((id) => objects.PBXNativeTarget[id].buildPhases?.some((phase) =>
31
+ objects.PBXSourcesBuildPhase[phase.value]?.files?.some((file) => file.value === build)));
32
+ IOSConfig.XcodeUtils.addBuildSourceFileToGroup({ filepath: "main.m", groupName: group.path.replaceAll('"', ""), project, targetUuid });
33
+ IOSConfig.XcodeUtils.addResourceFileToGroup({ filepath: "Main.storyboard", groupName: group.path.replaceAll('"', ""), project, isBuildFile: true, targetUuid });
34
+ const storyboard = Object.keys(references).find((id) => references[id].path === '"Main.storyboard"');
35
+ references[storyboard].lastKnownFileType = "file.storyboard";
36
+ return project;
37
+ }
38
+
39
+ module.exports = { installHostFiles, installHostProject };