@rocapine/react-native-onboarding 1.0.0 → 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -1,4 +1,5 @@
1
1
  export { OnboardingStudioClient } from "./OnboardingStudioClient";
2
2
  export * from "./types";
3
+ export * from "./onboarding-example";
3
4
  export * from "./infra";
4
5
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAC;AAClE,cAAc,SAAS,CAAC;AAGxB,cAAc,SAAS,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAC;AAClE,cAAc,SAAS,CAAC;AACxB,cAAc,sBAAsB,CAAC;AAErC,cAAc,SAAS,CAAC"}
package/dist/index.js CHANGED
@@ -19,6 +19,7 @@ exports.OnboardingStudioClient = void 0;
19
19
  var OnboardingStudioClient_1 = require("./OnboardingStudioClient");
20
20
  Object.defineProperty(exports, "OnboardingStudioClient", { enumerable: true, get: function () { return OnboardingStudioClient_1.OnboardingStudioClient; } });
21
21
  __exportStar(require("./types"), exports);
22
+ __exportStar(require("./onboarding-example"), exports);
22
23
  // Hooks and providers
23
24
  __exportStar(require("./infra"), exports);
24
25
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAAA,wBAAwB;AACxB,mEAAkE;AAAzD,gIAAA,sBAAsB,OAAA;AAC/B,0CAAwB;AAExB,sBAAsB;AACtB,0CAAwB"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAAA,wBAAwB;AACxB,mEAAkE;AAAzD,gIAAA,sBAAsB,OAAA;AAC/B,0CAAwB;AACxB,uDAAqC;AACrC,sBAAsB;AACtB,0CAAwB"}
@@ -0,0 +1,149 @@
1
+ export declare const onboardingExample: {
2
+ metadata: {
3
+ id: string;
4
+ name: string;
5
+ audienceId: undefined;
6
+ audienceName: undefined;
7
+ audienceOrder: undefined;
8
+ draft: true;
9
+ };
10
+ steps: ({
11
+ id: string;
12
+ name: string;
13
+ type: string;
14
+ payload: {
15
+ title: string;
16
+ description: string;
17
+ mediaSource: {
18
+ url: string;
19
+ type: string;
20
+ };
21
+ answers?: undefined;
22
+ infoBox?: undefined;
23
+ subtitle?: undefined;
24
+ multipleAnswer?: undefined;
25
+ pickerType?: undefined;
26
+ steps?: undefined;
27
+ variant?: undefined;
28
+ duration?: undefined;
29
+ didYouKnowImages?: undefined;
30
+ socialProofs?: undefined;
31
+ rateTheAppButtonLabel?: undefined;
32
+ };
33
+ figmaUrl: null;
34
+ customPayload: {};
35
+ continueButtonLabel: string;
36
+ displayProgressHeader: true;
37
+ } | {
38
+ id: string;
39
+ name: string;
40
+ type: string;
41
+ payload: {
42
+ title: string;
43
+ answers: {
44
+ label: string;
45
+ value: string;
46
+ }[];
47
+ infoBox: null;
48
+ subtitle: null;
49
+ multipleAnswer: boolean;
50
+ description?: undefined;
51
+ mediaSource?: undefined;
52
+ pickerType?: undefined;
53
+ steps?: undefined;
54
+ variant?: undefined;
55
+ duration?: undefined;
56
+ didYouKnowImages?: undefined;
57
+ socialProofs?: undefined;
58
+ rateTheAppButtonLabel?: undefined;
59
+ };
60
+ figmaUrl: null;
61
+ customPayload: {};
62
+ displayProgressHeader: true;
63
+ continueButtonLabel?: undefined;
64
+ } | {
65
+ id: string;
66
+ name: string;
67
+ type: string;
68
+ payload: {
69
+ title: string;
70
+ pickerType: string;
71
+ description: string;
72
+ mediaSource?: undefined;
73
+ answers?: undefined;
74
+ infoBox?: undefined;
75
+ subtitle?: undefined;
76
+ multipleAnswer?: undefined;
77
+ steps?: undefined;
78
+ variant?: undefined;
79
+ duration?: undefined;
80
+ didYouKnowImages?: undefined;
81
+ socialProofs?: undefined;
82
+ rateTheAppButtonLabel?: undefined;
83
+ };
84
+ figmaUrl: null;
85
+ customPayload: {};
86
+ continueButtonLabel: string;
87
+ displayProgressHeader: true;
88
+ } | {
89
+ id: string;
90
+ name: string;
91
+ type: string;
92
+ payload: {
93
+ steps: {
94
+ label: string;
95
+ completed: string;
96
+ }[];
97
+ title: string;
98
+ variant: string;
99
+ duration: number;
100
+ didYouKnowImages: {
101
+ url: string;
102
+ type: string;
103
+ }[];
104
+ description?: undefined;
105
+ mediaSource?: undefined;
106
+ answers?: undefined;
107
+ infoBox?: undefined;
108
+ subtitle?: undefined;
109
+ multipleAnswer?: undefined;
110
+ pickerType?: undefined;
111
+ socialProofs?: undefined;
112
+ rateTheAppButtonLabel?: undefined;
113
+ };
114
+ figmaUrl: null;
115
+ customPayload: {};
116
+ continueButtonLabel: string;
117
+ displayProgressHeader: false;
118
+ } | {
119
+ id: string;
120
+ name: string;
121
+ type: string;
122
+ payload: {
123
+ title: string;
124
+ subtitle: string;
125
+ socialProofs: {
126
+ content: string;
127
+ authorName: string;
128
+ numberOfStar: number;
129
+ }[];
130
+ rateTheAppButtonLabel: string;
131
+ description?: undefined;
132
+ mediaSource?: undefined;
133
+ answers?: undefined;
134
+ infoBox?: undefined;
135
+ multipleAnswer?: undefined;
136
+ pickerType?: undefined;
137
+ steps?: undefined;
138
+ variant?: undefined;
139
+ duration?: undefined;
140
+ didYouKnowImages?: undefined;
141
+ };
142
+ figmaUrl: null;
143
+ customPayload: {};
144
+ continueButtonLabel: string;
145
+ displayProgressHeader: false;
146
+ })[];
147
+ configuration: {};
148
+ };
149
+ //# sourceMappingURL=onboarding-example.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"onboarding-example.d.ts","sourceRoot":"","sources":["../src/onboarding-example.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAgHR,CAAC"}
@@ -0,0 +1,116 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.onboardingExample = void 0;
4
+ exports.onboardingExample = {
5
+ metadata: {
6
+ id: "example-onboarding",
7
+ name: "Example Onboarding",
8
+ audienceId: undefined,
9
+ audienceName: undefined,
10
+ audienceOrder: undefined,
11
+ draft: true,
12
+ },
13
+ steps: [
14
+ {
15
+ id: "welcome",
16
+ name: "Welcome",
17
+ type: "MediaContent",
18
+ payload: {
19
+ title: "Welcome Test 11/12!",
20
+ description: "Get started with your personalized experience",
21
+ mediaSource: {
22
+ url: "https://api-ninjas.com/images/cats/abyssinian.jpg",
23
+ type: "image",
24
+ },
25
+ },
26
+ figmaUrl: null,
27
+ customPayload: {},
28
+ continueButtonLabel: "Continue",
29
+ displayProgressHeader: true,
30
+ },
31
+ {
32
+ id: "question-favorite-color",
33
+ name: "Favorite Color",
34
+ type: "Question",
35
+ payload: {
36
+ title: "What's your favorite color?",
37
+ answers: [
38
+ { label: "Red", value: "red" },
39
+ { label: "Blue", value: "blue" },
40
+ { label: "Green", value: "green" },
41
+ { label: "Yellow", value: "yellow" },
42
+ ],
43
+ infoBox: null,
44
+ subtitle: null,
45
+ multipleAnswer: false,
46
+ },
47
+ figmaUrl: null,
48
+ customPayload: {},
49
+ displayProgressHeader: true,
50
+ },
51
+ {
52
+ id: "picker-name",
53
+ name: "Name",
54
+ type: "Picker",
55
+ payload: {
56
+ title: "What's your name?",
57
+ pickerType: "name",
58
+ description: "",
59
+ },
60
+ figmaUrl: null,
61
+ customPayload: {},
62
+ continueButtonLabel: "Continue",
63
+ displayProgressHeader: true,
64
+ },
65
+ {
66
+ id: "loader-creating-profile",
67
+ name: "Creating Profile",
68
+ type: "Loader",
69
+ payload: {
70
+ steps: [
71
+ {
72
+ label: "Processing your information",
73
+ completed: "Information processed",
74
+ },
75
+ { label: "Setting up your profile", completed: "Profile ready" },
76
+ { label: "Preparing your experience", completed: "All set!" },
77
+ ],
78
+ title: "Creating your personalized profile...",
79
+ variant: "bars",
80
+ duration: 2000,
81
+ didYouKnowImages: [
82
+ { url: "https://picsum.photos/300/200?random=1", type: "image" },
83
+ { url: "https://picsum.photos/300/200?random=2", type: "image" },
84
+ { url: "https://picsum.photos/300/200?random=3", type: "image" },
85
+ ],
86
+ },
87
+ figmaUrl: null,
88
+ customPayload: {},
89
+ continueButtonLabel: "Continue",
90
+ displayProgressHeader: false,
91
+ },
92
+ {
93
+ id: "ratings-app",
94
+ name: "Rate the App",
95
+ type: "Ratings",
96
+ payload: {
97
+ title: "Enjoying the app?",
98
+ subtitle: "How do you rate our app?",
99
+ socialProofs: [
100
+ {
101
+ content: "This app is amazing! It helped me get started quickly and the experience is so smooth.",
102
+ authorName: "happyuser2024",
103
+ numberOfStar: 5,
104
+ },
105
+ ],
106
+ rateTheAppButtonLabel: "Rate the App",
107
+ },
108
+ figmaUrl: null,
109
+ customPayload: {},
110
+ continueButtonLabel: "Continue",
111
+ displayProgressHeader: false,
112
+ },
113
+ ],
114
+ configuration: {},
115
+ };
116
+ //# sourceMappingURL=onboarding-example.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"onboarding-example.js","sourceRoot":"","sources":["../src/onboarding-example.ts"],"names":[],"mappings":";;;AAEa,QAAA,iBAAiB,GAAG;IAC/B,QAAQ,EAAE;QACR,EAAE,EAAE,oBAAoB;QACxB,IAAI,EAAE,oBAAoB;QAC1B,UAAU,EAAE,SAAS;QACrB,YAAY,EAAE,SAAS;QACvB,aAAa,EAAE,SAAS;QACxB,KAAK,EAAE,IAAI;KACZ;IACD,KAAK,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version": "1.0.1",
4
4
  "description": "Headless React Native SDK for Rocapine Onboarding Studio - Data fetching, state management, and hooks",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
