@mobileai/react-native 0.9.27 → 0.9.29

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (65) hide show
  1. package/README.md +28 -16
  2. package/android/build.gradle +17 -0
  3. package/android/src/main/java/com/mobileai/overlay/FloatingOverlayDialogRootViewGroup.kt +243 -0
  4. package/android/src/main/java/com/mobileai/overlay/FloatingOverlayView.kt +281 -87
  5. package/android/src/newarch/com/mobileai/overlay/FloatingOverlayViewManager.kt +52 -17
  6. package/android/src/oldarch/com/mobileai/overlay/FloatingOverlayViewManager.kt +49 -2
  7. package/bin/generate-map.cjs +45 -6
  8. package/ios/MobileAIFloatingOverlayComponentView.h +8 -0
  9. package/ios/MobileAIFloatingOverlayComponentView.mm +12 -41
  10. package/ios/Podfile +63 -0
  11. package/ios/Podfile.lock +2290 -0
  12. package/ios/Podfile.properties.json +4 -0
  13. package/ios/mobileaireactnative/AppDelegate.swift +69 -0
  14. package/ios/mobileaireactnative/Images.xcassets/AppIcon.appiconset/Contents.json +13 -0
  15. package/ios/mobileaireactnative/Images.xcassets/Contents.json +6 -0
  16. package/ios/mobileaireactnative/Images.xcassets/SplashScreenLegacy.imageset/Contents.json +21 -0
  17. package/ios/mobileaireactnative/Images.xcassets/SplashScreenLegacy.imageset/SplashScreenLegacy.png +0 -0
  18. package/ios/mobileaireactnative/Info.plist +55 -0
  19. package/ios/mobileaireactnative/PrivacyInfo.xcprivacy +48 -0
  20. package/ios/mobileaireactnative/SplashScreen.storyboard +47 -0
  21. package/ios/mobileaireactnative/Supporting/Expo.plist +6 -0
  22. package/ios/mobileaireactnative/mobileaireactnative-Bridging-Header.h +3 -0
  23. package/ios/mobileaireactnative.xcodeproj/project.pbxproj +547 -0
  24. package/ios/mobileaireactnative.xcodeproj/xcshareddata/xcschemes/mobileaireactnative.xcscheme +88 -0
  25. package/ios/mobileaireactnative.xcworkspace/contents.xcworkspacedata +10 -0
  26. package/lib/module/components/AIAgent.js +501 -191
  27. package/lib/module/components/AgentChatBar.js +250 -59
  28. package/lib/module/components/FloatingOverlayWrapper.js +68 -32
  29. package/lib/module/config/endpoints.js +22 -1
  30. package/lib/module/core/AgentRuntime.js +110 -8
  31. package/lib/module/core/FiberTreeWalker.js +211 -10
  32. package/lib/module/core/OutcomeVerifier.js +149 -0
  33. package/lib/module/core/systemPrompt.js +96 -25
  34. package/lib/module/providers/GeminiProvider.js +9 -3
  35. package/lib/module/services/telemetry/TelemetryService.js +21 -2
  36. package/lib/module/services/telemetry/TouchAutoCapture.js +235 -38
  37. package/lib/module/services/telemetry/analyticsLabeling.js +187 -0
  38. package/lib/module/specs/FloatingOverlayNativeComponent.ts +7 -1
  39. package/lib/module/support/supportPrompt.js +22 -7
  40. package/lib/module/support/supportStyle.js +55 -0
  41. package/lib/module/support/types.js +2 -0
  42. package/lib/module/tools/typeTool.js +20 -0
  43. package/lib/module/utils/humanizeScreenName.js +49 -0
  44. package/lib/typescript/src/components/AIAgent.d.ts +6 -2
  45. package/lib/typescript/src/components/AgentChatBar.d.ts +15 -1
  46. package/lib/typescript/src/components/FloatingOverlayWrapper.d.ts +22 -10
  47. package/lib/typescript/src/config/endpoints.d.ts +4 -0
  48. package/lib/typescript/src/core/AgentRuntime.d.ts +12 -3
  49. package/lib/typescript/src/core/FiberTreeWalker.d.ts +12 -1
  50. package/lib/typescript/src/core/OutcomeVerifier.d.ts +46 -0
  51. package/lib/typescript/src/core/systemPrompt.d.ts +3 -10
  52. package/lib/typescript/src/core/types.d.ts +63 -0
  53. package/lib/typescript/src/index.d.ts +1 -0
  54. package/lib/typescript/src/services/telemetry/TelemetryService.d.ts +7 -1
  55. package/lib/typescript/src/services/telemetry/TouchAutoCapture.d.ts +6 -1
  56. package/lib/typescript/src/services/telemetry/analyticsLabeling.d.ts +20 -0
  57. package/lib/typescript/src/services/telemetry/types.d.ts +1 -1
  58. package/lib/typescript/src/specs/FloatingOverlayNativeComponent.d.ts +5 -0
  59. package/lib/typescript/src/support/index.d.ts +1 -0
  60. package/lib/typescript/src/support/supportStyle.d.ts +9 -0
  61. package/lib/typescript/src/support/types.d.ts +3 -0
  62. package/lib/typescript/src/utils/humanizeScreenName.d.ts +6 -0
  63. package/package.json +10 -10
  64. package/src/specs/FloatingOverlayNativeComponent.ts +7 -1
  65. package/ios/MobileAIPilotIntents.swift +0 -51
