@intentcomputing/koko-agent-sdk 1.0.1
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/CHANGELOG.md +10 -0
- package/CODE_OF_CONDUCT.md +3 -0
- package/CONTRIBUTING.md +9 -0
- package/LICENSE +21 -0
- package/README.md +65 -0
- package/README.zh-CN.md +50 -0
- package/SECURITY.md +5 -0
- package/android/build.gradle +40 -0
- package/android/src/main/AndroidManifest.xml +2 -0
- package/android/src/main/java/cn/intentcomputing/kokoagentsdk/KokoAgentSdkModule.java +1356 -0
- package/android/src/main/java/cn/intentcomputing/kokoagentsdk/KokoAgentSdkPackage.java +23 -0
- package/docs/INTEGRATION.md +168 -0
- package/docs/INTEGRATION.zh-CN.md +140 -0
- package/docs/PRIVACY.md +11 -0
- package/docs/PRIVACY.zh-CN.md +11 -0
- package/docs/PUBLISH.md +11 -0
- package/docs/PUBLISH.zh-CN.md +11 -0
- package/ios/KokoAgentSdk/KokoAgentSdk.h +5 -0
- package/ios/KokoAgentSdk/KokoAgentSdk.m +2464 -0
- package/ios/KokoAgentSdk/KokoOcrBounds.h +20 -0
- package/ios/KokoAgentSdk/KokoScrollBounds.h +21 -0
- package/koko-agent-sdk.podspec +23 -0
- package/lib/commonjs/KokoAgent.js +1427 -0
- package/lib/commonjs/KokoAgent.js.map +1 -0
- package/lib/commonjs/assist/OnDeviceAssist.js +94 -0
- package/lib/commonjs/assist/OnDeviceAssist.js.map +1 -0
- package/lib/commonjs/assist/intentClassify.js +100 -0
- package/lib/commonjs/assist/intentClassify.js.map +1 -0
- package/lib/commonjs/assist/nodeRank.js +120 -0
- package/lib/commonjs/assist/nodeRank.js.map +1 -0
- package/lib/commonjs/assist/ocrTarget.js +135 -0
- package/lib/commonjs/assist/ocrTarget.js.map +1 -0
- package/lib/commonjs/assist/webVisualChange.js +29 -0
- package/lib/commonjs/assist/webVisualChange.js.map +1 -0
- package/lib/commonjs/client/ActionOutcomeUnknownError.js +28 -0
- package/lib/commonjs/client/ActionOutcomeUnknownError.js.map +1 -0
- package/lib/commonjs/client/AgentSession.js +858 -0
- package/lib/commonjs/client/AgentSession.js.map +1 -0
- package/lib/commonjs/client/GatewayClient.js +302 -0
- package/lib/commonjs/client/GatewayClient.js.map +1 -0
- package/lib/commonjs/client/OperationReplayGuard.js +62 -0
- package/lib/commonjs/client/OperationReplayGuard.js.map +1 -0
- package/lib/commonjs/client/RunCheckpoint.js +139 -0
- package/lib/commonjs/client/RunCheckpoint.js.map +1 -0
- package/lib/commonjs/client/loopDetect.js +184 -0
- package/lib/commonjs/client/loopDetect.js.map +1 -0
- package/lib/commonjs/client/recentSearch.js +50 -0
- package/lib/commonjs/client/recentSearch.js.map +1 -0
- package/lib/commonjs/client/walletChoiceGuard.js +18 -0
- package/lib/commonjs/client/walletChoiceGuard.js.map +1 -0
- package/lib/commonjs/client/webResultCategory.js +38 -0
- package/lib/commonjs/client/webResultCategory.js.map +1 -0
- package/lib/commonjs/commercial/AccountStore.js +78 -0
- package/lib/commonjs/commercial/AccountStore.js.map +1 -0
- package/lib/commonjs/commercial/AgentDebug.js +104 -0
- package/lib/commonjs/commercial/AgentDebug.js.map +1 -0
- package/lib/commonjs/commercial/ExecutionGuard.js +53 -0
- package/lib/commonjs/commercial/ExecutionGuard.js.map +1 -0
- package/lib/commonjs/commercial/UsageBus.js +42 -0
- package/lib/commonjs/commercial/UsageBus.js.map +1 -0
- package/lib/commonjs/commercial/branding.js +69 -0
- package/lib/commonjs/commercial/branding.js.map +1 -0
- package/lib/commonjs/commercial/devMode.js +52 -0
- package/lib/commonjs/commercial/devMode.js.map +1 -0
- package/lib/commonjs/commercial/trust.js +69 -0
- package/lib/commonjs/commercial/trust.js.map +1 -0
- package/lib/commonjs/confirmation/gate.js +62 -0
- package/lib/commonjs/confirmation/gate.js.map +1 -0
- package/lib/commonjs/cursor/CursorOverlay.js +141 -0
- package/lib/commonjs/cursor/CursorOverlay.js.map +1 -0
- package/lib/commonjs/cursor/PointerHand.js +51 -0
- package/lib/commonjs/cursor/PointerHand.js.map +1 -0
- package/lib/commonjs/cursor/controller.js +91 -0
- package/lib/commonjs/cursor/controller.js.map +1 -0
- package/lib/commonjs/cursor/pointer.js +49 -0
- package/lib/commonjs/cursor/pointer.js.map +1 -0
- package/lib/commonjs/debug/KokoRemoteSmoke.js +611 -0
- package/lib/commonjs/debug/KokoRemoteSmoke.js.map +1 -0
- package/lib/commonjs/explore/ExplorationGraph.js +418 -0
- package/lib/commonjs/explore/ExplorationGraph.js.map +1 -0
- package/lib/commonjs/explore/bootstrapExplore.js +59 -0
- package/lib/commonjs/explore/bootstrapExplore.js.map +1 -0
- package/lib/commonjs/host/HostActions.js +266 -0
- package/lib/commonjs/host/HostActions.js.map +1 -0
- package/lib/commonjs/i18n/index.js +169 -0
- package/lib/commonjs/i18n/index.js.map +1 -0
- package/lib/commonjs/i18n/runtimeMessages.js +184 -0
- package/lib/commonjs/i18n/runtimeMessages.js.map +1 -0
- package/lib/commonjs/index.js +640 -0
- package/lib/commonjs/index.js.map +1 -0
- package/lib/commonjs/native/NativeBridge.js +132 -0
- package/lib/commonjs/native/NativeBridge.js.map +1 -0
- package/lib/commonjs/native/navigationLabel.js +16 -0
- package/lib/commonjs/native/navigationLabel.js.map +1 -0
- package/lib/commonjs/native/normalizeViewTree.js +28 -0
- package/lib/commonjs/native/normalizeViewTree.js.map +1 -0
- package/lib/commonjs/native/pruneOffscreen.js +76 -0
- package/lib/commonjs/native/pruneOffscreen.js.map +1 -0
- package/lib/commonjs/native/scrollViewport.js +69 -0
- package/lib/commonjs/native/scrollViewport.js.map +1 -0
- package/lib/commonjs/package.json +1 -0
- package/lib/commonjs/privacy/redact.js +108 -0
- package/lib/commonjs/privacy/redact.js.map +1 -0
- package/lib/commonjs/privacy/screenEvidence.js +59 -0
- package/lib/commonjs/privacy/screenEvidence.js.map +1 -0
- package/lib/commonjs/privacy/screenModel.js +404 -0
- package/lib/commonjs/privacy/screenModel.js.map +1 -0
- package/lib/commonjs/privacy/sensitiveScreen.js +58 -0
- package/lib/commonjs/privacy/sensitiveScreen.js.map +1 -0
- package/lib/commonjs/privacy/userGate.js +213 -0
- package/lib/commonjs/privacy/userGate.js.map +1 -0
- package/lib/commonjs/protocol/actions.js +112 -0
- package/lib/commonjs/protocol/actions.js.map +1 -0
- package/lib/commonjs/provider/HostAppearanceStore.js +111 -0
- package/lib/commonjs/provider/HostAppearanceStore.js.map +1 -0
- package/lib/commonjs/provider/KokoProvider.js +81 -0
- package/lib/commonjs/provider/KokoProvider.js.map +1 -0
- package/lib/commonjs/provider/KokoUiContext.js +102 -0
- package/lib/commonjs/provider/KokoUiContext.js.map +1 -0
- package/lib/commonjs/selector/match.js +378 -0
- package/lib/commonjs/selector/match.js.map +1 -0
- package/lib/commonjs/task/TaskStore.js +361 -0
- package/lib/commonjs/task/TaskStore.js.map +1 -0
- package/lib/commonjs/task/types.js +2 -0
- package/lib/commonjs/task/types.js.map +1 -0
- package/lib/commonjs/task/useTaskStore.js +14 -0
- package/lib/commonjs/task/useTaskStore.js.map +1 -0
- package/lib/commonjs/types.js +2 -0
- package/lib/commonjs/types.js.map +1 -0
- package/lib/commonjs/ui/KokoChatSheet.js +885 -0
- package/lib/commonjs/ui/KokoChatSheet.js.map +1 -0
- package/lib/commonjs/ui/KokoComposer.js +161 -0
- package/lib/commonjs/ui/KokoComposer.js.map +1 -0
- package/lib/commonjs/ui/KokoDialogHost.js +254 -0
- package/lib/commonjs/ui/KokoDialogHost.js.map +1 -0
- package/lib/commonjs/ui/KokoEntryButton.js +81 -0
- package/lib/commonjs/ui/KokoEntryButton.js.map +1 -0
- package/lib/commonjs/ui/KokoObserver.js +522 -0
- package/lib/commonjs/ui/KokoObserver.js.map +1 -0
- package/lib/commonjs/ui/KokoOverlayLayer.js +45 -0
- package/lib/commonjs/ui/KokoOverlayLayer.js.map +1 -0
- package/lib/commonjs/ui/KokoSubtitle.js +95 -0
- package/lib/commonjs/ui/KokoSubtitle.js.map +1 -0
- package/lib/commonjs/ui/KokoTaskPanel.js +322 -0
- package/lib/commonjs/ui/KokoTaskPanel.js.map +1 -0
- package/lib/commonjs/ui/hostOverlay.js +126 -0
- package/lib/commonjs/ui/hostOverlay.js.map +1 -0
- package/lib/commonjs/ui/icons.js +132 -0
- package/lib/commonjs/ui/icons.js.map +1 -0
- package/lib/commonjs/ui/progressChrome.js +66 -0
- package/lib/commonjs/ui/progressChrome.js.map +1 -0
- package/lib/commonjs/ui/safeArea.js +96 -0
- package/lib/commonjs/ui/safeArea.js.map +1 -0
- package/lib/commonjs/ui/useOverlayOrigin.js +40 -0
- package/lib/commonjs/ui/useOverlayOrigin.js.map +1 -0
- package/lib/module/KokoAgent.js +1418 -0
- package/lib/module/KokoAgent.js.map +1 -0
- package/lib/module/assist/OnDeviceAssist.js +89 -0
- package/lib/module/assist/OnDeviceAssist.js.map +1 -0
- package/lib/module/assist/intentClassify.js +95 -0
- package/lib/module/assist/intentClassify.js.map +1 -0
- package/lib/module/assist/nodeRank.js +115 -0
- package/lib/module/assist/nodeRank.js.map +1 -0
- package/lib/module/assist/ocrTarget.js +123 -0
- package/lib/module/assist/ocrTarget.js.map +1 -0
- package/lib/module/assist/webVisualChange.js +24 -0
- package/lib/module/assist/webVisualChange.js.map +1 -0
- package/lib/module/client/ActionOutcomeUnknownError.js +23 -0
- package/lib/module/client/ActionOutcomeUnknownError.js.map +1 -0
- package/lib/module/client/AgentSession.js +854 -0
- package/lib/module/client/AgentSession.js.map +1 -0
- package/lib/module/client/GatewayClient.js +293 -0
- package/lib/module/client/GatewayClient.js.map +1 -0
- package/lib/module/client/OperationReplayGuard.js +58 -0
- package/lib/module/client/OperationReplayGuard.js.map +1 -0
- package/lib/module/client/RunCheckpoint.js +135 -0
- package/lib/module/client/RunCheckpoint.js.map +1 -0
- package/lib/module/client/loopDetect.js +177 -0
- package/lib/module/client/loopDetect.js.map +1 -0
- package/lib/module/client/recentSearch.js +46 -0
- package/lib/module/client/recentSearch.js.map +1 -0
- package/lib/module/client/walletChoiceGuard.js +14 -0
- package/lib/module/client/walletChoiceGuard.js.map +1 -0
- package/lib/module/client/webResultCategory.js +34 -0
- package/lib/module/client/webResultCategory.js.map +1 -0
- package/lib/module/commercial/AccountStore.js +75 -0
- package/lib/module/commercial/AccountStore.js.map +1 -0
- package/lib/module/commercial/AgentDebug.js +99 -0
- package/lib/module/commercial/AgentDebug.js.map +1 -0
- package/lib/module/commercial/ExecutionGuard.js +49 -0
- package/lib/module/commercial/ExecutionGuard.js.map +1 -0
- package/lib/module/commercial/UsageBus.js +38 -0
- package/lib/module/commercial/UsageBus.js.map +1 -0
- package/lib/module/commercial/branding.js +63 -0
- package/lib/module/commercial/branding.js.map +1 -0
- package/lib/module/commercial/devMode.js +45 -0
- package/lib/module/commercial/devMode.js.map +1 -0
- package/lib/module/commercial/trust.js +62 -0
- package/lib/module/commercial/trust.js.map +1 -0
- package/lib/module/confirmation/gate.js +54 -0
- package/lib/module/confirmation/gate.js.map +1 -0
- package/lib/module/cursor/CursorOverlay.js +136 -0
- package/lib/module/cursor/CursorOverlay.js.map +1 -0
- package/lib/module/cursor/PointerHand.js +47 -0
- package/lib/module/cursor/PointerHand.js.map +1 -0
- package/lib/module/cursor/controller.js +87 -0
- package/lib/module/cursor/controller.js.map +1 -0
- package/lib/module/cursor/pointer.js +45 -0
- package/lib/module/cursor/pointer.js.map +1 -0
- package/lib/module/debug/KokoRemoteSmoke.js +608 -0
- package/lib/module/debug/KokoRemoteSmoke.js.map +1 -0
- package/lib/module/explore/ExplorationGraph.js +406 -0
- package/lib/module/explore/ExplorationGraph.js.map +1 -0
- package/lib/module/explore/bootstrapExplore.js +55 -0
- package/lib/module/explore/bootstrapExplore.js.map +1 -0
- package/lib/module/host/HostActions.js +255 -0
- package/lib/module/host/HostActions.js.map +1 -0
- package/lib/module/i18n/index.js +159 -0
- package/lib/module/i18n/index.js.map +1 -0
- package/lib/module/i18n/runtimeMessages.js +180 -0
- package/lib/module/i18n/runtimeMessages.js.map +1 -0
- package/lib/module/index.js +44 -0
- package/lib/module/index.js.map +1 -0
- package/lib/module/native/NativeBridge.js +128 -0
- package/lib/module/native/NativeBridge.js.map +1 -0
- package/lib/module/native/navigationLabel.js +12 -0
- package/lib/module/native/navigationLabel.js.map +1 -0
- package/lib/module/native/normalizeViewTree.js +25 -0
- package/lib/module/native/normalizeViewTree.js.map +1 -0
- package/lib/module/native/pruneOffscreen.js +72 -0
- package/lib/module/native/pruneOffscreen.js.map +1 -0
- package/lib/module/native/scrollViewport.js +63 -0
- package/lib/module/native/scrollViewport.js.map +1 -0
- package/lib/module/package.json +1 -0
- package/lib/module/privacy/redact.js +103 -0
- package/lib/module/privacy/redact.js.map +1 -0
- package/lib/module/privacy/screenEvidence.js +50 -0
- package/lib/module/privacy/screenEvidence.js.map +1 -0
- package/lib/module/privacy/screenModel.js +397 -0
- package/lib/module/privacy/screenModel.js.map +1 -0
- package/lib/module/privacy/sensitiveScreen.js +52 -0
- package/lib/module/privacy/sensitiveScreen.js.map +1 -0
- package/lib/module/privacy/userGate.js +202 -0
- package/lib/module/privacy/userGate.js.map +1 -0
- package/lib/module/protocol/actions.js +108 -0
- package/lib/module/protocol/actions.js.map +1 -0
- package/lib/module/provider/HostAppearanceStore.js +101 -0
- package/lib/module/provider/HostAppearanceStore.js.map +1 -0
- package/lib/module/provider/KokoProvider.js +74 -0
- package/lib/module/provider/KokoProvider.js.map +1 -0
- package/lib/module/provider/KokoUiContext.js +96 -0
- package/lib/module/provider/KokoUiContext.js.map +1 -0
- package/lib/module/selector/match.js +366 -0
- package/lib/module/selector/match.js.map +1 -0
- package/lib/module/task/TaskStore.js +356 -0
- package/lib/module/task/TaskStore.js.map +1 -0
- package/lib/module/task/types.js +2 -0
- package/lib/module/task/types.js.map +1 -0
- package/lib/module/task/useTaskStore.js +10 -0
- package/lib/module/task/useTaskStore.js.map +1 -0
- package/lib/module/types.js +2 -0
- package/lib/module/types.js.map +1 -0
- package/lib/module/ui/KokoChatSheet.js +879 -0
- package/lib/module/ui/KokoChatSheet.js.map +1 -0
- package/lib/module/ui/KokoComposer.js +155 -0
- package/lib/module/ui/KokoComposer.js.map +1 -0
- package/lib/module/ui/KokoDialogHost.js +247 -0
- package/lib/module/ui/KokoDialogHost.js.map +1 -0
- package/lib/module/ui/KokoEntryButton.js +74 -0
- package/lib/module/ui/KokoEntryButton.js.map +1 -0
- package/lib/module/ui/KokoObserver.js +516 -0
- package/lib/module/ui/KokoObserver.js.map +1 -0
- package/lib/module/ui/KokoOverlayLayer.js +39 -0
- package/lib/module/ui/KokoOverlayLayer.js.map +1 -0
- package/lib/module/ui/KokoSubtitle.js +90 -0
- package/lib/module/ui/KokoSubtitle.js.map +1 -0
- package/lib/module/ui/KokoTaskPanel.js +316 -0
- package/lib/module/ui/KokoTaskPanel.js.map +1 -0
- package/lib/module/ui/hostOverlay.js +120 -0
- package/lib/module/ui/hostOverlay.js.map +1 -0
- package/lib/module/ui/icons.js +124 -0
- package/lib/module/ui/icons.js.map +1 -0
- package/lib/module/ui/progressChrome.js +58 -0
- package/lib/module/ui/progressChrome.js.map +1 -0
- package/lib/module/ui/safeArea.js +92 -0
- package/lib/module/ui/safeArea.js.map +1 -0
- package/lib/module/ui/useOverlayOrigin.js +36 -0
- package/lib/module/ui/useOverlayOrigin.js.map +1 -0
- package/lib/typescript/commonjs/KokoAgent.d.ts +167 -0
- package/lib/typescript/commonjs/KokoAgent.d.ts.map +1 -0
- package/lib/typescript/commonjs/assist/OnDeviceAssist.d.ts +31 -0
- package/lib/typescript/commonjs/assist/OnDeviceAssist.d.ts.map +1 -0
- package/lib/typescript/commonjs/assist/intentClassify.d.ts +18 -0
- package/lib/typescript/commonjs/assist/intentClassify.d.ts.map +1 -0
- package/lib/typescript/commonjs/assist/nodeRank.d.ts +32 -0
- package/lib/typescript/commonjs/assist/nodeRank.d.ts.map +1 -0
- package/lib/typescript/commonjs/assist/ocrTarget.d.ts +25 -0
- package/lib/typescript/commonjs/assist/ocrTarget.d.ts.map +1 -0
- package/lib/typescript/commonjs/assist/webVisualChange.d.ts +6 -0
- package/lib/typescript/commonjs/assist/webVisualChange.d.ts.map +1 -0
- package/lib/typescript/commonjs/client/ActionOutcomeUnknownError.d.ts +13 -0
- package/lib/typescript/commonjs/client/ActionOutcomeUnknownError.d.ts.map +1 -0
- package/lib/typescript/commonjs/client/AgentSession.d.ts +56 -0
- package/lib/typescript/commonjs/client/AgentSession.d.ts.map +1 -0
- package/lib/typescript/commonjs/client/GatewayClient.d.ts +149 -0
- package/lib/typescript/commonjs/client/GatewayClient.d.ts.map +1 -0
- package/lib/typescript/commonjs/client/OperationReplayGuard.d.ts +13 -0
- package/lib/typescript/commonjs/client/OperationReplayGuard.d.ts.map +1 -0
- package/lib/typescript/commonjs/client/RunCheckpoint.d.ts +57 -0
- package/lib/typescript/commonjs/client/RunCheckpoint.d.ts.map +1 -0
- package/lib/typescript/commonjs/client/loopDetect.d.ts +15 -0
- package/lib/typescript/commonjs/client/loopDetect.d.ts.map +1 -0
- package/lib/typescript/commonjs/client/recentSearch.d.ts +5 -0
- package/lib/typescript/commonjs/client/recentSearch.d.ts.map +1 -0
- package/lib/typescript/commonjs/client/walletChoiceGuard.d.ts +4 -0
- package/lib/typescript/commonjs/client/walletChoiceGuard.d.ts.map +1 -0
- package/lib/typescript/commonjs/client/webResultCategory.d.ts +5 -0
- package/lib/typescript/commonjs/client/webResultCategory.d.ts.map +1 -0
- package/lib/typescript/commonjs/commercial/AccountStore.d.ts +17 -0
- package/lib/typescript/commonjs/commercial/AccountStore.d.ts.map +1 -0
- package/lib/typescript/commonjs/commercial/AgentDebug.d.ts +25 -0
- package/lib/typescript/commonjs/commercial/AgentDebug.d.ts.map +1 -0
- package/lib/typescript/commonjs/commercial/ExecutionGuard.d.ts +18 -0
- package/lib/typescript/commonjs/commercial/ExecutionGuard.d.ts.map +1 -0
- package/lib/typescript/commonjs/commercial/UsageBus.d.ts +18 -0
- package/lib/typescript/commonjs/commercial/UsageBus.d.ts.map +1 -0
- package/lib/typescript/commonjs/commercial/branding.d.ts +25 -0
- package/lib/typescript/commonjs/commercial/branding.d.ts.map +1 -0
- package/lib/typescript/commonjs/commercial/devMode.d.ts +26 -0
- package/lib/typescript/commonjs/commercial/devMode.d.ts.map +1 -0
- package/lib/typescript/commonjs/commercial/trust.d.ts +21 -0
- package/lib/typescript/commonjs/commercial/trust.d.ts.map +1 -0
- package/lib/typescript/commonjs/confirmation/gate.d.ts +18 -0
- package/lib/typescript/commonjs/confirmation/gate.d.ts.map +1 -0
- package/lib/typescript/commonjs/cursor/CursorOverlay.d.ts +13 -0
- package/lib/typescript/commonjs/cursor/CursorOverlay.d.ts.map +1 -0
- package/lib/typescript/commonjs/cursor/PointerHand.d.ts +16 -0
- package/lib/typescript/commonjs/cursor/PointerHand.d.ts.map +1 -0
- package/lib/typescript/commonjs/cursor/controller.d.ts +30 -0
- package/lib/typescript/commonjs/cursor/controller.d.ts.map +1 -0
- package/lib/typescript/commonjs/cursor/pointer.d.ts +23 -0
- package/lib/typescript/commonjs/cursor/pointer.d.ts.map +1 -0
- package/lib/typescript/commonjs/debug/KokoRemoteSmoke.d.ts +96 -0
- package/lib/typescript/commonjs/debug/KokoRemoteSmoke.d.ts.map +1 -0
- package/lib/typescript/commonjs/explore/ExplorationGraph.d.ts +96 -0
- package/lib/typescript/commonjs/explore/ExplorationGraph.d.ts.map +1 -0
- package/lib/typescript/commonjs/explore/bootstrapExplore.d.ts +40 -0
- package/lib/typescript/commonjs/explore/bootstrapExplore.d.ts.map +1 -0
- package/lib/typescript/commonjs/host/HostActions.d.ts +101 -0
- package/lib/typescript/commonjs/host/HostActions.d.ts.map +1 -0
- package/lib/typescript/commonjs/i18n/index.d.ts +20 -0
- package/lib/typescript/commonjs/i18n/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/i18n/runtimeMessages.d.ts +178 -0
- package/lib/typescript/commonjs/i18n/runtimeMessages.d.ts.map +1 -0
- package/lib/typescript/commonjs/index.d.ts +66 -0
- package/lib/typescript/commonjs/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/native/NativeBridge.d.ts +70 -0
- package/lib/typescript/commonjs/native/NativeBridge.d.ts.map +1 -0
- package/lib/typescript/commonjs/native/navigationLabel.d.ts +4 -0
- package/lib/typescript/commonjs/native/navigationLabel.d.ts.map +1 -0
- package/lib/typescript/commonjs/native/normalizeViewTree.d.ts +4 -0
- package/lib/typescript/commonjs/native/normalizeViewTree.d.ts.map +1 -0
- package/lib/typescript/commonjs/native/pruneOffscreen.d.ts +3 -0
- package/lib/typescript/commonjs/native/pruneOffscreen.d.ts.map +1 -0
- package/lib/typescript/commonjs/native/scrollViewport.d.ts +13 -0
- package/lib/typescript/commonjs/native/scrollViewport.d.ts.map +1 -0
- package/lib/typescript/commonjs/package.json +1 -0
- package/lib/typescript/commonjs/privacy/redact.d.ts +9 -0
- package/lib/typescript/commonjs/privacy/redact.d.ts.map +1 -0
- package/lib/typescript/commonjs/privacy/screenEvidence.d.ts +14 -0
- package/lib/typescript/commonjs/privacy/screenEvidence.d.ts.map +1 -0
- package/lib/typescript/commonjs/privacy/screenModel.d.ts +26 -0
- package/lib/typescript/commonjs/privacy/screenModel.d.ts.map +1 -0
- package/lib/typescript/commonjs/privacy/sensitiveScreen.d.ts +8 -0
- package/lib/typescript/commonjs/privacy/sensitiveScreen.d.ts.map +1 -0
- package/lib/typescript/commonjs/privacy/userGate.d.ts +58 -0
- package/lib/typescript/commonjs/privacy/userGate.d.ts.map +1 -0
- package/lib/typescript/commonjs/protocol/actions.d.ts +7 -0
- package/lib/typescript/commonjs/protocol/actions.d.ts.map +1 -0
- package/lib/typescript/commonjs/provider/HostAppearanceStore.d.ts +64 -0
- package/lib/typescript/commonjs/provider/HostAppearanceStore.d.ts.map +1 -0
- package/lib/typescript/commonjs/provider/KokoProvider.d.ts +39 -0
- package/lib/typescript/commonjs/provider/KokoProvider.d.ts.map +1 -0
- package/lib/typescript/commonjs/provider/KokoUiContext.d.ts +22 -0
- package/lib/typescript/commonjs/provider/KokoUiContext.d.ts.map +1 -0
- package/lib/typescript/commonjs/selector/match.d.ts +27 -0
- package/lib/typescript/commonjs/selector/match.d.ts.map +1 -0
- package/lib/typescript/commonjs/task/TaskStore.d.ts +65 -0
- package/lib/typescript/commonjs/task/TaskStore.d.ts.map +1 -0
- package/lib/typescript/commonjs/task/types.d.ts +66 -0
- package/lib/typescript/commonjs/task/types.d.ts.map +1 -0
- package/lib/typescript/commonjs/task/useTaskStore.d.ts +3 -0
- package/lib/typescript/commonjs/task/useTaskStore.d.ts.map +1 -0
- package/lib/typescript/commonjs/types.d.ts +372 -0
- package/lib/typescript/commonjs/types.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/KokoChatSheet.d.ts +8 -0
- package/lib/typescript/commonjs/ui/KokoChatSheet.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/KokoComposer.d.ts +13 -0
- package/lib/typescript/commonjs/ui/KokoComposer.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/KokoDialogHost.d.ts +32 -0
- package/lib/typescript/commonjs/ui/KokoDialogHost.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/KokoEntryButton.d.ts +18 -0
- package/lib/typescript/commonjs/ui/KokoEntryButton.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/KokoObserver.d.ts +13 -0
- package/lib/typescript/commonjs/ui/KokoObserver.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/KokoOverlayLayer.d.ts +35 -0
- package/lib/typescript/commonjs/ui/KokoOverlayLayer.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/KokoSubtitle.d.ts +7 -0
- package/lib/typescript/commonjs/ui/KokoSubtitle.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/KokoTaskPanel.d.ts +7 -0
- package/lib/typescript/commonjs/ui/KokoTaskPanel.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/hostOverlay.d.ts +28 -0
- package/lib/typescript/commonjs/ui/hostOverlay.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/icons.d.ts +26 -0
- package/lib/typescript/commonjs/ui/icons.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/progressChrome.d.ts +21 -0
- package/lib/typescript/commonjs/ui/progressChrome.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/safeArea.d.ts +12 -0
- package/lib/typescript/commonjs/ui/safeArea.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/useOverlayOrigin.d.ts +22 -0
- package/lib/typescript/commonjs/ui/useOverlayOrigin.d.ts.map +1 -0
- package/lib/typescript/module/KokoAgent.d.ts +167 -0
- package/lib/typescript/module/KokoAgent.d.ts.map +1 -0
- package/lib/typescript/module/assist/OnDeviceAssist.d.ts +31 -0
- package/lib/typescript/module/assist/OnDeviceAssist.d.ts.map +1 -0
- package/lib/typescript/module/assist/intentClassify.d.ts +18 -0
- package/lib/typescript/module/assist/intentClassify.d.ts.map +1 -0
- package/lib/typescript/module/assist/nodeRank.d.ts +32 -0
- package/lib/typescript/module/assist/nodeRank.d.ts.map +1 -0
- package/lib/typescript/module/assist/ocrTarget.d.ts +25 -0
- package/lib/typescript/module/assist/ocrTarget.d.ts.map +1 -0
- package/lib/typescript/module/assist/webVisualChange.d.ts +6 -0
- package/lib/typescript/module/assist/webVisualChange.d.ts.map +1 -0
- package/lib/typescript/module/client/ActionOutcomeUnknownError.d.ts +13 -0
- package/lib/typescript/module/client/ActionOutcomeUnknownError.d.ts.map +1 -0
- package/lib/typescript/module/client/AgentSession.d.ts +56 -0
- package/lib/typescript/module/client/AgentSession.d.ts.map +1 -0
- package/lib/typescript/module/client/GatewayClient.d.ts +149 -0
- package/lib/typescript/module/client/GatewayClient.d.ts.map +1 -0
- package/lib/typescript/module/client/OperationReplayGuard.d.ts +13 -0
- package/lib/typescript/module/client/OperationReplayGuard.d.ts.map +1 -0
- package/lib/typescript/module/client/RunCheckpoint.d.ts +57 -0
- package/lib/typescript/module/client/RunCheckpoint.d.ts.map +1 -0
- package/lib/typescript/module/client/loopDetect.d.ts +15 -0
- package/lib/typescript/module/client/loopDetect.d.ts.map +1 -0
- package/lib/typescript/module/client/recentSearch.d.ts +5 -0
- package/lib/typescript/module/client/recentSearch.d.ts.map +1 -0
- package/lib/typescript/module/client/walletChoiceGuard.d.ts +4 -0
- package/lib/typescript/module/client/walletChoiceGuard.d.ts.map +1 -0
- package/lib/typescript/module/client/webResultCategory.d.ts +5 -0
- package/lib/typescript/module/client/webResultCategory.d.ts.map +1 -0
- package/lib/typescript/module/commercial/AccountStore.d.ts +17 -0
- package/lib/typescript/module/commercial/AccountStore.d.ts.map +1 -0
- package/lib/typescript/module/commercial/AgentDebug.d.ts +25 -0
- package/lib/typescript/module/commercial/AgentDebug.d.ts.map +1 -0
- package/lib/typescript/module/commercial/ExecutionGuard.d.ts +18 -0
- package/lib/typescript/module/commercial/ExecutionGuard.d.ts.map +1 -0
- package/lib/typescript/module/commercial/UsageBus.d.ts +18 -0
- package/lib/typescript/module/commercial/UsageBus.d.ts.map +1 -0
- package/lib/typescript/module/commercial/branding.d.ts +25 -0
- package/lib/typescript/module/commercial/branding.d.ts.map +1 -0
- package/lib/typescript/module/commercial/devMode.d.ts +26 -0
- package/lib/typescript/module/commercial/devMode.d.ts.map +1 -0
- package/lib/typescript/module/commercial/trust.d.ts +21 -0
- package/lib/typescript/module/commercial/trust.d.ts.map +1 -0
- package/lib/typescript/module/confirmation/gate.d.ts +18 -0
- package/lib/typescript/module/confirmation/gate.d.ts.map +1 -0
- package/lib/typescript/module/cursor/CursorOverlay.d.ts +13 -0
- package/lib/typescript/module/cursor/CursorOverlay.d.ts.map +1 -0
- package/lib/typescript/module/cursor/PointerHand.d.ts +16 -0
- package/lib/typescript/module/cursor/PointerHand.d.ts.map +1 -0
- package/lib/typescript/module/cursor/controller.d.ts +30 -0
- package/lib/typescript/module/cursor/controller.d.ts.map +1 -0
- package/lib/typescript/module/cursor/pointer.d.ts +23 -0
- package/lib/typescript/module/cursor/pointer.d.ts.map +1 -0
- package/lib/typescript/module/debug/KokoRemoteSmoke.d.ts +96 -0
- package/lib/typescript/module/debug/KokoRemoteSmoke.d.ts.map +1 -0
- package/lib/typescript/module/explore/ExplorationGraph.d.ts +96 -0
- package/lib/typescript/module/explore/ExplorationGraph.d.ts.map +1 -0
- package/lib/typescript/module/explore/bootstrapExplore.d.ts +40 -0
- package/lib/typescript/module/explore/bootstrapExplore.d.ts.map +1 -0
- package/lib/typescript/module/host/HostActions.d.ts +101 -0
- package/lib/typescript/module/host/HostActions.d.ts.map +1 -0
- package/lib/typescript/module/i18n/index.d.ts +20 -0
- package/lib/typescript/module/i18n/index.d.ts.map +1 -0
- package/lib/typescript/module/i18n/runtimeMessages.d.ts +178 -0
- package/lib/typescript/module/i18n/runtimeMessages.d.ts.map +1 -0
- package/lib/typescript/module/index.d.ts +66 -0
- package/lib/typescript/module/index.d.ts.map +1 -0
- package/lib/typescript/module/native/NativeBridge.d.ts +70 -0
- package/lib/typescript/module/native/NativeBridge.d.ts.map +1 -0
- package/lib/typescript/module/native/navigationLabel.d.ts +4 -0
- package/lib/typescript/module/native/navigationLabel.d.ts.map +1 -0
- package/lib/typescript/module/native/normalizeViewTree.d.ts +4 -0
- package/lib/typescript/module/native/normalizeViewTree.d.ts.map +1 -0
- package/lib/typescript/module/native/pruneOffscreen.d.ts +3 -0
- package/lib/typescript/module/native/pruneOffscreen.d.ts.map +1 -0
- package/lib/typescript/module/native/scrollViewport.d.ts +13 -0
- package/lib/typescript/module/native/scrollViewport.d.ts.map +1 -0
- package/lib/typescript/module/package.json +1 -0
- package/lib/typescript/module/privacy/redact.d.ts +9 -0
- package/lib/typescript/module/privacy/redact.d.ts.map +1 -0
- package/lib/typescript/module/privacy/screenEvidence.d.ts +14 -0
- package/lib/typescript/module/privacy/screenEvidence.d.ts.map +1 -0
- package/lib/typescript/module/privacy/screenModel.d.ts +26 -0
- package/lib/typescript/module/privacy/screenModel.d.ts.map +1 -0
- package/lib/typescript/module/privacy/sensitiveScreen.d.ts +8 -0
- package/lib/typescript/module/privacy/sensitiveScreen.d.ts.map +1 -0
- package/lib/typescript/module/privacy/userGate.d.ts +58 -0
- package/lib/typescript/module/privacy/userGate.d.ts.map +1 -0
- package/lib/typescript/module/protocol/actions.d.ts +7 -0
- package/lib/typescript/module/protocol/actions.d.ts.map +1 -0
- package/lib/typescript/module/provider/HostAppearanceStore.d.ts +64 -0
- package/lib/typescript/module/provider/HostAppearanceStore.d.ts.map +1 -0
- package/lib/typescript/module/provider/KokoProvider.d.ts +39 -0
- package/lib/typescript/module/provider/KokoProvider.d.ts.map +1 -0
- package/lib/typescript/module/provider/KokoUiContext.d.ts +22 -0
- package/lib/typescript/module/provider/KokoUiContext.d.ts.map +1 -0
- package/lib/typescript/module/selector/match.d.ts +27 -0
- package/lib/typescript/module/selector/match.d.ts.map +1 -0
- package/lib/typescript/module/task/TaskStore.d.ts +65 -0
- package/lib/typescript/module/task/TaskStore.d.ts.map +1 -0
- package/lib/typescript/module/task/types.d.ts +66 -0
- package/lib/typescript/module/task/types.d.ts.map +1 -0
- package/lib/typescript/module/task/useTaskStore.d.ts +3 -0
- package/lib/typescript/module/task/useTaskStore.d.ts.map +1 -0
- package/lib/typescript/module/types.d.ts +372 -0
- package/lib/typescript/module/types.d.ts.map +1 -0
- package/lib/typescript/module/ui/KokoChatSheet.d.ts +8 -0
- package/lib/typescript/module/ui/KokoChatSheet.d.ts.map +1 -0
- package/lib/typescript/module/ui/KokoComposer.d.ts +13 -0
- package/lib/typescript/module/ui/KokoComposer.d.ts.map +1 -0
- package/lib/typescript/module/ui/KokoDialogHost.d.ts +32 -0
- package/lib/typescript/module/ui/KokoDialogHost.d.ts.map +1 -0
- package/lib/typescript/module/ui/KokoEntryButton.d.ts +18 -0
- package/lib/typescript/module/ui/KokoEntryButton.d.ts.map +1 -0
- package/lib/typescript/module/ui/KokoObserver.d.ts +13 -0
- package/lib/typescript/module/ui/KokoObserver.d.ts.map +1 -0
- package/lib/typescript/module/ui/KokoOverlayLayer.d.ts +35 -0
- package/lib/typescript/module/ui/KokoOverlayLayer.d.ts.map +1 -0
- package/lib/typescript/module/ui/KokoSubtitle.d.ts +7 -0
- package/lib/typescript/module/ui/KokoSubtitle.d.ts.map +1 -0
- package/lib/typescript/module/ui/KokoTaskPanel.d.ts +7 -0
- package/lib/typescript/module/ui/KokoTaskPanel.d.ts.map +1 -0
- package/lib/typescript/module/ui/hostOverlay.d.ts +28 -0
- package/lib/typescript/module/ui/hostOverlay.d.ts.map +1 -0
- package/lib/typescript/module/ui/icons.d.ts +26 -0
- package/lib/typescript/module/ui/icons.d.ts.map +1 -0
- package/lib/typescript/module/ui/progressChrome.d.ts +21 -0
- package/lib/typescript/module/ui/progressChrome.d.ts.map +1 -0
- package/lib/typescript/module/ui/safeArea.d.ts +12 -0
- package/lib/typescript/module/ui/safeArea.d.ts.map +1 -0
- package/lib/typescript/module/ui/useOverlayOrigin.d.ts +22 -0
- package/lib/typescript/module/ui/useOverlayOrigin.d.ts.map +1 -0
- package/package.json +153 -0
- package/react-native.config.js +12 -0
- package/src/KokoAgent.ts +1415 -0
- package/src/assist/OnDeviceAssist.ts +133 -0
- package/src/assist/intentClassify.ts +122 -0
- package/src/assist/nodeRank.ts +167 -0
- package/src/assist/ocrTarget.ts +146 -0
- package/src/assist/webVisualChange.ts +24 -0
- package/src/client/ActionOutcomeUnknownError.ts +18 -0
- package/src/client/AgentSession.ts +952 -0
- package/src/client/GatewayClient.ts +439 -0
- package/src/client/OperationReplayGuard.ts +61 -0
- package/src/client/RunCheckpoint.ts +154 -0
- package/src/client/loopDetect.ts +213 -0
- package/src/client/recentSearch.ts +47 -0
- package/src/client/walletChoiceGuard.ts +15 -0
- package/src/client/webResultCategory.ts +28 -0
- package/src/commercial/AccountStore.ts +85 -0
- package/src/commercial/AgentDebug.ts +142 -0
- package/src/commercial/ExecutionGuard.ts +67 -0
- package/src/commercial/UsageBus.ts +44 -0
- package/src/commercial/branding.ts +97 -0
- package/src/commercial/devMode.ts +48 -0
- package/src/commercial/trust.ts +67 -0
- package/src/confirmation/gate.ts +82 -0
- package/src/cursor/CursorOverlay.tsx +138 -0
- package/src/cursor/PointerHand.tsx +49 -0
- package/src/cursor/controller.ts +98 -0
- package/src/cursor/pointer.ts +40 -0
- package/src/debug/KokoRemoteSmoke.tsx +561 -0
- package/src/explore/ExplorationGraph.ts +518 -0
- package/src/explore/bootstrapExplore.ts +89 -0
- package/src/host/HostActions.ts +349 -0
- package/src/i18n/index.ts +229 -0
- package/src/i18n/runtimeMessages.ts +180 -0
- package/src/index.ts +203 -0
- package/src/native/NativeBridge.ts +207 -0
- package/src/native/navigationLabel.ts +11 -0
- package/src/native/normalizeViewTree.ts +16 -0
- package/src/native/pruneOffscreen.ts +72 -0
- package/src/native/scrollViewport.ts +51 -0
- package/src/privacy/redact.ts +115 -0
- package/src/privacy/screenEvidence.ts +55 -0
- package/src/privacy/screenModel.ts +504 -0
- package/src/privacy/sensitiveScreen.ts +55 -0
- package/src/privacy/userGate.ts +233 -0
- package/src/protocol/actions.ts +66 -0
- package/src/provider/HostAppearanceStore.ts +148 -0
- package/src/provider/KokoProvider.tsx +118 -0
- package/src/provider/KokoUiContext.tsx +162 -0
- package/src/selector/match.ts +417 -0
- package/src/task/TaskStore.ts +387 -0
- package/src/task/types.ts +82 -0
- package/src/task/useTaskStore.ts +9 -0
- package/src/types.ts +318 -0
- package/src/ui/KokoChatSheet.tsx +930 -0
- package/src/ui/KokoComposer.tsx +174 -0
- package/src/ui/KokoDialogHost.tsx +249 -0
- package/src/ui/KokoEntryButton.tsx +74 -0
- package/src/ui/KokoObserver.tsx +587 -0
- package/src/ui/KokoOverlayLayer.tsx +53 -0
- package/src/ui/KokoSubtitle.tsx +80 -0
- package/src/ui/KokoTaskPanel.tsx +299 -0
- package/src/ui/hostOverlay.tsx +148 -0
- package/src/ui/icons.tsx +145 -0
- package/src/ui/progressChrome.ts +73 -0
- package/src/ui/safeArea.ts +95 -0
- package/src/ui/useOverlayOrigin.ts +29 -0
|
@@ -0,0 +1,372 @@
|
|
|
1
|
+
/** Frame in window / screen coordinates (density-independent points). */
|
|
2
|
+
export type Frame = {
|
|
3
|
+
x: number;
|
|
4
|
+
y: number;
|
|
5
|
+
width: number;
|
|
6
|
+
height: number;
|
|
7
|
+
};
|
|
8
|
+
/** One node in the dumped native view tree. */
|
|
9
|
+
export type ViewNode = {
|
|
10
|
+
/** Stable-enough path for this dump snapshot (e.g. "0/2/1"). */
|
|
11
|
+
id: string;
|
|
12
|
+
/** Native class name (UIView / android.view.View subclass). */
|
|
13
|
+
type: string;
|
|
14
|
+
frame: Frame;
|
|
15
|
+
/** Visible text aggregated from this node and text descendants. */
|
|
16
|
+
text?: string;
|
|
17
|
+
accessibilityLabel?: string;
|
|
18
|
+
testID?: string;
|
|
19
|
+
/** True for secure/password text fields (user must type; agent waits). */
|
|
20
|
+
secure?: boolean;
|
|
21
|
+
/** Already-active tab / segment / option — re-tapping it does nothing. */
|
|
22
|
+
selected?: boolean;
|
|
23
|
+
/** System alert / action sheet / share / menu surface. */
|
|
24
|
+
sheet?: boolean;
|
|
25
|
+
/** UISwitch-like toggle. */
|
|
26
|
+
toggle?: boolean;
|
|
27
|
+
on?: boolean;
|
|
28
|
+
/** Picker / slider / stepper / adjustable control. */
|
|
29
|
+
adjustable?: boolean;
|
|
30
|
+
/** Current numeric value when known (slider / stepper / segment index). */
|
|
31
|
+
value?: number;
|
|
32
|
+
min?: number;
|
|
33
|
+
max?: number;
|
|
34
|
+
clickable: boolean;
|
|
35
|
+
enabled: boolean;
|
|
36
|
+
visible: boolean;
|
|
37
|
+
/** Whether this view can scroll vertically; supplied by the native host. */
|
|
38
|
+
scrollable?: boolean;
|
|
39
|
+
/** Descendants are clipped to this view's window-relative bounds. */
|
|
40
|
+
clipsChildren?: boolean;
|
|
41
|
+
children: ViewNode[];
|
|
42
|
+
};
|
|
43
|
+
/** Single match rule inside a multi-factor selector. */
|
|
44
|
+
export type MatchRule = {
|
|
45
|
+
text: string;
|
|
46
|
+
exact?: boolean;
|
|
47
|
+
} | {
|
|
48
|
+
nearText: string;
|
|
49
|
+
exact?: boolean;
|
|
50
|
+
} | {
|
|
51
|
+
clickable: boolean;
|
|
52
|
+
} | {
|
|
53
|
+
type: string;
|
|
54
|
+
} | {
|
|
55
|
+
testID: string;
|
|
56
|
+
} | {
|
|
57
|
+
accessibilityLabel: string;
|
|
58
|
+
exact?: boolean;
|
|
59
|
+
} | {
|
|
60
|
+
region: 'top' | 'bottom' | 'left' | 'right' | 'center';
|
|
61
|
+
ratio?: number;
|
|
62
|
+
};
|
|
63
|
+
/**
|
|
64
|
+
* Multi-factor selector (DOM-like).
|
|
65
|
+
* All `match` rules must pass; `index` picks the N-th among matches.
|
|
66
|
+
*/
|
|
67
|
+
export type Selector = {
|
|
68
|
+
match: MatchRule[];
|
|
69
|
+
index?: number;
|
|
70
|
+
};
|
|
71
|
+
export type Point = {
|
|
72
|
+
x: number;
|
|
73
|
+
y: number;
|
|
74
|
+
};
|
|
75
|
+
export type TapOptions = {
|
|
76
|
+
/** Search by scrolling when absent. Planners disable this and choose navigation explicitly. */
|
|
77
|
+
revealIfNeeded?: boolean;
|
|
78
|
+
/** Skip cursor animation. */
|
|
79
|
+
silent?: boolean;
|
|
80
|
+
/** Cursor move duration ms. */
|
|
81
|
+
cursorDurationMs?: number;
|
|
82
|
+
};
|
|
83
|
+
export type SwipeOptions = {
|
|
84
|
+
durationMs?: number;
|
|
85
|
+
silent?: boolean;
|
|
86
|
+
};
|
|
87
|
+
export type PinchOptions = {
|
|
88
|
+
/** Finger travel duration ms (default 280). */
|
|
89
|
+
durationMs?: number;
|
|
90
|
+
silent?: boolean;
|
|
91
|
+
};
|
|
92
|
+
export type TypeOptions = {
|
|
93
|
+
clear?: boolean;
|
|
94
|
+
silent?: boolean;
|
|
95
|
+
};
|
|
96
|
+
/** Sensitive-action confirmation policy. */
|
|
97
|
+
export type ConfirmationPolicy = {
|
|
98
|
+
/**
|
|
99
|
+
* When true (default), high-risk goals need a human OK.
|
|
100
|
+
* Combined with `mode` (default `preflight`).
|
|
101
|
+
*/
|
|
102
|
+
requireUserConfirm: boolean;
|
|
103
|
+
/**
|
|
104
|
+
* - `preflight` (default): ask once before the run; execution is unattended
|
|
105
|
+
* - `inline`: legacy per-tap confirm (not recommended)
|
|
106
|
+
* - `off`: never ask
|
|
107
|
+
*/
|
|
108
|
+
mode?: 'preflight' | 'inline' | 'off';
|
|
109
|
+
/** Keywords / patterns that trigger the gate (matched against goal / labels). */
|
|
110
|
+
sensitivePatterns?: RegExp[];
|
|
111
|
+
};
|
|
112
|
+
/** UI language for built-in chrome (chat sheet, dialogs, progress). */
|
|
113
|
+
export type KokoLocale = 'zh' | 'en';
|
|
114
|
+
/**
|
|
115
|
+
* A light or dark color scheme.
|
|
116
|
+
*
|
|
117
|
+
* Where it names the host App's theme (`config.theme`, `setKokoAppearance`),
|
|
118
|
+
* Koko chrome renders in the opposite one for contrast.
|
|
119
|
+
*/
|
|
120
|
+
export type KokoTheme = 'light' | 'dark';
|
|
121
|
+
/**
|
|
122
|
+
* Host branding for the built-in chat sheet.
|
|
123
|
+
* Custom name / icon / tagline / placeholder require plan entitlement `custom_branding`.
|
|
124
|
+
* Without entitlement, SDK falls back to default Koko branding.
|
|
125
|
+
*/
|
|
126
|
+
export type KokoBrandingConfig = {
|
|
127
|
+
/** Display name (paid). Default: Koko */
|
|
128
|
+
name?: string;
|
|
129
|
+
/**
|
|
130
|
+
* Brand mark — image URI / require() source, or a short letter shown in the badge.
|
|
131
|
+
* Custom image/letter beyond default "K" requires `custom_branding`.
|
|
132
|
+
*/
|
|
133
|
+
icon?: number | {
|
|
134
|
+
uri: string;
|
|
135
|
+
} | string;
|
|
136
|
+
/** Tagline under the name (paid). */
|
|
137
|
+
tagline?: string;
|
|
138
|
+
/** Composer placeholder (paid when customized). */
|
|
139
|
+
placeholder?: string;
|
|
140
|
+
/** Accent color for badge / send button (paid with branding). */
|
|
141
|
+
primaryColor?: string;
|
|
142
|
+
};
|
|
143
|
+
/** Plan entitlements returned by gateway `/v1/me`. */
|
|
144
|
+
export type KokoEntitlements = {
|
|
145
|
+
custom_branding: boolean;
|
|
146
|
+
locale: boolean;
|
|
147
|
+
};
|
|
148
|
+
export type KokoPlanId = 'free' | 'pro' | 'enterprise';
|
|
149
|
+
export type KokoAccountSnapshot = {
|
|
150
|
+
plan: KokoPlanId;
|
|
151
|
+
region?: string;
|
|
152
|
+
provider?: string;
|
|
153
|
+
entitlements: KokoEntitlements;
|
|
154
|
+
quota: {
|
|
155
|
+
daily: number;
|
|
156
|
+
used_today: number;
|
|
157
|
+
remaining: number;
|
|
158
|
+
/** Present when gateway bills LLM tokens via the account service. */
|
|
159
|
+
meter?: 'llm_tokens' | 'agent_step';
|
|
160
|
+
free_monthly?: number;
|
|
161
|
+
free_used?: number;
|
|
162
|
+
free_remaining?: number;
|
|
163
|
+
prepaid_balance?: number;
|
|
164
|
+
};
|
|
165
|
+
};
|
|
166
|
+
/**
|
|
167
|
+
* Side-channel usage notifications for host analytics / UX.
|
|
168
|
+
* Does NOT affect task execution or billing (server is authoritative).
|
|
169
|
+
*/
|
|
170
|
+
export type KokoUsageEvent = {
|
|
171
|
+
type: 'task_started';
|
|
172
|
+
taskId?: string;
|
|
173
|
+
goal: string;
|
|
174
|
+
at: number;
|
|
175
|
+
} | {
|
|
176
|
+
type: 'task_finished';
|
|
177
|
+
taskId?: string;
|
|
178
|
+
status: 'success' | 'failed' | 'cancelled';
|
|
179
|
+
steps?: number;
|
|
180
|
+
at: number;
|
|
181
|
+
} | {
|
|
182
|
+
type: 'agent_step';
|
|
183
|
+
sessionId?: string;
|
|
184
|
+
step?: number;
|
|
185
|
+
tool?: string;
|
|
186
|
+
at: number;
|
|
187
|
+
} | {
|
|
188
|
+
type: 'quota_exceeded';
|
|
189
|
+
message?: string;
|
|
190
|
+
quota?: KokoAccountSnapshot['quota'];
|
|
191
|
+
at: number;
|
|
192
|
+
} | {
|
|
193
|
+
type: 'sheet_opened' | 'sheet_closed';
|
|
194
|
+
at: number;
|
|
195
|
+
} | {
|
|
196
|
+
type: 'branding_downgraded';
|
|
197
|
+
reason: 'missing_entitlement';
|
|
198
|
+
at: number;
|
|
199
|
+
};
|
|
200
|
+
export type KokoAgentConfig = {
|
|
201
|
+
/** Public chooser labels that the host confirms refer to its own injected wallet provider. */
|
|
202
|
+
webWalletAliases?: string[];
|
|
203
|
+
/** Called when a sensitive step needs a human confirm. Return true to proceed. */
|
|
204
|
+
onConfirmSensitive?: (ctx: SensitiveConfirmContext) => Promise<boolean>;
|
|
205
|
+
confirmation?: ConfirmationPolicy;
|
|
206
|
+
/**
|
|
207
|
+
* Max depth when dumping (performance). Must clear the host's real nesting:
|
|
208
|
+
* RN plus a component library spends 25-35 levels on navigators, safe-area,
|
|
209
|
+
* gesture and style wrappers before reaching the first button, so a tight cap
|
|
210
|
+
* silently truncates the page body and leaves the agent only the shallow
|
|
211
|
+
* chrome around it.
|
|
212
|
+
*/
|
|
213
|
+
dumpMaxDepth?: number;
|
|
214
|
+
/** Drop non-visible nodes from dump. */
|
|
215
|
+
dumpSkipInvisible?: boolean;
|
|
216
|
+
/** Default cursor animation duration. */
|
|
217
|
+
cursorDurationMs?: number;
|
|
218
|
+
/**
|
|
219
|
+
* Show task subtitle + history panel (default true).
|
|
220
|
+
* Set false to disable observer chrome / auto logging.
|
|
221
|
+
*/
|
|
222
|
+
observer?: boolean;
|
|
223
|
+
/**
|
|
224
|
+
* Official gateway. Defaults applied in runGoal if omitted:
|
|
225
|
+
* baseUrl https://sdk.intentcomputing.net — LLM vendor is server-side only.
|
|
226
|
+
*/
|
|
227
|
+
gateway?: {
|
|
228
|
+
baseUrl?: string;
|
|
229
|
+
/** App member token (not an LLM key). */
|
|
230
|
+
token: string;
|
|
231
|
+
/**
|
|
232
|
+
* Host App ID (bundle id / package name). Bound to the API key on the server.
|
|
233
|
+
* Defaults to the native host App ID when omitted.
|
|
234
|
+
*/
|
|
235
|
+
appId?: string;
|
|
236
|
+
};
|
|
237
|
+
/**
|
|
238
|
+
* Verbose developer logs: App capabilities / steps the SDK sees.
|
|
239
|
+
* Does not print security policy details.
|
|
240
|
+
* Default: on in Metro `__DEV__`; set `false` to silence.
|
|
241
|
+
* @deprecated `devMode` is an alias for `debug`. Prefer `debug`.
|
|
242
|
+
*/
|
|
243
|
+
debug?: boolean;
|
|
244
|
+
/** @deprecated Use `debug`. Same meaning: verbose capability logs only. */
|
|
245
|
+
devMode?: boolean;
|
|
246
|
+
/**
|
|
247
|
+
* Built-in UI language. Default `en` (pass `zh` for Chinese).
|
|
248
|
+
* Prefer `setKokoAppearance({ locale })` so the host can follow its own setting.
|
|
249
|
+
*/
|
|
250
|
+
locale?: KokoLocale;
|
|
251
|
+
/**
|
|
252
|
+
* The **host App's** theme — not the SDK's. Default `light`.
|
|
253
|
+
*
|
|
254
|
+
* Koko chrome paints in the opposite theme so it reads as a separate
|
|
255
|
+
* surface floating over the App: report `dark` and the pill, chat sheet
|
|
256
|
+
* and dialogs go light, and vice versa.
|
|
257
|
+
*
|
|
258
|
+
* Prefer `setKokoAppearance({ theme })` so chrome follows the host when the
|
|
259
|
+
* user changes it at runtime.
|
|
260
|
+
*/
|
|
261
|
+
theme?: KokoTheme;
|
|
262
|
+
/**
|
|
263
|
+
* Branding for chat sheet header / placeholder.
|
|
264
|
+
* Requires lifetime branding license (`custom_branding` from official `/v1/me`).
|
|
265
|
+
* Soft-enforced in built-in UI only; usage billing is separate (server-side).
|
|
266
|
+
*/
|
|
267
|
+
branding?: KokoBrandingConfig;
|
|
268
|
+
/**
|
|
269
|
+
* Optional host analytics. Never blocks or changes agent execution.
|
|
270
|
+
*/
|
|
271
|
+
onUsageEvent?: (event: KokoUsageEvent) => void;
|
|
272
|
+
};
|
|
273
|
+
export type SensitiveConfirmContext = {
|
|
274
|
+
action: string;
|
|
275
|
+
label?: string;
|
|
276
|
+
selector?: Selector;
|
|
277
|
+
node?: ViewNode;
|
|
278
|
+
};
|
|
279
|
+
export type DumpOptions = {
|
|
280
|
+
maxDepth?: number;
|
|
281
|
+
skipInvisible?: boolean;
|
|
282
|
+
/**
|
|
283
|
+
* Internal observation dump — do not write task log / subtitle.
|
|
284
|
+
* Use for per-step UI refresh; keep false for explicit agent `dump` tool.
|
|
285
|
+
*/
|
|
286
|
+
silent?: boolean;
|
|
287
|
+
};
|
|
288
|
+
/** Agent ↔ SDK JSON tool-call protocol (cloud agent side). */
|
|
289
|
+
export type AgentAction = {
|
|
290
|
+
tool: 'dump';
|
|
291
|
+
args?: DumpOptions;
|
|
292
|
+
} | {
|
|
293
|
+
tool: 'find';
|
|
294
|
+
args: {
|
|
295
|
+
selector: Selector;
|
|
296
|
+
};
|
|
297
|
+
} | {
|
|
298
|
+
tool: 'findAll';
|
|
299
|
+
args: {
|
|
300
|
+
selector: Selector;
|
|
301
|
+
};
|
|
302
|
+
} | {
|
|
303
|
+
tool: 'tap';
|
|
304
|
+
args: {
|
|
305
|
+
selector?: Selector;
|
|
306
|
+
nodeId?: string;
|
|
307
|
+
point?: Point;
|
|
308
|
+
options?: TapOptions;
|
|
309
|
+
};
|
|
310
|
+
} | {
|
|
311
|
+
tool: 'swipe';
|
|
312
|
+
args: {
|
|
313
|
+
from: Point;
|
|
314
|
+
to: Point;
|
|
315
|
+
options?: SwipeOptions;
|
|
316
|
+
};
|
|
317
|
+
} | {
|
|
318
|
+
tool: 'pinch';
|
|
319
|
+
args: {
|
|
320
|
+
center: Point;
|
|
321
|
+
scale: number;
|
|
322
|
+
options?: PinchOptions;
|
|
323
|
+
};
|
|
324
|
+
} | {
|
|
325
|
+
tool: 'type';
|
|
326
|
+
args: {
|
|
327
|
+
text: string;
|
|
328
|
+
selector?: Selector;
|
|
329
|
+
nodeId?: string;
|
|
330
|
+
options?: TypeOptions;
|
|
331
|
+
};
|
|
332
|
+
} | {
|
|
333
|
+
tool: 'confirm';
|
|
334
|
+
args: {
|
|
335
|
+
label?: string;
|
|
336
|
+
action?: string;
|
|
337
|
+
};
|
|
338
|
+
};
|
|
339
|
+
export type AgentActionResult = {
|
|
340
|
+
ok: true;
|
|
341
|
+
tool: 'dump';
|
|
342
|
+
tree: ViewNode;
|
|
343
|
+
} | {
|
|
344
|
+
ok: true;
|
|
345
|
+
tool: 'find';
|
|
346
|
+
node: ViewNode | null;
|
|
347
|
+
} | {
|
|
348
|
+
ok: true;
|
|
349
|
+
tool: 'findAll';
|
|
350
|
+
nodes: ViewNode[];
|
|
351
|
+
} | {
|
|
352
|
+
ok: true;
|
|
353
|
+
tool: 'tap';
|
|
354
|
+
} | {
|
|
355
|
+
ok: true;
|
|
356
|
+
tool: 'swipe';
|
|
357
|
+
} | {
|
|
358
|
+
ok: true;
|
|
359
|
+
tool: 'pinch';
|
|
360
|
+
} | {
|
|
361
|
+
ok: true;
|
|
362
|
+
tool: 'type';
|
|
363
|
+
} | {
|
|
364
|
+
ok: true;
|
|
365
|
+
tool: 'confirm';
|
|
366
|
+
confirmed: boolean;
|
|
367
|
+
} | {
|
|
368
|
+
ok: false;
|
|
369
|
+
tool: AgentAction['tool'];
|
|
370
|
+
error: string;
|
|
371
|
+
};
|
|
372
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/types.ts"],"names":[],"mappings":"AAAA,yEAAyE;AACzE,MAAM,MAAM,KAAK,GAAG;IAClB,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,MAAM,CAAC;IACV,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;CAChB,CAAC;AAEF,+CAA+C;AAC/C,MAAM,MAAM,QAAQ,GAAG;IACrB,gEAAgE;IAChE,EAAE,EAAE,MAAM,CAAC;IACX,+DAA+D;IAC/D,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,KAAK,CAAC;IACb,mEAAmE;IACnE,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,kBAA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,CAAA;CAAE,GACzB;IAAE,EAAE,EAAE,IAAI,CAAC;IAAC,IAAI,EAAE,OAAO,CAAA;CAAE,GAC3B;IAAE,EAAE,EAAE,IAAI,CAAC;IAAC,IAAI,EAAE,OAAO,CAAA;CAAE,GAC3B;IAAE,EAAE,EAAE,IAAI,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,GAC1B;IAAE,EAAE,EAAE,IAAI,CAAC;IAAC,IAAI,EAAE,SAAS,CAAC;IAAC,SAAS,EAAE,OAAO,CAAA;CAAE,GACjD;IAAE,EAAE,EAAE,KAAK,CAAC;IAAC,IAAI,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* Chat sheet: backdrop fades in first, then sheet slides down from the top.
|
|
4
|
+
*/
|
|
5
|
+
export declare function KokoChatSheet({ placeholder }: {
|
|
6
|
+
placeholder?: string;
|
|
7
|
+
}): React.JSX.Element | null;
|
|
8
|
+
//# sourceMappingURL=KokoChatSheet.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"KokoChatSheet.d.ts","sourceRoot":"","sources":["../../../../src/ui/KokoChatSheet.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA4D,MAAM,OAAO,CAAC;AA8GjF;;GAEG;AACH,wBAAgB,aAAa,CAAC,EAAE,WAAW,EAAE,EAAE;IAAE,WAAW,CAAC,EAAE,MAAM,CAAA;CAAE,4BAmhBtE"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export type KokoComposerProps = {
|
|
3
|
+
/** Placeholder for the natural-language input. */
|
|
4
|
+
placeholder?: string;
|
|
5
|
+
/** Disable while true (in addition to running task). */
|
|
6
|
+
disabled?: boolean;
|
|
7
|
+
};
|
|
8
|
+
/**
|
|
9
|
+
* Natural-language dialog (需求 §1.1 / §3.5):
|
|
10
|
+
* 用户自由输入一句话 → 云端 Agent → 本 App 内 dump/find/tap,字幕与任务可观测。
|
|
11
|
+
*/
|
|
12
|
+
export declare function KokoComposer({ placeholder, disabled, }: KokoComposerProps): React.JSX.Element;
|
|
13
|
+
//# sourceMappingURL=KokoComposer.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"KokoComposer.d.ts","sourceRoot":"","sources":["../../../../src/ui/KokoComposer.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAgC,MAAM,OAAO,CAAC;AAerD,MAAM,MAAM,iBAAiB,GAAG;IAC9B,kDAAkD;IAClD,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,wDAAwD;IACxD,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB,CAAC;AAEF;;;GAGG;AACH,wBAAgB,YAAY,CAAC,EAC3B,WAAW,EACX,QAAgB,GACjB,EAAE,iBAAiB,qBA0FnB"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export type ConfirmRequest = {
|
|
3
|
+
id: string;
|
|
4
|
+
title: string;
|
|
5
|
+
message: string;
|
|
6
|
+
resolve: (ok: boolean) => void;
|
|
7
|
+
};
|
|
8
|
+
export type AskRequest = {
|
|
9
|
+
id: string;
|
|
10
|
+
question: string;
|
|
11
|
+
resolve: (answer: string | null) => void;
|
|
12
|
+
};
|
|
13
|
+
type Listener = (state: {
|
|
14
|
+
confirm: ConfirmRequest | null;
|
|
15
|
+
ask: AskRequest | null;
|
|
16
|
+
}) => void;
|
|
17
|
+
declare class DialogBusImpl {
|
|
18
|
+
confirm: ConfirmRequest | null;
|
|
19
|
+
ask: AskRequest | null;
|
|
20
|
+
private listeners;
|
|
21
|
+
subscribe(l: Listener): () => void;
|
|
22
|
+
private emit;
|
|
23
|
+
requestConfirm(title: string, message: string): Promise<boolean>;
|
|
24
|
+
requestAsk(question: string): Promise<string | null>;
|
|
25
|
+
}
|
|
26
|
+
export declare const DialogBus: DialogBusImpl;
|
|
27
|
+
/**
|
|
28
|
+
* Built-in confirm + ask-user modal. Mounted by KokoProvider.
|
|
29
|
+
*/
|
|
30
|
+
export declare function KokoDialogHost(): React.JSX.Element;
|
|
31
|
+
export {};
|
|
32
|
+
//# sourceMappingURL=KokoDialogHost.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"KokoDialogHost.d.ts","sourceRoot":"","sources":["../../../../src/ui/KokoDialogHost.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA2C,MAAM,OAAO,CAAC;AAYhE,MAAM,MAAM,cAAc,GAAG;IAC3B,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,CAAC,EAAE,EAAE,OAAO,KAAK,IAAI,CAAC;CAChC,CAAC;AAEF,MAAM,MAAM,UAAU,GAAG;IACvB,EAAE,EAAE,MAAM,CAAC;IACX,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI,KAAK,IAAI,CAAC;CAC1C,CAAC;AAEF,KAAK,QAAQ,GAAG,CAAC,KAAK,EAAE;IAAE,OAAO,EAAE,cAAc,GAAG,IAAI,CAAC;IAAC,GAAG,EAAE,UAAU,GAAG,IAAI,CAAA;CAAE,KAAK,IAAI,CAAC;AAE5F,cAAM,aAAa;IACjB,OAAO,EAAE,cAAc,GAAG,IAAI,CAAQ;IACtC,GAAG,EAAE,UAAU,GAAG,IAAI,CAAQ;IAC9B,OAAO,CAAC,SAAS,CAAuB;IAExC,SAAS,CAAC,CAAC,EAAE,QAAQ;IAQrB,OAAO,CAAC,IAAI;IAIZ,cAAc,CAAC,KAAK,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC;IAgBhE,UAAU,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC;CAcrD;AAED,eAAO,MAAM,SAAS,eAAsB,CAAC;AAE7C;;GAEG;AACH,wBAAgB,cAAc,sBAyG7B"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { type StyleProp, type ViewStyle } from 'react-native';
|
|
3
|
+
export type KokoEntryButtonProps = {
|
|
4
|
+
label?: string;
|
|
5
|
+
style?: StyleProp<ViewStyle>;
|
|
6
|
+
};
|
|
7
|
+
/**
|
|
8
|
+
* Demo convenience button. Production hosts should draw their own entry UI
|
|
9
|
+
* and call `openKokoChat()` / `agent.openChat()`.
|
|
10
|
+
*
|
|
11
|
+
* Marked as overlay so dump/tap skip it — otherwise the agent mistakes it for
|
|
12
|
+
* an in-app control near bottom tabs (e.g. 我的).
|
|
13
|
+
*/
|
|
14
|
+
export declare function KokoEntryButton({ label, style, }: KokoEntryButtonProps): React.JSX.Element;
|
|
15
|
+
/** Imperative open for custom host buttons (preferred). */
|
|
16
|
+
export declare function openKokoChat(taskId?: string | null): void;
|
|
17
|
+
export declare function closeKokoChat(): void;
|
|
18
|
+
//# sourceMappingURL=KokoEntryButton.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"KokoEntryButton.d.ts","sourceRoot":"","sources":["../../../../src/ui/KokoEntryButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAA+B,KAAK,SAAS,EAAE,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAK3F,MAAM,MAAM,oBAAoB,GAAG;IACjC,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,SAAS,CAAC,SAAS,CAAC,CAAC;CAC9B,CAAC;AAEF;;;;;;GAMG;AACH,wBAAgB,eAAe,CAAC,EAC9B,KAAc,EACd,KAAK,GACN,EAAE,oBAAoB,qBAsBtB;AAED,2DAA2D;AAC3D,wBAAgB,YAAY,CAAC,MAAM,CAAC,EAAE,MAAM,GAAG,IAAI,QAElD;AAED,wBAAgB,aAAa,SAE5B"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export type KokoObserverProps = {
|
|
3
|
+
/** @deprecated Prefer config.branding.placeholder */
|
|
4
|
+
composerPlaceholder?: string;
|
|
5
|
+
/** Draw agent cursor in the same overlay Modal (default true). */
|
|
6
|
+
cursor?: boolean;
|
|
7
|
+
};
|
|
8
|
+
/**
|
|
9
|
+
* Progress pill + stop (+ optional cursor) in one host overlay Modal.
|
|
10
|
+
* After a run ends, shows an animated success/fail icon then auto-dismisses.
|
|
11
|
+
*/
|
|
12
|
+
export declare function KokoObserver({ composerPlaceholder, cursor, }: KokoObserverProps): React.JSX.Element;
|
|
13
|
+
//# sourceMappingURL=KokoObserver.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"KokoObserver.d.ts","sourceRoot":"","sources":["../../../../src/ui/KokoObserver.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA4D,MAAM,OAAO,CAAC;AAuCjF,MAAM,MAAM,iBAAiB,GAAG;IAC9B,qDAAqD;IACrD,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B,kEAAkE;IAClE,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB,CAAC;AAEF;;;GAGG;AACH,wBAAgB,YAAY,CAAC,EAC3B,mBAAmB,EACnB,MAAa,GACd,EAAE,iBAAiB,qBAwWnB"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import React, { type ReactNode } from 'react';
|
|
2
|
+
import { type StyleProp, type ViewStyle } from 'react-native';
|
|
3
|
+
/** Native dump / tap / screenshot skip views whose testID starts with this. */
|
|
4
|
+
export declare const KOKO_OVERLAY_TEST_ID = "koko-agent-overlay";
|
|
5
|
+
/** Cursor layer — skipped in dump, but NOT hidden during tap (must stay visible). */
|
|
6
|
+
export declare const KOKO_CURSOR_TEST_ID = "koko-agent-cursor";
|
|
7
|
+
export type KokoOverlayLayerProps = {
|
|
8
|
+
children: ReactNode;
|
|
9
|
+
style?: StyleProp<ViewStyle>;
|
|
10
|
+
/**
|
|
11
|
+
* `box-none` (default): children receive touches; empty area passes through.
|
|
12
|
+
* `none`: entire layer ignores touches (cursor).
|
|
13
|
+
* `auto`: layer blocks (modal sheet content).
|
|
14
|
+
*/
|
|
15
|
+
pointerEvents?: 'box-none' | 'none' | 'auto' | 'box-only';
|
|
16
|
+
/** Override testID / nativeID (default: koko-agent-overlay). */
|
|
17
|
+
testID?: string;
|
|
18
|
+
};
|
|
19
|
+
/**
|
|
20
|
+
* Host for SDK chrome (progress / cursor / sheet / dialogs).
|
|
21
|
+
* Marked so native dump & agent taps can ignore / pierce this layer.
|
|
22
|
+
*/
|
|
23
|
+
export declare function KokoOverlayLayer({ children, style, pointerEvents, testID, }: KokoOverlayLayerProps): React.JSX.Element;
|
|
24
|
+
export declare const overlayFill: {
|
|
25
|
+
fill: {
|
|
26
|
+
zIndex: number;
|
|
27
|
+
elevation: number;
|
|
28
|
+
position: "absolute";
|
|
29
|
+
left: 0;
|
|
30
|
+
right: 0;
|
|
31
|
+
top: 0;
|
|
32
|
+
bottom: 0;
|
|
33
|
+
};
|
|
34
|
+
};
|
|
35
|
+
//# sourceMappingURL=KokoOverlayLayer.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"KokoOverlayLayer.d.ts","sourceRoot":"","sources":["../../../../src/ui/KokoOverlayLayer.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAC9C,OAAO,EAAoB,KAAK,SAAS,EAAE,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAEhF,+EAA+E;AAC/E,eAAO,MAAM,oBAAoB,uBAAuB,CAAC;AACzD,qFAAqF;AACrF,eAAO,MAAM,mBAAmB,sBAAsB,CAAC;AAEvD,MAAM,MAAM,qBAAqB,GAAG;IAClC,QAAQ,EAAE,SAAS,CAAC;IACpB,KAAK,CAAC,EAAE,SAAS,CAAC,SAAS,CAAC,CAAC;IAC7B;;;;OAIG;IACH,aAAa,CAAC,EAAE,UAAU,GAAG,MAAM,GAAG,MAAM,GAAG,UAAU,CAAC;IAC1D,gEAAgE;IAChE,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB,CAAC;AAEF;;;GAGG;AACH,wBAAgB,gBAAgB,CAAC,EAC/B,QAAQ,EACR,KAAK,EACL,aAA0B,EAC1B,MAA6B,GAC9B,EAAE,qBAAqB,qBAcvB;AAED,eAAO,MAAM,WAAW;;;;;;;;;;CAMtB,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* Karaoke-style subtitle for the current task action.
|
|
4
|
+
* Prefer KokoObserver progress pill in the default UX; kept for custom layouts.
|
|
5
|
+
*/
|
|
6
|
+
export declare function KokoSubtitle(): React.JSX.Element | null;
|
|
7
|
+
//# sourceMappingURL=KokoSubtitle.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"KokoSubtitle.d.ts","sourceRoot":"","sources":["../../../../src/ui/KokoSubtitle.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA4B,MAAM,OAAO,CAAC;AAIjD;;;GAGG;AACH,wBAAgB,YAAY,6BAuC3B"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* @deprecated Prefer KokoChatSheet via KokoObserver / KokoEntryButton.
|
|
4
|
+
* Legacy inline task list; maps to sheetOpen for expand/collapse.
|
|
5
|
+
*/
|
|
6
|
+
export declare function KokoTaskPanel(): React.JSX.Element | null;
|
|
7
|
+
//# sourceMappingURL=KokoTaskPanel.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"KokoTaskPanel.d.ts","sourceRoot":"","sources":["../../../../src/ui/KokoTaskPanel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAkB,MAAM,OAAO,CAAC;AAmFvC;;;GAGG;AACH,wBAAgB,aAAa,6BAiE5B"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import React, { type ReactNode } from 'react';
|
|
2
|
+
import { type ViewStyle } from 'react-native';
|
|
3
|
+
type OverlayProps = {
|
|
4
|
+
children: ReactNode;
|
|
5
|
+
/** Remount / bring-to-front token (host FullWindowOverlay). */
|
|
6
|
+
liftToken?: number;
|
|
7
|
+
style?: ViewStyle;
|
|
8
|
+
};
|
|
9
|
+
/**
|
|
10
|
+
* Host chrome above native Settings / stack modals.
|
|
11
|
+
*
|
|
12
|
+
* Prefer FullWindowOverlay: it adds a view to the window rather than presenting
|
|
13
|
+
* a view controller, so `pointerEvents="box-none"` lets the user keep using the
|
|
14
|
+
* App underneath while a task runs. An RN Modal is its own iOS window and
|
|
15
|
+
* swallows every touch that is not aimed at the chrome itself — the agent does
|
|
16
|
+
* not notice, because the native tap skips Koko chrome windows, but the user
|
|
17
|
+
* cannot tap anything until the task ends.
|
|
18
|
+
*
|
|
19
|
+
* Modal stays as the fallback for hosts without react-native-screens, and
|
|
20
|
+
* `forceModalOverlay` keeps it reachable if a host needs it.
|
|
21
|
+
*/
|
|
22
|
+
export declare function KokoHostOverlay({ children, liftToken, style, forceModalOverlay, }: OverlayProps & {
|
|
23
|
+
forceModalOverlay?: boolean;
|
|
24
|
+
}): React.JSX.Element;
|
|
25
|
+
/** Whether this build can pierce native-stack modals via screens overlay. */
|
|
26
|
+
export declare function kokoHostOverlayUsesScreens(): boolean;
|
|
27
|
+
export {};
|
|
28
|
+
//# sourceMappingURL=hostOverlay.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"hostOverlay.d.ts","sourceRoot":"","sources":["../../../../src/ui/hostOverlay.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAsB,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAClE,OAAO,EAKL,KAAK,SAAS,EACf,MAAM,cAAc,CAAC;AAGtB,KAAK,YAAY,GAAG;IAClB,QAAQ,EAAE,SAAS,CAAC;IACpB,+DAA+D;IAC/D,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,SAAS,CAAC;CACnB,CAAC;AA0BF;;;;;;;;;;;;GAYG;AACH,wBAAgB,eAAe,CAAC,EAC9B,QAAQ,EACR,SAAa,EACb,KAAK,EACL,iBAAyB,GAC1B,EAAE,YAAY,GAAG;IAAE,iBAAiB,CAAC,EAAE,OAAO,CAAA;CAAE,qBAkEhD;AAED,6EAA6E;AAC7E,wBAAgB,0BAA0B,IAAI,OAAO,CAEpD"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { type StyleProp, type ViewStyle } from 'react-native';
|
|
3
|
+
/** Minimal vector-less icons for SDK UI (no icon font dependency). */
|
|
4
|
+
export declare function IconClose({ color, size, style, }: {
|
|
5
|
+
color?: string;
|
|
6
|
+
size?: number;
|
|
7
|
+
style?: StyleProp<ViewStyle>;
|
|
8
|
+
}): React.JSX.Element;
|
|
9
|
+
export declare function IconStop({ color, size, style, }: {
|
|
10
|
+
color?: string;
|
|
11
|
+
size?: number;
|
|
12
|
+
style?: StyleProp<ViewStyle>;
|
|
13
|
+
}): React.JSX.Element;
|
|
14
|
+
/** Checkmark (two bars) for success result. */
|
|
15
|
+
export declare function IconCheck({ color, size, style, }: {
|
|
16
|
+
color?: string;
|
|
17
|
+
size?: number;
|
|
18
|
+
style?: StyleProp<ViewStyle>;
|
|
19
|
+
}): React.JSX.Element;
|
|
20
|
+
/** Horizontal dash for cancelled. */
|
|
21
|
+
export declare function IconDash({ color, size, style, }: {
|
|
22
|
+
color?: string;
|
|
23
|
+
size?: number;
|
|
24
|
+
style?: StyleProp<ViewStyle>;
|
|
25
|
+
}): React.JSX.Element;
|
|
26
|
+
//# sourceMappingURL=icons.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"icons.d.ts","sourceRoot":"","sources":["../../../../src/ui/icons.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAoB,KAAK,SAAS,EAAE,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAEhF,sEAAsE;AAEtE,wBAAgB,SAAS,CAAC,EACxB,KAAgC,EAChC,IAAS,EACT,KAAK,GACN,EAAE;IACD,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,SAAS,CAAC,SAAS,CAAC,CAAC;CAC9B,qBA8BA;AAED,wBAAgB,QAAQ,CAAC,EACvB,KAAc,EACd,IAAS,EACT,KAAK,GACN,EAAE;IACD,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,SAAS,CAAC,SAAS,CAAC,CAAC;CAC9B,qBAeA;AAED,+CAA+C;AAC/C,wBAAgB,SAAS,CAAC,EACxB,KAAc,EACd,IAAS,EACT,KAAK,GACN,EAAE;IACD,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,SAAS,CAAC,SAAS,CAAC,CAAC;CAC9B,qBA8BA;AAED,qCAAqC;AACrC,wBAAgB,QAAQ,CAAC,EACvB,KAAc,EACd,IAAS,EACT,KAAK,GACN,EAAE;IACD,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,SAAS,CAAC,SAAS,CAAC,CAAC;CAC9B,qBAgBA"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import type { Point } from '../types';
|
|
2
|
+
export type ChromeRect = {
|
|
3
|
+
x: number;
|
|
4
|
+
y: number;
|
|
5
|
+
width: number;
|
|
6
|
+
height: number;
|
|
7
|
+
};
|
|
8
|
+
export declare function setProgressChromeFrame(rect: ChromeRect | null): void;
|
|
9
|
+
export declare function getProgressChromeFrame(): ChromeRect | null;
|
|
10
|
+
/**
|
|
11
|
+
* Clearance rect = where the chrome actually is, padded for hitSlop.
|
|
12
|
+
*
|
|
13
|
+
* Follows the chrome once the user drags it; the fixed bottom-right band is
|
|
14
|
+
* only a guess for before the first measurement lands. Blanketing the corner
|
|
15
|
+
* regardless would both hide host controls the chrome has been moved off of
|
|
16
|
+
* and keep swallowing tab-bar centres that were never covered.
|
|
17
|
+
*/
|
|
18
|
+
export declare function getChromeClearanceRect(): ChromeRect;
|
|
19
|
+
export declare function pointOverlapsProgressChrome(point: Point, pad?: number): boolean;
|
|
20
|
+
export declare function pointsOverlapProgressChrome(points: Point[], pad?: number): boolean;
|
|
21
|
+
//# sourceMappingURL=progressChrome.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"progressChrome.d.ts","sourceRoot":"","sources":["../../../../src/ui/progressChrome.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,UAAU,CAAC;AAEtC,MAAM,MAAM,UAAU,GAAG;IACvB,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,MAAM,CAAC;IACV,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;CAChB,CAAC;AAKF,wBAAgB,sBAAsB,CAAC,IAAI,EAAE,UAAU,GAAG,IAAI,QAE7D;AAED,wBAAgB,sBAAsB,IAAI,UAAU,GAAG,IAAI,CAE1D;AAkBD;;;;;;;GAOG;AACH,wBAAgB,sBAAsB,IAAI,UAAU,CAUnD;AAED,wBAAgB,2BAA2B,CAAC,KAAK,EAAE,KAAK,EAAE,GAAG,SAAK,GAAG,OAAO,CAQ3E;AAED,wBAAgB,2BAA2B,CACzC,MAAM,EAAE,KAAK,EAAE,EACf,GAAG,SAAK,GACP,OAAO,CAET"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export type SafeAreaInsets = {
|
|
2
|
+
top: number;
|
|
3
|
+
right: number;
|
|
4
|
+
bottom: number;
|
|
5
|
+
left: number;
|
|
6
|
+
};
|
|
7
|
+
/**
|
|
8
|
+
* Optional safe-area without requiring react-native-safe-area-context as peer.
|
|
9
|
+
* Prefers live context → native initial metrics → platform heuristics (Modal-safe).
|
|
10
|
+
*/
|
|
11
|
+
export declare function useSafeAreaInsetsOptional(): SafeAreaInsets;
|
|
12
|
+
//# sourceMappingURL=safeArea.d.ts.map
|