react-native-acoustic-connect-beta 18.0.35 → 18.0.36

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 CHANGED
@@ -1,3 +1,4 @@
1
+ ## [18.0.36](https://github.com/aipoweredmarketer/react-native-acoustic-connect-beta/compare/18.0.35...18.0.36) (2026-06-17)
1
2
  ## [18.0.35](https://github.com/aipoweredmarketer/react-native-acoustic-connect-beta/compare/18.0.34...18.0.35) (2026-06-15)
2
3
  ## [18.0.34](https://github.com/aipoweredmarketer/react-native-acoustic-connect-beta/compare/18.0.33...18.0.34) (2026-06-15)
3
4
  ## [18.0.33](https://github.com/aipoweredmarketer/react-native-acoustic-connect-beta/compare/18.0.32...18.0.33) (2026-06-15)
package/README.md CHANGED
@@ -163,14 +163,40 @@ During `expo prebuild` the plugin automatically:
163
163
  - adds a `ConnectNSE` Notification Service Extension target to the Xcode
164
164
  project (rich-media push attachments + delivery tracking), with
165
165
  `NotificationService.swift` generated from the SDK template;
166
- - adds the App Group entitlement to both the host app and the NSE;
167
- - appends a `ConnectNSE` target to the generated `Podfile` that links the
168
- same Connect SDK pod as the app.
166
+ - adds a `ConnectNCE` Notification Content Extension target (rich expansion
167
+ UI renders the attached media / expanded body when the user expands an
168
+ Acoustic notification), with `NotificationViewController.swift` generated
169
+ from the SDK template;
170
+ - adds the App Group entitlement to the host app and to both extensions, so
171
+ all three processes share the same pending store;
172
+ - appends `ConnectNSE` and `ConnectNCE` targets to the generated `Podfile`,
173
+ each linking the same Connect SDK pod as the app.
169
174
 
170
175
  Re-running `expo prebuild` — with or without `--clean` — is idempotent: no
171
176
  duplicate targets, entitlements, or Podfile entries.
172
177
 
