@getuserfeedback/react-native 5.1.10 → 5.1.11

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/dist/client.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import type { AppEventExternalId, AppEventJsonValue, PublicCommandPayload } from "@getuserfeedback/protocol";
2
- import type { CapabilitiesInput, ConfigureOptions, GraphOperations, InitOptions } from "@getuserfeedback/sdk";
2
+ import type { CapabilitiesInput, ConfigureOptions, GraphOperations, InitOptions, TrackOptions } from "@getuserfeedback/sdk";
3
3
  type IdentifyTraits = Record<string, unknown>;
4
4
  type TrackProperties = Record<string, AppEventJsonValue>;
5
5
  type OpenCommand = Extract<PublicCommandPayload, {
@@ -11,9 +11,6 @@ type PrerenderCommand = Extract<PublicCommandPayload, {
11
11
  type IdentifyOptions = {
12
12
  externalIds?: AppEventExternalId[];
13
13
  };
14
- type TrackOptions = {
15
- externalIds?: AppEventExternalId[];
16
- };
17
14
  type OpenFlowOptions = Pick<OpenCommand, "hideCloseButton" | "metadata">;
18
15
  type PrerenderFlowOptions = Pick<PrerenderCommand, "hideCloseButton">;
19
16
  type HostContext = Extract<PublicCommandPayload, {
@@ -1,4 +1,5 @@
1
1
  import { assertNoSegmentExternalIdsInValueArgument } from "@getuserfeedback/protocol/host";
2
+ import { parseTrackMessageId } from "@getuserfeedback/protocol/internal/sdk-event-options";
2
3
  export const parseRequiredString = (name, value) => {
3
4
  const normalized = value === null || value === void 0 ? void 0 : value.trim();
4
5
  if (!normalized) {
@@ -41,7 +42,8 @@ export function createNativeProviderClient({ dispatchCommand, flow, instanceId,
41
42
  valueArgumentName: "properties",
42
43
  callShape: "track(eventName, properties, { externalIds })",
43
44
  });
44
- return dispatchCommand(Object.assign(Object.assign({ kind: "track", origin: "customer", event: parseRequiredString("eventName", eventName) }, (properties === undefined ? {} : { properties })), ((options === null || options === void 0 ? void 0 : options.externalIds) === undefined
45
+ const messageId = parseTrackMessageId(options === null || options === void 0 ? void 0 : options.messageId);
46
+ return dispatchCommand(Object.assign(Object.assign(Object.assign({ kind: "track", origin: "customer", event: parseRequiredString("eventName", eventName) }, (properties === undefined ? {} : { properties })), (messageId === undefined ? {} : { messageId })), ((options === null || options === void 0 ? void 0 : options.externalIds) === undefined
45
47
  ? {}
46
48
  : { context: { externalIds: options.externalIds } })));
47
49
  };
package/dist/version.js CHANGED
@@ -3,4 +3,4 @@ const reactNativeSdkVersion = typeof __GX_REACT_NATIVE_SDK_VERSION__ === "string
3
3
  : "";
4
4
  // Build scripts patch this fallback to the package version for published artifacts.
5
5
  // Source-linked workspace usage keeps the local fallback.
6
- export const REACT_NATIVE_SDK_VERSION = reactNativeSdkVersion.length > 0 ? reactNativeSdkVersion : "5.1.10";
6
+ export const REACT_NATIVE_SDK_VERSION = reactNativeSdkVersion.length > 0 ? reactNativeSdkVersion : "5.1.11";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@getuserfeedback/react-native",
3
- "version": "5.1.10",
3
+ "version": "5.1.11",
4
4
  "description": "getuserfeedback React Native SDK",
5
5
  "keywords": [
6
6
  "getuserfeedback",
@@ -45,7 +45,7 @@
45
45
  },
46
46
  "dependencies": {
47
47
  "@getuserfeedback/protocol": "^5.0.2",
48
- "@getuserfeedback/sdk": "^0.13.8",
48
+ "@getuserfeedback/sdk": "^0.13.9",
49
49
  "robot3": "^1.2.0"
50
50
  },
51
51
  "peerDependencies": {