@legendapp/spark 0.0.1-next.2 → 0.0.1-next.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.
- package/LICENSE +21 -0
- package/README.md +10 -4
- package/ai-codex.ts +1 -0
- package/ai.ts +1 -0
- package/app-documents.ts +1 -0
- package/config-plugin.d.cts +2 -0
- package/contracts.ts +2 -0
- package/diagnostics.ts +1 -0
- package/expo-config.d.cts +1 -0
- package/metro.cjs +4 -1
- package/metro.d.cts +12 -0
- package/native.cjs +3 -1
- package/native.d.cts +6 -0
- package/package.json +82 -14
- package/schema.json +276 -58
- package/settings-observable.ts +1 -0
- package/settings-window.ts +1 -0
- package/shortcuts-commands.ts +1 -0
- package/shortcuts-keyboard.ts +3 -0
- package/ui-classnames.ts +1 -0
- package/ui-glass.ts +1 -0
- package/ui-search.ts +1 -0
- package/ui-sidebar.ts +1 -0
- package/ui-split-view.ts +1 -0
- package/ui-symbol.ts +1 -0
- package/vendor/node_modules/@legendapp/spark-ai/package.json +19 -0
- package/vendor/node_modules/@legendapp/spark-ai/src/availability.ts +17 -0
- package/vendor/node_modules/@legendapp/spark-ai/src/index.ts +15 -0
- package/vendor/node_modules/@legendapp/spark-ai/src/invocations.ts +34 -0
- package/vendor/node_modules/@legendapp/spark-ai/src/output.ts +62 -0
- package/vendor/node_modules/@legendapp/spark-ai/src/run.ts +12 -0
- package/vendor/node_modules/@legendapp/spark-ai/src/types.ts +16 -0
- package/vendor/node_modules/@legendapp/spark-audio/macos/RNSparkAudio.h +2 -1
- package/vendor/node_modules/@legendapp/spark-audio/macos/RNSparkAudio.mm +126 -24
- package/vendor/node_modules/@legendapp/spark-audio/package.json +5 -2
- package/vendor/node_modules/@legendapp/spark-audio/src/NativeSparkAudio.ts +5 -1
- package/vendor/node_modules/@legendapp/spark-audio/src/desktop.ts +36 -32
- package/vendor/node_modules/@legendapp/spark-audio/src/events.ts +11 -0
- package/vendor/node_modules/@legendapp/spark-audio/src/hooks.ts +65 -0
- package/vendor/node_modules/@legendapp/spark-audio/src/index.web.ts +92 -33
- package/vendor/node_modules/@legendapp/spark-audio/src/media-session-unavailable.ts +6 -4
- package/vendor/node_modules/@legendapp/spark-audio/src/media-session.ts +52 -19
- package/vendor/node_modules/@legendapp/spark-audio/src/media-session.web.ts +18 -10
- package/vendor/node_modules/@legendapp/spark-audio/src/media-types.ts +40 -13
- package/vendor/node_modules/@legendapp/spark-audio/src/mobile.ts +40 -32
- package/vendor/node_modules/@legendapp/spark-audio/src/player.ts +97 -0
- package/vendor/node_modules/@legendapp/spark-audio/src/status-listeners.ts +21 -15
- package/vendor/node_modules/@legendapp/spark-audio/src/types.ts +9 -4
- package/vendor/node_modules/@legendapp/spark-audio/windows/SparkAudio/SparkAudio.h +67 -20
- package/vendor/node_modules/@legendapp/spark-auth-session/package.json +4 -3
- package/vendor/node_modules/@legendapp/spark-auth-session/src/core.ts +60 -42
- package/vendor/node_modules/@legendapp/spark-auth-session/src/index.ts +28 -12
- package/vendor/node_modules/@legendapp/spark-auth-session/src/mobile.ts +97 -41
- package/vendor/node_modules/@legendapp/spark-auth-session/src/types.ts +20 -9
- package/vendor/node_modules/@legendapp/spark-cli/dist/add-desktop.js +50 -7
- package/vendor/node_modules/@legendapp/spark-cli/dist/build-mode.js +1 -1
- package/vendor/node_modules/@legendapp/spark-cli/dist/build.js +83 -48
- package/vendor/node_modules/@legendapp/spark-cli/dist/cli-arguments.js +60 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/commands.js +7 -2
- package/vendor/node_modules/@legendapp/spark-cli/dist/create.js +31 -5
- package/vendor/node_modules/@legendapp/spark-cli/dist/credentials.js +69 -23
- package/vendor/node_modules/@legendapp/spark-cli/dist/dev-command.js +12 -3
- package/vendor/node_modules/@legendapp/spark-cli/dist/dev.js +12 -9
- package/vendor/node_modules/@legendapp/spark-cli/dist/examples.js +1 -1
- package/vendor/node_modules/@legendapp/spark-cli/dist/expo-dev-patch.cjs +4 -2
- package/vendor/node_modules/@legendapp/spark-cli/dist/expo-metro.cjs +1 -1
- package/vendor/node_modules/@legendapp/spark-cli/dist/expo-node.js +3 -3
- package/vendor/node_modules/@legendapp/spark-cli/dist/index.js +10 -38
- package/vendor/node_modules/@legendapp/spark-cli/dist/local.js +1 -1
- package/vendor/node_modules/@legendapp/spark-cli/dist/metro.cjs +26 -5
- package/vendor/node_modules/@legendapp/spark-cli/dist/native-metadata.js +26 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/native-patch-preflight.js +84 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/native-preparation.js +88 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/notary-profiles.js +75 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/package.js +4 -2
- package/vendor/node_modules/@legendapp/spark-cli/dist/platform.js +16 -2
- package/vendor/node_modules/@legendapp/spark-cli/dist/project.js +66 -13
- package/vendor/node_modules/@legendapp/spark-cli/dist/release.js +84 -4
- package/vendor/node_modules/@legendapp/spark-cli/dist/release.json +23 -18
- package/vendor/node_modules/@legendapp/spark-cli/dist/runner-install.js +145 -31
- package/vendor/node_modules/@legendapp/spark-cli/dist/signing.js +4 -3
- package/vendor/node_modules/@legendapp/spark-cli/dist/updates.js +41 -4
- package/vendor/node_modules/@legendapp/spark-cli/dist/windows.js +4 -1
- package/vendor/node_modules/@legendapp/spark-cli/package.json +7 -6
- package/vendor/node_modules/@legendapp/spark-cli/templates/blank-typescript/App.tsx +6 -12
- package/vendor/node_modules/@legendapp/spark-cli/templates/blank-typescript/desktop.config.json +5 -3
- package/vendor/node_modules/@legendapp/spark-cli/templates/blank-typescript/package.json +11 -9
- package/vendor/node_modules/@legendapp/spark-cli/templates/diff-lite/Git.macos.tsx +2 -2
- package/vendor/node_modules/@legendapp/spark-cli/templates/document-editor/Integration.macos.tsx +23 -21
- package/vendor/node_modules/@legendapp/spark-cli/templates/document-editor/Integration.windows.tsx +23 -21
- package/vendor/node_modules/@legendapp/spark-cli/templates/document-editor/io.desktop.ts +11 -8
- package/vendor/node_modules/@legendapp/spark-cli/templates/document-editor/io.macos.ts +3 -3
- package/vendor/node_modules/@legendapp/spark-cli/templates/example-shared/Lifecycle.desktop.tsx +8 -14
- package/vendor/node_modules/@legendapp/spark-cli/templates/example-shared/OpenFiles.desktop.tsx +5 -10
- package/vendor/node_modules/@legendapp/spark-cli/templates/example-shared/io.desktop.ts +11 -8
- package/vendor/node_modules/@legendapp/spark-cli/templates/example-shared/io.macos.ts +3 -3
- package/vendor/node_modules/@legendapp/spark-cli/templates/music-lite/assets.desktop.ts +2 -2
- package/vendor/node_modules/@legendapp/spark-cli/templates/notes-lite/Activation.desktop.tsx +2 -2
- package/vendor/node_modules/@legendapp/spark-cli/templates/notes-lite/Desktop.desktop.ts +37 -15
- package/vendor/node_modules/@legendapp/spark-cli/templates/notes-lite/session.ts +5 -6
- package/vendor/node_modules/@legendapp/spark-cli/templates/notes-lite/window-session.ts +5 -4
- package/vendor/node_modules/@legendapp/spark-cli/templates/universal/desktop.config.json +5 -3
- package/vendor/node_modules/@legendapp/spark-cli/templates/universal/metro.config.js +1 -1
- package/vendor/node_modules/@legendapp/spark-cli/templates/universal/package.json +13 -11
- package/vendor/node_modules/@legendapp/spark-cli/templates/universal/react-native.config.js +1 -1
- package/vendor/node_modules/@legendapp/spark-cli/templates/windows/package.json +13 -11
- package/vendor/node_modules/@legendapp/spark-cli/templates/windows/react-native.config.js +1 -1
- package/vendor/node_modules/@legendapp/spark-clipboard/macos/RNDesktopClipboard.mm +10 -16
- package/vendor/node_modules/@legendapp/spark-clipboard/package.json +2 -2
- package/vendor/node_modules/@legendapp/spark-clipboard/src/NativeDesktopClipboard.ts +1 -1
- package/vendor/node_modules/@legendapp/spark-clipboard/src/desktop.ts +55 -31
- package/vendor/node_modules/@legendapp/spark-clipboard/src/expo.ts +21 -11
- package/vendor/node_modules/@legendapp/spark-clipboard/src/options.ts +8 -0
- package/vendor/node_modules/@legendapp/spark-clipboard/src/types.ts +10 -0
- package/vendor/node_modules/@legendapp/spark-clipboard/windows/SparkClipboard/SparkClipboard.h +38 -15
- package/vendor/node_modules/@legendapp/spark-clipboard/windows/SparkClipboard/SparkClipboard.vcxproj +2 -0
- package/vendor/node_modules/@legendapp/spark-codex/RNCodex.podspec +22 -0
- package/vendor/node_modules/@legendapp/spark-codex/cpp/HybridCodexAppServer.hpp +23 -0
- package/vendor/node_modules/@legendapp/spark-codex/cpp/HybridCodexAppServer.mm +1529 -0
- package/vendor/node_modules/@legendapp/spark-codex/nitro.json +21 -0
- package/vendor/node_modules/@legendapp/spark-codex/nitrogen/generated/.gitattributes +1 -0
- package/vendor/node_modules/@legendapp/spark-codex/nitrogen/generated/ios/RNCodex+autolinking.rb +62 -0
- package/vendor/node_modules/@legendapp/spark-codex/nitrogen/generated/ios/RNCodex-Swift-Cxx-Bridge.cpp +17 -0
- package/vendor/node_modules/@legendapp/spark-codex/nitrogen/generated/ios/RNCodex-Swift-Cxx-Bridge.hpp +27 -0
- package/vendor/node_modules/@legendapp/spark-codex/nitrogen/generated/ios/RNCodex-Swift-Cxx-Umbrella.hpp +38 -0
- package/vendor/node_modules/@legendapp/spark-codex/nitrogen/generated/ios/RNCodexAutolinking.mm +35 -0
- package/vendor/node_modules/@legendapp/spark-codex/nitrogen/generated/ios/RNCodexAutolinking.swift +16 -0
- package/vendor/node_modules/@legendapp/spark-codex/nitrogen/generated/shared/c++/CodexAvailability.hpp +95 -0
- package/vendor/node_modules/@legendapp/spark-codex/nitrogen/generated/shared/c++/CodexRunResult.hpp +99 -0
- package/vendor/node_modules/@legendapp/spark-codex/nitrogen/generated/shared/c++/HybridCodexAppServerSpec.cpp +24 -0
- package/vendor/node_modules/@legendapp/spark-codex/nitrogen/generated/shared/c++/HybridCodexAppServerSpec.hpp +71 -0
- package/vendor/node_modules/@legendapp/spark-codex/package.json +35 -0
- package/vendor/node_modules/@legendapp/spark-codex/react-native.config.js +11 -0
- package/vendor/node_modules/@legendapp/spark-codex/src/Codex.nitro.ts +30 -0
- package/vendor/node_modules/@legendapp/spark-codex/src/index.ts +65 -0
- package/vendor/node_modules/@legendapp/spark-codex/src/native.ts +6 -0
- package/vendor/node_modules/@legendapp/spark-commands/package.json +21 -0
- package/vendor/node_modules/@legendapp/spark-commands/src/bindings.ts +90 -0
- package/vendor/node_modules/@legendapp/spark-commands/src/index.tsx +400 -0
- package/vendor/node_modules/@legendapp/spark-commands/src/router.ts +138 -0
- package/vendor/node_modules/@legendapp/spark-commands/src/storage.ts +20 -0
- package/vendor/node_modules/@legendapp/spark-context-menu/macos/RNContextMenu.mm +7 -8
- package/vendor/node_modules/@legendapp/spark-context-menu/package.json +4 -3
- package/vendor/node_modules/@legendapp/spark-context-menu/src/NativeContextMenu.ts +1 -1
- package/vendor/node_modules/@legendapp/spark-context-menu/src/index.ts +26 -26
- package/vendor/node_modules/@legendapp/spark-context-menu/windows/SparkContextMenu/SparkContextMenu.h +3 -2
- package/vendor/node_modules/@legendapp/spark-desktop-app/RNDesktopApp.podspec +2 -1
- package/vendor/node_modules/@legendapp/spark-desktop-app/cpp/SparkBinaryJSI.hpp +89 -0
- package/vendor/node_modules/@legendapp/spark-desktop-app/cpp/SparkBinaryWindows.hpp +22 -0
- package/vendor/node_modules/@legendapp/spark-desktop-app/macos/RNDesktopApp.mm +13 -7
- package/vendor/node_modules/@legendapp/spark-desktop-app/macos/SparkBinaryJSI.h +48 -0
- package/vendor/node_modules/@legendapp/spark-desktop-app/macos/SparkDesktop.h +4 -0
- package/vendor/node_modules/@legendapp/spark-desktop-app/macos/SparkDesktop.mm +33 -33
- package/vendor/node_modules/@legendapp/spark-desktop-app/macos/SparkDesktopError.h +20 -0
- package/vendor/node_modules/@legendapp/spark-desktop-app/macos/SparkLifecycle.h +26 -0
- package/vendor/node_modules/@legendapp/spark-desktop-app/macos/SparkLifecycle.mm +49 -0
- package/vendor/node_modules/@legendapp/spark-desktop-app/macos/SparkQuitCoordinator.h +9 -0
- package/vendor/node_modules/@legendapp/spark-desktop-app/macos/SparkQuitCoordinator.mm +70 -0
- package/vendor/node_modules/@legendapp/spark-desktop-app/macos/SparkWindow.mm +9 -6
- package/vendor/node_modules/@legendapp/spark-desktop-app/macos/recent-documents/RNRecentDocumentController.mm +55 -0
- package/vendor/node_modules/@legendapp/spark-desktop-app/package.json +5 -3
- package/vendor/node_modules/@legendapp/spark-desktop-app/src/NativeDesktopApp.ts +1 -1
- package/vendor/node_modules/@legendapp/spark-desktop-app/src/api.ts +86 -40
- package/vendor/node_modules/@legendapp/spark-desktop-app/src/contracts/accelerator.ts +40 -0
- package/vendor/node_modules/@legendapp/spark-desktop-app/src/contracts/index.ts +56 -0
- package/vendor/node_modules/@legendapp/spark-desktop-app/src/contracts/menu.ts +114 -0
- package/vendor/node_modules/@legendapp/spark-desktop-app/src/contracts/native-buffer.ts +22 -0
- package/vendor/node_modules/@legendapp/spark-desktop-app/src/contracts/path.ts +24 -0
- package/vendor/node_modules/@legendapp/spark-desktop-app/src/events.ts +75 -0
- package/vendor/node_modules/@legendapp/spark-desktop-app/src/index.ts +2 -0
- package/vendor/node_modules/@legendapp/spark-desktop-app/src/index.windows.ts +2 -0
- package/vendor/node_modules/@legendapp/spark-desktop-app/src/open-requests.ts +43 -0
- package/vendor/node_modules/@legendapp/spark-desktop-app/src/restoration.ts +11 -0
- package/vendor/node_modules/@legendapp/spark-desktop-app/src/transport.ts +10 -0
- package/vendor/node_modules/@legendapp/spark-desktop-config/app.plugin.cjs +10 -5
- package/vendor/node_modules/@legendapp/spark-desktop-config/app.plugin.d.cts +3 -0
- package/vendor/node_modules/@legendapp/spark-desktop-config/autolinking.cjs +35 -0
- package/vendor/node_modules/@legendapp/spark-desktop-config/config.cjs +16 -3
- package/vendor/node_modules/@legendapp/spark-desktop-config/config.d.cts +89 -9
- package/vendor/node_modules/@legendapp/spark-desktop-config/expo.d.cts +3 -0
- package/vendor/node_modules/@legendapp/spark-desktop-config/identity.cjs +3 -2
- package/vendor/node_modules/@legendapp/spark-desktop-config/lifecycle.cjs +20 -0
- package/vendor/node_modules/@legendapp/spark-desktop-config/package.json +6 -5
- package/vendor/node_modules/@legendapp/spark-desktop-config/schema.json +276 -58
- package/vendor/node_modules/@legendapp/spark-desktop-config/updates.cjs +1 -0
- package/vendor/node_modules/@legendapp/spark-desktop-config/validation.cjs +35 -0
- package/vendor/node_modules/@legendapp/spark-desktop-config/windows.plugin.cjs +2 -1
- package/vendor/node_modules/@legendapp/spark-desktop-host/AppDelegate.mm +129 -11
- package/vendor/node_modules/@legendapp/spark-desktop-host/package.json +2 -2
- package/vendor/node_modules/@legendapp/spark-desktop-host/windows/application.inc +277 -121
- package/vendor/node_modules/@legendapp/spark-desktop-links/common/AuthLoopback.h +5 -7
- package/vendor/node_modules/@legendapp/spark-desktop-links/macos/RNDesktopLinks.mm +10 -9
- package/vendor/node_modules/@legendapp/spark-desktop-links/package.json +2 -2
- package/vendor/node_modules/@legendapp/spark-desktop-links/src/NativeDesktopLinks.ts +1 -1
- package/vendor/node_modules/@legendapp/spark-desktop-links/src/api.ts +27 -33
- package/vendor/node_modules/@legendapp/spark-desktop-links/src/expo.ts +3 -4
- package/vendor/node_modules/@legendapp/spark-desktop-links/src/native.ts +9 -0
- package/vendor/node_modules/@legendapp/spark-desktop-links/windows/SparkLinks/SparkLinks.h +22 -22
- package/vendor/node_modules/@legendapp/spark-desktop-shortcuts/RNDesktopShortcuts.podspec +1 -0
- package/vendor/node_modules/@legendapp/spark-desktop-shortcuts/macos/RNDesktopShortcuts.mm +1 -1
- package/vendor/node_modules/@legendapp/spark-desktop-shortcuts/macos/keyboard-manager/RNKeyboardManager.h +9 -0
- package/vendor/node_modules/@legendapp/spark-desktop-shortcuts/macos/keyboard-manager/RNKeyboardManager.mm +307 -0
- package/vendor/node_modules/@legendapp/spark-desktop-shortcuts/package.json +8 -5
- package/vendor/node_modules/@legendapp/spark-desktop-shortcuts/src/NativeDesktopShortcuts.ts +1 -1
- package/vendor/node_modules/@legendapp/spark-desktop-shortcuts/src/api.ts +39 -14
- package/vendor/node_modules/@legendapp/spark-desktop-shortcuts/src/keyboard-manager/NativeKeyboardManager.ts +12 -0
- package/vendor/node_modules/@legendapp/spark-desktop-shortcuts/src/keyboard-manager/codes.ts +108 -0
- package/vendor/node_modules/@legendapp/spark-desktop-shortcuts/src/keyboard-manager/index.ts +99 -0
- package/vendor/node_modules/@legendapp/spark-desktop-windows/RNDesktopWindows.podspec +2 -0
- package/vendor/node_modules/@legendapp/spark-desktop-windows/macos/RNDesktopWindows.mm +229 -103
- package/vendor/node_modules/@legendapp/spark-desktop-windows/macos/SparkWindowGeometry.h +63 -0
- package/vendor/node_modules/@legendapp/spark-desktop-windows/macos/window-manager/LegendWindowRegistry.h +20 -0
- package/vendor/node_modules/@legendapp/spark-desktop-windows/macos/window-manager/LegendWindowRegistry.mm +27 -0
- package/vendor/node_modules/@legendapp/spark-desktop-windows/macos/window-manager/RNWindowManager.h +12 -0
- package/vendor/node_modules/@legendapp/spark-desktop-windows/macos/window-manager/RNWindowManager.mm +3130 -0
- package/vendor/node_modules/@legendapp/spark-desktop-windows/macos/window-manager/RNWindowManagerStartup.mm +31 -0
- package/vendor/node_modules/@legendapp/spark-desktop-windows/macos/window-manager/SidebarStartupFallbacks.mm +14 -0
- package/vendor/node_modules/@legendapp/spark-desktop-windows/package.json +10 -6
- package/vendor/node_modules/@legendapp/spark-desktop-windows/src/NativeDesktopWindowManager.ts +1 -1
- package/vendor/node_modules/@legendapp/spark-desktop-windows/src/api.ts +144 -70
- package/vendor/node_modules/@legendapp/spark-desktop-windows/src/diagnostics.ts +17 -0
- package/vendor/node_modules/@legendapp/spark-desktop-windows/src/index.ts +3 -1
- package/vendor/node_modules/@legendapp/spark-desktop-windows/src/index.windows.ts +3 -1
- package/vendor/node_modules/@legendapp/spark-desktop-windows/src/macos-adapter.ts +53 -0
- package/vendor/node_modules/@legendapp/spark-desktop-windows/src/macos.ts +51 -0
- package/vendor/node_modules/@legendapp/spark-desktop-windows/src/transport.ts +41 -0
- package/vendor/node_modules/@legendapp/spark-desktop-windows/src/types.ts +140 -0
- package/vendor/node_modules/@legendapp/spark-desktop-windows/src/validation.ts +162 -0
- package/vendor/node_modules/@legendapp/spark-desktop-windows/src/window-manager/NativeWindowManager.ts +28 -0
- package/vendor/node_modules/@legendapp/spark-desktop-windows/src/windows/WindowProvider.tsx +20 -0
- package/vendor/node_modules/@legendapp/spark-desktop-windows/src/windows/createWindowsNavigator.tsx +78 -0
- package/vendor/node_modules/@legendapp/spark-desktop-windows/src/windows/index.ts +6 -0
- package/vendor/node_modules/@legendapp/spark-desktop-windows/src/windows/primaryWindowLifecycle.ts +34 -0
- package/vendor/node_modules/@legendapp/spark-desktop-windows/src/windows/types.ts +11 -0
- package/vendor/node_modules/@legendapp/spark-desktop-windows/src/windows/usePrimaryWindowLifecycle.ts +18 -0
- package/vendor/node_modules/@legendapp/spark-desktop-windows/src/windows/useWindowFocusEffect.ts +17 -0
- package/vendor/node_modules/@legendapp/spark-documents/package.json +22 -0
- package/vendor/node_modules/@legendapp/spark-documents/src/controller.ts +97 -0
- package/vendor/node_modules/@legendapp/spark-documents/src/documentTransition.ts +13 -0
- package/vendor/node_modules/@legendapp/spark-documents/src/hooks.ts +139 -0
- package/vendor/node_modules/@legendapp/spark-documents/src/index.tsx +50 -0
- package/vendor/node_modules/@legendapp/spark-documents/src/reload.ts +39 -0
- package/vendor/node_modules/@legendapp/spark-documents/src/requests.ts +15 -0
- package/vendor/node_modules/@legendapp/spark-drag-drop/package.json +4 -3
- package/vendor/node_modules/@legendapp/spark-drag-drop/src/DesktopDragViewNativeComponent.ts +1 -1
- package/vendor/node_modules/@legendapp/spark-drag-drop/src/contracts.ts +73 -18
- package/vendor/node_modules/@legendapp/spark-drag-drop/src/index.tsx +58 -15
- package/vendor/node_modules/@legendapp/spark-drag-drop/windows/SparkDragDrop/SparkDragDrop.h +14 -8
- package/vendor/node_modules/@legendapp/spark-file-dialog/ios/RNFileDialog.mm +34 -121
- package/vendor/node_modules/@legendapp/spark-file-dialog/package.json +12 -5
- package/vendor/node_modules/@legendapp/spark-file-dialog/src/NativeFileDialog.ts +1 -5
- package/vendor/node_modules/@legendapp/spark-file-dialog/src/index.ts +19 -84
- package/vendor/node_modules/@legendapp/spark-file-dialog/src/native.ts +12 -0
- package/vendor/node_modules/@legendapp/spark-file-dialog/src/options.ts +34 -14
- package/vendor/node_modules/@legendapp/spark-file-dialog/src/types.ts +26 -0
- package/vendor/node_modules/@legendapp/spark-file-dialog/windows/SparkFileDialog/SparkFileDialog.h +42 -58
- package/vendor/node_modules/@legendapp/spark-file-system/RNDesktopFileSystem.podspec +1 -0
- package/vendor/node_modules/@legendapp/spark-file-system/macos/RNDesktopFileSystem.mm +32 -21
- package/vendor/node_modules/@legendapp/spark-file-system/macos/SparkFileMutations.h +24 -0
- package/vendor/node_modules/@legendapp/spark-file-system/macos/SparkFileMutations.mm +215 -0
- package/vendor/node_modules/@legendapp/spark-file-system/macos/file-scanner/RNFileScanner.h +9 -0
- package/vendor/node_modules/@legendapp/spark-file-system/macos/file-scanner/RNFileScanner.mm +82 -0
- package/vendor/node_modules/@legendapp/spark-file-system/macos/file-scanner/RNFileScannerCore.h +47 -0
- package/vendor/node_modules/@legendapp/spark-file-system/macos/file-scanner/RNFileScannerCore.mm +306 -0
- package/vendor/node_modules/@legendapp/spark-file-system/package.json +8 -6
- package/vendor/node_modules/@legendapp/spark-file-system/src/NativeDesktopFileSystem.ts +1 -1
- package/vendor/node_modules/@legendapp/spark-file-system/src/file-scanner/NativeFileScanner.ts +11 -0
- package/vendor/node_modules/@legendapp/spark-file-system/src/file-scanner/index.ts +93 -0
- package/vendor/node_modules/@legendapp/spark-file-system/src/handles.ts +48 -14
- package/vendor/node_modules/@legendapp/spark-file-system/src/index.ts +134 -45
- package/vendor/node_modules/@legendapp/spark-file-system/src/path.ts +1 -9
- package/vendor/node_modules/@legendapp/spark-file-system/windows/SparkFileSystem/SparkFileSystem.h +102 -26
- package/vendor/node_modules/@legendapp/spark-file-system/windows/SparkFileSystem/SparkFileSystem.vcxproj +2 -0
- package/vendor/node_modules/@legendapp/spark-global-shortcuts/RNDesktopGlobalShortcuts.podspec +1 -0
- package/vendor/node_modules/@legendapp/spark-global-shortcuts/macos/RNDesktopGlobalShortcuts.mm +7 -4
- package/vendor/node_modules/@legendapp/spark-global-shortcuts/package.json +4 -3
- package/vendor/node_modules/@legendapp/spark-global-shortcuts/src/NativeDesktopGlobalShortcuts.ts +1 -1
- package/vendor/node_modules/@legendapp/spark-global-shortcuts/src/index.ts +39 -10
- package/vendor/node_modules/@legendapp/spark-global-shortcuts/windows/SparkGlobalShortcuts/SparkGlobalShortcuts.h +5 -4
- package/vendor/node_modules/@legendapp/spark-message-dialog/macos/RNDesktopMessageDialog.mm +2 -2
- package/vendor/node_modules/@legendapp/spark-message-dialog/package.json +2 -2
- package/vendor/node_modules/@legendapp/spark-message-dialog/src/NativeDesktopMessageDialog.ts +1 -1
- package/vendor/node_modules/@legendapp/spark-message-dialog/src/index.ts +48 -11
- package/vendor/node_modules/@legendapp/spark-native-menu/ios/RNNativeMenu.mm +141 -609
- package/vendor/node_modules/@legendapp/spark-native-menu/package.json +9 -4
- package/vendor/node_modules/@legendapp/spark-native-menu/src/NativeMenu.ts +2 -7
- package/vendor/node_modules/@legendapp/spark-native-menu/src/api.ts +76 -121
- package/vendor/node_modules/@legendapp/spark-native-menu/src/hooks.ts +97 -0
- package/vendor/node_modules/@legendapp/spark-native-menu/src/windows-menus.ts +43 -37
- package/vendor/node_modules/@legendapp/spark-notifications/macos/RNDesktopNotifications.mm +75 -30
- package/vendor/node_modules/@legendapp/spark-notifications/package.json +2 -2
- package/vendor/node_modules/@legendapp/spark-notifications/src/NativeDesktopNotifications.ts +1 -1
- package/vendor/node_modules/@legendapp/spark-notifications/src/index.ts +130 -42
- package/vendor/node_modules/@legendapp/spark-notifications/windows/SparkNotifications/SparkNotifications.h +46 -8
- package/vendor/node_modules/@legendapp/spark-processes/macos/RNDesktopProcesses.mm +94 -21
- package/vendor/node_modules/@legendapp/spark-processes/package.json +4 -3
- package/vendor/node_modules/@legendapp/spark-processes/src/NativeDesktopProcesses.ts +1 -1
- package/vendor/node_modules/@legendapp/spark-processes/src/index.ts +124 -28
- package/vendor/node_modules/@legendapp/spark-processes/src/types.ts +34 -0
- package/vendor/node_modules/@legendapp/spark-processes/windows/SparkProcesses/SparkProcesses.h +83 -34
- package/vendor/node_modules/@legendapp/spark-processes/windows/SparkProcesses/SparkProcesses.vcxproj +2 -0
- package/vendor/node_modules/@legendapp/spark-secure-storage/macos/RNDesktopSecureStorage.mm +49 -40
- package/vendor/node_modules/@legendapp/spark-secure-storage/package.json +2 -2
- package/vendor/node_modules/@legendapp/spark-secure-storage/src/NativeDesktopSecureStorage.ts +1 -1
- package/vendor/node_modules/@legendapp/spark-secure-storage/src/desktop.ts +16 -14
- package/vendor/node_modules/@legendapp/spark-secure-storage/src/expo.ts +0 -1
- package/vendor/node_modules/@legendapp/spark-secure-storage/src/options.ts +3 -2
- package/vendor/node_modules/@legendapp/spark-secure-storage/src/unavailable.ts +6 -3
- package/vendor/node_modules/@legendapp/spark-settings/package.json +10 -3
- package/vendor/node_modules/@legendapp/spark-settings/src/fileStorage.ts +11 -0
- package/vendor/node_modules/@legendapp/spark-settings/src/index.ts +7 -9
- package/vendor/node_modules/@legendapp/spark-settings/src/storage/index.ts +142 -0
- package/vendor/node_modules/@legendapp/spark-settings/src/store.ts +63 -21
- package/vendor/node_modules/@legendapp/spark-settings-ui/package.json +20 -0
- package/vendor/node_modules/@legendapp/spark-settings-ui/src/index.tsx +436 -0
- package/vendor/node_modules/@legendapp/spark-settings-ui/src/options.ts +10 -0
- package/vendor/node_modules/@legendapp/spark-sqlite/package.json +3 -3
- package/vendor/node_modules/@legendapp/spark-sqlite/src/database.ts +182 -0
- package/vendor/node_modules/@legendapp/spark-sqlite/src/index.ts +19 -6
- package/vendor/node_modules/@legendapp/spark-sqlite/src/types.ts +22 -0
- package/vendor/node_modules/@legendapp/spark-system/macos/RNDesktopSystem.mm +36 -11
- package/vendor/node_modules/@legendapp/spark-system/package.json +2 -2
- package/vendor/node_modules/@legendapp/spark-system/src/NativeDesktopSystem.ts +1 -1
- package/vendor/node_modules/@legendapp/spark-system/src/index.ts +89 -32
- package/vendor/node_modules/@legendapp/spark-system/windows/SparkSystem/SparkSystem.h +8 -4
- package/vendor/node_modules/@legendapp/spark-tray/macos/RNDesktopTray.mm +20 -8
- package/vendor/node_modules/@legendapp/spark-tray/package.json +2 -2
- package/vendor/node_modules/@legendapp/spark-tray/src/NativeDesktopTray.ts +1 -1
- package/vendor/node_modules/@legendapp/spark-tray/src/index.ts +91 -34
- package/vendor/node_modules/@legendapp/spark-tray/windows/SparkTray/SparkTray.h +45 -15
- package/vendor/node_modules/@legendapp/spark-ui/macos/RNSparkButton.mm +2 -1
- package/vendor/node_modules/@legendapp/spark-ui/macos/RNSparkTextInput.mm +10 -2
- package/vendor/node_modules/@legendapp/spark-ui/macos/appkit-split-view/RNSidebarSplitViewComponent.h +15 -0
- package/vendor/node_modules/@legendapp/spark-ui/macos/appkit-split-view/RNSidebarSplitViewComponent.mm +1182 -0
- package/vendor/node_modules/@legendapp/spark-ui/macos/glass-effect-view/RNGlassEffectView.mm +72 -0
- package/vendor/node_modules/@legendapp/spark-ui/macos/native-select/RNNativeSegmentedControl.h +15 -0
- package/vendor/node_modules/@legendapp/spark-ui/macos/native-select/RNNativeSegmentedControl.mm +194 -0
- package/vendor/node_modules/@legendapp/spark-ui/macos/native-select/RNNativeSelect.h +15 -0
- package/vendor/node_modules/@legendapp/spark-ui/macos/native-select/RNNativeSelect.mm +180 -0
- package/vendor/node_modules/@legendapp/spark-ui/macos/sf-symbol/RNSFSymbol.h +15 -0
- package/vendor/node_modules/@legendapp/spark-ui/macos/sf-symbol/RNSFSymbol.mm +155 -0
- package/vendor/node_modules/@legendapp/spark-ui/macos/sidebar/RNSidebar.h +18 -0
- package/vendor/node_modules/@legendapp/spark-ui/macos/sidebar/RNSidebar.mm +645 -0
- package/vendor/node_modules/@legendapp/spark-ui/macos/text-input-search/RNTextInputSearch.h +15 -0
- package/vendor/node_modules/@legendapp/spark-ui/macos/text-input-search/RNTextInputSearch.mm +164 -0
- package/vendor/node_modules/@legendapp/spark-ui/package.json +16 -4
- package/vendor/node_modules/@legendapp/spark-ui/src/SparkSelectNativeComponent.ts +3 -1
- package/vendor/node_modules/@legendapp/spark-ui/src/SparkTextInputNativeComponent.ts +6 -2
- package/vendor/node_modules/@legendapp/spark-ui/src/appkit-split-view/SidebarSplitViewNativeComponent.ts +31 -0
- package/vendor/node_modules/@legendapp/spark-ui/src/appkit-split-view/index.tsx +77 -0
- package/vendor/node_modules/@legendapp/spark-ui/src/availability.ts +10 -0
- package/vendor/node_modules/@legendapp/spark-ui/src/classnames/index.ts +8 -0
- package/vendor/node_modules/@legendapp/spark-ui/src/control.ts +42 -0
- package/vendor/node_modules/@legendapp/spark-ui/src/desktop.tsx +56 -0
- package/vendor/node_modules/@legendapp/spark-ui/src/glass-effect-view/index.tsx +15 -0
- package/vendor/node_modules/@legendapp/spark-ui/src/index.android.tsx +35 -21
- package/vendor/node_modules/@legendapp/spark-ui/src/index.ios.tsx +55 -26
- package/vendor/node_modules/@legendapp/spark-ui/src/index.tsx +1 -27
- package/vendor/node_modules/@legendapp/spark-ui/src/index.web.tsx +45 -14
- package/vendor/node_modules/@legendapp/spark-ui/src/index.windows.tsx +1 -42
- package/vendor/node_modules/@legendapp/spark-ui/src/mobile-input.tsx +11 -0
- package/vendor/node_modules/@legendapp/spark-ui/src/native-select/NativeSegmentedControlNativeComponent.ts +17 -0
- package/vendor/node_modules/@legendapp/spark-ui/src/native-select/NativeSelectNativeComponent.ts +17 -0
- package/vendor/node_modules/@legendapp/spark-ui/src/select.ts +5 -3
- package/vendor/node_modules/@legendapp/spark-ui/src/sf-symbol/SFSymbolNativeComponent.ts +13 -0
- package/vendor/node_modules/@legendapp/spark-ui/src/sf-symbol/index.tsx +27 -0
- package/vendor/node_modules/@legendapp/spark-ui/src/sidebar/SidebarItemNativeComponent.ts +25 -0
- package/vendor/node_modules/@legendapp/spark-ui/src/sidebar/SidebarNativeComponent.ts +24 -0
- package/vendor/node_modules/@legendapp/spark-ui/src/sidebar/index.tsx +104 -0
- package/vendor/node_modules/@legendapp/spark-ui/src/specialized.ts +22 -0
- package/vendor/node_modules/@legendapp/spark-ui/src/text-input-search/TextInputSearchNativeComponent.ts +33 -0
- package/vendor/node_modules/@legendapp/spark-ui/src/text-input-search/index.tsx +34 -0
- package/vendor/node_modules/@legendapp/spark-ui/src/types.ts +30 -19
- package/vendor/node_modules/@legendapp/spark-ui/uniwind.ts +3 -1
- package/vendor/node_modules/@legendapp/spark-ui/uniwind.web.ts +3 -1
- package/vendor/node_modules/@legendapp/spark-ui/windows/SparkUI/SparkUI.h +16 -11
- package/vendor/node_modules/@legendapp/spark-updates/macos/RNDesktopUpdates.mm +21 -8
- package/vendor/node_modules/@legendapp/spark-updates/package.json +2 -2
- package/vendor/node_modules/@legendapp/spark-updates/src/NativeDesktopUpdates.ts +3 -2
- package/vendor/node_modules/@legendapp/spark-updates/src/index.ts +71 -15
- package/vendor/node_modules/@legendapp/spark-webview/package.json +2 -2
- package/vendor/node_modules/@legendapp/spark-webview/src/WebView.tsx +11 -0
- package/vendor/node_modules/@legendapp/spark-webview/src/adapter.ts +55 -0
- package/vendor/node_modules/@legendapp/spark-webview/src/index.ts +2 -2
- package/vendor/node_modules/@legendapp/spark-webview/src/types.ts +32 -0
- package/vendor/node_modules/@legendapp/spark-webview/src/view-props.ts +28 -0
- package/vendor/node_modules/@legendapp/spark-window-options/index.cjs +51 -14
- package/vendor/node_modules/@legendapp/spark-window-options/index.d.ts +21 -8
- package/vendor/node_modules/@legendapp/spark-window-options/package.json +1 -1
- package/windows-macos.ts +1 -0
- package/expo-metro.cjs +0 -1
- package/message-dialog.ts +0 -1
- package/universal.cjs +0 -1
- package/vendor/node_modules/@legendapp/spark-desktop-shortcuts/src/accelerator.ts +0 -22
- package/vendor/node_modules/@legendapp/spark-desktop-windows/src/windows-options.ts +0 -11
- package/vendor/node_modules/@legendapp/spark-file-dialog/src/index.windows.ts +0 -15
- package/vendor/node_modules/@legendapp/spark-global-shortcuts/src/accelerator.ts +0 -22
- package/vendor/node_modules/@legendapp/spark-ui/macos/RNSparkSelect.h +0 -4
- package/vendor/node_modules/@legendapp/spark-ui/macos/RNSparkSelect.mm +0 -53
package/schema.json
CHANGED
|
@@ -11,47 +11,94 @@
|
|
|
11
11
|
"type": "string"
|
|
12
12
|
},
|
|
13
13
|
"name": {
|
|
14
|
-
"type": "string"
|
|
14
|
+
"type": "string",
|
|
15
|
+
"minLength": 1
|
|
15
16
|
},
|
|
16
17
|
"projectId": {
|
|
17
|
-
"type": "string"
|
|
18
|
+
"type": "string",
|
|
19
|
+
"minLength": 1
|
|
18
20
|
},
|
|
19
21
|
"version": {
|
|
20
|
-
"type": "string"
|
|
22
|
+
"type": "string",
|
|
23
|
+
"minLength": 1
|
|
21
24
|
},
|
|
22
25
|
"window": {
|
|
23
26
|
"type": "object",
|
|
24
27
|
"additionalProperties": false,
|
|
25
28
|
"properties": {
|
|
26
|
-
"
|
|
27
|
-
"type": "
|
|
28
|
-
"
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
"
|
|
33
|
-
"
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
29
|
+
"size": {
|
|
30
|
+
"type": "object",
|
|
31
|
+
"required": [
|
|
32
|
+
"width",
|
|
33
|
+
"height"
|
|
34
|
+
],
|
|
35
|
+
"additionalProperties": false,
|
|
36
|
+
"properties": {
|
|
37
|
+
"width": {
|
|
38
|
+
"type": "number",
|
|
39
|
+
"minimum": 100,
|
|
40
|
+
"maximum": 20000
|
|
41
|
+
},
|
|
42
|
+
"height": {
|
|
43
|
+
"type": "number",
|
|
44
|
+
"minimum": 100,
|
|
45
|
+
"maximum": 20000
|
|
46
|
+
}
|
|
47
|
+
}
|
|
45
48
|
},
|
|
46
|
-
"
|
|
47
|
-
"
|
|
48
|
-
|
|
49
|
-
|
|
49
|
+
"minSize": {
|
|
50
|
+
"anyOf": [
|
|
51
|
+
{
|
|
52
|
+
"type": "object",
|
|
53
|
+
"required": [
|
|
54
|
+
"width",
|
|
55
|
+
"height"
|
|
56
|
+
],
|
|
57
|
+
"additionalProperties": false,
|
|
58
|
+
"properties": {
|
|
59
|
+
"width": {
|
|
60
|
+
"type": "number",
|
|
61
|
+
"minimum": 100,
|
|
62
|
+
"maximum": 20000
|
|
63
|
+
},
|
|
64
|
+
"height": {
|
|
65
|
+
"type": "number",
|
|
66
|
+
"minimum": 100,
|
|
67
|
+
"maximum": 20000
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
},
|
|
71
|
+
{
|
|
72
|
+
"type": "null"
|
|
73
|
+
}
|
|
74
|
+
]
|
|
50
75
|
},
|
|
51
|
-
"
|
|
52
|
-
"
|
|
53
|
-
|
|
54
|
-
|
|
76
|
+
"maxSize": {
|
|
77
|
+
"anyOf": [
|
|
78
|
+
{
|
|
79
|
+
"type": "object",
|
|
80
|
+
"required": [
|
|
81
|
+
"width",
|
|
82
|
+
"height"
|
|
83
|
+
],
|
|
84
|
+
"additionalProperties": false,
|
|
85
|
+
"properties": {
|
|
86
|
+
"width": {
|
|
87
|
+
"type": "number",
|
|
88
|
+
"minimum": 100,
|
|
89
|
+
"maximum": 20000
|
|
90
|
+
},
|
|
91
|
+
"height": {
|
|
92
|
+
"type": "number",
|
|
93
|
+
"minimum": 100,
|
|
94
|
+
"maximum": 20000
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
},
|
|
98
|
+
{
|
|
99
|
+
"type": "null"
|
|
100
|
+
}
|
|
101
|
+
]
|
|
55
102
|
},
|
|
56
103
|
"resizable": {
|
|
57
104
|
"type": "boolean"
|
|
@@ -71,10 +118,7 @@
|
|
|
71
118
|
"hasShadow": {
|
|
72
119
|
"type": "boolean"
|
|
73
120
|
},
|
|
74
|
-
"
|
|
75
|
-
"type": "boolean"
|
|
76
|
-
},
|
|
77
|
-
"restoreFrame": {
|
|
121
|
+
"restoreBounds": {
|
|
78
122
|
"type": "boolean"
|
|
79
123
|
},
|
|
80
124
|
"titleBarStyle": {
|
|
@@ -92,21 +136,36 @@
|
|
|
92
136
|
"dark"
|
|
93
137
|
]
|
|
94
138
|
},
|
|
95
|
-
"material": {
|
|
96
|
-
"enum": [
|
|
97
|
-
"none",
|
|
98
|
-
"sidebar",
|
|
99
|
-
"windowBackground",
|
|
100
|
-
"hudWindow",
|
|
101
|
-
"popover"
|
|
102
|
-
]
|
|
103
|
-
},
|
|
104
139
|
"title": {
|
|
105
140
|
"type": "string"
|
|
106
141
|
},
|
|
107
142
|
"backgroundColor": {
|
|
108
143
|
"type": "string",
|
|
109
144
|
"pattern": "^#[0-9a-fA-F]{6}([0-9a-fA-F]{2})?$"
|
|
145
|
+
},
|
|
146
|
+
"macos": {
|
|
147
|
+
"type": "object",
|
|
148
|
+
"additionalProperties": false,
|
|
149
|
+
"properties": {
|
|
150
|
+
"backgroundMaterial": {
|
|
151
|
+
"enum": [
|
|
152
|
+
"none",
|
|
153
|
+
"sidebar",
|
|
154
|
+
"windowBackground",
|
|
155
|
+
"hudWindow",
|
|
156
|
+
"popover"
|
|
157
|
+
]
|
|
158
|
+
},
|
|
159
|
+
"titleBar": {
|
|
160
|
+
"type": "object",
|
|
161
|
+
"additionalProperties": false,
|
|
162
|
+
"properties": {
|
|
163
|
+
"trafficLights": {
|
|
164
|
+
"type": "boolean"
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
}
|
|
110
169
|
}
|
|
111
170
|
}
|
|
112
171
|
},
|
|
@@ -117,7 +176,8 @@
|
|
|
117
176
|
],
|
|
118
177
|
"properties": {
|
|
119
178
|
"bundleIdentifier": {
|
|
120
|
-
"type": "string"
|
|
179
|
+
"type": "string",
|
|
180
|
+
"pattern": "^[A-Za-z0-9-]+(?:\\.[A-Za-z0-9-]+)+$"
|
|
121
181
|
},
|
|
122
182
|
"buildNumber": {
|
|
123
183
|
"type": "string"
|
|
@@ -127,8 +187,92 @@
|
|
|
127
187
|
},
|
|
128
188
|
"infoPlist": {
|
|
129
189
|
"type": "object"
|
|
190
|
+
},
|
|
191
|
+
"lifecycle": {
|
|
192
|
+
"type": "object",
|
|
193
|
+
"additionalProperties": false,
|
|
194
|
+
"properties": {
|
|
195
|
+
"plugins": {
|
|
196
|
+
"type": "array",
|
|
197
|
+
"uniqueItems": true,
|
|
198
|
+
"items": {
|
|
199
|
+
"type": "string",
|
|
200
|
+
"pattern": "^[A-Za-z_][A-Za-z0-9_]*$"
|
|
201
|
+
}
|
|
202
|
+
},
|
|
203
|
+
"mainWindow": {
|
|
204
|
+
"type": "object",
|
|
205
|
+
"additionalProperties": false,
|
|
206
|
+
"properties": {
|
|
207
|
+
"hidden": {
|
|
208
|
+
"type": "boolean"
|
|
209
|
+
},
|
|
210
|
+
"glass": {
|
|
211
|
+
"type": "boolean"
|
|
212
|
+
},
|
|
213
|
+
"autosaveName": {
|
|
214
|
+
"type": "string",
|
|
215
|
+
"minLength": 1
|
|
216
|
+
},
|
|
217
|
+
"closeBehavior": {
|
|
218
|
+
"enum": [
|
|
219
|
+
"close",
|
|
220
|
+
"hide",
|
|
221
|
+
"request"
|
|
222
|
+
]
|
|
223
|
+
},
|
|
224
|
+
"reopenBehavior": {
|
|
225
|
+
"enum": [
|
|
226
|
+
"default",
|
|
227
|
+
"manual",
|
|
228
|
+
"visibleWindows"
|
|
229
|
+
]
|
|
230
|
+
},
|
|
231
|
+
"toolbarStyle": {
|
|
232
|
+
"enum": [
|
|
233
|
+
"unified",
|
|
234
|
+
"expanded"
|
|
235
|
+
]
|
|
236
|
+
},
|
|
237
|
+
"titlebarSeparatorStyle": {
|
|
238
|
+
"enum": [
|
|
239
|
+
"automatic",
|
|
240
|
+
"none",
|
|
241
|
+
"line",
|
|
242
|
+
"shadow"
|
|
243
|
+
]
|
|
244
|
+
},
|
|
245
|
+
"backgroundColors": {
|
|
246
|
+
"type": "object",
|
|
247
|
+
"required": [
|
|
248
|
+
"light",
|
|
249
|
+
"dark"
|
|
250
|
+
],
|
|
251
|
+
"additionalProperties": false,
|
|
252
|
+
"properties": {
|
|
253
|
+
"light": {
|
|
254
|
+
"type": "string",
|
|
255
|
+
"pattern": "^#[0-9a-fA-F]{6}([0-9a-fA-F]{2})?$"
|
|
256
|
+
},
|
|
257
|
+
"dark": {
|
|
258
|
+
"type": "string",
|
|
259
|
+
"pattern": "^#[0-9a-fA-F]{6}([0-9a-fA-F]{2})?$"
|
|
260
|
+
}
|
|
261
|
+
}
|
|
262
|
+
}
|
|
263
|
+
}
|
|
264
|
+
},
|
|
265
|
+
"appearance": {
|
|
266
|
+
"enum": [
|
|
267
|
+
"system",
|
|
268
|
+
"light",
|
|
269
|
+
"dark"
|
|
270
|
+
]
|
|
271
|
+
}
|
|
272
|
+
}
|
|
130
273
|
}
|
|
131
|
-
}
|
|
274
|
+
},
|
|
275
|
+
"additionalProperties": false
|
|
132
276
|
},
|
|
133
277
|
"scheme": {
|
|
134
278
|
"oneOf": [
|
|
@@ -144,7 +288,35 @@
|
|
|
144
288
|
]
|
|
145
289
|
},
|
|
146
290
|
"documentTypes": {
|
|
147
|
-
"type": "array"
|
|
291
|
+
"type": "array",
|
|
292
|
+
"items": {
|
|
293
|
+
"type": "object",
|
|
294
|
+
"required": [
|
|
295
|
+
"name",
|
|
296
|
+
"contentTypes"
|
|
297
|
+
],
|
|
298
|
+
"additionalProperties": false,
|
|
299
|
+
"properties": {
|
|
300
|
+
"name": {
|
|
301
|
+
"type": "string",
|
|
302
|
+
"minLength": 1
|
|
303
|
+
},
|
|
304
|
+
"contentTypes": {
|
|
305
|
+
"type": "array",
|
|
306
|
+
"minItems": 1,
|
|
307
|
+
"items": {
|
|
308
|
+
"type": "string",
|
|
309
|
+
"pattern": "\\."
|
|
310
|
+
}
|
|
311
|
+
},
|
|
312
|
+
"role": {
|
|
313
|
+
"enum": [
|
|
314
|
+
"Editor",
|
|
315
|
+
"Viewer"
|
|
316
|
+
]
|
|
317
|
+
}
|
|
318
|
+
}
|
|
319
|
+
}
|
|
148
320
|
},
|
|
149
321
|
"menuBarOnly": {
|
|
150
322
|
"type": "boolean"
|
|
@@ -160,9 +332,11 @@
|
|
|
160
332
|
"type": "string"
|
|
161
333
|
},
|
|
162
334
|
"publicKey": {
|
|
163
|
-
"type": "string"
|
|
335
|
+
"type": "string",
|
|
336
|
+
"pattern": "^[A-Za-z0-9+/]{43}=$"
|
|
164
337
|
}
|
|
165
|
-
}
|
|
338
|
+
},
|
|
339
|
+
"additionalProperties": false
|
|
166
340
|
},
|
|
167
341
|
"include": {
|
|
168
342
|
"type": "array",
|
|
@@ -212,7 +386,30 @@
|
|
|
212
386
|
}
|
|
213
387
|
},
|
|
214
388
|
"signing": {
|
|
215
|
-
"type": "object"
|
|
389
|
+
"type": "object",
|
|
390
|
+
"additionalProperties": false,
|
|
391
|
+
"properties": {
|
|
392
|
+
"macos": {
|
|
393
|
+
"type": "object",
|
|
394
|
+
"additionalProperties": false,
|
|
395
|
+
"properties": {
|
|
396
|
+
"identity": {
|
|
397
|
+
"type": "string",
|
|
398
|
+
"minLength": 1
|
|
399
|
+
},
|
|
400
|
+
"teamId": {
|
|
401
|
+
"type": "string",
|
|
402
|
+
"minLength": 1
|
|
403
|
+
},
|
|
404
|
+
"entitlementsByPath": {
|
|
405
|
+
"type": "object",
|
|
406
|
+
"additionalProperties": {
|
|
407
|
+
"type": "object"
|
|
408
|
+
}
|
|
409
|
+
}
|
|
410
|
+
}
|
|
411
|
+
}
|
|
412
|
+
}
|
|
216
413
|
},
|
|
217
414
|
"expo": {
|
|
218
415
|
"type": "object"
|
|
@@ -260,19 +457,40 @@
|
|
|
260
457
|
"allOf": [
|
|
261
458
|
{
|
|
262
459
|
"if": {
|
|
263
|
-
"
|
|
264
|
-
|
|
265
|
-
"
|
|
266
|
-
"
|
|
460
|
+
"allOf": [
|
|
461
|
+
{
|
|
462
|
+
"not": {
|
|
463
|
+
"required": [
|
|
464
|
+
"extends"
|
|
465
|
+
]
|
|
466
|
+
}
|
|
467
|
+
},
|
|
468
|
+
{
|
|
469
|
+
"anyOf": [
|
|
470
|
+
{
|
|
471
|
+
"not": {
|
|
472
|
+
"required": [
|
|
473
|
+
"platforms"
|
|
474
|
+
]
|
|
475
|
+
}
|
|
476
|
+
},
|
|
477
|
+
{
|
|
478
|
+
"properties": {
|
|
479
|
+
"platforms": {
|
|
480
|
+
"contains": {
|
|
481
|
+
"const": "macos"
|
|
482
|
+
}
|
|
483
|
+
}
|
|
484
|
+
},
|
|
485
|
+
"required": [
|
|
486
|
+
"platforms"
|
|
487
|
+
]
|
|
488
|
+
}
|
|
267
489
|
]
|
|
268
490
|
}
|
|
269
|
-
},
|
|
270
|
-
"required": [
|
|
271
|
-
"platforms"
|
|
272
491
|
]
|
|
273
492
|
},
|
|
274
|
-
"then": {
|
|
275
|
-
"else": {
|
|
493
|
+
"then": {
|
|
276
494
|
"required": [
|
|
277
495
|
"macos"
|
|
278
496
|
]
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./vendor/node_modules/@legendapp/spark-settings/src/storage/index.ts";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./vendor/node_modules/@legendapp/spark-settings-ui/src/index.tsx";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./vendor/node_modules/@legendapp/spark-commands/src/index.tsx";
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
export { addKeyboardListener, getKeyboardAvailability, hasModifier, createModifierMask, KeyCodes, KeyText } from "./vendor/node_modules/@legendapp/spark-desktop-shortcuts/src/keyboard-manager/index.ts";
|
|
2
|
+
export type { KeyboardEvent, KeyboardEventListener, KeyboardListenerOptions } from "./vendor/node_modules/@legendapp/spark-desktop-shortcuts/src/keyboard-manager/index.ts";
|
|
3
|
+
export type { AsyncRegistration } from "./vendor/node_modules/@legendapp/spark-desktop-shortcuts/src/keyboard-manager/index.ts";
|
package/ui-classnames.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./vendor/node_modules/@legendapp/spark-ui/src/classnames/index.ts";
|
package/ui-glass.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./vendor/node_modules/@legendapp/spark-ui/src/glass-effect-view/index.tsx";
|
package/ui-search.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./vendor/node_modules/@legendapp/spark-ui/src/text-input-search/index.tsx";
|
package/ui-sidebar.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./vendor/node_modules/@legendapp/spark-ui/src/sidebar/index.tsx";
|
package/ui-split-view.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./vendor/node_modules/@legendapp/spark-ui/src/appkit-split-view/index.tsx";
|
package/ui-symbol.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./vendor/node_modules/@legendapp/spark-ui/src/sf-symbol/index.tsx";
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@legendapp/spark-ai",
|
|
3
|
+
"version": "0.0.1-next.3",
|
|
4
|
+
"private": true,
|
|
5
|
+
"main": "src/index.ts",
|
|
6
|
+
"react-native": "src/index.ts",
|
|
7
|
+
"dependencies": {
|
|
8
|
+
"@legendapp/spark-desktop-app": "0.0.1-next.3",
|
|
9
|
+
"@legendapp/spark-processes": "0.0.1-next.3"
|
|
10
|
+
},
|
|
11
|
+
"peerDependencies": {
|
|
12
|
+
"react": "19.1.4",
|
|
13
|
+
"react-native": "0.81.6"
|
|
14
|
+
},
|
|
15
|
+
"license": "MIT",
|
|
16
|
+
"files": [
|
|
17
|
+
"src"
|
|
18
|
+
]
|
|
19
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { resolveCommand, getProcessAvailability } from "@legendapp/spark-processes";
|
|
2
|
+
import { SparkError } from "@legendapp/spark-desktop-app/src/contracts";
|
|
3
|
+
import type { AIAvailabilityOptions, AICommandAvailability, AIToolId } from "./types";
|
|
4
|
+
export function selectPreferredAITool(availability: Pick<AICommandAvailability, "claude" | "codex">, options: AIAvailabilityOptions = {}): AIToolId | null {
|
|
5
|
+
if (!options || typeof options !== "object" || Array.isArray(options)) throw new SparkError("E_INVALID_ARGUMENT", "Expected AI availability options");
|
|
6
|
+
for (const key of Object.keys(options)) if (key !== "preferredTool") throw new SparkError("E_UNSUPPORTED_OPTION", `Unknown availability option: ${key}`);
|
|
7
|
+
if (options.preferredTool !== undefined && !["claude", "codex"].includes(options.preferredTool)) throw new SparkError("E_INVALID_ARGUMENT", "Unknown preferred AI tool");
|
|
8
|
+
if (options.preferredTool && availability[options.preferredTool]) return options.preferredTool;
|
|
9
|
+
return availability.claude ? "claude" : availability.codex ? "codex" : null;
|
|
10
|
+
}
|
|
11
|
+
export async function getAICommandAvailability(options: AIAvailabilityOptions = {}): Promise<AICommandAvailability> {
|
|
12
|
+
selectPreferredAITool({ claude: false, codex: false }, options);
|
|
13
|
+
if (!getProcessAvailability().available) return { claude: false, codex: false, preferredTool: null };
|
|
14
|
+
const [claude, codex] = await Promise.all([resolveCommand("claude"), resolveCommand("codex")]);
|
|
15
|
+
const result = { claude: claude !== null, codex: codex !== null };
|
|
16
|
+
return { ...result, preferredTool: selectPreferredAITool(result, options) };
|
|
17
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export { getAICommandAvailability, selectPreferredAITool } from "./availability";
|
|
2
|
+
export { buildAIInvocation } from "./invocations";
|
|
3
|
+
export { extractJsonCandidate, formatAIErrorOutput, parseAIJson } from "./output";
|
|
4
|
+
export { runAITool } from "./run";
|
|
5
|
+
export type {
|
|
6
|
+
AIAvailabilityOptions,
|
|
7
|
+
AICommandAvailability,
|
|
8
|
+
AICodexInvocationOptions,
|
|
9
|
+
AIInvocation,
|
|
10
|
+
AIInvocationOptions,
|
|
11
|
+
AIToolId,
|
|
12
|
+
AIToolRunResult,
|
|
13
|
+
RunAIToolOptions,
|
|
14
|
+
} from "./types";
|
|
15
|
+
export type { AIErrorOutputOptions } from "./output";
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { SparkError } from "@legendapp/spark-desktop-app/src/contracts";
|
|
2
|
+
import type { AIInvocation, AIInvocationOptions, AIToolId } from "./types";
|
|
3
|
+
|
|
4
|
+
const defaultCodexReasoningEffort = "low";
|
|
5
|
+
|
|
6
|
+
export function buildAIInvocation(tool: AIToolId, prompt: string, options: AIInvocationOptions = {}): AIInvocation {
|
|
7
|
+
if (!["claude", "codex"].includes(tool) || typeof prompt !== "string" || !prompt.trim() || prompt.includes("\0")) throw new SparkError("E_INVALID_ARGUMENT", "Expected an AI tool and nonempty prompt");
|
|
8
|
+
if (!options || typeof options !== "object" || Array.isArray(options)) throw new SparkError("E_INVALID_ARGUMENT", "Expected invocation options");
|
|
9
|
+
for (const key of Object.keys(options)) if (key !== "codex") throw new SparkError("E_UNSUPPORTED_OPTION", `Unknown invocation option: ${key}`);
|
|
10
|
+
if (options.codex !== undefined) {
|
|
11
|
+
if (!options.codex || typeof options.codex !== "object" || Array.isArray(options.codex)) throw new SparkError("E_INVALID_ARGUMENT", "Expected Codex invocation options");
|
|
12
|
+
for (const key of Object.keys(options.codex)) if (!["model", "reasoningEffort"].includes(key)) throw new SparkError("E_UNSUPPORTED_OPTION", `Unknown Codex option: ${key}`);
|
|
13
|
+
if (options.codex.model !== undefined && (typeof options.codex.model !== "string" || !options.codex.model.trim() || /[\0\r\n]/.test(options.codex.model))) throw new SparkError("E_INVALID_ARGUMENT", "Expected a model name");
|
|
14
|
+
if (options.codex.reasoningEffort !== undefined && !["minimal", "low", "medium", "high", "xhigh"].includes(options.codex.reasoningEffort)) throw new SparkError("E_INVALID_ARGUMENT", "Unknown reasoning effort");
|
|
15
|
+
if (tool !== "codex") throw new SparkError("E_UNSUPPORTED_OPTION", "Codex options require the Codex tool");
|
|
16
|
+
}
|
|
17
|
+
if (tool === "codex") {
|
|
18
|
+
const model = options.codex?.model;
|
|
19
|
+
const reasoningEffort = options.codex?.reasoningEffort ?? defaultCodexReasoningEffort;
|
|
20
|
+
const args: string[] = ["exec", "--ephemeral", "--ignore-user-config", "--ignore-rules", "--skip-git-repo-check"];
|
|
21
|
+
if (model) {
|
|
22
|
+
args.push("--model", model);
|
|
23
|
+
}
|
|
24
|
+
args.push("--config", `model_reasoning_effort=${reasoningEffort}`, "-");
|
|
25
|
+
|
|
26
|
+
return {
|
|
27
|
+
command: "codex",
|
|
28
|
+
args,
|
|
29
|
+
input: prompt,
|
|
30
|
+
};
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
return { command: "claude", args: ["-p", prompt] };
|
|
34
|
+
}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import { SparkError } from "@legendapp/spark-desktop-app/src/contracts";
|
|
2
|
+
export interface AIErrorOutputOptions { maxLength?: number }
|
|
3
|
+
const defaultMaxErrorOutputLength = 300;
|
|
4
|
+
|
|
5
|
+
export function extractJsonCandidate(text: string): string | null {
|
|
6
|
+
if (typeof text !== "string") throw new SparkError("E_INVALID_ARGUMENT", "Expected AI output text");
|
|
7
|
+
const fenced = text.match(/```(?:json)?\s*([\s\S]*?)```/i);
|
|
8
|
+
if (fenced?.[1]) {
|
|
9
|
+
return fenced[1].trim();
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
const trimmed = text.trim();
|
|
13
|
+
if (!trimmed) {
|
|
14
|
+
return null;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
if (trimmed.startsWith("{") || trimmed.startsWith("[")) {
|
|
18
|
+
return trimmed;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
const firstBrace = trimmed.search(/[[{]/);
|
|
22
|
+
if (firstBrace === -1) {
|
|
23
|
+
return null;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
const open = trimmed[firstBrace];
|
|
27
|
+
const close = open === "{" ? "}" : "]";
|
|
28
|
+
const lastBrace = trimmed.lastIndexOf(close);
|
|
29
|
+
if (lastBrace <= firstBrace) {
|
|
30
|
+
return null;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
return trimmed.slice(firstBrace, lastBrace + 1);
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
export function parseAIJson(text: string): unknown {
|
|
37
|
+
const candidate = extractJsonCandidate(text);
|
|
38
|
+
if (!candidate) {
|
|
39
|
+
return null;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
try {
|
|
43
|
+
return JSON.parse(candidate);
|
|
44
|
+
} catch {
|
|
45
|
+
return null;
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export function formatAIErrorOutput(output: string, options: AIErrorOutputOptions = {}): string {
|
|
50
|
+
if (typeof output !== "string" || !options || typeof options !== "object" || Array.isArray(options)) throw new SparkError("E_INVALID_ARGUMENT", "Expected output text and preview options");
|
|
51
|
+
for (const key of Object.keys(options)) if (key !== "maxLength") throw new SparkError("E_UNSUPPORTED_OPTION", `Unknown preview option: ${key}`);
|
|
52
|
+
const maxLength = options.maxLength ?? defaultMaxErrorOutputLength;
|
|
53
|
+
if (!Number.isInteger(maxLength) || maxLength < 1) throw new SparkError("E_INVALID_ARGUMENT", "maxLength must be a positive integer");
|
|
54
|
+
const trimmed = output.trim();
|
|
55
|
+
if (!trimmed) {
|
|
56
|
+
return "";
|
|
57
|
+
}
|
|
58
|
+
if (trimmed.length <= maxLength) {
|
|
59
|
+
return trimmed;
|
|
60
|
+
}
|
|
61
|
+
return `${trimmed.slice(0, maxLength).trim()}...`;
|
|
62
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { runCommand } from "@legendapp/spark-processes";
|
|
2
|
+
import { SparkError } from "@legendapp/spark-desktop-app/src/contracts";
|
|
3
|
+
import { buildAIInvocation } from "./invocations";
|
|
4
|
+
import type { AIToolRunResult, RunAIToolOptions } from "./types";
|
|
5
|
+
export async function runAITool(options: RunAIToolOptions): Promise<AIToolRunResult> {
|
|
6
|
+
if (!options || typeof options !== "object" || Array.isArray(options)) throw new SparkError("E_INVALID_ARGUMENT", "Expected AI run options");
|
|
7
|
+
for (const key of Object.keys(options)) if (!["prompt", "tool", "timeoutMs", "signal", "cwd", "invocationOptions"].includes(key)) throw new SparkError("E_UNSUPPORTED_OPTION", `Unknown AI run option: ${key}`);
|
|
8
|
+
const invocation = buildAIInvocation(options.tool, options.prompt, options.invocationOptions);
|
|
9
|
+
const result = await runCommand({ target: { type: "command", name: invocation.command }, args: invocation.args, input: invocation.input, timeoutMs: options.timeoutMs, signal: options.signal, cwd: options.cwd });
|
|
10
|
+
const decoder = new TextDecoder();
|
|
11
|
+
return { ...result, output: decoder.decode(result.stdout).trim() || decoder.decode(result.stderr).trim(), tool: options.tool };
|
|
12
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { ProcessResult } from "@legendapp/spark-processes";
|
|
2
|
+
export type AIToolId = "claude" | "codex";
|
|
3
|
+
export interface AICommandAvailability { claude: boolean; codex: boolean; preferredTool: AIToolId | null }
|
|
4
|
+
export interface AIAvailabilityOptions { preferredTool?: AIToolId }
|
|
5
|
+
export interface AIInvocation { command: string; args: readonly string[]; input?: string }
|
|
6
|
+
export interface AICodexInvocationOptions { model?: string; reasoningEffort?: "minimal" | "low" | "medium" | "high" | "xhigh" }
|
|
7
|
+
export interface AIInvocationOptions { codex?: AICodexInvocationOptions }
|
|
8
|
+
export interface RunAIToolOptions {
|
|
9
|
+
prompt: string;
|
|
10
|
+
tool: AIToolId;
|
|
11
|
+
timeoutMs?: number;
|
|
12
|
+
signal?: AbortSignal;
|
|
13
|
+
cwd?: string;
|
|
14
|
+
invocationOptions?: AIInvocationOptions;
|
|
15
|
+
}
|
|
16
|
+
export type AIToolRunResult = ProcessResult & { output: string; tool: AIToolId };
|