173
- A working example lives in [`Examples/expo`](Examples/expo).
178
+ The NCE renders notifications whose category matches
179
+ `ACOUSTIC_RICH_NOTIFICATION` or `ACTIONABLE_NOTIFICATION` (the categories the
180
+ Connect backend sets on rich-media pushes). No app-side configuration is
181
+ required — the category identifiers are baked into the generated target's
182
+ `Info.plist`.
183
+
184
+ ### EAS Build
185
+
186
+ The plugin works with [EAS Build](https://docs.expo.dev/build/introduction/)
187
+ out of the box — the NSE and NCE targets are provisioned by the same
188
+ `expo prebuild` step EAS runs on its build workers. iOS extension targets are
189
+ signed automatically when you use EAS-managed credentials (`eas credentials`),
190
+ which provisions the host app and both extension App IDs together.
191
+
192
+ ```bash
193
+ eas build --profile development --platform ios
194
+ eas build --profile development --platform android
195
+ ```
196
+
197
+ A working example — including a sample
198
+ [`eas.json`](Examples/expo/eas.json) — lives in
199
+ [`Examples/expo`](Examples/expo).
174
200
 
175
201
  ## Quick start
176
202
 
@@ -1,4 +1,4 @@
1
- #Mon Jun 15 05:39:24 PDT 2026
1
+ #Wed Jun 17 07:43:32 PDT 2026
2
2
  UseWhiteList=true
3
3
  PrintScreen=3
4
4
  UseRandomSample=false
package/package.json CHANGED
@@ -210,7 +210,7 @@
210
210
  "source": "src/index",
211
211
  "summary": "react-native ios android tealeaf connect cxa wxca er enhanced-replay",
212
212
  "types": "./lib/typescript/src/index.d.ts",
213
- "version": "18.0.35",
213
+ "version": "18.0.36",
214
214
  "workspaces": [
215
215
  "example",
216
216
  "Examples/bare-workflow"
@@ -1,12 +1,15 @@
1
1
  import { type ConfigPlugin } from '@expo/config-plugins';
2
2
  import { withConnectNSE, type ConnectPluginProps } from './withConnectNSE';
3
+ import { withConnectNCE } from './withConnectNCE';
3
4
  /**
4
5
  * Expo Config Plugin for react-native-acoustic-connect-beta.
5
6
  *
6
- * Provisions the ConnectNSE Notification Service Extension target during
7
- * `expo prebuild`. Designed as a chainable composition: additional mods
8
- * (e.g. withConnectNCE from CA-143488) are appended by adding to the mods
9
- * array without touching this file.
7
+ * Provisions the ConnectNSE Notification Service Extension and the ConnectNCE
8
+ * Notification Content Extension targets during `expo prebuild`. Designed as a
9
+ * chainable composition: additional mods are appended by adding to the mods
10
+ * array. Order matters withConnectNSE runs first so it seeds the host
11
+ * entitlements and the PBXTargetDependency/PBXContainerItemProxy sections that
12
+ * withConnectNCE reuses.
10
13
  *
11
14
  * Consumer app.json usage:
12
15
  * // With explicit App Group override:
@@ -17,6 +20,6 @@ import { withConnectNSE, type ConnectPluginProps } from './withConnectNSE';
17
20
  */
18
21
  declare const withAcousticConnect: ConfigPlugin<ConnectPluginProps | void>;
19
22
  export default withAcousticConnect;
20
- export { withConnectNSE };
23
+ export { withConnectNSE, withConnectNCE };
21
24
  export type { ConnectPluginProps };
22
25
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAQA,OAAO,EAAE,KAAK,YAAY,EAAE,MAAM,sBAAsB,CAAA;AACxD,OAAO,EAAE,cAAc,EAAE,KAAK,kBAAkB,EAAE,MAAM,kBAAkB,CAAA;AAE1E;;;;;;;;;;;;;;GAcG;AACH,QAAA,MAAM,mBAAmB,EAAE,YAAY,CAAC,kBAAkB,GAAG,IAAI,CAWhE,CAAA;AAED,eAAe,mBAAmB,CAAA;AAClC,OAAO,EAAE,cAAc,EAAE,CAAA;AACzB,YAAY,EAAE,kBAAkB,EAAE,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAQA,OAAO,EAAE,KAAK,YAAY,EAAE,MAAM,sBAAsB,CAAA;AACxD,OAAO,EAAE,cAAc,EAAE,KAAK,kBAAkB,EAAE,MAAM,kBAAkB,CAAA;AAC1E,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAA;AAEjD;;;;;;;;;;;;;;;;GAgBG;AACH,QAAA,MAAM,mBAAmB,EAAE,YAAY,CAAC,kBAAkB,GAAG,IAAI,CAgBhE,CAAA;AAED,eAAe,mBAAmB,CAAA;AAClC,OAAO,EAAE,cAAc,EAAE,cAAc,EAAE,CAAA;AACzC,YAAY,EAAE,kBAAkB,EAAE,CAAA"}
@@ -7,16 +7,20 @@
7
7
  // be provided in an agreement with Acoustic, L.P. Any unauthorized copying or
8
8
  // distribution of content from this file is prohibited.
9
9
  Object.defineProperty(exports, "__esModule", { value: true });
10
- exports.withConnectNSE = void 0;
10
+ exports.withConnectNCE = exports.withConnectNSE = void 0;
11
11
  const withConnectNSE_1 = require("./withConnectNSE");
12
12
  Object.defineProperty(exports, "withConnectNSE", { enumerable: true, get: function () { return withConnectNSE_1.withConnectNSE; } });
13
+ const withConnectNCE_1 = require("./withConnectNCE");
14
+ Object.defineProperty(exports, "withConnectNCE", { enumerable: true, get: function () { return withConnectNCE_1.withConnectNCE; } });
13
15
  /**
14
16
  * Expo Config Plugin for react-native-acoustic-connect-beta.
15
17
  *
16
- * Provisions the ConnectNSE Notification Service Extension target during
17
- * `expo prebuild`. Designed as a chainable composition: additional mods
18
- * (e.g. withConnectNCE from CA-143488) are appended by adding to the mods
19
- * array without touching this file.
18
+ * Provisions the ConnectNSE Notification Service Extension and the ConnectNCE
19
+ * Notification Content Extension targets during `expo prebuild`. Designed as a
20
+ * chainable composition: additional mods are appended by adding to the mods
21
+ * array. Order matters withConnectNSE runs first so it seeds the host
22
+ * entitlements and the PBXTargetDependency/PBXContainerItemProxy sections that
23
+ * withConnectNCE reuses.
20
24
  *
21
25
  * Consumer app.json usage:
22
26
  * // With explicit App Group override:
@@ -27,8 +31,13 @@ Object.defineProperty(exports, "withConnectNSE", { enumerable: true, get: functi
27
31
  */
28
32
  const withAcousticConnect = (config, props) => {
29
33
  const resolvedProps = props != null && typeof props === 'object' ? props : {};
30
- // Chainable composition array CA-143488 appends withConnectNCE here.
31
- const mods = [withConnectNSE_1.withConnectNSE];
34
+ // Chainable composition array. withConnectNSE must precede withConnectNCE:
35
+ // the NSE mod seeds the host App Group entitlement and the
36
+ // PBXTargetDependency/PBXContainerItemProxy sections the NCE mod relies on.
37
+ const mods = [
38
+ withConnectNSE_1.withConnectNSE,
39
+ withConnectNCE_1.withConnectNCE,
40
+ ];
32
41
  return mods.reduce((accConfig, mod) => mod(accConfig, resolvedProps), config);
33
42
  };
34
43
  exports.default = withAcousticConnect;
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAAA,yDAAyD;AACzD,EAAE;AACF,8EAA8E;AAC9E,0EAA0E;AAC1E,6EAA6E;AAC7E,8EAA8E;AAC9E,wDAAwD;;;AAGxD,qDAA0E;AA+BjE,+FA/BA,+BAAc,OA+BA;AA7BvB;;;;;;;;;;;;;;GAcG;AACH,MAAM,mBAAmB,GAA4C,CACnE,MAAM,EACN,KAAK,EACL,EAAE;IACF,MAAM,aAAa,GACjB,KAAK,IAAI,IAAI,IAAI,OAAO,KAAK,KAAK,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,CAAA;IAEzD,uEAAuE;IACvE,MAAM,IAAI,GAA4C,CAAC,+BAAc,CAAC,CAAA;IAEtE,OAAO,IAAI,CAAC,MAAM,CAAC,CAAC,SAAS,EAAE,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,SAAS,EAAE,aAAa,CAAC,EAAE,MAAM,CAAC,CAAA;AAC/E,CAAC,CAAA;AAED,kBAAe,mBAAmB,CAAA"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAAA,yDAAyD;AACzD,EAAE;AACF,8EAA8E;AAC9E,0EAA0E;AAC1E,6EAA6E;AAC7E,8EAA8E;AAC9E,wDAAwD;;;AAGxD,qDAA0E;AAuCjE,+FAvCA,+BAAc,OAuCA;AAtCvB,qDAAiD;AAsCxB,+FAtChB,+BAAc,OAsCgB;AApCvC;;;;;;;;;;;;;;;;GAgBG;AACH,MAAM,mBAAmB,GAA4C,CACnE,MAAM,EACN,KAAK,EACL,EAAE;IACF,MAAM,aAAa,GACjB,KAAK,IAAI,IAAI,IAAI,OAAO,KAAK,KAAK,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,CAAA;IAEzD,2EAA2E;IAC3E,2DAA2D;IAC3D,4EAA4E;IAC5E,MAAM,IAAI,GAA4C;QACpD,+BAAc;QACd,+BAAc;KACf,CAAA;IAED,OAAO,IAAI,CAAC,MAAM,CAAC,CAAC,SAAS,EAAE,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,SAAS,EAAE,aAAa,CAAC,EAAE,MAAM,CAAC,CAAA;AAC/E,CAAC,CAAA;AAED,kBAAe,mBAAmB,CAAA"}
@@ -0,0 +1,88 @@
1
+ import { type ConfigPlugin } from '@expo/config-plugins';
2
+ import type { ExpoConfig } from '@expo/config-types';
3
+ import { type ConnectPluginProps } from './withConnectNSE';
4
+ /**
5
+ * Generates the Info.plist content for the ConnectNCE target.
6
+ *
7
+ * The NSExtensionAttributes mirror the canonical bare-workflow reference
8
+ * (Examples/bare-workflow/ios/ConnectNCE/Info.plist), which itself mirrors the
9
+ * iOS-SDK NCE 1:1:
10
+ * - UNNotificationExtensionCategory: the category identifiers the Connect
11
+ * APNs payload routes rich-media notifications through. Must match the
12
+ * category the SDK/Collector sets — keep in sync with the iOS-SDK NCE.
13
+ * - UNNotificationExtensionDefaultContentHidden=false: keep the default
14
+ * system body alongside the custom content view.
15
+ * - UNNotificationExtensionInitialContentSizeRatio=1.0: start full-height;
16
+ * the SDK content controller resizes to fit the rendered media.
17
+ *
18
+ * RCTNewArchEnabled is intentionally omitted: the NCE links the Connect SDK
19
+ * only — no React Native runtime is present in the extension process. (The
20
+ * bare-workflow reference carries it as an Xcode-template leftover; the
21
+ * plugin-generated target drops it, consistent with the NSE template.)
22
+ */
23
+ export declare function buildNCEInfoPlist(): string;
24
+ /** Generates the entitlements plist content for the ConnectNCE target. */
25
+ export declare function buildNCEEntitlements(appGroupIdentifier: string): string;
26
+ /**
27
+ * Returns the Ruby snippet to inject into the Expo-generated Podfile for the
28
+ * ConnectNCE target. Thin wrapper over the shared
29
+ * {@link buildConnectPodTargetBlock} (single source of truth for the
30
+ * AcousticConnect pod-resolution helper), parameterised with the NCE marker,
31
+ * helper name, and target name.
32
+ */
33
+ export declare function buildPodfileBlock(): string;
34
+ /**
35
+ * Injects the ConnectNCE Podfile block into `podfileContent` if not already
36
+ * present (idempotent, guarded by PODFILE_MARKER).
37
+ */
38
+ export declare function injectPodfileBlock(podfileContent: string): string;
39
+ /**
40
+ * Adds the ConnectNCE Xcode target (app_extension) to the project.
41
+ *
42
+ * Sibling to withNSEXcodeProject; the only differences are the target name,
43
+ * the Swift source file (NotificationViewController.swift), the NCE Info.plist
44
+ * (content-extension NSExtension keys), and skipping BOTH extension targets'
45
+ * configs when mirroring host build settings.
46
+ *
47
+ * Idempotent: if a target named ConnectNCE already exists, skips target
48
+ * creation but still (re)writes the source files.
49
+ */
50
+ export declare function withNCEXcodeProject(config: ExpoConfig, appGroupIdentifier: string, swiftContent: string): ExpoConfig;
51
+ /**
52
+ * Injects the ConnectNCE Podfile target block via withDangerousMod.
53
+ * Guarded by a marker comment — re-runs are no-ops.
54
+ *
55
+ * Throws a clear, actionable error when the Podfile does not exist at
56
+ * mod-execution time, instead of silently returning — a silent skip would
57
+ * ship an NCE whose `import Connect` cannot resolve.
58
+ */
59
+ export declare function withNCEPodfile(config: ExpoConfig): ExpoConfig;
60
+ /**
61
+ * Expo Config Plugin mod that provisions a Notification Content Extension
62
+ * (NCE) Xcode target named `ConnectNCE`.
63
+ *
64
+ * Applies three mutations — all idempotent:
65
+ * 1. Host app entitlements: merges App Group into
66
+ * `com.apple.security.application-groups` (reuses the NSE host-entitlements
67
+ * mod — the host shares one App Group across app + NSE + NCE; the merge is
68
+ * a no-op when the NSE mod already added it).
69
+ * 2. Xcode project: adds ConnectNCE target + files (skips if already present).
70
+ * 3. Podfile: injects `target 'ConnectNCE'` block (guarded by marker comment).
71
+ *
72
+ * `config._internal.projectRoot` is required (injected by Expo CLI during
73
+ * `expo prebuild`); an actionable error is thrown if absent rather than
74
+ * silently falling back to `process.cwd()`.
75
+ *
76
+ * NSE coupling (intentional, tracked for refactor): this mod deliberately
77
+ * reuses three pieces of withConnectNSE — `withNSEEntitlements` (the host App
78
+ * Group is shared across app + NSE + NCE), `buildConnectPodTargetBlock` (one
79
+ * source for the pod-resolution helper), and `getHostBuildSettingForConfig`
80
+ * (the per-config mirroring logic). The composition always runs withConnectNSE
81
+ * before withConnectNCE, so the shared host entitlement and the
82
+ * PBXTargetDependency/PBXContainerItemProxy sections already exist when this
83
+ * runs. Extracting a shared `withConnectExtension` base for NSE + NCE is
84
+ * tracked as a follow-up refactor (see PR description) rather than done here,
85
+ * to keep the already-landed NSE mod stable.
86
+ */
87
+ export declare const withConnectNCE: ConfigPlugin<ConnectPluginProps>;
88
+ //# sourceMappingURL=withConnectNCE.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"withConnectNCE.d.ts","sourceRoot":"","sources":["../src/withConnectNCE.ts"],"names":[],"mappings":"AAQA,OAAO,EAGL,KAAK,YAAY,EAClB,MAAM,sBAAsB,CAAA;AAC7B,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAA;AAGpD,OAAO,EAML,KAAK,kBAAkB,EACxB,MAAM,kBAAkB,CAAA;AAuBzB;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,iBAAiB,IAAI,MAAM,CA6C1C;AAED,0EAA0E;AAC1E,wBAAgB,oBAAoB,CAAC,kBAAkB,EAAE,MAAM,GAAG,MAAM,CAYvE;AAOD;;;;;;GAMG;AACH,wBAAgB,iBAAiB,IAAI,MAAM,CAM1C;AAED;;;GAGG;AACH,wBAAgB,kBAAkB,CAAC,cAAc,EAAE,MAAM,GAAG,MAAM,CAKjE;AAID;;;;;;;;;;GAUG;AACH,wBAAgB,mBAAmB,CACjC,MAAM,EAAE,UAAU,EAClB,kBAAkB,EAAE,MAAM,EAC1B,YAAY,EAAE,MAAM,GACnB,UAAU,CAqNZ;AAID;;;;;;;GAOG;AACH,wBAAgB,cAAc,CAAC,MAAM,EAAE,UAAU,GAAG,UAAU,CAuB7D;AAID;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,eAAO,MAAM,cAAc,EAAE,YAAY,CAAC,kBAAkB,CAgC3D,CAAA"}
@@ -0,0 +1,366 @@
1
+ "use strict";
2
+ // Copyright (C) 2026 Acoustic, L.P. All rights reserved.
3
+ //
4
+ // NOTICE: This file contains material that is confidential and proprietary to
5
+ // Acoustic, L.P. and/or other developers. No license is granted under any
6
+ // intellectual or industrial property rights of Acoustic, L.P. except as may
7
+ // be provided in an agreement with Acoustic, L.P. Any unauthorized copying or
8
+ // distribution of content from this file is prohibited.
9
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ var desc = Object.getOwnPropertyDescriptor(m, k);
12
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
13
+ desc = { enumerable: true, get: function() { return m[k]; } };
14
+ }
15
+ Object.defineProperty(o, k2, desc);
16
+ }) : (function(o, m, k, k2) {
17
+ if (k2 === undefined) k2 = k;
18
+ o[k2] = m[k];
19
+ }));
20
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
21
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
22
+ }) : function(o, v) {
23
+ o["default"] = v;
24
+ });
25
+ var __importStar = (this && this.__importStar) || function (mod) {
26
+ if (mod && mod.__esModule) return mod;
27
+ var result = {};
28
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
29
+ __setModuleDefault(result, mod);
30
+ return result;
31
+ };
32
+ Object.defineProperty(exports, "__esModule", { value: true });
33
+ exports.withConnectNCE = exports.withNCEPodfile = exports.withNCEXcodeProject = exports.injectPodfileBlock = exports.buildPodfileBlock = exports.buildNCEEntitlements = exports.buildNCEInfoPlist = void 0;
34
+ const config_plugins_1 = require("@expo/config-plugins");
35
+ const fs = __importStar(require("fs"));
36
+ const path = __importStar(require("path"));
37
+ const withConnectNSE_1 = require("./withConnectNSE");
38
+ // ─── Target / config constants ─────────────────────────────────────────────
39
+ const NSE_TARGET_NAME = 'ConnectNSE';
40
+ const NCE_TARGET_NAME = 'ConnectNCE';
41
+ // Configs belonging to either extension target must be skipped when mirroring
42
+ // host build settings. The NCE mod runs AFTER the NSE mod in the composition,
43
+ // so by the time this executes the pbxproj already carries ConnectNSE configs;
44
+ // without skipping both, the NCE could mirror the NSE target's settings rather
45
+ // than the host app's.
46
+ const EXTENSION_TARGET_NAMES = [NSE_TARGET_NAME, NCE_TARGET_NAME];
47
+ // ─── Plist helpers ────────────────────────────────────────────────────────────
48
+ /**
49
+ * Generates the Info.plist content for the ConnectNCE target.
50
+ *
51
+ * The NSExtensionAttributes mirror the canonical bare-workflow reference
52
+ * (Examples/bare-workflow/ios/ConnectNCE/Info.plist), which itself mirrors the
53
+ * iOS-SDK NCE 1:1:
54
+ * - UNNotificationExtensionCategory: the category identifiers the Connect
55
+ * APNs payload routes rich-media notifications through. Must match the
56
+ * category the SDK/Collector sets — keep in sync with the iOS-SDK NCE.
57
+ * - UNNotificationExtensionDefaultContentHidden=false: keep the default
58
+ * system body alongside the custom content view.
59
+ * - UNNotificationExtensionInitialContentSizeRatio=1.0: start full-height;
60
+ * the SDK content controller resizes to fit the rendered media.
61
+ *
62
+ * RCTNewArchEnabled is intentionally omitted: the NCE links the Connect SDK
63
+ * only — no React Native runtime is present in the extension process. (The
64
+ * bare-workflow reference carries it as an Xcode-template leftover; the
65
+ * plugin-generated target drops it, consistent with the NSE template.)
66
+ */
67
+ function buildNCEInfoPlist() {
68
+ return `<?xml version="1.0" encoding="UTF-8"?>
69
+ <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
70
+ <plist version="1.0">
71
+ <dict>
72
+ \t<key>CFBundleDevelopmentRegion</key>
73
+ \t<string>$(DEVELOPMENT_LANGUAGE)</string>
74
+ \t<key>CFBundleDisplayName</key>
75
+ \t<string>ConnectNCE</string>
76
+ \t<key>CFBundleExecutable</key>
77
+ \t<string>$(EXECUTABLE_NAME)</string>
78
+ \t<key>CFBundleIdentifier</key>
79
+ \t<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
80
+ \t<key>CFBundleInfoDictionaryVersion</key>
81
+ \t<string>6.0</string>
82
+ \t<key>CFBundleName</key>
83
+ \t<string>$(PRODUCT_NAME)</string>
84
+ \t<key>CFBundlePackageType</key>
85
+ \t<string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string>
86
+ \t<key>CFBundleShortVersionString</key>
87
+ \t<string>$(MARKETING_VERSION)</string>
88
+ \t<key>CFBundleVersion</key>
89
+ \t<string>$(CURRENT_PROJECT_VERSION)</string>
90
+ \t<key>NSExtension</key>
91
+ \t<dict>
92
+ \t\t<key>NSExtensionAttributes</key>
93
+ \t\t<dict>
94
+ \t\t\t<key>UNNotificationExtensionCategory</key>
95
+ \t\t\t<array>
96
+ \t\t\t\t<string>ACOUSTIC_RICH_NOTIFICATION</string>
97
+ \t\t\t\t<string>ACTIONABLE_NOTIFICATION</string>
98
+ \t\t\t</array>
99
+ \t\t\t<key>UNNotificationExtensionDefaultContentHidden</key>
100
+ \t\t\t<false/>
101
+ \t\t\t<key>UNNotificationExtensionInitialContentSizeRatio</key>
102
+ \t\t\t<real>1.0</real>
103
+ \t\t</dict>
104
+ \t\t<key>NSExtensionPointIdentifier</key>
105
+ \t\t<string>com.apple.usernotifications.content-extension</string>
106
+ \t\t<key>NSExtensionPrincipalClass</key>
107
+ \t\t<string>$(PRODUCT_MODULE_NAME).NotificationViewController</string>
108
+ \t</dict>
109
+ </dict>
110
+ </plist>
111
+ `;
112
+ }
113
+ exports.buildNCEInfoPlist = buildNCEInfoPlist;
114
+ /** Generates the entitlements plist content for the ConnectNCE target. */
115
+ function buildNCEEntitlements(appGroupIdentifier) {
116
+ return `<?xml version="1.0" encoding="UTF-8"?>
117
+ <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
118
+ <plist version="1.0">
119
+ <dict>
120
+ \t<key>com.apple.security.application-groups</key>
121
+ \t<array>
122
+ \t\t<string>${appGroupIdentifier}</string>
123
+ \t</array>
124
+ </dict>
125
+ </plist>
126
+ `;
127
+ }
128
+ exports.buildNCEEntitlements = buildNCEEntitlements;
129
+ // ─── Podfile injection ────────────────────────────────────────────────────────
130
+ const PODFILE_MARKER = '# @generated ConnectNCE target (react-native-acoustic-connect-beta)';
131
+ /**
132
+ * Returns the Ruby snippet to inject into the Expo-generated Podfile for the
133
+ * ConnectNCE target. Thin wrapper over the shared
134
+ * {@link buildConnectPodTargetBlock} (single source of truth for the
135
+ * AcousticConnect pod-resolution helper), parameterised with the NCE marker,
136
+ * helper name, and target name.
137
+ */
138
+ function buildPodfileBlock() {
139
+ return (0, withConnectNSE_1.buildConnectPodTargetBlock)(PODFILE_MARKER, 'acoustic_connect_pod_nce', NCE_TARGET_NAME);
140
+ }
141
+ exports.buildPodfileBlock = buildPodfileBlock;
142
+ /**
143
+ * Injects the ConnectNCE Podfile block into `podfileContent` if not already
144
+ * present (idempotent, guarded by PODFILE_MARKER).
145
+ */
146
+ function injectPodfileBlock(podfileContent) {
147
+ if (podfileContent.includes(PODFILE_MARKER)) {
148
+ return podfileContent;
149
+ }
150
+ return podfileContent + buildPodfileBlock();
151
+ }
152
+ exports.injectPodfileBlock = injectPodfileBlock;
153
+ // ─── Xcode project mod ───────────────────────────────────────────────────────
154
+ /**
155
+ * Adds the ConnectNCE Xcode target (app_extension) to the project.
156
+ *
157
+ * Sibling to withNSEXcodeProject; the only differences are the target name,
158
+ * the Swift source file (NotificationViewController.swift), the NCE Info.plist
159
+ * (content-extension NSExtension keys), and skipping BOTH extension targets'
160
+ * configs when mirroring host build settings.
161
+ *
162
+ * Idempotent: if a target named ConnectNCE already exists, skips target
163
+ * creation but still (re)writes the source files.
164
+ */
165
+ function withNCEXcodeProject(config, appGroupIdentifier, swiftContent) {
166
+ return (0, config_plugins_1.withXcodeProject)(config, (c) => {
167
+ var _a, _b, _c, _d;
168
+ const xcodeProject = c.modResults;
169
+ // ios/ directory — modRequest.platformProjectRoot is the canonical
170
+ // native project root. (xcodeProject.filepath points INSIDE the
171
+ // .xcodeproj bundle, so deriving from it misplaces the files.)
172
+ const iosDir = c.modRequest.platformProjectRoot;
173
+ const nceDir = path.join(iosDir, NCE_TARGET_NAME);
174
+ // Always write / overwrite the source files (idempotent)
175
+ fs.mkdirSync(nceDir, { recursive: true });
176
+ fs.writeFileSync(path.join(nceDir, 'NotificationViewController.swift'), swiftContent, 'utf8');
177
+ fs.writeFileSync(path.join(nceDir, 'Info.plist'), buildNCEInfoPlist(), 'utf8');
178
+ fs.writeFileSync(path.join(nceDir, `${NCE_TARGET_NAME}.entitlements`), buildNCEEntitlements(appGroupIdentifier), 'utf8');
179
+ // Idempotency check — skip if target already registered in the pbxproj.
180
+ // Note: pbxTargetByName misses targets on a REPARSED project because the
181
+ // xcode lib stores written names with literal quotes ('"ConnectNCE"'),
182
+ // so compare quote-stripped names across the native-target section.
183
+ const nativeTargets = xcodeProject.pbxNativeTargetSection();
184
+ const targetExists = Object.values(nativeTargets).some((t) => typeof t === 'object' &&
185
+ typeof t.name === 'string' &&
186
+ t.name.replace(/"/g, '') === NCE_TARGET_NAME);
187
+ if (targetExists) {
188
+ return c;
189
+ }
190
+ // Derive the host bundle id — the NCE bundle id must be
191
+ // `<hostBundleId>.ConnectNCE`. Fail fast rather than emit a placeholder
192
+ // (a wrong bundle id breaks App Group pairing and App Store submission).
193
+ const hostBundleId = (_a = c.ios) === null || _a === void 0 ? void 0 : _a.bundleIdentifier;
194
+ if (!hostBundleId) {
195
+ throw new Error(`[react-native-acoustic-connect-beta] ios.bundleIdentifier is not set.\n\n` +
196
+ `The ConnectNCE extension bundle id is derived as ` +
197
+ `"<ios.bundleIdentifier>.ConnectNCE", so the host bundle id must be ` +
198
+ `defined in app.json before prebuild:\n` +
199
+ ` { "expo": { "ios": { "bundleIdentifier": "com.example.app" } } }`);
200
+ }
201
+ // Add the native target (app_extension)
202
+ const nceTarget = xcodeProject.addTarget(NCE_TARGET_NAME, 'app_extension', NCE_TARGET_NAME, `${hostBundleId}.ConnectNCE`);
203
+ if (!nceTarget) {
204
+ throw new Error(`[react-native-acoustic-connect-beta] Failed to add ConnectNCE Xcode target.`);
205
+ }
206
+ // Add the build phase for Swift sources
207
+ xcodeProject.addBuildPhase(['NotificationViewController.swift'], 'PBXSourcesBuildPhase', 'Sources', nceTarget.uuid);
208
+ // Add Resources build phase (empty, but required by Xcode)
209
+ xcodeProject.addBuildPhase([], 'PBXResourcesBuildPhase', 'Resources', nceTarget.uuid);
210
+ // Add Frameworks build phase (empty — CocoaPods populates it)
211
+ xcodeProject.addBuildPhase([], 'PBXFrameworksBuildPhase', 'Frameworks', nceTarget.uuid);
212
+ // Make the host app target depend on ConnectNCE. CocoaPods resolves an
213
+ // extension's host target through PBXTargetDependency
214
+ // (xcodeproj's host_targets_for_embedded_target), NOT through the embed
215
+ // copy phase — without this edge `pod install` fails with "Unable to find
216
+ // host target(s) for ConnectNCE".
217
+ // The xcode lib SILENTLY no-ops addTargetDependency when these sections
218
+ // are absent from the parsed project — create them first. (The NSE mod
219
+ // already creates them when it runs before this; guarding here keeps the
220
+ // NCE mod correct if it ever runs first.)
221
+ const objects = xcodeProject.hash.project.objects;
222
+ objects['PBXTargetDependency'] = (_b = objects['PBXTargetDependency']) !== null && _b !== void 0 ? _b : {};
223
+ objects['PBXContainerItemProxy'] = (_c = objects['PBXContainerItemProxy']) !== null && _c !== void 0 ? _c : {};
224
+ const hostTargetUuid = xcodeProject.getFirstTarget().uuid;
225
+ xcodeProject.addTargetDependency(hostTargetUuid, [nceTarget.uuid]);
226
+ // Create a PBXGroup for ConnectNCE source files
227
+ const nceGroup = xcodeProject.addPbxGroup([
228
+ 'NotificationViewController.swift',
229
+ 'Info.plist',
230
+ `${NCE_TARGET_NAME}.entitlements`,
231
+ ], NCE_TARGET_NAME, NCE_TARGET_NAME);
232
+ // Add the group to the main project group
233
+ const mainGroup = xcodeProject.getFirstProject().firstProject.mainGroup;
234
+ xcodeProject.addToPbxGroup(nceGroup.uuid, mainGroup);
235
+ // Set per-configuration build settings — mirror each host configuration
236
+ // individually so Debug gets Debug values and Release gets Release values.
237
+ const buildConfigurations = xcodeProject.pbxXCConfigurationList();
238
+ const nceConfigListUuid = nceTarget.pbxNativeTarget.buildConfigurationList;
239
+ if (nceConfigListUuid) {
240
+ const configList = buildConfigurations[nceConfigListUuid];
241
+ if (configList &&
242
+ Array.isArray(configList
243
+ .buildConfigurations)) {
244
+ const configs = xcodeProject.pbxXCBuildConfigurationSection();
245
+ for (const entry of configList.buildConfigurations) {
246
+ const buildConfig = configs[entry.value];
247
+ if (buildConfig && buildConfig.buildSettings) {
248
+ // Determine which host config name to mirror (Debug → Debug, etc.)
249
+ const configName = (_d = buildConfig.name) !== null && _d !== void 0 ? _d : 'Debug';
250
+ // Mirror per-configuration values; fall back to the other config's
251
+ // value only when the matching one is absent. Skip BOTH extension
252
+ // targets so the NCE never mirrors the NSE target's settings.
253
+ const deploymentTarget = (0, withConnectNSE_1.getHostBuildSettingForConfig)(xcodeProject, 'IPHONEOS_DEPLOYMENT_TARGET', configName,
254
+ // Matches the AcousticConnect podspec floor (iOS >= 15.1) so the
255
+ // NCE never demands a higher minimum than the host app.
256
+ '15.1', EXTENSION_TARGET_NAMES);
257
+ const swiftVersion = (0, withConnectNSE_1.getHostBuildSettingForConfig)(xcodeProject, 'SWIFT_VERSION', configName, '5.0', EXTENSION_TARGET_NAMES);
258
+ const marketingVersion = (0, withConnectNSE_1.getHostBuildSettingForConfig)(xcodeProject, 'MARKETING_VERSION', configName, '1.0', EXTENSION_TARGET_NAMES);
259
+ const currentProjectVersion = (0, withConnectNSE_1.getHostBuildSettingForConfig)(xcodeProject, 'CURRENT_PROJECT_VERSION', configName, '1', EXTENSION_TARGET_NAMES);
260
+ Object.assign(buildConfig.buildSettings, {
261
+ // Prevent Xcode from synthesising a second Info.plist that would
262
+ // shadow the NSExtension dictionary in ours.
263
+ GENERATE_INFOPLIST_FILE: 'NO',
264
+ INFOPLIST_FILE: `${NCE_TARGET_NAME}/Info.plist`,
265
+ // Extension must target the device SDK and restrict to
266
+ // extension-safe APIs (mirrors bare-workflow reference target).
267
+ SDKROOT: 'iphoneos',
268
+ APPLICATION_EXTENSION_API_ONLY: 'YES',
269
+ IPHONEOS_DEPLOYMENT_TARGET: deploymentTarget,
270
+ SWIFT_VERSION: swiftVersion,
271
+ MARKETING_VERSION: marketingVersion,
272
+ CURRENT_PROJECT_VERSION: currentProjectVersion,
273
+ CODE_SIGN_ENTITLEMENTS: `${NCE_TARGET_NAME}/${NCE_TARGET_NAME}.entitlements`,
274
+ PRODUCT_NAME: NCE_TARGET_NAME,
275
+ PRODUCT_BUNDLE_IDENTIFIER: `${hostBundleId}.ConnectNCE`,
276
+ TARGETED_DEVICE_FAMILY: '"1,2"',
277
+ CODE_SIGN_STYLE: 'Automatic',
278
+ });
279
+ }
280
+ }
281
+ }
282
+ }
283
+ return c;
284
+ });
285
+ }
286
+ exports.withNCEXcodeProject = withNCEXcodeProject;
287
+ // ─── Podfile mod ─────────────────────────────────────────────────────────────
288
+ /**
289
+ * Injects the ConnectNCE Podfile target block via withDangerousMod.
290
+ * Guarded by a marker comment — re-runs are no-ops.
291
+ *
292
+ * Throws a clear, actionable error when the Podfile does not exist at
293
+ * mod-execution time, instead of silently returning — a silent skip would
294
+ * ship an NCE whose `import Connect` cannot resolve.
295
+ */
296
+ function withNCEPodfile(config) {
297
+ return (0, config_plugins_1.withDangerousMod)(config, [
298
+ 'ios',
299
+ async (c) => {
300
+ const podfilePath = path.join(c.modRequest.platformProjectRoot, 'Podfile');
301
+ if (!fs.existsSync(podfilePath)) {
302
+ throw new Error(`[react-native-acoustic-connect-beta] ios/Podfile not found at ${podfilePath}.\n\n` +
303
+ `This mod runs after prebuild generates the ios/ directory. ` +
304
+ `If you are running this plugin outside of \`expo prebuild\`, ` +
305
+ `ensure the Podfile exists before the dangerous mod phase executes.\n` +
306
+ `Check prebuild ordering: withDangerousMod('ios') runs after ` +
307
+ `withXcodeProject, so the ios/ directory should already be present.`);
308
+ }
309
+ const current = fs.readFileSync(podfilePath, 'utf8');
310
+ const updated = injectPodfileBlock(current);
311
+ if (updated !== current) {
312
+ fs.writeFileSync(podfilePath, updated, 'utf8');
313
+ }
314
+ return c;
315
+ },
316
+ ]);
317
+ }
318
+ exports.withNCEPodfile = withNCEPodfile;
319
+ // ─── Composed mod ─────────────────────────────────────────────────────────────
320
+ /**
321
+ * Expo Config Plugin mod that provisions a Notification Content Extension
322
+ * (NCE) Xcode target named `ConnectNCE`.
323
+ *
324
+ * Applies three mutations — all idempotent:
325
+ * 1. Host app entitlements: merges App Group into
326
+ * `com.apple.security.application-groups` (reuses the NSE host-entitlements
327
+ * mod — the host shares one App Group across app + NSE + NCE; the merge is
328
+ * a no-op when the NSE mod already added it).
329
+ * 2. Xcode project: adds ConnectNCE target + files (skips if already present).
330
+ * 3. Podfile: injects `target 'ConnectNCE'` block (guarded by marker comment).
331
+ *
332
+ * `config._internal.projectRoot` is required (injected by Expo CLI during
333
+ * `expo prebuild`); an actionable error is thrown if absent rather than
334
+ * silently falling back to `process.cwd()`.
335
+ *
336
+ * NSE coupling (intentional, tracked for refactor): this mod deliberately
337
+ * reuses three pieces of withConnectNSE — `withNSEEntitlements` (the host App
338
+ * Group is shared across app + NSE + NCE), `buildConnectPodTargetBlock` (one
339
+ * source for the pod-resolution helper), and `getHostBuildSettingForConfig`
340
+ * (the per-config mirroring logic). The composition always runs withConnectNSE
341
+ * before withConnectNCE, so the shared host entitlement and the
342
+ * PBXTargetDependency/PBXContainerItemProxy sections already exist when this
343
+ * runs. Extracting a shared `withConnectExtension` base for NSE + NCE is
344
+ * tracked as a follow-up refactor (see PR description) rather than done here,
345
+ * to keep the already-landed NSE mod stable.
346
+ */
347
+ const withConnectNCE = (config, props = {}) => {
348
+ var _a;
349
+ const projectRoot = (_a = config._internal) === null || _a === void 0 ? void 0 : _a.projectRoot;
350
+ if (!projectRoot) {
351
+ throw new Error(`[react-native-acoustic-connect-beta] config._internal.projectRoot is not set.\n\n` +
352
+ `This value is injected by Expo CLI during \`expo prebuild\`. ` +
353
+ `If you are calling this plugin outside of Expo CLI (e.g. in a test or ` +
354
+ `custom script), set config._internal = { projectRoot: '/abs/path/to/project' } ` +
355
+ `before invoking the plugin.`);
356
+ }
357
+ const appGroupIdentifier = (0, withConnectNSE_1.resolveAppGroupIdentifier)(projectRoot, props);
358
+ const swiftTemplatePath = path.join(__dirname, '..', 'swift', 'NotificationViewController.swift');
359
+ const swiftContent = (0, withConnectNSE_1.substituteSwiftTemplate)(swiftTemplatePath, appGroupIdentifier);
360
+ let result = (0, withConnectNSE_1.withNSEEntitlements)(config, appGroupIdentifier);
361
+ result = withNCEXcodeProject(result, appGroupIdentifier, swiftContent);
362
+ result = withNCEPodfile(result);
363
+ return result;
364
+ };
365
+ exports.withConnectNCE = withConnectNCE;
366
+ //# sourceMappingURL=withConnectNCE.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"withConnectNCE.js","sourceRoot":"","sources":["../src/withConnectNCE.ts"],"names":[],"mappings":";AAAA,yDAAyD;AACzD,EAAE;AACF,8EAA8E;AAC9E,0EAA0E;AAC1E,6EAA6E;AAC7E,8EAA8E;AAC9E,wDAAwD;;;;;;;;;;;;;;;;;;;;;;;;;;AAExD,yDAI6B;AAE7B,uCAAwB;AACxB,2CAA4B;AAC5B,qDAOyB;AASzB,8EAA8E;AAE9E,MAAM,eAAe,GAAG,YAAY,CAAA;AACpC,MAAM,eAAe,GAAG,YAAY,CAAA;AAEpC,8EAA8E;AAC9E,8EAA8E;AAC9E,+EAA+E;AAC/E,+EAA+E;AAC/E,uBAAuB;AACvB,MAAM,sBAAsB,GAAG,CAAC,eAAe,EAAE,eAAe,CAAC,CAAA;A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