package/src/index.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  // Core client and types
2
2
  export { OnboardingStudioClient } from "./OnboardingStudioClient";
3
3
  export * from "./types";
4
-
4
+ export * from "./onboarding-example";
5
5
  // Hooks and providers
6
6
  export * from "./infra";
@@ -0,0 +1,115 @@
1
+ import { Onboarding } from "./types";
2
+
3
+ export const onboardingExample = {
4
+ metadata: {
5
+ id: "example-onboarding",
6
+ name: "Example Onboarding",
7
+ audienceId: undefined,
8
+ audienceName: undefined,
9
+ audienceOrder: undefined,
10
+ draft: true,
11
+ },
12
+ steps: [
13
+ {
14
+ id: "welcome",
15
+ name: "Welcome",
16
+ type: "MediaContent",
17
+ payload: {
18
+ title: "Welcome Test 11/12!",
19
+ description: "Get started with your personalized experience",
20
+ mediaSource: {
21
+ url: "https://api-ninjas.com/images/cats/abyssinian.jpg",
22
+ type: "image",
23
+ },
24
+ },
25
+ figmaUrl: null,
26
+ customPayload: {},
27
+ continueButtonLabel: "Continue",
28
+ displayProgressHeader: true,
29
+ },
30
+ {
31
+ id: "question-favorite-color",
32
+ name: "Favorite Color",
33
+ type: "Question",
34
+ payload: {
35
+ title: "What's your favorite color?",
36
+ answers: [
37
+ { label: "Red", value: "red" },
38
+ { label: "Blue", value: "blue" },
39
+ { label: "Green", value: "green" },
40
+ { label: "Yellow", value: "yellow" },
41
+ ],
42
+ infoBox: null,
43
+ subtitle: null,
44
+ multipleAnswer: false,
45
+ },
46
+ figmaUrl: null,
47
+ customPayload: {},
48
+ displayProgressHeader: true,
49
+ },
50
+ {
51
+ id: "picker-name",
52
+ name: "Name",
53
+ type: "Picker",
54
+ payload: {
55
+ title: "What's your name?",
56
+ pickerType: "name",
57
+ description: "",
58
+ },
59
+ figmaUrl: null,
60
+ customPayload: {},
61
+ continueButtonLabel: "Continue",
62
+ displayProgressHeader: true,
63
+ },
64
+ {
65
+ id: "loader-creating-profile",
66
+ name: "Creating Profile",
67
+ type: "Loader",
68
+ payload: {
69
+ steps: [
70
+ {
71
+ label: "Processing your information",
72
+ completed: "Information processed",
73
+ },
74
+ { label: "Setting up your profile", completed: "Profile ready" },
75
+ { label: "Preparing your experience", completed: "All set!" },
76
+ ],
77
+ title: "Creating your personalized profile...",
78
+ variant: "bars",
79
+ duration: 2000,
80
+ didYouKnowImages: [
81
+ { url: "https://picsum.photos/300/200?random=1", type: "image" },
82
+ { url: "https://picsum.photos/300/200?random=2", type: "image" },
83
+ { url: "https://picsum.photos/300/200?random=3", type: "image" },
84
+ ],
85
+ },
86
+ figmaUrl: null,
87
+ customPayload: {},
88
+ continueButtonLabel: "Continue",
89
+ displayProgressHeader: false,
90
+ },
91
+ {
92
+ id: "ratings-app",
93
+ name: "Rate the App",
94
+ type: "Ratings",
95
+ payload: {
96
+ title: "Enjoying the app?",
97
+ subtitle: "How do you rate our app?",
98
+ socialProofs: [
99
+ {
100
+ content:
101
+ "This app is amazing! It helped me get started quickly and the experience is so smooth.",
102
+ authorName: "happyuser2024",
103
+ numberOfStar: 5,
104
+ },
105
+ ],
106
+ rateTheAppButtonLabel: "Rate the App",
107
+ },
108
+ figmaUrl: null,
109
+ customPayload: {},
110
+ continueButtonLabel: "Continue",
111
+ displayProgressHeader: false,
112
+ },
113
+ ],
114
+ configuration: {},
115
+ } satisfies Onboarding;