@@ -0,0 +1,4 @@
1
+ {
2
+ "expo.jsEngine": "hermes",
3
+ "EX_DEV_CLIENT_NETWORK_INSPECTOR": "true"
4
+ }
@@ -0,0 +1,69 @@
1
+ internal import Expo
2
+ import React
3
+ import ReactAppDependencyProvider
4
+
5
+ @main
6
+ class AppDelegate: ExpoAppDelegate {
7
+ var window: UIWindow?
8
+
9
+ var reactNativeDelegate: ExpoReactNativeFactoryDelegate?
10
+ var reactNativeFactory: RCTReactNativeFactory?
11
+
12
+ public override func application(
13
+ _ application: UIApplication,
14
+ didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? = nil
15
+ ) -> Bool {
16
+ let delegate = ReactNativeDelegate()
17
+ let factory = ExpoReactNativeFactory(delegate: delegate)
18
+ delegate.dependencyProvider = RCTAppDependencyProvider()
19
+
20
+ reactNativeDelegate = delegate
21
+ reactNativeFactory = factory
22
+
23
+ #if os(iOS) || os(tvOS)
24
+ window = UIWindow(frame: UIScreen.main.bounds)
25
+ factory.startReactNative(
26
+ withModuleName: "main",
27
+ in: window,
28
+ launchOptions: launchOptions)
29
+ #endif
30
+
31
+ return super.application(application, didFinishLaunchingWithOptions: launchOptions)
32
+ }
33
+
34
+ // Linking API
35
+ public override func application(
36
+ _ app: UIApplication,
37
+ open url: URL,
38
+ options: [UIApplication.OpenURLOptionsKey: Any] = [:]
39
+ ) -> Bool {
40
+ return super.application(app, open: url, options: options) || RCTLinkingManager.application(app, open: url, options: options)
41
+ }
42
+
43
+ // Universal Links
44
+ public override func application(
45
+ _ application: UIApplication,
46
+ continue userActivity: NSUserActivity,
47
+ restorationHandler: @escaping ([UIUserActivityRestoring]?) -> Void
48
+ ) -> Bool {
49
+ let result = RCTLinkingManager.application(application, continue: userActivity, restorationHandler: restorationHandler)
50
+ return super.application(application, continue: userActivity, restorationHandler: restorationHandler) || result
51
+ }
52
+ }
53
+
54
+ class ReactNativeDelegate: ExpoReactNativeFactoryDelegate {
55
+ // Extension point for config-plugins
56
+
57
+ override func sourceURL(for bridge: RCTBridge) -> URL? {
58
+ // needed to return the correct URL for expo-dev-client.
59
+ bridge.bundleURL ?? bundleURL()
60
+ }
61
+
62
+ override func bundleURL() -> URL? {
63
+ #if DEBUG
64
+ return RCTBundleURLProvider.sharedSettings().jsBundleURL(forBundleRoot: ".expo/.virtual-metro-entry")
65
+ #else
66
+ return Bundle.main.url(forResource: "main", withExtension: "jsbundle")
67
+ #endif
68
+ }
69
+ }
@@ -0,0 +1,13 @@
1
+ {
2
+ "images" : [
3
+ {
4
+ "idiom" : "universal",
5
+ "platform" : "ios",
6
+ "size" : "1024x1024"
7
+ }
8
+ ],
9
+ "info" : {
10
+ "version" : 1,
11
+ "author" : "expo"
12
+ }
13
+ }
@@ -0,0 +1,6 @@
1
+ {
2
+ "info" : {
3
+ "version" : 1,
4
+ "author" : "expo"
5
+ }
6
+ }
@@ -0,0 +1,21 @@
1
+ {
2
+ "images" : [
3
+ {
4
+ "filename" : "SplashScreenLegacy.png",
5
+ "idiom" : "universal",
6
+ "scale" : "1x"
7
+ },
8
+ {
9
+ "idiom" : "universal",
10
+ "scale" : "2x"
11
+ },
12
+ {
13
+ "idiom" : "universal",
14
+ "scale" : "3x"
15
+ }
16
+ ],
17
+ "info" : {
18
+ "author" : "xcode",
19
+ "version" : 1
20
+ }
21
+ }
@@ -0,0 +1,55 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3
+ <plist version="1.0">
4
+ <dict>
5
+ <key>CADisableMinimumFrameDurationOnPhone</key>
6
+ <true/>
7
+ <key>CFBundleDevelopmentRegion</key>
8
+ <string>$(DEVELOPMENT_LANGUAGE)</string>
9
+ <key>CFBundleExecutable</key>
10
+ <string>$(EXECUTABLE_NAME)</string>
11
+ <key>CFBundleIdentifier</key>
12
+ <string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
13
+ <key>CFBundleInfoDictionaryVersion</key>
14
+ <string>6.0</string>
15
+ <key>CFBundleName</key>
16
+ <string>$(PRODUCT_NAME)</string>
17
+ <key>CFBundlePackageType</key>
18
+ <string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string>
19
+ <key>CFBundleShortVersionString</key>
20
+ <string>1.0</string>
21
+ <key>CFBundleSignature</key>
22
+ <string>????</string>
23
+ <key>CFBundleVersion</key>
24
+ <string>1</string>
25
+ <key>LSMinimumSystemVersion</key>
26
+ <string>12.0</string>
27
+ <key>LSRequiresIPhoneOS</key>
28
+ <true/>
29
+ <key>NSAppTransportSecurity</key>
30
+ <dict>
31
+ <key>NSAllowsArbitraryLoads</key>
32
+ <false/>
33
+ <key>NSAllowsLocalNetworking</key>
34
+ <true/>
35
+ </dict>
36
+ <key>RCTNewArchEnabled</key>
37
+ <true/>
38
+ <key>UILaunchStoryboardName</key>
39
+ <string>SplashScreen</string>
40
+ <key>UIRequiredDeviceCapabilities</key>
41
+ <array>
42
+ <string>arm64</string>
43
+ </array>
44
+ <key>UIStatusBarStyle</key>
45
+ <string>UIStatusBarStyleDefault</string>
46
+ <key>UISupportedInterfaceOrientations</key>
47
+ <array>
48
+ <string>UIInterfaceOrientationPortrait</string>
49
+ <string>UIInterfaceOrientationLandscapeLeft</string>
50
+ <string>UIInterfaceOrientationLandscapeRight</string>
51
+ </array>
52
+ <key>UIViewControllerBasedStatusBarAppearance</key>
53
+ <false/>
54
+ </dict>
55
+ </plist>
@@ -0,0 +1,48 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3
+ <plist version="1.0">
4
+ <dict>
5
+ <key>NSPrivacyAccessedAPITypes</key>
6
+ <array>
7
+ <dict>
8
+ <key>NSPrivacyAccessedAPIType</key>
9
+ <string>NSPrivacyAccessedAPICategoryUserDefaults</string>
10
+ <key>NSPrivacyAccessedAPITypeReasons</key>
11
+ <array>
12
+ <string>CA92.1</string>
13
+ </array>
14
+ </dict>
15
+ <dict>
16
+ <key>NSPrivacyAccessedAPIType</key>
17
+ <string>NSPrivacyAccessedAPICategoryFileTimestamp</string>
18
+ <key>NSPrivacyAccessedAPITypeReasons</key>
19
+ <array>
20
+ <string>0A2A.1</string>
21
+ <string>3B52.1</string>
22
+ <string>C617.1</string>
23
+ </array>
24
+ </dict>
25
+ <dict>
26
+ <key>NSPrivacyAccessedAPIType</key>
27
+ <string>NSPrivacyAccessedAPICategoryDiskSpace</string>
28
+ <key>NSPrivacyAccessedAPITypeReasons</key>
29
+ <array>
30
+ <string>E174.1</string>
31
+ <string>85F4.1</string>
32
+ </array>
33
+ </dict>
34
+ <dict>
35
+ <key>NSPrivacyAccessedAPIType</key>
36
+ <string>NSPrivacyAccessedAPICategorySystemBootTime</string>
37
+ <key>NSPrivacyAccessedAPITypeReasons</key>
38
+ <array>
39
+ <string>35F9.1</string>
40
+ </array>
41
+ </dict>
42
+ </array>
43
+ <key>NSPrivacyCollectedDataTypes</key>
44
+ <array/>
45
+ <key>NSPrivacyTracking</key>
46
+ <false/>
47
+ </dict>
48
+ </plist>
@@ -0,0 +1,47 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="24093.7" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES" initialViewController="EXPO-VIEWCONTROLLER-1">
3
+ <device id="retina6_12" orientation="portrait" appearance="light"/>
4
+ <dependencies>
5
+ <deployment identifier="iOS"/>
6
+ <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="24053.1"/>
7
+ <capability name="Named colors" minToolsVersion="9.0"/>
8
+ <capability name="Safe area layout guides" minToolsVersion="9.0"/>
9
+ <capability name="System colors in document resources" minToolsVersion="11.0"/>
10
+ <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
11
+ </dependencies>
12
+ <scenes>
13
+ <!--View Controller-->
14
+ <scene sceneID="EXPO-SCENE-1">
15
+ <objects>
16
+ <viewController storyboardIdentifier="SplashScreenViewController" id="EXPO-VIEWCONTROLLER-1" sceneMemberID="viewController">
17
+ <view key="view" userInteractionEnabled="NO" contentMode="scaleToFill" insetsLayoutMarginsFromSafeArea="NO" id="EXPO-ContainerView" userLabel="ContainerView">
18
+ <rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
19
+ <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
20
+ <subviews>
21
+ <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="SplashScreen" translatesAutoresizingMaskIntoConstraints="NO" id="EXPO-SplashScreen" userLabel="SplashScreen">
22
+ <rect key="frame" x="146.66666666666666" y="381" width="100" height="90.333333333333314"/>
23
+ <accessibility key="accessibilityConfiguration">
24
+ <accessibilityTraits key="traits" image="YES" notEnabled="YES"/>
25
+ </accessibility>
26
+ </imageView>
27
+ </subviews>
28
+ <viewLayoutGuide key="safeArea" id="Rmq-lb-GrQ"/>
29
+ <constraints>
30
+ <constraint firstItem="EXPO-SplashScreen" firstAttribute="centerY" secondItem="EXPO-ContainerView" secondAttribute="centerY" id="0VC-Wk-OaO"/>
31
+ <constraint firstItem="EXPO-SplashScreen" firstAttribute="centerX" secondItem="EXPO-ContainerView" secondAttribute="centerX" id="zR4-NK-mVN"/>
32
+ </constraints>
33
+ <color key="backgroundColor" systemColor="systemBackgroundColor"/>
34
+ </view>
35
+ </viewController>
36
+ <placeholder placeholderIdentifier="IBFirstResponder" id="EXPO-PLACEHOLDER-1" userLabel="First Responder" sceneMemberID="firstResponder"/>
37
+ </objects>
38
+ <point key="canvasLocation" x="0.0" y="0.0"/>
39
+ </scene>
40
+ </scenes>
41
+ <resources>
42
+ <image name="SplashScreenLogo" width="100" height="90.333335876464844"/>
43
+ <systemColor name="systemBackgroundColor">
44
+ <color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
45
+ </systemColor>
46
+ </resources>
47
+ </document>
@@ -0,0 +1,6 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3
+ <plist version="1.0">
4
+ <dict>
5
+ </dict>
6
+ </plist>
@@ -0,0 +1,3 @@
1
+ //
2
+ // Use this file to import your target's public headers that you would like to expose to Swift.
3
+ //