@blotch/angular-lynx-native 22.2.26 → 22.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +12 -10
- package/dist/android/project.d.ts +11 -0
- package/dist/android/project.d.ts.map +1 -1
- package/dist/android/project.js +36 -10
- package/dist/app-links.d.ts +53 -0
- package/dist/app-links.d.ts.map +1 -0
- package/dist/app-links.js +115 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +14 -0
- package/dist/ios/build.d.ts.map +1 -1
- package/dist/ios/build.js +5 -0
- package/dist/ios/project.d.ts +14 -1
- package/dist/ios/project.d.ts.map +1 -1
- package/dist/ios/project.js +46 -5
- package/dist/options.d.ts +11 -1
- package/dist/options.d.ts.map +1 -1
- package/dist/options.js +19 -0
- package/dist/permissions.d.ts.map +1 -1
- package/dist/permissions.js +7 -0
- package/package.json +1 -1
- package/templates/android/README.md +6 -4
- package/templates/android/app/build.gradle.kts +22 -13
- package/templates/android/app/proguard-rules.pro +67 -55
- package/templates/android/app/src/main/java/dev/angularlynx/shell/LinkingModule.kt +42 -0
- package/templates/android/app/src/main/java/dev/angularlynx/shell/MainActivity.kt +39 -6
- package/templates/android/app/src/main/java/dev/angularlynx/shell/ShellApplication.kt +15 -0
- package/templates/android/app/src/main/java/dev/angularlynx/shell/ShellModule.kt +14 -0
- package/templates/android/build.gradle.kts +1 -1
- package/templates/android/gradle/wrapper/gradle-wrapper.jar +0 -0
- package/templates/android/gradle/wrapper/gradle-wrapper.properties +2 -2
- package/templates/android/gradlew.bat +41 -11
- package/templates/ios/App/AngularLynxWebGLContext.m +79 -5
- package/templates/ios/App/AppDelegate.swift +46 -0
- package/templates/ios/App/LinkingModule.swift +62 -1
- package/templates/ios/App/LynxViewController.swift +11 -5
- package/templates/ios/App/ShellModule.swift +26 -0
package/README.md
CHANGED
|
@@ -21,9 +21,11 @@ Both are one full-screen `LynxView` running `main.lynx.bundle`; Angular Router d
|
|
|
21
21
|
|
|
22
22
|
Both run Lynx's engine thread, where the main thread's JavaScript, and so the whole Angular app, runs with layout and Lynx's animator, off the platform's UI thread: Lynx's `MostOnTASM` thread strategy (`setThreadStrategyForRender(.mostOnTASM)`, `setThreadStrategyForRendering(ThreadStrategyForRendering.MOST_ON_TASM)`), where Lynx's default, and Lynx Explorer's, is `AllOnUI`. So change detection, a screen being built or a busy event handler doesn't freeze what UIKit and Android run themselves: a scroll view's momentum, typing in a text field, a web view. The cost is that the element tree reaches the screen a step later, after the flush crosses to the UI thread, and UI methods with it: the build plugin turns on Lynx's pending invokes (`enableElementInvokeUIMethodPendingTask`), which send a method after the flush that makes the element's UI. A `<list>` needs `enable-async-list` under this strategy, which the runtime sets on every list. The main-thread modules run on the engine thread too (below).
|
|
23
23
|
|
|
24
|
-
|
|
24
|
+
Release builds log only Lynx's warnings and errors. Lynx's iOS frameworks and Android AARs are built for release, where Lynx logs at INFO: a line for every touch move, hit test, flush, layout, event listener and main-thread module call, written as it's logged (`NSLog` on iOS, a call from native code into `android.util.Log` on Android), mostly on the engine thread and, during a touch, on the UI thread. So `AppDelegate` calls `SetMinimumLoggingLevel(.warning)` before anything else, under `#if !DEBUG`, and `ShellApplication` calls `LLog.setMinimumLoggingLevel(LLog.WARN)` when the app isn't debuggable, after `LynxEnv`'s init, which loads the native library the call needs. The development build (`ng serve --platform`) keeps every line. The app's JavaScript errors still reach the system log, since Lynx logs them as errors, and its `console` output is unchanged: Lynx writes that whatever the level.
|
|
25
25
|
|
|
26
|
-
Both
|
|
26
|
+
Both send the same global props, which the runtime's services read: `platform`, `theme` (again whenever the phone switches between light and dark), `appLocale` (the phone's language as a BCP 47 tag), `appTimeZone` (its time zone's IANA name, which the `intl` build option's `Intl.DateTimeFormat` uses), `isNotchScreen`, `edgeToEdge`, the safe-area insets `safeAreaTop`, `safeAreaBottom`, `safeAreaLeft` and `safeAreaRight` (again whenever they change), `osVersion` (which Lynx leaves out of the main thread's `SystemInfo`), the accessibility settings `reduceMotion`, `reduceTransparency` (iOS only) and `increaseContrast`, again whenever the user changes one, and `initialURL`, the link that started the app, if one did, with one of angular.json's `deepLinkSchemes` or an https link to its `appLinkDomains` (the scene's `connectionOptions.urlContexts`, or for a Universal Link its web browsing `userActivities`, on iOS, the launch intent's data on Android, unless the app was reopened from Recents), which `LynxLinking.getInitialURL()` returns and the router starts at. Android 12 and later also send `dynamicColors`, the wallpaper's Material 3 color roles in light and dark (`DynamicColors.kt`), again when the user changes their wallpaper or colors. Lynx Explorer sends `theme` and `isNotchScreen` too, but no `appLocale`, `appTimeZone`, `osVersion` or accessibility settings. See [`templates/android/README.md`](templates/android/README.md) for the Android shell's details.
|
|
27
|
+
|
|
28
|
+
Both register the native modules the runtime's services call, which Lynx Explorer doesn't have: `AngularLynxWebAuth` (`WebAuthModule.swift`, `WebAuthModule.kt`) opens `LynxWebAuthSession`'s sign-in page, in `ASWebAuthenticationSession` on iOS and a Custom Tab on Android, and returns the URL it redirects to. `AngularLynxLocalStorage` (`LocalStorageModule.swift`, `LocalStorageModule.kt`) keeps `LynxLocalStorage`'s values in a `UserDefaults` suite and a `SharedPreferences` file of their own. `AngularLynxSecureStorage` (`SecureStorageModule.swift`, `SecureStorageModule.kt`) keeps `LynxSecureStorage`'s in the Keychain on iOS and, on Android, in `SharedPreferences`, each value encrypted with AES-GCM by an Android Keystore key, a file Auto Backup leaves out (`res/xml/backup_rules.xml`, `data_extraction_rules.xml`). `AngularLynxLinking` (`LinkingModule.swift`, `LinkingModule.kt`) opens `LynxLinking`'s links: `openURL` with `UIApplication.open` and an `ACTION_VIEW` intent, `openInApp` in `SFSafariViewController` and a Custom Tab, and `canOpenURL` with `UIApplication.canOpenURL` and `resolveActivity`, which answer only for the schemes the generator writes from angular.json's `canOpenURLSchemes` (with `http`, `https`, `mailto`, `tel` and `sms`) into Info.plist's `LSApplicationQueriesSchemes` and the manifest's `<queries>`. It also has `takeURLs`, which hands `LynxLinking.onURL()` and the router the links that open the app while it's running: `SceneDelegate.scene(_:openURLContexts:)` and `scene(_:continue:)` (a Universal Link), and `MainActivity.onNewIntent` (after a waiting web sign-in has had its redirect) keep each one (`LinkCenter` in `LinkingModule.swift`, the module's companion on Android) and send the `angularLynxURL` global event, which the runtime answers by taking them, as `LynxShortcuts` does. `AngularLynxImagePicker` (`ImagePickerModule.swift`, `ImagePickerModule.kt`) lets the person pick a photo for `LynxImagePicker`, with `PHPickerViewController` on iOS and the Photo Picker on Android, neither of which needs a permission, and calls back with it as base64, re-encoded as an upright JPEG when the app asks for a smaller one or the photo is a format such as HEIC. `AngularLynxShare` (`ShareModule.swift`, `ShareModule.kt`) opens `LynxShare`'s share sheet, `UIActivityViewController` on iOS and an `ACTION_SEND` chooser on Android, with the files written to temporary files on iOS and shared through a `FileProvider` on Android. Save Image on iOS needs `NSPhotoLibraryAddUsageDescription`, which the generator always writes (angular.json's `permissions.savePhotos`, with a default). `AngularLynxShell` (`ShellModule.swift`, `ShellModule.kt`) has `hideSplashScreen`, which the runtime's `LynxSplashScreen` calls once the app's first screen is drawn (at Angular's first frame, or when `provideSplashScreen()` says): the phone takes a launch screen down at the app's first frame, which is the empty LynxView, so the iOS shell keeps a copy of it over the LynxView (`SplashScreen.swift`, the `LaunchBackground` color and `LaunchImage` image the generator writes from angular.json's `splash`) and Android's `MainActivity` keeps AndroidX's splash screen up (`installSplashScreen()`, `setKeepOnScreenCondition`), each fading it out when it's called, or five seconds after the app starts. It has `collectGarbage`, which the runtime calls once the app has released about a screen's worth of elements and settled: it reports moderate memory pressure with `LynxEnv.trimMemory`, which makes Lynx run a full collection of the main thread's JavaScript heap, freeing what PrimJS's routine collections leave behind of the screens that went. On Android it also connects the back button. Both shells report the system's memory warnings to `trimMemory` too, and leaving the screen. `AngularLynxShortcuts` (`ShortcutsModule.swift`, `ShortcutsModule.kt`) keeps the shortcuts the person ran until the runtime's `LynxShortcuts` takes them, with `take`, at startup and each time the shell sends the `angularLynxShortcut` global event, so the shortcut that started the app isn't lost and none is handled twice. The generator writes angular.json's `shortcuts` as App Intents on iOS (`App/AppShortcuts.swift`, with an `AppShortcutsProvider`: Xcode's App Intents step reads the titles and phrases out of the compiled code, so they have to be source), which Siri, Spotlight and the Shortcuts app run, and as static shortcuts on Android (`res/xml/shortcuts.xml`, with the titles in `res/values/shortcuts.xml`), in the menu a long press on the app's icon opens. Android starts a static shortcut's activity in a cleared task, which would end the running app, so they point at `ShortcutActivity`, which has a task of its own and passes the shortcut on to `MainActivity`.
|
|
27
29
|
|
|
28
30
|
Only the development build (`ng serve --platform`) loads from a dev server: the code is in `App/DevServer.swift` and `App/DevServerModules.swift` under `#if DEBUG`, and in the debug source set on Android (`app/src/debug`, with a no-op `DevServer` in `app/src/release`), so a release build can't be pointed anywhere else. `DevServer` reads the URL from the launch argument or intent extra and keeps it (`UserDefaults`, `SharedPreferences`), so the app opened from the home screen loads from the same server. The loaders (`BundleResourceFetcher.swift`, `ResourceFetchers.kt`) and `AngularLynxAssets` then fetch every relative URL, and on Android every URL on the address the bundle was built with, from the dev server instead of the app, uncached. When the bundle itself doesn't load, `DevServer` covers the page with a message and loads it again every two seconds. rspeedy's live reload client talks to Lynx DevTool, which the shells don't have: `NativeModules.LynxWebSocketModule` (through `@lynx-js/websocket`) for the dev server's socket and `NativeModules.LynxDevToolSetModule.invokeCdp` for a full reload (a DevTool protocol `Page.reload`). The development build registers modules under those names (`DevWebSocketModule`, `DevReloadModule`): a WebSocket with `URLSessionWebSocketTask` and OkHttp that sends the same `websocketOpen`, `websocketMessage`, `websocketClosed` and `websocketFailed` global events as Lynx DevTool's, and a `Page.reload` that loads the bundle again, as DevTool's `LynxPageReloadHelper` does. URLSession sends an empty `Sec-WebSocket-Protocol` header for an empty protocol list, which the dev server refuses, so the iOS socket passes none then. On Android, the debug build's `network_security_config.xml` allows plain HTTP to any host, since the app's own `fetch()` of an imported file goes to the address the bundle was built with; the release build's allows it to `localhost` alone.
|
|
29
31
|
|
|
@@ -31,15 +33,15 @@ Only the development build (`ng serve --platform`) loads from a dev server: the
|
|
|
31
33
|
|
|
32
34
|
Both link Lynx's XElement library, which holds `<input>`, `<textarea>`, `<overlay>`, `<svg>`, `<blur-view>`, `<viewpager>`, `<refresh>`, the `<scroll-coordinator>` family, `<webview>` and `<video>`. Lynx's core doesn't include these, and a host that doesn't register them renders nothing for those tags (on Android, nothing after them either). XElement's AnimaX and Markdown elements are left out: the runtime doesn't support them. On iOS, `<blur-view>` is XElement's with more of UIKit in it (`App/BlurView.swift`): a `blur-material` attribute for UIKit's adaptive blur materials, which the glass components draw their design before iOS 26 on (Lynx's blur-view has only the styles from before iOS 13); Liquid Glass that materializes, dissolves and eases between effects inside a `glass-container`, where Lynx's sets its effect at once; and a `glass-effect-id` attribute that pairs two glass shapes across a change so one morphs into the other (`App/GlassTransitions.swift`). `<webview>` loads through XElement's loader, wrapped (`App/WebViewLoader.swift`) to take the loader off its web view's script message handlers when the element goes: XElement's loader never does, so the loader and the web view kept each other, and the web view's WebContent process, for as long as the app ran (issue #397).
|
|
33
35
|
|
|
34
|
-
Both have `<canvas>` with WebGL2 (issue #211), which Lynx doesn't: a `canvas` element (`App/AngularLynxWebGL.m`'s `AngularLynxCanvas`, a `CAMetalLayer` view; `CanvasUI.kt`, a `TextureView`) and the `AngularLynxWebGL` module the runtime's WebGL2 context sends its calls to, which runs them on OpenGL ES 3.0 (`App/AngularLynxWebGLContext.m`, `WebGLContext.kt`). On iOS that's [ANGLE](https://chromium.googlesource.com/angle/angle)'s OpenGL ES, on Metal, which Safari draws WebGL with too: iOS's own OpenGL ES is deprecated, and the Simulator runs it on the CPU, at seconds a frame for a lit three.js scene (issue #238), where Metal draws on the Mac's GPU. ANGLE's `libEGL` and `libGLESv2` frameworks, and its headers, come in the Lynx frameworks zip (below). Android's OpenGL ES is the phone's, which the emulator already runs on the Mac's GPU. The runtime runs on Lynx's main thread and WebGL needs answers synchronously, so both turn on main-thread modules (`enableMTSModule`): the config's modules are then callable from main-thread JavaScript as `lynx.module(name)`, and Lynx calls them on its engine thread, not the UI thread. An EGL context is current on one thread at a time, so GL runs there too, while the canvas's view lives on the UI thread. On iOS the view hands the context what it draws into, its `CAMetalLayer` and its size in pixels (`AngularLynxCanvasTarget`), through Lynx's `runOnTasmThread:`, so the contexts and the canvas registry are the engine thread's alone, and the context keeps its EGL context current there between batches; it sets the view's opacity back on the UI thread. On Android each call already makes the context current and puts back what was current before, so `WebGLContext` and `CanvasRegistry` are locked instead: the `TextureView`'s surface callbacks, on the UI thread, wait for a batch to end, which keeps the EGL surface from outliving the `SurfaceTexture` it draws to. The WebGL module's `encodeImage`, behind `canvas.toBlob()` and `toDataURL()`, reads the drawing buffer and encodes it as a PNG or JPEG with ImageIO or `Bitmap.compress
|
|
36
|
+
Both have `<canvas>` with WebGL2 (issue #211), which Lynx doesn't: a `canvas` element (`App/AngularLynxWebGL.m`'s `AngularLynxCanvas`, a `CAMetalLayer` view; `CanvasUI.kt`, a `TextureView`) and the `AngularLynxWebGL` module the runtime's WebGL2 context sends its calls to, which runs them on OpenGL ES 3.0 (`App/AngularLynxWebGLContext.m`, `WebGLContext.kt`). On iOS that's [ANGLE](https://chromium.googlesource.com/angle/angle)'s OpenGL ES, on Metal, which Safari draws WebGL with too: iOS's own OpenGL ES is deprecated, and the Simulator runs it on the CPU, at seconds a frame for a lit three.js scene (issue #238), where Metal draws on the Mac's GPU. ANGLE's `libEGL` and `libGLESv2` frameworks, and its headers, come in the Lynx frameworks zip (below). Android's OpenGL ES is the phone's, which the emulator already runs on the Mac's GPU. The runtime runs on Lynx's main thread and WebGL needs answers synchronously, so both turn on main-thread modules (`enableMTSModule`): the config's modules are then callable from main-thread JavaScript as `lynx.module(name)`, and Lynx calls them on its engine thread, not the UI thread. An EGL context is current on one thread at a time, so GL runs there too, while the canvas's view lives on the UI thread. On iOS the view hands the context what it draws into, its `CAMetalLayer` and its size in pixels (`AngularLynxCanvasTarget`), through Lynx's `runOnTasmThread:`, so the contexts and the canvas registry are the engine thread's alone, and the context keeps its EGL context current there between batches; it sets the view's opacity back on the UI thread. On Android each call already makes the context current and puts back what was current before, so `WebGLContext` and `CanvasRegistry` are locked instead: the `TextureView`'s surface callbacks, on the UI thread, wait for a batch to end, which keeps the EGL surface from outliving the `SurfaceTexture` it draws to. The WebGL module's `encodeImage`, behind `canvas.toBlob()` and `toDataURL()`, reads the drawing buffer and encodes it as a PNG or JPEG with ImageIO or `Bitmap.compress`. On iOS it, and `readPixels()` into an array, read through a pixel pack buffer of their own, mapped, since ANGLE on Metal is slow to read straight into memory; a `readPixels()` that GL rejects answers nothing, so the app's array keeps what it held, as WebGL leaves it. `AngularLynxAssets` (`App/AssetsModule.swift`, `AssetsModule.kt`) reads a file the app bundles for the main thread's `fetch`, which has no page URL to resolve `/static/...` against. The command numbers the WebGL module reads (`App/AngularLynxWebGLOps.h`, `WebGLOps.kt`) are generated from the runtime's `canvas/webgl-ops.ts` with `npm run generate:webgl-ops -w packages/native`; `scripts/webgl-ops.test.ts` fails when they're stale. UIKit's module imports Apple's OpenGL ES headers into every file, so `AngularLynxWebGLContext.m` turns off their deprecation warnings, which land on ANGLE's functions of the same names; the explicit link to `libGLESv2` comes before UIKit's automatic one to OpenGLES, so those calls bind to ANGLE.
|
|
35
37
|
|
|
36
|
-
| | iOS
|
|
37
|
-
| ---------------- |
|
|
38
|
-
| Language | Swift, scene lifecycle
|
|
39
|
-
| Lynx | 4.1.0, prebuilt XCFrameworks (below)
|
|
40
|
-
| XElement | Linked and registered (`App/XElementRegistry.swift`)
|
|
41
|
-
| Toolchain | Xcode 27, iOS 15+
|
|
42
|
-
| Generated config | `Config/App.xcconfig`, `App/Info.plist` markers
|
|
38
|
+
| | iOS | Android |
|
|
39
|
+
| ---------------- | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------- |
|
|
40
|
+
| Language | Swift, scene lifecycle | Kotlin |
|
|
41
|
+
| Lynx | 4.1.0, prebuilt XCFrameworks (below) | 4.1.0 AARs from Maven Central |
|
|
42
|
+
| XElement | Linked and registered (`App/XElementRegistry.swift`) | Linked and registered (`XElementBehaviors`) |
|
|
43
|
+
| Toolchain | Xcode 27, iOS 15+ | AGP 9.4, Gradle 9.6, JDK 17+, SDK 36, minSdk 24 |
|
|
44
|
+
| Generated config | `Config/App.xcconfig`, `App/Info.plist` markers, `Config/App.entitlements` (with `appLinkDomains`) | `angular-lynx.properties`, `AndroidManifest.xml` markers |
|
|
43
45
|
|
|
44
46
|
## Lynx for iOS
|
|
45
47
|
|
|
@@ -17,6 +17,17 @@ export declare const androidGenerator: PlatformGenerator;
|
|
|
17
17
|
export declare const propertyValue: (value: string) => string;
|
|
18
18
|
export declare const properties: (app: ResolvedApp) => string;
|
|
19
19
|
export declare const permissionEntries: (app: ResolvedApp) => string;
|
|
20
|
+
/**
|
|
21
|
+
* The intent filters for the links that open the app: one for the
|
|
22
|
+
* `deepLinkSchemes`, and one for https links to the `appLinkDomains`.
|
|
23
|
+
*
|
|
24
|
+
* The second is an App Link: `autoVerify` has Android check, when the app is
|
|
25
|
+
* installed, that each domain's assetlinks.json names the app and its
|
|
26
|
+
* signing key (see appLinkFiles), and then open its links in the app with
|
|
27
|
+
* no chooser. Android 12 and later open an unverified domain's links in the
|
|
28
|
+
* browser. The `<data>` elements of one filter combine, so the scheme goes
|
|
29
|
+
* with every host.
|
|
30
|
+
*/
|
|
20
31
|
export declare const deepLinkEntries: (app: ResolvedApp) => string;
|
|
21
32
|
/**
|
|
22
33
|
* The apps LinkingModule's canOpenURL can see from Android 11: those that
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"project.d.ts","sourceRoot":"","sources":["../../src/android/project.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AACxD,OAAO,EAEL,KAAK,WAAW,EAEjB,MAAM,eAAe,CAAC;AAevB;;;;;;;GAOG;AACH,eAAO,MAAM,gBAAgB,EAAE,iBA+B9B,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,aAAa,GAAI,OAAO,MAAM,WAOtC,CAAC;AAEN,eAAO,MAAM,UAAU,GAAI,KAAK,WAAW,KAAG,MAYhC,CAAC;AAEf,eAAO,MAAM,iBAAiB,GAAI,KAAK,WAAW,KAAG,MAiBpD,CAAC;AAEF,eAAO,MAAM,eAAe,GAAI,KAAK,WAAW,KAAG,
|
|
1
|
+
{"version":3,"file":"project.d.ts","sourceRoot":"","sources":["../../src/android/project.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AACxD,OAAO,EAEL,KAAK,WAAW,EAEjB,MAAM,eAAe,CAAC;AAevB;;;;;;;GAOG;AACH,eAAO,MAAM,gBAAgB,EAAE,iBA+B9B,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,aAAa,GAAI,OAAO,MAAM,WAOtC,CAAC;AAEN,eAAO,MAAM,UAAU,GAAI,KAAK,WAAW,KAAG,MAYhC,CAAC;AAEf,eAAO,MAAM,iBAAiB,GAAI,KAAK,WAAW,KAAG,MAiBpD,CAAC;AAEF;;;;;;;;;;GAUG;AACH,eAAO,MAAM,eAAe,GAAI,KAAK,WAAW,KAAG,MAuBrC,CAAC;AASf;;;;GAIG;AACH,eAAO,MAAM,cAAc,GAAI,KAAK,WAAW,KAAG,MAUpC,CAAC;AAOf;;;;;;;;;;GAUG;AACH,eAAO,MAAM,YAAY,GAAI,KAAK,WAAW,KAAG,MAgClC,CAAC;AAEf;;;;GAIG;AACH,eAAO,MAAM,cAAc,GAAI,MAAM,MAAM,KAAG,MAMpB,CAAC;AAE3B;;;GAGG;AACH,eAAO,MAAM,kBAAkB,GAAI,KAAK,WAAW,KAAG,MAWxC,CAAC;AAEf,2EAA2E;AAC3E,eAAO,MAAM,cAAc,GACzB,MAAK,MAAM,CAAC,UAAwB,KACnC,MAAM,GAAG,SAaX,CAAC"}
|
package/dist/android/project.js
CHANGED
|
@@ -76,16 +76,42 @@ export const permissionEntries = (app) => {
|
|
|
76
76
|
...features.map((name) => `<uses-feature android:name="${escapeXml(name)}" android:required="false" />`),
|
|
77
77
|
].join('\n');
|
|
78
78
|
};
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
79
|
+
/**
|
|
80
|
+
* The intent filters for the links that open the app: one for the
|
|
81
|
+
* `deepLinkSchemes`, and one for https links to the `appLinkDomains`.
|
|
82
|
+
*
|
|
83
|
+
* The second is an App Link: `autoVerify` has Android check, when the app is
|
|
84
|
+
* installed, that each domain's assetlinks.json names the app and its
|
|
85
|
+
* signing key (see appLinkFiles), and then open its links in the app with
|
|
86
|
+
* no chooser. Android 12 and later open an unverified domain's links in the
|
|
87
|
+
* browser. The `<data>` elements of one filter combine, so the scheme goes
|
|
88
|
+
* with every host.
|
|
89
|
+
*/
|
|
90
|
+
export const deepLinkEntries = (app) => [
|
|
91
|
+
...(app.deepLinkSchemes.length === 0
|
|
92
|
+
? []
|
|
93
|
+
: [
|
|
94
|
+
'<intent-filter>',
|
|
95
|
+
...VIEW_INTENT,
|
|
96
|
+
...app.deepLinkSchemes.map((scheme) => ` <data android:scheme="${escapeXml(scheme)}" />`),
|
|
97
|
+
'</intent-filter>',
|
|
98
|
+
]),
|
|
99
|
+
...(app.appLinkDomains.length === 0
|
|
100
|
+
? []
|
|
101
|
+
: [
|
|
102
|
+
'<intent-filter android:autoVerify="true">',
|
|
103
|
+
...VIEW_INTENT,
|
|
104
|
+
' <data android:scheme="https" />',
|
|
105
|
+
...app.appLinkDomains.map((domain) => ` <data android:host="${escapeXml(domain)}" />`),
|
|
106
|
+
'</intent-filter>',
|
|
107
|
+
]),
|
|
108
|
+
].join('\n');
|
|
109
|
+
/** What an intent filter for links a browser can follow opens on. */
|
|
110
|
+
const VIEW_INTENT = [
|
|
111
|
+
' <action android:name="android.intent.action.VIEW" />',
|
|
112
|
+
' <category android:name="android.intent.category.DEFAULT" />',
|
|
113
|
+
' <category android:name="android.intent.category.BROWSABLE" />',
|
|
114
|
+
];
|
|
89
115
|
/**
|
|
90
116
|
* The apps LinkingModule's canOpenURL can see from Android 11: those that
|
|
91
117
|
* open a URL with one of the schemes. resolveActivity() finds no other app,
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import type { ResolvedApp } from './options.ts';
|
|
2
|
+
/**
|
|
3
|
+
* The files each of `appLinkDomains` serves so its https links open the app.
|
|
4
|
+
* The phone opens a domain's links in the app only once the domain says the
|
|
5
|
+
* app is its own: iOS reads `/.well-known/apple-app-site-association`, through
|
|
6
|
+
* Apple's CDN, and Android checks `/.well-known/assetlinks.json` when the app
|
|
7
|
+
* is installed. The build can't put them on the site, so it writes them
|
|
8
|
+
* beside the app, ready to upload.
|
|
9
|
+
*
|
|
10
|
+
* Each goes at the root of each domain, over https, as `application/json`
|
|
11
|
+
* and with no redirect. A `*.example.com` domain's file goes on
|
|
12
|
+
* `example.com`.
|
|
13
|
+
*/
|
|
14
|
+
/** What iOS asks for and Android verifies, under the domain's root. */
|
|
15
|
+
export declare const APPLE_APP_SITE_ASSOCIATION = ".well-known/apple-app-site-association";
|
|
16
|
+
export declare const ASSET_LINKS = ".well-known/assetlinks.json";
|
|
17
|
+
/** In the iOS file where a build without `ios.teamId` knows no team. */
|
|
18
|
+
export declare const TEAM_ID_PLACEHOLDER = "TEAM_ID";
|
|
19
|
+
/** In the Android file where the build couldn't read the signing key. */
|
|
20
|
+
export declare const FINGERPRINT_PLACEHOLDER = "SHA256_FINGERPRINT";
|
|
21
|
+
/**
|
|
22
|
+
* apple-app-site-association: every path on the domain opens the app, whose
|
|
23
|
+
* ID iOS knows by its team. Narrow `components` on the site to leave some
|
|
24
|
+
* paths to the browser; a link the app doesn't route can also go elsewhere
|
|
25
|
+
* with `provideDeepLinkRoute()`.
|
|
26
|
+
*/
|
|
27
|
+
export declare const appleAppSiteAssociation: (app: ResolvedApp) => string;
|
|
28
|
+
/**
|
|
29
|
+
* assetlinks.json: the app, by its applicationId and the SHA-256 fingerprints
|
|
30
|
+
* of the certificates that sign it, may handle all of the domain's links.
|
|
31
|
+
*/
|
|
32
|
+
export declare const assetLinks: (app: ResolvedApp, fingerprints: readonly string[]) => string;
|
|
33
|
+
/**
|
|
34
|
+
* The SHA-256 fingerprints of the certificates that signed the APK, as
|
|
35
|
+
* assetlinks.json writes them (`AB:CD:…`), from the newest build tools'
|
|
36
|
+
* apksigner. Empty when there's no apksigner, or it can't read the APK.
|
|
37
|
+
*/
|
|
38
|
+
export declare const apkSignerFingerprints: (apk: string, sdk?: string | undefined) => Promise<string[]>;
|
|
39
|
+
/**
|
|
40
|
+
* Writes the platform's file for the app link domains into `outputDir`, and
|
|
41
|
+
* says where it goes. Returns its path, or undefined for an app without app
|
|
42
|
+
* links.
|
|
43
|
+
*/
|
|
44
|
+
export declare const writeAppLinkFile: ({ platform, app, outputDir, apk, log, warn, }: {
|
|
45
|
+
readonly platform: "ios" | "android";
|
|
46
|
+
readonly app: ResolvedApp;
|
|
47
|
+
readonly outputDir: string;
|
|
48
|
+
/** The APK the Android build signed, whose certificates the file names. */
|
|
49
|
+
readonly apk?: string;
|
|
50
|
+
readonly log: (message: string) => void;
|
|
51
|
+
readonly warn: (message: string) => void;
|
|
52
|
+
}) => Promise<string | undefined>;
|
|
53
|
+
//# sourceMappingURL=app-links.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"app-links.d.ts","sourceRoot":"","sources":["../src/app-links.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAGhD;;;;;;;;;;;GAWG;AAEH,uEAAuE;AACvE,eAAO,MAAM,0BAA0B,2CACG,CAAC;AAC3C,eAAO,MAAM,WAAW,gCAAgC,CAAC;AAEzD,wEAAwE;AACxE,eAAO,MAAM,mBAAmB,YAAY,CAAC;AAC7C,yEAAyE;AACzE,eAAO,MAAM,uBAAuB,uBAAuB,CAAC;AAE5D;;;;;GAKG;AACH,eAAO,MAAM,uBAAuB,GAAI,KAAK,WAAW,KAAG,MAcpD,CAAC;AAER;;;GAGG;AACH,eAAO,MAAM,UAAU,GACrB,KAAK,WAAW,EAChB,cAAc,SAAS,MAAM,EAAE,KAC9B,MAcI,CAAC;AAER;;;;GAIG;AACH,eAAO,MAAM,qBAAqB,GAChC,KAAK,MAAM,EACX,wBAAsB,KACrB,OAAO,CAAC,MAAM,EAAE,CASlB,CAAC;AAeF;;;;GAIG;AACH,eAAO,MAAM,gBAAgB,GAAU,+CAOpC;IACD,QAAQ,CAAC,QAAQ,EAAE,KAAK,GAAG,SAAS,CAAC;IACrC,QAAQ,CAAC,GAAG,EAAE,WAAW,CAAC;IAC1B,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,2EAA2E;IAC3E,QAAQ,CAAC,GAAG,CAAC,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,GAAG,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;IACxC,QAAQ,CAAC,IAAI,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;CAC1C,KAAG,OAAO,CAAC,MAAM,GAAG,SAAS,CA4C7B,CAAC"}
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
import { existsSync, mkdirSync, readdirSync, writeFileSync } from 'node:fs';
|
|
2
|
+
import path from 'node:path';
|
|
3
|
+
import { findAndroidSdk } from "./android/project.js";
|
|
4
|
+
import { capture } from "./process.js";
|
|
5
|
+
/**
|
|
6
|
+
* The files each of `appLinkDomains` serves so its https links open the app.
|
|
7
|
+
* The phone opens a domain's links in the app only once the domain says the
|
|
8
|
+
* app is its own: iOS reads `/.well-known/apple-app-site-association`, through
|
|
9
|
+
* Apple's CDN, and Android checks `/.well-known/assetlinks.json` when the app
|
|
10
|
+
* is installed. The build can't put them on the site, so it writes them
|
|
11
|
+
* beside the app, ready to upload.
|
|
12
|
+
*
|
|
13
|
+
* Each goes at the root of each domain, over https, as `application/json`
|
|
14
|
+
* and with no redirect. A `*.example.com` domain's file goes on
|
|
15
|
+
* `example.com`.
|
|
16
|
+
*/
|
|
17
|
+
/** What iOS asks for and Android verifies, under the domain's root. */
|
|
18
|
+
export const APPLE_APP_SITE_ASSOCIATION = '.well-known/apple-app-site-association';
|
|
19
|
+
export const ASSET_LINKS = '.well-known/assetlinks.json';
|
|
20
|
+
/** In the iOS file where a build without `ios.teamId` knows no team. */
|
|
21
|
+
export const TEAM_ID_PLACEHOLDER = 'TEAM_ID';
|
|
22
|
+
/** In the Android file where the build couldn't read the signing key. */
|
|
23
|
+
export const FINGERPRINT_PLACEHOLDER = 'SHA256_FINGERPRINT';
|
|
24
|
+
/**
|
|
25
|
+
* apple-app-site-association: every path on the domain opens the app, whose
|
|
26
|
+
* ID iOS knows by its team. Narrow `components` on the site to leave some
|
|
27
|
+
* paths to the browser; a link the app doesn't route can also go elsewhere
|
|
28
|
+
* with `provideDeepLinkRoute()`.
|
|
29
|
+
*/
|
|
30
|
+
export const appleAppSiteAssociation = (app) => `${JSON.stringify({
|
|
31
|
+
applinks: {
|
|
32
|
+
details: [
|
|
33
|
+
{
|
|
34
|
+
appIDs: [`${app.ios.teamId ?? TEAM_ID_PLACEHOLDER}.${app.id}`],
|
|
35
|
+
components: [{ '/': '*' }],
|
|
36
|
+
},
|
|
37
|
+
],
|
|
38
|
+
},
|
|
39
|
+
}, null, 2)}\n`;
|
|
40
|
+
/**
|
|
41
|
+
* assetlinks.json: the app, by its applicationId and the SHA-256 fingerprints
|
|
42
|
+
* of the certificates that sign it, may handle all of the domain's links.
|
|
43
|
+
*/
|
|
44
|
+
export const assetLinks = (app, fingerprints) => `${JSON.stringify([
|
|
45
|
+
{
|
|
46
|
+
relation: ['delegate_permission/common.handle_all_urls'],
|
|
47
|
+
target: {
|
|
48
|
+
namespace: 'android_app',
|
|
49
|
+
package_name: app.id,
|
|
50
|
+
sha256_cert_fingerprints: fingerprints,
|
|
51
|
+
},
|
|
52
|
+
},
|
|
53
|
+
], null, 2)}\n`;
|
|
54
|
+
/**
|
|
55
|
+
* The SHA-256 fingerprints of the certificates that signed the APK, as
|
|
56
|
+
* assetlinks.json writes them (`AB:CD:…`), from the newest build tools'
|
|
57
|
+
* apksigner. Empty when there's no apksigner, or it can't read the APK.
|
|
58
|
+
*/
|
|
59
|
+
export const apkSignerFingerprints = async (apk, sdk = findAndroidSdk()) => {
|
|
60
|
+
const apksigner = findApksigner(sdk);
|
|
61
|
+
if (!apksigner)
|
|
62
|
+
return [];
|
|
63
|
+
const output = await capture(apksigner, ['verify', '--print-certs', apk]);
|
|
64
|
+
return [
|
|
65
|
+
...(output ?? '').matchAll(/^Signer #\d+ certificate SHA-256 digest: ([0-9a-f]{64})$/gim),
|
|
66
|
+
].map(([, digest]) => digest.toUpperCase().match(/../g).join(':'));
|
|
67
|
+
};
|
|
68
|
+
/**
|
|
69
|
+
* apksigner in the SDK's newest build tools, if it has any.
|
|
70
|
+
*/
|
|
71
|
+
const findApksigner = (sdk) => {
|
|
72
|
+
const buildTools = sdk && path.join(sdk, 'build-tools');
|
|
73
|
+
if (!buildTools || !existsSync(buildTools))
|
|
74
|
+
return undefined;
|
|
75
|
+
const name = process.platform === 'win32' ? 'apksigner.bat' : 'apksigner';
|
|
76
|
+
return readdirSync(buildTools)
|
|
77
|
+
.sort((a, b) => b.localeCompare(a, undefined, { numeric: true }))
|
|
78
|
+
.map((version) => path.join(buildTools, version, name))
|
|
79
|
+
.find((file) => existsSync(file));
|
|
80
|
+
};
|
|
81
|
+
/**
|
|
82
|
+
* Writes the platform's file for the app link domains into `outputDir`, and
|
|
83
|
+
* says where it goes. Returns its path, or undefined for an app without app
|
|
84
|
+
* links.
|
|
85
|
+
*/
|
|
86
|
+
export const writeAppLinkFile = async ({ platform, app, outputDir, apk, log, warn, }) => {
|
|
87
|
+
if (app.appLinkDomains.length === 0)
|
|
88
|
+
return undefined;
|
|
89
|
+
const relative = platform === 'ios' ? APPLE_APP_SITE_ASSOCIATION : ASSET_LINKS;
|
|
90
|
+
const file = path.join(outputDir, relative);
|
|
91
|
+
mkdirSync(path.dirname(file), { recursive: true });
|
|
92
|
+
if (platform === 'ios') {
|
|
93
|
+
if (!app.ios.teamId) {
|
|
94
|
+
warn(`${relative} names the app as ${TEAM_ID_PLACEHOLDER}.${app.id}: set ios.teamId in angular.json, or put the team's ID in its place, before uploading it.`);
|
|
95
|
+
}
|
|
96
|
+
writeFileSync(file, appleAppSiteAssociation(app));
|
|
97
|
+
}
|
|
98
|
+
else {
|
|
99
|
+
const fingerprints = apk ? await apkSignerFingerprints(apk) : [];
|
|
100
|
+
if (fingerprints.length === 0) {
|
|
101
|
+
warn(`Couldn't read the certificate that signed the app with the Android SDK's apksigner: put its SHA-256 fingerprint in ${relative} in place of ${FINGERPRINT_PLACEHOLDER} before uploading it (keytool -list -v -keystore <keystore> prints it).`);
|
|
102
|
+
}
|
|
103
|
+
writeFileSync(file, assetLinks(app, fingerprints.length > 0 ? fingerprints : [FINGERPRINT_PLACEHOLDER]));
|
|
104
|
+
}
|
|
105
|
+
const roots = [
|
|
106
|
+
...new Set(app.appLinkDomains.map((domain) => domain.replace(/^\*\./, ''))),
|
|
107
|
+
];
|
|
108
|
+
log(`Wrote ${file}. Serve it at ${roots.map((root) => `https://${root}/${relative}`).join(' and ')}, as application/json with no redirect, so the phone opens the app for those links.`);
|
|
109
|
+
// Google Play signs the app it installs with its own key (Play App
|
|
110
|
+
// Signing), not the upload key that signed this build.
|
|
111
|
+
if (platform === 'android') {
|
|
112
|
+
log(`For an app installed from Google Play, add its app signing key's SHA-256 fingerprint to ${relative} too: Play Console → Test and release → App integrity → App signing.`);
|
|
113
|
+
}
|
|
114
|
+
return file;
|
|
115
|
+
};
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file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AS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,GAAG,EAAE,gBAAgB,CAAC;IAC/B;;;OAGG;IACH,QAAQ,CAAC,GAAG,CAAC,EAAE,UAAU,CAAC;IAC1B;;;;OAIG;IACH,QAAQ,CAAC,SAAS,CAAC,EAAE,gBAAgB,CAAC;IACtC,QAAQ,CAAC,GAAG,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;IACxC,yEAAyE;IACzE,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;CAC3C,CAAC;AAEF;;;;;GAKG;AACH,eAAO,MAAM,cAAc,GACzB,SAAS,qBAAqB,KAC7B,OAAO,CAAC;IACT,QAAQ,CAAC,SAAS,EAAE,SAAS,MAAM,EAAE,CAAC;IACtC,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;CAC7B,CA8JA,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -2,6 +2,7 @@ import { existsSync, mkdirSync, readFileSync, rmSync, writeFileSync, } from 'nod
|
|
|
2
2
|
import path from 'node:path';
|
|
3
3
|
import { androidGenerator } from "./android/project.js";
|
|
4
4
|
import { buildAndroid, resolveAndroidSigning } from "./android/build.js";
|
|
5
|
+
import { writeAppLinkFile } from "./app-links.js";
|
|
5
6
|
import { startAndroidDevice } from "./android/run.js";
|
|
6
7
|
import { devBuildKey, recordDevBuild, reusableDevBuild } from "./dev-build.js";
|
|
7
8
|
import { prepareProject, removeLegacyWorkDir, } from "./generate.js";
|
|
@@ -144,6 +145,19 @@ export const buildNativeApp = async (options) => {
|
|
|
144
145
|
});
|
|
145
146
|
if (devKey)
|
|
146
147
|
recordDevBuild(options.outputDir, devKey, artifacts);
|
|
148
|
+
// The file the app link domains serve, beside the app. Not for the
|
|
149
|
+
// development app: it's the store app's file, and the dev app's debug key
|
|
150
|
+
// isn't the key the store app is signed with.
|
|
151
|
+
if (!devServer) {
|
|
152
|
+
await writeAppLinkFile({
|
|
153
|
+
platform,
|
|
154
|
+
app,
|
|
155
|
+
outputDir: options.outputDir,
|
|
156
|
+
apk: artifacts.find((artifact) => artifact.endsWith('.apk')),
|
|
157
|
+
log,
|
|
158
|
+
warn: options.warn ?? log,
|
|
159
|
+
});
|
|
160
|
+
}
|
|
147
161
|
await target?.launch(
|
|
148
162
|
// The simulator's or the iPhone's .app or the .apk, not the .ipa or .aab
|
|
149
163
|
// for the stores.
|
package/dist/ios/build.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"build.d.ts","sourceRoot":"","sources":["../../src/ios/build.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AACtD,OAAO,KAAK,EAAE,eAAe,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAIlE,MAAM,MAAM,UAAU,GAAG;IACvB,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB;;;;OAIG;IACH,QAAQ,CAAC,MAAM,CAAC,EAAE;QAChB,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;QACzB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;QACvB,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;KAC3B,CAAC;IACF,0DAA0D;IAC1D,QAAQ,CAAC,MAAM,CAAC,EAAE,eAAe,CAAC;CACnC,CAAC;AAEF;;;;;;;;;;GAUG;AACH,eAAO,MAAM,iBAAiB,GAC5B,KAAK,WAAW,EAChB,MAAK,MAAM,CAAC,UAAwB,KACnC,UAAU,GAAG,SAwCf,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,QAAQ,GAAU,8GAY5B;IACD,QAAQ,CAAC,OAAO,EAAE,eAAe,CAAC;IAClC,QAAQ,CAAC,GAAG,EAAE,WAAW,CAAC;IAC1B,QAAQ,CAAC,aAAa,EAAE,MAAM,CAAC;IAC/B,wEAAwE;IACxE,QAAQ,CAAC,QAAQ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AChD,KAAG,OAAO,CAAC,MAAM,EAAE,CAsJnB,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,kBAAkB,GAC7B,YAAY,MAAM,KACjB,OAAO,CAAC,MAAM,CAShB,CAAC;AAEF,MAAM,MAAM,WAAW,GAAG;IAAE,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAA;CAAE,CAAC;AAEzE;;;;;GAKG;AACH,eAAO,MAAM,YAAY,GAAU,mBAKhC;IAAE,QAAQ,CAAC,WAAW,CAAC,EAAE,MAAM,CAAA;CAAO,KAAG,OAAO,CAAC,SAAS,WAAW,EAAE,CA2DzE,CAAC;AAwEF,eAAO,MAAM,kBAAkB,GAC7B,QAAQ,MAAM,EACd,QAAQ,eAAe,KACtB,MAuBF,CAAC"}
|
package/dist/ios/build.js
CHANGED
|
@@ -276,6 +276,11 @@ const explainSigningFailure = (error, teamId) => {
|
|
|
276
276
|
if (/maximum number of registered \w+ devices/i.test(error.message)) {
|
|
277
277
|
return new NativeBuildError(`Team ${teamId} can't register this device: it has as many as Apple allows. A paid team can remove the devices it no longer uses at the start of its membership year (developer.apple.com → Certificates, IDs & Profiles → Devices). A free Personal Team can't remove them, so set ios.teamId to another team, such as the Personal Team of another Apple ID signed in to Xcode.\n\n${error.message}`);
|
|
278
278
|
}
|
|
279
|
+
// xcodebuild then also reports "No profiles for", which alone would point
|
|
280
|
+
// at the wrong fix.
|
|
281
|
+
if (/Personal development teams.*Associated Domains/is.test(error.message)) {
|
|
282
|
+
return new NativeBuildError(`Team ${teamId} is a free Personal Team, which can't sign the Associated Domains capability that appLinkDomains adds. Set ios.teamId to a team in the paid Apple Developer Program, or leave appLinkDomains out of the configuration you build for this iPhone.\n\n${error.message}`);
|
|
283
|
+
}
|
|
279
284
|
if (/requires a development team|No profiles for/i.test(error.message)) {
|
|
280
285
|
return new NativeBuildError(`Xcode couldn't make a provisioning profile for team ${teamId}. Check that ios.teamId is a team your Apple ID in Xcode → Settings → Accounts belongs to, and for an .ipa that the team is in the paid Apple Developer Program.\n\n${error.message}`);
|
|
281
286
|
}
|
package/dist/ios/project.d.ts
CHANGED
|
@@ -4,11 +4,24 @@ import { type ResolvedApp } from '../options.ts';
|
|
|
4
4
|
* Writes the app options into the iOS template: build settings go in
|
|
5
5
|
* Config/App.xcconfig (which App.xcodeproj reads), Info.plist entries go
|
|
6
6
|
* between the template's `angular-lynx:info` markers, the shortcuts
|
|
7
|
-
* become App/AppShortcuts.swift,
|
|
7
|
+
* become App/AppShortcuts.swift, the app link domains become
|
|
8
|
+
* Config/App.entitlements, and the icon and the splash go in the asset
|
|
8
9
|
* catalog.
|
|
9
10
|
*/
|
|
10
11
|
export declare const iosGenerator: PlatformGenerator;
|
|
11
12
|
export declare const xcconfig: (app: ResolvedApp) => string;
|
|
13
|
+
/**
|
|
14
|
+
* Config/App.entitlements: the Associated Domains entitlement, which has iOS
|
|
15
|
+
* open the app for an https link to one of the domains (a Universal Link),
|
|
16
|
+
* once the domain's apple-app-site-association names the app (see
|
|
17
|
+
* appLinkFiles). iOS fetches that file through Apple's CDN when the app is
|
|
18
|
+
* installed.
|
|
19
|
+
*
|
|
20
|
+
* Signing it needs a team in the paid Apple Developer Program: a free
|
|
21
|
+
* Personal Team can't sign Associated Domains. The simulator app needs no
|
|
22
|
+
* team.
|
|
23
|
+
*/
|
|
24
|
+
export declare const entitlementsPlist: (app: ResolvedApp) => string;
|
|
12
25
|
/** What iOS shows the first time someone taps Save Image, without `savePhotos`. */
|
|
13
26
|
export declare const DEFAULT_SAVE_PHOTOS_REASON = "Saves the images you choose to your photo library.";
|
|
14
27
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"project.d.ts","sourceRoot":"","sources":["../../src/ios/project.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AAExD,OAAO,EAGL,KAAK,WAAW,EAEjB,MAAM,eAAe,CAAC;AAkBvB
|
|
1
|
+
{"version":3,"file":"project.d.ts","sourceRoot":"","sources":["../../src/ios/project.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AAExD,OAAO,EAGL,KAAK,WAAW,EAEjB,MAAM,eAAe,CAAC;AAkBvB;;;;;;;GAOG;AACH,eAAO,MAAM,YAAY,EAAE,iBAgD1B,CAAC;AAWF,eAAO,MAAM,QAAQ,GAAI,KAAK,WAAW,KAAG,MAgB9B,CAAC;AAEf;;;;;;;;;;GAUG;AACH,eAAO,MAAM,iBAAiB,GAAI,KAAK,WAAW,KAAG,MAgBvC,CAAC;AAEf,mFAAmF;AACnF,eAAO,MAAM,0BAA0B,uDACe,CAAC;AAEvD;;;GAGG;AACH,eAAO,MAAM,oBAAoB,uEACqC,CAAC;AAEvE,eAAO,MAAM,gBAAgB,GAC3B,KAAK,WAAW,EAChB,kBAAyB;IAAE,QAAQ,CAAC,WAAW,CAAC,EAAE,OAAO,CAAA;CAAO,KAC/D,MAmFF,CAAC;AAoBF;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,iBAAiB,GAAI,KAAK,WAAW,KAAG,MAwDpD,CAAC"}
|
package/dist/ios/project.js
CHANGED
|
@@ -21,7 +21,8 @@ const ORIENTATIONS = {
|
|
|
21
21
|
* Writes the app options into the iOS template: build settings go in
|
|
22
22
|
* Config/App.xcconfig (which App.xcodeproj reads), Info.plist entries go
|
|
23
23
|
* between the template's `angular-lynx:info` markers, the shortcuts
|
|
24
|
-
* become App/AppShortcuts.swift,
|
|
24
|
+
* become App/AppShortcuts.swift, the app link domains become
|
|
25
|
+
* Config/App.entitlements, and the icon and the splash go in the asset
|
|
25
26
|
* catalog.
|
|
26
27
|
*/
|
|
27
28
|
export const iosGenerator = {
|
|
@@ -34,6 +35,13 @@ export const iosGenerator = {
|
|
|
34
35
|
if (app.shortcuts.length > 0) {
|
|
35
36
|
writeFileSync(path.join(dir, 'App/AppShortcuts.swift'), appShortcutsSwift(app));
|
|
36
37
|
}
|
|
38
|
+
// In Config/, beside the xcconfig that points the target at it, rather
|
|
39
|
+
// than in App/: Xcode would copy a file in that synchronized folder into
|
|
40
|
+
// the app as a resource. An app without app links signs with no
|
|
41
|
+
// entitlements, as the template does.
|
|
42
|
+
if (app.appLinkDomains.length > 0) {
|
|
43
|
+
writeFileSync(path.join(dir, ENTITLEMENTS), entitlementsPlist(app));
|
|
44
|
+
}
|
|
37
45
|
if (app.icon) {
|
|
38
46
|
const icon = path.resolve(projectRoot, app.icon);
|
|
39
47
|
const size = readPngSize(icon);
|
|
@@ -46,6 +54,8 @@ export const iosGenerator = {
|
|
|
46
54
|
},
|
|
47
55
|
bundleDir: (dir) => path.join(dir, 'LynxBundle'),
|
|
48
56
|
};
|
|
57
|
+
/** The app's entitlements, from the project folder (see xcconfig). */
|
|
58
|
+
const ENTITLEMENTS = 'Config/App.entitlements';
|
|
49
59
|
/**
|
|
50
60
|
* xcconfig values can't be quoted; `$` and `//` would start a variable or a comment.
|
|
51
61
|
*/
|
|
@@ -60,6 +70,35 @@ export const xcconfig = (app) => [
|
|
|
60
70
|
`MARKETING_VERSION = ${app.version}`,
|
|
61
71
|
`CURRENT_PROJECT_VERSION = ${app.buildNumber}`,
|
|
62
72
|
`DEVELOPMENT_TEAM = ${app.ios.teamId ?? ''}`,
|
|
73
|
+
// Only with app links: the only entitlement the generator writes.
|
|
74
|
+
...(app.appLinkDomains.length > 0
|
|
75
|
+
? [`CODE_SIGN_ENTITLEMENTS = ${ENTITLEMENTS}`]
|
|
76
|
+
: []),
|
|
77
|
+
'',
|
|
78
|
+
].join('\n');
|
|
79
|
+
/**
|
|
80
|
+
* Config/App.entitlements: the Associated Domains entitlement, which has iOS
|
|
81
|
+
* open the app for an https link to one of the domains (a Universal Link),
|
|
82
|
+
* once the domain's apple-app-site-association names the app (see
|
|
83
|
+
* appLinkFiles). iOS fetches that file through Apple's CDN when the app is
|
|
84
|
+
* installed.
|
|
85
|
+
*
|
|
86
|
+
* Signing it needs a team in the paid Apple Developer Program: a free
|
|
87
|
+
* Personal Team can't sign Associated Domains. The simulator app needs no
|
|
88
|
+
* team.
|
|
89
|
+
*/
|
|
90
|
+
export const entitlementsPlist = (app) => [
|
|
91
|
+
'<?xml version="1.0" encoding="UTF-8"?>',
|
|
92
|
+
'<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">',
|
|
93
|
+
'<!-- Written by @blotch/angular-lynx-native from appLinkDomains in angular.json. -->',
|
|
94
|
+
'<plist version="1.0">',
|
|
95
|
+
'<dict>',
|
|
96
|
+
'\t<key>com.apple.developer.associated-domains</key>',
|
|
97
|
+
'\t<array>',
|
|
98
|
+
...app.appLinkDomains.map((domain) => `\t\t<string>applinks:${escapeXml(domain)}</string>`),
|
|
99
|
+
'\t</array>',
|
|
100
|
+
'</dict>',
|
|
101
|
+
'</plist>',
|
|
63
102
|
'',
|
|
64
103
|
].join('\n');
|
|
65
104
|
/** What iOS shows the first time someone taps Save Image, without `savePhotos`. */
|
|
@@ -103,10 +142,12 @@ export const infoPlistEntries = (app, { development = false } = {}) => {
|
|
|
103
142
|
// `ng serve --platform ios`'s development app loads from the dev server at
|
|
104
143
|
// the Mac's address on the local network, which iOS (14 and later) lets an
|
|
105
144
|
// app reach only once the person allows it. iOS asks the first time, with
|
|
106
|
-
// this reason. Only the development app has it
|
|
107
|
-
//
|
|
108
|
-
// need.
|
|
109
|
-
|
|
145
|
+
// this reason. Only the development app has it, unless the app asks for
|
|
146
|
+
// `localNetwork` itself: the app for the stores loads its own bundle, and
|
|
147
|
+
// App Review asks about any reason it doesn't need.
|
|
148
|
+
// An app that asks for `localNetwork` already has the key, with its own
|
|
149
|
+
// reason, which also covers the dev server.
|
|
150
|
+
if (development && !app.permissions.localNetwork) {
|
|
110
151
|
lines.push('<key>NSLocalNetworkUsageDescription</key>', `<string>${escapeXml(LOCAL_NETWORK_REASON)}</string>`);
|
|
111
152
|
}
|
|
112
153
|
// The schemes LinkingModule's canOpenURL can ask about: iOS answers false
|
package/dist/options.d.ts
CHANGED
|
@@ -30,6 +30,14 @@ export type NativeAppOptions = {
|
|
|
30
30
|
readonly permissions?: Partial<Record<Permission, string>>;
|
|
31
31
|
/** Custom URL schemes that open the app, e.g. `["myapp"]`. */
|
|
32
32
|
readonly deepLinkSchemes?: readonly string[];
|
|
33
|
+
/**
|
|
34
|
+
* The app's own websites, whose https links open the app rather than the
|
|
35
|
+
* browser, e.g. `["example.com", "*.example.com"]`: Universal Links on iOS
|
|
36
|
+
* (the Associated Domains entitlement) and App Links on Android (a
|
|
37
|
+
* verified intent filter). Each site has to serve the file that names the
|
|
38
|
+
* app, which the build writes beside the app (see `appLinkFiles`).
|
|
39
|
+
*/
|
|
40
|
+
readonly appLinkDomains?: readonly string[];
|
|
33
41
|
/**
|
|
34
42
|
* Other apps' URL schemes `LynxLinking.canOpenURL()` can ask about, e.g.
|
|
35
43
|
* `["whatsapp", "instagram"]`. iOS answers only for the schemes in
|
|
@@ -161,7 +169,7 @@ export type ResolvedShortcut = {
|
|
|
161
169
|
};
|
|
162
170
|
/** Where a shortcut's phrase names the app. */
|
|
163
171
|
export declare const APP_NAME_PLACEHOLDER = "{appName}";
|
|
164
|
-
export type Permission = 'camera' | 'microphone' | 'location' | 'photos' | 'savePhotos' | 'contacts' | 'notifications';
|
|
172
|
+
export type Permission = 'camera' | 'microphone' | 'location' | 'photos' | 'savePhotos' | 'contacts' | 'notifications' | 'localNetwork';
|
|
165
173
|
/**
|
|
166
174
|
* How the `.ipa` is signed, as Xcode's export methods name it:
|
|
167
175
|
* `app-store-connect` for App Store Connect and TestFlight, and
|
|
@@ -233,6 +241,8 @@ export type ResolvedApp = {
|
|
|
233
241
|
readonly edgeToEdge: boolean;
|
|
234
242
|
readonly permissions: Partial<Record<Permission, string>>;
|
|
235
243
|
readonly deepLinkSchemes: readonly string[];
|
|
244
|
+
/** {@link NativeAppOptions.appLinkDomains} in lowercase, each once. */
|
|
245
|
+
readonly appLinkDomains: readonly string[];
|
|
236
246
|
/**
|
|
237
247
|
* {@link NativeAppOptions.canOpenURLSchemes} after
|
|
238
248
|
* {@link ALWAYS_QUERIED_SCHEMES}, in lowercase, each once.
|
package/dist/options.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"options.d.ts","sourceRoot":"","sources":["../src/options.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AACH,MAAM,MAAM,gBAAgB,GAAG;IAC7B,6DAA6D;IAC7D,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC;IAC1B,yEAAyE;IACzE,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;IACxB,0EAA0E;IAC1E,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC;IAC1B,8DAA8D;IAC9D,QAAQ,CAAC,WAAW,CAAC,EAAE,MAAM,CAAC;IAC9B,QAAQ,CAAC,WAAW,CAAC,EAAE,WAAW,CAAC;IACnC;;;;;OAKG;IACH,QAAQ,CAAC,UAAU,CAAC,EAAE,OAAO,CAAC;IAC9B,uEAAuE;IACvE,QAAQ,CAAC,WAAW,CAAC,EAAE,OAAO,CAAC,MAAM,CAAC,UAAU,EAAE,MAAM,CAAC,CAAC,CAAC;IAC3D,8DAA8D;IAC9D,QAAQ,CAAC,eAAe,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IAC7C;;;;;;OAMG;IACH,QAAQ,CAAC,iBAAiB,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IAC/C;;;;;OAKG;IACH,QAAQ,CAAC,SAAS,CAAC,EAAE,SAAS,WAAW,EAAE,CAAC;IAC5C;;;;;OAKG;IACH,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAC;IACvB;;;OAGG;IACH,QAAQ,CAAC,MAAM,CAAC,EAAE,aAAa,CAAC;IAChC,QAA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