@kakadu/types-play 1.0.0 → 1.0.2
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/build/index.d.mts +206 -0
- package/build/index.d.ts +206 -0
- package/build/index.js +154 -0
- package/build/index.js.map +1 -0
- package/build/index.mjs +140 -0
- package/build/index.mjs.map +1 -0
- package/package.json +11 -11
- package/dist/index.d.mts +0 -1186
- package/dist/index.d.ts +0 -1186
- package/dist/index.js +0 -146
- package/dist/index.js.map +0 -1
- package/dist/index.mjs +0 -134
- package/dist/index.mjs.map +0 -1
|
@@ -0,0 +1,206 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* @maxLength 50
|
|
5
|
+
*/
|
|
6
|
+
type Id = string;
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* @schema string().url().startsWith("https://")
|
|
10
|
+
*/
|
|
11
|
+
type Url = string;
|
|
12
|
+
|
|
13
|
+
type Image = {
|
|
14
|
+
url: Url;
|
|
15
|
+
/**
|
|
16
|
+
* @schema number().int().min(1).optional()
|
|
17
|
+
*/
|
|
18
|
+
width?: number;
|
|
19
|
+
/**
|
|
20
|
+
* @schema number().int().min(1).optional()
|
|
21
|
+
*/
|
|
22
|
+
height?: number;
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
/**
|
|
26
|
+
* @maxLength 450
|
|
27
|
+
*/
|
|
28
|
+
type Name = string;
|
|
29
|
+
|
|
30
|
+
type DatabasePlayStepTarget = {
|
|
31
|
+
Id: string;
|
|
32
|
+
RecipeStepId: string;
|
|
33
|
+
X: number;
|
|
34
|
+
Y: number;
|
|
35
|
+
W: number;
|
|
36
|
+
H: number;
|
|
37
|
+
};
|
|
38
|
+
type PlayStepTarget = {
|
|
39
|
+
id: Id;
|
|
40
|
+
playStepId: Id;
|
|
41
|
+
x: number;
|
|
42
|
+
y: number;
|
|
43
|
+
width: number;
|
|
44
|
+
height: number;
|
|
45
|
+
};
|
|
46
|
+
type ClientPlayStepTarget = Omit<PlayStepTarget, 'playStepId'>;
|
|
47
|
+
|
|
48
|
+
type DatabasePlayStep = {
|
|
49
|
+
Id: string;
|
|
50
|
+
RecipeId: string;
|
|
51
|
+
Order: number;
|
|
52
|
+
Description: string;
|
|
53
|
+
ImagePath: string;
|
|
54
|
+
};
|
|
55
|
+
type PlayStep = {
|
|
56
|
+
id: Id;
|
|
57
|
+
playId: Id;
|
|
58
|
+
order: number;
|
|
59
|
+
description?: Name;
|
|
60
|
+
image?: Image;
|
|
61
|
+
};
|
|
62
|
+
type ClientPlayStep = Omit<PlayStep, 'playId' | 'order'> & {
|
|
63
|
+
target?: ClientPlayStepTarget;
|
|
64
|
+
};
|
|
65
|
+
|
|
66
|
+
type DatabasePlay = {
|
|
67
|
+
Id: string;
|
|
68
|
+
CreatedDate: Date;
|
|
69
|
+
CustomerId: string;
|
|
70
|
+
Locale: string;
|
|
71
|
+
Status?: 'Published' | 'Listed' | 'Private';
|
|
72
|
+
Title: string;
|
|
73
|
+
Slug: string;
|
|
74
|
+
Description: string;
|
|
75
|
+
ImagePath: string;
|
|
76
|
+
IsDeleted: boolean;
|
|
77
|
+
};
|
|
78
|
+
type Play = {
|
|
79
|
+
id: Id;
|
|
80
|
+
organizationId: Id;
|
|
81
|
+
locale: string;
|
|
82
|
+
title?: Name;
|
|
83
|
+
slug: Name;
|
|
84
|
+
description?: Name;
|
|
85
|
+
image?: Image;
|
|
86
|
+
creationDate: Date;
|
|
87
|
+
};
|
|
88
|
+
type ClientPlay = Omit<Play, 'organizationId'> & {
|
|
89
|
+
urls: {
|
|
90
|
+
page: string;
|
|
91
|
+
embed: string;
|
|
92
|
+
};
|
|
93
|
+
stepsCount: number;
|
|
94
|
+
steps?: ClientPlayStep[];
|
|
95
|
+
};
|
|
96
|
+
|
|
97
|
+
declare const playSchema: z.ZodType<Play>;
|
|
98
|
+
declare const clientPlaySchema: z.ZodType<ClientPlay>;
|
|
99
|
+
|
|
100
|
+
declare const playStepSchema: z.ZodType<PlayStep>;
|
|
101
|
+
declare const clientPlayStepSchema: z.ZodType<ClientPlayStep>;
|
|
102
|
+
|
|
103
|
+
declare const playStepTargetSchema: z.ZodType<PlayStepTarget>;
|
|
104
|
+
declare const clientPlayStepTargetSchema: z.ZodType<ClientPlayStepTarget>;
|
|
105
|
+
|
|
106
|
+
type DatabasePlayFeedback = {
|
|
107
|
+
Id: string;
|
|
108
|
+
RecipeId: string;
|
|
109
|
+
Positive: boolean;
|
|
110
|
+
Comment?: string;
|
|
111
|
+
VoteDate: Date;
|
|
112
|
+
};
|
|
113
|
+
type PlayFeedback = {
|
|
114
|
+
id: Id;
|
|
115
|
+
playId: Id;
|
|
116
|
+
value: boolean;
|
|
117
|
+
content?: string;
|
|
118
|
+
creationDate: Date;
|
|
119
|
+
};
|
|
120
|
+
type ClientPlayFeedback = Omit<PlayFeedback, 'playId'>;
|
|
121
|
+
|
|
122
|
+
declare const playFeedbackSchema: z.ZodType<PlayFeedback>;
|
|
123
|
+
declare const clientPlayFeedbackSchema: z.ZodType<ClientPlayFeedback>;
|
|
124
|
+
|
|
125
|
+
type PlayAnalyticsMetrics = {
|
|
126
|
+
/** Plausible unique visitors */
|
|
127
|
+
visitors: number;
|
|
128
|
+
/** Plausible pageview events */
|
|
129
|
+
pageviews: number;
|
|
130
|
+
};
|
|
131
|
+
type PlayAnalyticsEventMetrics = {
|
|
132
|
+
/** Plausible total event count */
|
|
133
|
+
total: number;
|
|
134
|
+
/** Plausible unique visitors */
|
|
135
|
+
visitors: number;
|
|
136
|
+
};
|
|
137
|
+
type PlayAnalyticsData = {
|
|
138
|
+
/** Plausible unique visitors */
|
|
139
|
+
visitors?: number;
|
|
140
|
+
/** Plausible pageview events */
|
|
141
|
+
pageviews?: number;
|
|
142
|
+
/** Event count of guide starts. */
|
|
143
|
+
started?: PlayAnalyticsEventMetrics;
|
|
144
|
+
/** Event count of guide finishes. */
|
|
145
|
+
finished?: PlayAnalyticsEventMetrics;
|
|
146
|
+
/** Event count of guide restarts. */
|
|
147
|
+
restarted?: PlayAnalyticsEventMetrics;
|
|
148
|
+
/** Event count of guides printed. */
|
|
149
|
+
printed?: PlayAnalyticsEventMetrics;
|
|
150
|
+
/** Step event counts and uniques per step. */
|
|
151
|
+
steps: PlayAnalyticsEventMetrics[];
|
|
152
|
+
/** Unique step counts per step. */
|
|
153
|
+
visitorsBySteps?: number[];
|
|
154
|
+
/** Metrics by date, where the key is a date string. */
|
|
155
|
+
metricsByDate?: Record<string, Partial<PlayAnalyticsMetrics>>;
|
|
156
|
+
/** Rate of how many started a guide vs viewed it. */
|
|
157
|
+
startRate?: number;
|
|
158
|
+
/** Rate of how many finished a guide vs started it. */
|
|
159
|
+
completionRate?: number;
|
|
160
|
+
/** Rate of how many restarted a guide vs finished it. */
|
|
161
|
+
restartRate?: number;
|
|
162
|
+
/** Rate of how many left at each step, not including step 1. */
|
|
163
|
+
dropoffRate?: number[];
|
|
164
|
+
/** Average dropoff rate across all steps (excluding step 1). */
|
|
165
|
+
averageDropoffRate?: number;
|
|
166
|
+
/** Rate of how many continued to the next step, not including step 1. */
|
|
167
|
+
continuationRate?: number[];
|
|
168
|
+
/** Average continuation rate across all steps (excluding step 1). */
|
|
169
|
+
averageContinuationRate?: number;
|
|
170
|
+
/** Rate of friction at each step (users moving back and forth). */
|
|
171
|
+
frictionRate?: number[];
|
|
172
|
+
/** Average friction rate across all steps. */
|
|
173
|
+
averageFrictionRate?: number;
|
|
174
|
+
/** On average, how many people from the first step are retained. */
|
|
175
|
+
averageRetention?: number;
|
|
176
|
+
/** How far through the guide (in percent) at least half the visitors get. */
|
|
177
|
+
medianProgress?: number;
|
|
178
|
+
/** Estimated number of visitors that were helped by the guide. */
|
|
179
|
+
estimatedVisitorsHelped?: number;
|
|
180
|
+
/** Estimated customer service hours saved by this guide. */
|
|
181
|
+
estimatedHoursSaved?: number;
|
|
182
|
+
/** User guide feedback. The basis for calculating the satisfaction rate. */
|
|
183
|
+
feedback?: {
|
|
184
|
+
total: number;
|
|
185
|
+
positive: number;
|
|
186
|
+
negative: number;
|
|
187
|
+
};
|
|
188
|
+
/** Rate of how many gave feedback that this guide was good vs bad. */
|
|
189
|
+
satisfactionRate?: number;
|
|
190
|
+
/** A somewhat "subjective" rating of this guide based on a weighted combination of these numbers, where 100 is the best. */
|
|
191
|
+
rating?: number;
|
|
192
|
+
};
|
|
193
|
+
type PlayAnalytics = {
|
|
194
|
+
id: Id;
|
|
195
|
+
data: PlayAnalyticsData;
|
|
196
|
+
play: ClientPlay;
|
|
197
|
+
};
|
|
198
|
+
type ClientPlayAnalytics = PlayAnalytics;
|
|
199
|
+
|
|
200
|
+
declare const playAnalyticsMetricsSchema: z.ZodType<PlayAnalyticsMetrics>;
|
|
201
|
+
declare const playAnalyticsEventMetricsSchema: z.ZodType<PlayAnalyticsEventMetrics>;
|
|
202
|
+
declare const playAnalyticsDataSchema: z.ZodType<PlayAnalyticsData>;
|
|
203
|
+
declare const playAnalyticsSchema: z.ZodType<PlayAnalytics>;
|
|
204
|
+
declare const clientPlayAnalyticsSchema: z.ZodType<ClientPlayAnalytics>;
|
|
205
|
+
|
|
206
|
+
export { type ClientPlay, type ClientPlayAnalytics, type ClientPlayFeedback, type ClientPlayStep, type ClientPlayStepTarget, type DatabasePlay, type DatabasePlayFeedback, type DatabasePlayStep, type DatabasePlayStepTarget, type Play, type PlayAnalytics, type PlayAnalyticsData, type PlayAnalyticsEventMetrics, type PlayAnalyticsMetrics, type PlayFeedback, type PlayStep, type PlayStepTarget, clientPlayAnalyticsSchema, clientPlayFeedbackSchema, clientPlaySchema, clientPlayStepSchema, clientPlayStepTargetSchema, playAnalyticsDataSchema, playAnalyticsEventMetricsSchema, playAnalyticsMetricsSchema, playAnalyticsSchema, playFeedbackSchema, playSchema, playStepSchema, playStepTargetSchema };
|
package/build/index.d.ts
ADDED
|
@@ -0,0 +1,206 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* @maxLength 50
|
|
5
|
+
*/
|
|
6
|
+
type Id = string;
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* @schema string().url().startsWith("https://")
|
|
10
|
+
*/
|
|
11
|
+
type Url = string;
|
|
12
|
+
|
|
13
|
+
type Image = {
|
|
14
|
+
url: Url;
|
|
15
|
+
/**
|
|
16
|
+
* @schema number().int().min(1).optional()
|
|
17
|
+
*/
|
|
18
|
+
width?: number;
|
|
19
|
+
/**
|
|
20
|
+
* @schema number().int().min(1).optional()
|
|
21
|
+
*/
|
|
22
|
+
height?: number;
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
/**
|
|
26
|
+
* @maxLength 450
|
|
27
|
+
*/
|
|
28
|
+
type Name = string;
|
|
29
|
+
|
|
30
|
+
type DatabasePlayStepTarget = {
|
|
31
|
+
Id: string;
|
|
32
|
+
RecipeStepId: string;
|
|
33
|
+
X: number;
|
|
34
|
+
Y: number;
|
|
35
|
+
W: number;
|
|
36
|
+
H: number;
|
|
37
|
+
};
|
|
38
|
+
type PlayStepTarget = {
|
|
39
|
+
id: Id;
|
|
40
|
+
playStepId: Id;
|
|
41
|
+
x: number;
|
|
42
|
+
y: number;
|
|
43
|
+
width: number;
|
|
44
|
+
height: number;
|
|
45
|
+
};
|
|
46
|
+
type ClientPlayStepTarget = Omit<PlayStepTarget, 'playStepId'>;
|
|
47
|
+
|
|
48
|
+
type DatabasePlayStep = {
|
|
49
|
+
Id: string;
|
|
50
|
+
RecipeId: string;
|
|
51
|
+
Order: number;
|
|
52
|
+
Description: string;
|
|
53
|
+
ImagePath: string;
|
|
54
|
+
};
|
|
55
|
+
type PlayStep = {
|
|
56
|
+
id: Id;
|
|
57
|
+
playId: Id;
|
|
58
|
+
order: number;
|
|
59
|
+
description?: Name;
|
|
60
|
+
image?: Image;
|
|
61
|
+
};
|
|
62
|
+
type ClientPlayStep = Omit<PlayStep, 'playId' | 'order'> & {
|
|
63
|
+
target?: ClientPlayStepTarget;
|
|
64
|
+
};
|
|
65
|
+
|
|
66
|
+
type DatabasePlay = {
|
|
67
|
+
Id: string;
|
|
68
|
+
CreatedDate: Date;
|
|
69
|
+
CustomerId: string;
|
|
70
|
+
Locale: string;
|
|
71
|
+
Status?: 'Published' | 'Listed' | 'Private';
|
|
72
|
+
Title: string;
|
|
73
|
+
Slug: string;
|
|
74
|
+
Description: string;
|
|
75
|
+
ImagePath: string;
|
|
76
|
+
IsDeleted: boolean;
|
|
77
|
+
};
|
|
78
|
+
type Play = {
|
|
79
|
+
id: Id;
|
|
80
|
+
organizationId: Id;
|
|
81
|
+
locale: string;
|
|
82
|
+
title?: Name;
|
|
83
|
+
slug: Name;
|
|
84
|
+
description?: Name;
|
|
85
|
+
image?: Image;
|
|
86
|
+
creationDate: Date;
|
|
87
|
+
};
|
|
88
|
+
type ClientPlay = Omit<Play, 'organizationId'> & {
|
|
89
|
+
urls: {
|
|
90
|
+
page: string;
|
|
91
|
+
embed: string;
|
|
92
|
+
};
|
|
93
|
+
stepsCount: number;
|
|
94
|
+
steps?: ClientPlayStep[];
|
|
95
|
+
};
|
|
96
|
+
|
|
97
|
+
declare const playSchema: z.ZodType<Play>;
|
|
98
|
+
declare const clientPlaySchema: z.ZodType<ClientPlay>;
|
|
99
|
+
|
|
100
|
+
declare const playStepSchema: z.ZodType<PlayStep>;
|
|
101
|
+
declare const clientPlayStepSchema: z.ZodType<ClientPlayStep>;
|
|
102
|
+
|
|
103
|
+
declare const playStepTargetSchema: z.ZodType<PlayStepTarget>;
|
|
104
|
+
declare const clientPlayStepTargetSchema: z.ZodType<ClientPlayStepTarget>;
|
|
105
|
+
|
|
106
|
+
type DatabasePlayFeedback = {
|
|
107
|
+
Id: string;
|
|
108
|
+
RecipeId: string;
|
|
109
|
+
Positive: boolean;
|
|
110
|
+
Comment?: string;
|
|
111
|
+
VoteDate: Date;
|
|
112
|
+
};
|
|
113
|
+
type PlayFeedback = {
|
|
114
|
+
id: Id;
|
|
115
|
+
playId: Id;
|
|
116
|
+
value: boolean;
|
|
117
|
+
content?: string;
|
|
118
|
+
creationDate: Date;
|
|
119
|
+
};
|
|
120
|
+
type ClientPlayFeedback = Omit<PlayFeedback, 'playId'>;
|
|
121
|
+
|
|
122
|
+
declare const playFeedbackSchema: z.ZodType<PlayFeedback>;
|
|
123
|
+
declare const clientPlayFeedbackSchema: z.ZodType<ClientPlayFeedback>;
|
|
124
|
+
|
|
125
|
+
type PlayAnalyticsMetrics = {
|
|
126
|
+
/** Plausible unique visitors */
|
|
127
|
+
visitors: number;
|
|
128
|
+
/** Plausible pageview events */
|
|
129
|
+
pageviews: number;
|
|
130
|
+
};
|
|
131
|
+
type PlayAnalyticsEventMetrics = {
|
|
132
|
+
/** Plausible total event count */
|
|
133
|
+
total: number;
|
|
134
|
+
/** Plausible unique visitors */
|
|
135
|
+
visitors: number;
|
|
136
|
+
};
|
|
137
|
+
type PlayAnalyticsData = {
|
|
138
|
+
/** Plausible unique visitors */
|
|
139
|
+
visitors?: number;
|
|
140
|
+
/** Plausible pageview events */
|
|
141
|
+
pageviews?: number;
|
|
142
|
+
/** Event count of guide starts. */
|
|
143
|
+
started?: PlayAnalyticsEventMetrics;
|
|
144
|
+
/** Event count of guide finishes. */
|
|
145
|
+
finished?: PlayAnalyticsEventMetrics;
|
|
146
|
+
/** Event count of guide restarts. */
|
|
147
|
+
restarted?: PlayAnalyticsEventMetrics;
|
|
148
|
+
/** Event count of guides printed. */
|
|
149
|
+
printed?: PlayAnalyticsEventMetrics;
|
|
150
|
+
/** Step event counts and uniques per step. */
|
|
151
|
+
steps: PlayAnalyticsEventMetrics[];
|
|
152
|
+
/** Unique step counts per step. */
|
|
153
|
+
visitorsBySteps?: number[];
|
|
154
|
+
/** Metrics by date, where the key is a date string. */
|
|
155
|
+
metricsByDate?: Record<string, Partial<PlayAnalyticsMetrics>>;
|
|
156
|
+
/** Rate of how many started a guide vs viewed it. */
|
|
157
|
+
startRate?: number;
|
|
158
|
+
/** Rate of how many finished a guide vs started it. */
|
|
159
|
+
completionRate?: number;
|
|
160
|
+
/** Rate of how many restarted a guide vs finished it. */
|
|
161
|
+
restartRate?: number;
|
|
162
|
+
/** Rate of how many left at each step, not including step 1. */
|
|
163
|
+
dropoffRate?: number[];
|
|
164
|
+
/** Average dropoff rate across all steps (excluding step 1). */
|
|
165
|
+
averageDropoffRate?: number;
|
|
166
|
+
/** Rate of how many continued to the next step, not including step 1. */
|
|
167
|
+
continuationRate?: number[];
|
|
168
|
+
/** Average continuation rate across all steps (excluding step 1). */
|
|
169
|
+
averageContinuationRate?: number;
|
|
170
|
+
/** Rate of friction at each step (users moving back and forth). */
|
|
171
|
+
frictionRate?: number[];
|
|
172
|
+
/** Average friction rate across all steps. */
|
|
173
|
+
averageFrictionRate?: number;
|
|
174
|
+
/** On average, how many people from the first step are retained. */
|
|
175
|
+
averageRetention?: number;
|
|
176
|
+
/** How far through the guide (in percent) at least half the visitors get. */
|
|
177
|
+
medianProgress?: number;
|
|
178
|
+
/** Estimated number of visitors that were helped by the guide. */
|
|
179
|
+
estimatedVisitorsHelped?: number;
|
|
180
|
+
/** Estimated customer service hours saved by this guide. */
|
|
181
|
+
estimatedHoursSaved?: number;
|
|
182
|
+
/** User guide feedback. The basis for calculating the satisfaction rate. */
|
|
183
|
+
feedback?: {
|
|
184
|
+
total: number;
|
|
185
|
+
positive: number;
|
|
186
|
+
negative: number;
|
|
187
|
+
};
|
|
188
|
+
/** Rate of how many gave feedback that this guide was good vs bad. */
|
|
189
|
+
satisfactionRate?: number;
|
|
190
|
+
/** A somewhat "subjective" rating of this guide based on a weighted combination of these numbers, where 100 is the best. */
|
|
191
|
+
rating?: number;
|
|
192
|
+
};
|
|
193
|
+
type PlayAnalytics = {
|
|
194
|
+
id: Id;
|
|
195
|
+
data: PlayAnalyticsData;
|
|
196
|
+
play: ClientPlay;
|
|
197
|
+
};
|
|
198
|
+
type ClientPlayAnalytics = PlayAnalytics;
|
|
199
|
+
|
|
200
|
+
declare const playAnalyticsMetricsSchema: z.ZodType<PlayAnalyticsMetrics>;
|
|
201
|
+
declare const playAnalyticsEventMetricsSchema: z.ZodType<PlayAnalyticsEventMetrics>;
|
|
202
|
+
declare const playAnalyticsDataSchema: z.ZodType<PlayAnalyticsData>;
|
|
203
|
+
declare const playAnalyticsSchema: z.ZodType<PlayAnalytics>;
|
|
204
|
+
declare const clientPlayAnalyticsSchema: z.ZodType<ClientPlayAnalytics>;
|
|
205
|
+
|
|
206
|
+
export { type ClientPlay, type ClientPlayAnalytics, type ClientPlayFeedback, type ClientPlayStep, type ClientPlayStepTarget, type DatabasePlay, type DatabasePlayFeedback, type DatabasePlayStep, type DatabasePlayStepTarget, type Play, type PlayAnalytics, type PlayAnalyticsData, type PlayAnalyticsEventMetrics, type PlayAnalyticsMetrics, type PlayFeedback, type PlayStep, type PlayStepTarget, clientPlayAnalyticsSchema, clientPlayFeedbackSchema, clientPlaySchema, clientPlayStepSchema, clientPlayStepTargetSchema, playAnalyticsDataSchema, playAnalyticsEventMetricsSchema, playAnalyticsMetricsSchema, playAnalyticsSchema, playFeedbackSchema, playSchema, playStepSchema, playStepTargetSchema };
|
package/build/index.js
ADDED
|
@@ -0,0 +1,154 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var zod = require('zod');
|
|
4
|
+
|
|
5
|
+
// types/play.zod.ts
|
|
6
|
+
var idSchema = zod.z.string().max(50);
|
|
7
|
+
var urlSchema = zod.z.string().url().startsWith("https://");
|
|
8
|
+
|
|
9
|
+
// ../../primitives/image.zod.ts
|
|
10
|
+
var imageSchema = zod.z.object({
|
|
11
|
+
url: urlSchema,
|
|
12
|
+
width: zod.z.number().int().min(1).optional(),
|
|
13
|
+
height: zod.z.number().int().min(1).optional()
|
|
14
|
+
});
|
|
15
|
+
var nameSchema = zod.z.string().max(450);
|
|
16
|
+
var playStepTargetSchema = zod.z.object({
|
|
17
|
+
id: idSchema,
|
|
18
|
+
playStepId: idSchema,
|
|
19
|
+
x: zod.z.number(),
|
|
20
|
+
y: zod.z.number(),
|
|
21
|
+
width: zod.z.number(),
|
|
22
|
+
height: zod.z.number()
|
|
23
|
+
});
|
|
24
|
+
var clientPlayStepTargetSchema = playStepTargetSchema.omit({
|
|
25
|
+
playStepId: true
|
|
26
|
+
});
|
|
27
|
+
|
|
28
|
+
// types/play-step.zod.ts
|
|
29
|
+
var playStepSchema = zod.z.object({
|
|
30
|
+
id: idSchema,
|
|
31
|
+
playId: idSchema,
|
|
32
|
+
order: zod.z.number(),
|
|
33
|
+
description: nameSchema.optional(),
|
|
34
|
+
image: imageSchema.optional()
|
|
35
|
+
});
|
|
36
|
+
var clientPlayStepSchema = playStepSchema.omit({ playId: true, order: true }).and(
|
|
37
|
+
zod.z.object({
|
|
38
|
+
target: clientPlayStepTargetSchema.optional()
|
|
39
|
+
})
|
|
40
|
+
);
|
|
41
|
+
|
|
42
|
+
// types/play.zod.ts
|
|
43
|
+
var playSchema = zod.z.object({
|
|
44
|
+
id: idSchema,
|
|
45
|
+
organizationId: idSchema,
|
|
46
|
+
locale: zod.z.string(),
|
|
47
|
+
title: nameSchema.optional(),
|
|
48
|
+
slug: nameSchema,
|
|
49
|
+
description: nameSchema.optional(),
|
|
50
|
+
image: imageSchema.optional(),
|
|
51
|
+
creationDate: zod.z.date()
|
|
52
|
+
});
|
|
53
|
+
var clientPlaySchema = playSchema.omit({ organizationId: true }).and(
|
|
54
|
+
zod.z.object({
|
|
55
|
+
urls: zod.z.object({
|
|
56
|
+
page: zod.z.string(),
|
|
57
|
+
embed: zod.z.string()
|
|
58
|
+
}),
|
|
59
|
+
stepsCount: zod.z.number(),
|
|
60
|
+
steps: zod.z.array(clientPlayStepSchema).optional()
|
|
61
|
+
})
|
|
62
|
+
);
|
|
63
|
+
|
|
64
|
+
// types/play.schemas.ts
|
|
65
|
+
var playSchema2 = playSchema;
|
|
66
|
+
var clientPlaySchema2 = clientPlaySchema;
|
|
67
|
+
|
|
68
|
+
// types/play-step.schemas.ts
|
|
69
|
+
var playStepSchema2 = playStepSchema;
|
|
70
|
+
var clientPlayStepSchema2 = clientPlayStepSchema;
|
|
71
|
+
|
|
72
|
+
// types/play-step-target.schemas.ts
|
|
73
|
+
var playStepTargetSchema2 = playStepTargetSchema;
|
|
74
|
+
var clientPlayStepTargetSchema2 = clientPlayStepTargetSchema;
|
|
75
|
+
var playFeedbackSchema = zod.z.object({
|
|
76
|
+
id: idSchema,
|
|
77
|
+
playId: idSchema,
|
|
78
|
+
value: zod.z.boolean(),
|
|
79
|
+
content: zod.z.string().optional(),
|
|
80
|
+
creationDate: zod.z.date()
|
|
81
|
+
});
|
|
82
|
+
var clientPlayFeedbackSchema = playFeedbackSchema.omit({ playId: true });
|
|
83
|
+
|
|
84
|
+
// types/play-feedback.schemas.ts
|
|
85
|
+
var playFeedbackSchema2 = playFeedbackSchema;
|
|
86
|
+
var clientPlayFeedbackSchema2 = clientPlayFeedbackSchema;
|
|
87
|
+
var playAnalyticsMetricsSchema = zod.z.object({
|
|
88
|
+
visitors: zod.z.number(),
|
|
89
|
+
pageviews: zod.z.number()
|
|
90
|
+
});
|
|
91
|
+
var playAnalyticsEventMetricsSchema = zod.z.object({
|
|
92
|
+
total: zod.z.number(),
|
|
93
|
+
visitors: zod.z.number()
|
|
94
|
+
});
|
|
95
|
+
var playAnalyticsDataSchema = zod.z.object({
|
|
96
|
+
visitors: zod.z.number().optional(),
|
|
97
|
+
pageviews: zod.z.number().optional(),
|
|
98
|
+
started: playAnalyticsEventMetricsSchema.optional(),
|
|
99
|
+
finished: playAnalyticsEventMetricsSchema.optional(),
|
|
100
|
+
restarted: playAnalyticsEventMetricsSchema.optional(),
|
|
101
|
+
printed: playAnalyticsEventMetricsSchema.optional(),
|
|
102
|
+
steps: zod.z.array(playAnalyticsEventMetricsSchema),
|
|
103
|
+
visitorsBySteps: zod.z.array(zod.z.number()).optional(),
|
|
104
|
+
metricsByDate: zod.z.record(zod.z.string(), playAnalyticsMetricsSchema.partial()).optional(),
|
|
105
|
+
startRate: zod.z.number().optional(),
|
|
106
|
+
completionRate: zod.z.number().optional(),
|
|
107
|
+
restartRate: zod.z.number().optional(),
|
|
108
|
+
dropoffRate: zod.z.array(zod.z.number()).optional(),
|
|
109
|
+
averageDropoffRate: zod.z.number().optional(),
|
|
110
|
+
continuationRate: zod.z.array(zod.z.number()).optional(),
|
|
111
|
+
averageContinuationRate: zod.z.number().optional(),
|
|
112
|
+
frictionRate: zod.z.array(zod.z.number()).optional(),
|
|
113
|
+
averageFrictionRate: zod.z.number().optional(),
|
|
114
|
+
averageRetention: zod.z.number().optional(),
|
|
115
|
+
medianProgress: zod.z.number().optional(),
|
|
116
|
+
estimatedVisitorsHelped: zod.z.number().optional(),
|
|
117
|
+
estimatedHoursSaved: zod.z.number().optional(),
|
|
118
|
+
feedback: zod.z.object({
|
|
119
|
+
total: zod.z.number(),
|
|
120
|
+
positive: zod.z.number(),
|
|
121
|
+
negative: zod.z.number()
|
|
122
|
+
}).optional(),
|
|
123
|
+
satisfactionRate: zod.z.number().optional(),
|
|
124
|
+
rating: zod.z.number().optional()
|
|
125
|
+
});
|
|
126
|
+
var playAnalyticsSchema = zod.z.object({
|
|
127
|
+
id: idSchema,
|
|
128
|
+
data: playAnalyticsDataSchema,
|
|
129
|
+
play: clientPlaySchema
|
|
130
|
+
});
|
|
131
|
+
var clientPlayAnalyticsSchema = playAnalyticsSchema;
|
|
132
|
+
|
|
133
|
+
// types/play-analytics.schemas.ts
|
|
134
|
+
var playAnalyticsMetricsSchema2 = playAnalyticsMetricsSchema;
|
|
135
|
+
var playAnalyticsEventMetricsSchema2 = playAnalyticsEventMetricsSchema;
|
|
136
|
+
var playAnalyticsDataSchema2 = playAnalyticsDataSchema;
|
|
137
|
+
var playAnalyticsSchema2 = playAnalyticsSchema;
|
|
138
|
+
var clientPlayAnalyticsSchema2 = clientPlayAnalyticsSchema;
|
|
139
|
+
|
|
140
|
+
exports.clientPlayAnalyticsSchema = clientPlayAnalyticsSchema2;
|
|
141
|
+
exports.clientPlayFeedbackSchema = clientPlayFeedbackSchema2;
|
|
142
|
+
exports.clientPlaySchema = clientPlaySchema2;
|
|
143
|
+
exports.clientPlayStepSchema = clientPlayStepSchema2;
|
|
144
|
+
exports.clientPlayStepTargetSchema = clientPlayStepTargetSchema2;
|
|
145
|
+
exports.playAnalyticsDataSchema = playAnalyticsDataSchema2;
|
|
146
|
+
exports.playAnalyticsEventMetricsSchema = playAnalyticsEventMetricsSchema2;
|
|
147
|
+
exports.playAnalyticsMetricsSchema = playAnalyticsMetricsSchema2;
|
|
148
|
+
exports.playAnalyticsSchema = playAnalyticsSchema2;
|
|
149
|
+
exports.playFeedbackSchema = playFeedbackSchema2;
|
|
150
|
+
exports.playSchema = playSchema2;
|
|
151
|
+
exports.playStepSchema = playStepSchema2;
|
|
152
|
+
exports.playStepTargetSchema = playStepTargetSchema2;
|
|
153
|
+
//# sourceMappingURL=index.js.map
|
|
154
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../primitives/id.zod.ts","../../../primitives/url.zod.ts","../../../primitives/image.zod.ts","../../../primitives/name.zod.ts","../types/play-step-target.zod.ts","../types/play-step.zod.ts","../types/play.zod.ts","../types/play.schemas.ts","../types/play-step.schemas.ts","../types/play-step-target.schemas.ts","../types/play-feedback.zod.ts","../types/play-feedback.schemas.ts","../types/play-analytics.zod.ts","../types/play-analytics.schemas.ts"],"names":["z","playSchema","clientPlaySchema","playStepSchema","clientPlayStepSchema","playStepTargetSchema","clientPlayStepTargetSchema","playFeedbackSchema","clientPlayFeedbackSchema","playAnalyticsMetricsSchema","playAnalyticsEventMetricsSchema","playAnalyticsDataSchema","playAnalyticsSchema","clientPlayAnalyticsSchema"],"mappings":";;;;;AAGO,IAAM,QAAA,GAAWA,KAAA,CAAE,MAAA,EAAO,CAAE,IAAI,EAAE,CAAA;ACAlC,IAAM,YAAYA,KAAAA,CAAE,MAAA,GAAS,GA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AAAA,EACN,IAAA,EAAM;AACR,CAAC,CAAA;AAEM,IAAM,yBAAA,GAA4B,mBAAA;;;ACzClC,IAAMS,2BAAAA,GACX;AACK,IAAMC,gCAAAA,GACX;AACK,IAAMC,wBAAAA,GACX;AACK,IAAMC,oBAAAA,GACX;AACK,IAAMC,0BAAAA,GACX","file":"index.js","sourcesContent":["// Generated by ts-to-zod\nimport {z} from 'zod';\n\nexport const idSchema = z.string().max(50);\n","// Generated by ts-to-zod\nimport {z} from 'zod';\n\nexport const urlSchema = z.string().url().startsWith('https://');\n","// Generated by ts-to-zod\nimport {z} from 'zod';\n\nimport {urlSchema} from './url.zod';\n\nexport const imageSchema = z.object({\n url: urlSchema,\n width: z.number().int().min(1).optional(),\n height: z.number().int().min(1).optional(),\n});\n","// Generated by ts-to-zod\nimport {z} from 'zod';\n\nexport const nameSchema = z.string().max(450);\n","// Generated by ts-to-zod\nimport {z} from 'zod';\n\nimport {idSchema} from './../../../primitives/id.zod';\n\nexport const playStepTargetSchema = z.object({\n id: idSchema,\n playStepId: idSchema,\n x: z.number(),\n y: z.number(),\n width: z.number(),\n height: z.number(),\n});\n\nexport const clientPlayStepTargetSchema = playStepTargetSchema.omit({\n playStepId: true,\n});\n","// Generated by ts-to-zod\nimport {z} from 'zod';\n\nimport {idSchema} from './../../../primitives/id.zod';\nimport {nameSchema} from './../../../primitives/name.zod';\nimport {imageSchema} from './../../../primitives/image.zod';\nimport {clientPlayStepTargetSchema} from './play-step-target.zod';\n\nexport const playStepSchema = z.object({\n id: idSchema,\n playId: idSchema,\n order: z.number(),\n description: nameSchema.optional(),\n image: imageSchema.optional(),\n});\n\nexport const clientPlayStepSchema = playStepSchema\n .omit({playId: true, order: true})\n .and(\n z.object({\n target: clientPlayStepTargetSchema.optional(),\n })\n );\n","// Generated by ts-to-zod\nimport {z} from 'zod';\n\nimport {idSchema} from './../../../primitives/id.zod';\nimport {imageSchema} from './../../../primitives/image.zod';\nimport {nameSchema} from './../../../primitives/name.zod';\nimport {clientPlayStepSchema} from './play-step.zod';\n\nexport const playSchema = z.object({\n id: idSchema,\n organizationId: idSchema,\n locale: z.string(),\n title: nameSchema.optional(),\n slug: nameSchema,\n description: nameSchema.optional(),\n image: imageSchema.optional(),\n creationDate: z.date(),\n});\n\nexport const clientPlaySchema = playSchema.omit({organizationId: true}).and(\n z.object({\n urls: z.object({\n page: z.string(),\n embed: z.string(),\n }),\n stepsCount: z.number(),\n steps: z.array(clientPlayStepSchema).optional(),\n })\n);\n","// Generated by generate-typed-schemas.mjs\nimport {type z} from 'zod';\nimport {type Play, type ClientPlay} from './play';\nimport {\n playSchema as playSchema_,\n clientPlaySchema as clientPlaySchema_,\n} from './play.zod';\n\nexport const playSchema: z.ZodType<Play> = playSchema_;\nexport const clientPlaySchema: z.ZodType<ClientPlay> = clientPlaySchema_;\n","// Generated by generate-typed-schemas.mjs\nimport {type z} from 'zod';\nimport {type PlayStep, type ClientPlayStep} from './play-step';\nimport {\n playStepSchema as playStepSchema_,\n clientPlayStepSchema as clientPlayStepSchema_,\n} from './play-step.zod';\n\nexport const playStepSchema: z.ZodType<PlayStep> = playStepSchema_;\nexport const clientPlayStepSchema: z.ZodType<ClientPlayStep> =\n clientPlayStepSchema_;\n","// Generated by generate-typed-schemas.mjs\nimport {type z} from 'zod';\nimport {\n type PlayStepTarget,\n type ClientPlayStepTarget,\n} from './play-step-target';\nimport {\n playStepTargetSchema as playStepTargetSchema_,\n clientPlayStepTargetSchema as clientPlayStepTargetSchema_,\n} from './play-step-target.zod';\n\nexport const playStepTargetSchema: z.ZodType<PlayStepTarget> =\n playStepTargetSchema_;\nexport const clientPlayStepTargetSchema: z.ZodType<ClientPlayStepTarget> =\n clientPlayStepTargetSchema_;\n","// Generated by ts-to-zod\nimport {z} from 'zod';\n\nimport {idSchema} from './../../../primitives/id.zod';\n\nexport const playFeedbackSchema = z.object({\n id: idSchema,\n playId: idSchema,\n value: z.boolean(),\n content: z.string().optional(),\n creationDate: z.date(),\n});\n\nexport const clientPlayFeedbackSchema = playFeedbackSchema.omit({playId: true});\n","// Generated by generate-typed-schemas.mjs\nimport {type z} from 'zod';\nimport {type PlayFeedback, type ClientPlayFeedback} from './play-feedback';\nimport {\n playFeedbackSchema as playFeedbackSchema_,\n clientPlayFeedbackSchema as clientPlayFeedbackSchema_,\n} from './play-feedback.zod';\n\nexport const playFeedbackSchema: z.ZodType<PlayFeedback> = playFeedbackSchema_;\nexport const clientPlayFeedbackSchema: z.ZodType<ClientPlayFeedback> =\n clientPlayFeedbackSchema_;\n","// Generated by ts-to-zod\nimport {z} from 'zod';\n\nimport {idSchema} from './../../../primitives/id.zod';\nimport {clientPlaySchema} from './play.zod';\n\nexport const playAnalyticsMetricsSchema = z.object({\n visitors: z.number(),\n pageviews: z.number(),\n});\n\nexport const playAnalyticsEventMetricsSchema = z.object({\n total: z.number(),\n visitors: z.number(),\n});\n\nexport const playAnalyticsDataSchema = z.object({\n visitors: z.number().optional(),\n pageviews: z.number().optional(),\n started: playAnalyticsEventMetricsSchema.optional(),\n finished: playAnalyticsEventMetricsSchema.optional(),\n restarted: playAnalyticsEventMetricsSchema.optional(),\n printed: playAnalyticsEventMetricsSchema.optional(),\n steps: z.array(playAnalyticsEventMetricsSchema),\n visitorsBySteps: z.array(z.number()).optional(),\n metricsByDate: z\n .record(z.string(), playAnalyticsMetricsSchema.partial())\n .optional(),\n startRate: z.number().optional(),\n completionRate: z.number().optional(),\n restartRate: z.number().optional(),\n dropoffRate: z.array(z.number()).optional(),\n averageDropoffRate: z.number().optional(),\n continuationRate: z.array(z.number()).optional(),\n averageContinuationRate: z.number().optional(),\n frictionRate: z.array(z.number()).optional(),\n averageFrictionRate: z.number().optional(),\n averageRetention: z.number().optional(),\n medianProgress: z.number().optional(),\n estimatedVisitorsHelped: z.number().optional(),\n estimatedHoursSaved: z.number().optional(),\n feedback: z\n .object({\n total: z.number(),\n positive: z.number(),\n negative: z.number(),\n })\n .optional(),\n satisfactionRate: z.number().optional(),\n rating: z.number().optional(),\n});\n\nexport const playAnalyticsSchema = z.object({\n id: idSchema,\n data: playAnalyticsDataSchema,\n play: clientPlaySchema,\n});\n\nexport const clientPlayAnalyticsSchema = playAnalyticsSchema;\n","// Generated by generate-typed-schemas.mjs\nimport {type z} from 'zod';\nimport {\n type PlayAnalyticsMetrics,\n type PlayAnalyticsEventMetrics,\n type PlayAnalyticsData,\n type PlayAnalytics,\n type ClientPlayAnalytics,\n} from './play-analytics';\nimport {\n playAnalyticsMetricsSchema as playAnalyticsMetricsSchema_,\n playAnalyticsEventMetricsSchema as playAnalyticsEventMetricsSchema_,\n playAnalyticsDataSchema as playAnalyticsDataSchema_,\n playAnalyticsSchema as playAnalyticsSchema_,\n clientPlayAnalyticsSchema as clientPlayAnalyticsSchema_,\n} from './play-analytics.zod';\n\nexport const playAnalyticsMetricsSchema: z.ZodType<PlayAnalyticsMetrics> =\n playAnalyticsMetricsSchema_;\nexport const playAnalyticsEventMetricsSchema: z.ZodType<PlayAnalyticsEventMetrics> =\n playAnalyticsEventMetricsSchema_;\nexport const playAnalyticsDataSchema: z.ZodType<PlayAnalyticsData> =\n playAnalyticsDataSchema_;\nexport const playAnalyticsSchema: z.ZodType<PlayAnalytics> =\n playAnalyticsSchema_;\nexport const clientPlayAnalyticsSchema: z.ZodType<ClientPlayAnalytics> =\n clientPlayAnalyticsSchema_;\n"]}
|