@ydtb/tk-scope-capture 0.22.0 → 0.23.6
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/src/client/components/CaptureFormSurface.d.ts +58 -0
- package/dist/src/client/components/CaptureFormSurface.d.ts.map +1 -0
- package/dist/src/client/components/CaptureFormSurface.js +301 -0
- package/dist/src/client/components/CaptureFormSurface.js.map +1 -0
- package/dist/src/client/components/CaptureSidebar.d.ts +43 -0
- package/dist/src/client/components/CaptureSidebar.d.ts.map +1 -0
- package/dist/src/client/components/CaptureSidebar.js +38 -0
- package/dist/src/client/components/CaptureSidebar.js.map +1 -0
- package/dist/src/client/pages/CaptureBuilderPage.d.ts.map +1 -1
- package/dist/src/client/pages/CaptureBuilderPage.js +1869 -129
- package/dist/src/client/pages/CaptureBuilderPage.js.map +1 -1
- package/dist/src/client/pages/CaptureSubmissionDetailPage.d.ts.map +1 -1
- package/dist/src/client/pages/CaptureSubmissionDetailPage.js +61 -10
- package/dist/src/client/pages/CaptureSubmissionDetailPage.js.map +1 -1
- package/dist/src/client/pages/CaptureSubmissionsPage.d.ts.map +1 -1
- package/dist/src/client/pages/CaptureSubmissionsPage.js +14 -2
- package/dist/src/client/pages/CaptureSubmissionsPage.js.map +1 -1
- package/dist/src/client/pages/PublicFormPage.d.ts.map +1 -1
- package/dist/src/client/pages/PublicFormPage.js +13 -56
- package/dist/src/client/pages/PublicFormPage.js.map +1 -1
- package/dist/src/client/pages/PublicQuizPage.d.ts.map +1 -1
- package/dist/src/client/pages/PublicQuizPage.js +23 -11
- package/dist/src/client/pages/PublicQuizPage.js.map +1 -1
- package/dist/src/client/pages/QuizBuilderPage.d.ts.map +1 -1
- package/dist/src/client/pages/QuizBuilderPage.js +6 -2
- package/dist/src/client/pages/QuizBuilderPage.js.map +1 -1
- package/dist/src/client.d.ts +858 -15
- package/dist/src/client.d.ts.map +1 -1
- package/dist/src/client.js +2 -0
- package/dist/src/client.js.map +1 -1
- package/dist/src/index.d.ts +2 -0
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js +1 -0
- package/dist/src/index.js.map +1 -1
- package/dist/src/server/api/action-adapters.d.ts +2 -0
- package/dist/src/server/api/action-adapters.d.ts.map +1 -1
- package/dist/src/server/api/action-adapters.js +1 -0
- package/dist/src/server/api/action-adapters.js.map +1 -1
- package/dist/src/server/api/router.d.ts +884 -16
- package/dist/src/server/api/router.d.ts.map +1 -1
- package/dist/src/server/api/router.js +547 -22
- package/dist/src/server/api/router.js.map +1 -1
- package/dist/src/server.d.ts.map +1 -1
- package/dist/src/server.js +51 -1
- package/dist/src/server.js.map +1 -1
- package/dist/src/shared/conditions.d.ts +2 -2
- package/dist/src/shared/conditions.d.ts.map +1 -1
- package/dist/src/shared/conditions.js +47 -0
- package/dist/src/shared/conditions.js.map +1 -1
- package/dist/src/shared/db/schema.d.ts +414 -0
- package/dist/src/shared/db/schema.d.ts.map +1 -1
- package/dist/src/shared/db/schema.js +40 -0
- package/dist/src/shared/db/schema.js.map +1 -1
- package/dist/src/shared/document.d.ts +120 -0
- package/dist/src/shared/document.d.ts.map +1 -0
- package/dist/src/shared/document.js +111 -0
- package/dist/src/shared/document.js.map +1 -0
- package/dist/src/shared/field-types.d.ts +2 -0
- package/dist/src/shared/field-types.d.ts.map +1 -1
- package/dist/src/shared/field-types.js +43 -10
- package/dist/src/shared/field-types.js.map +1 -1
- package/dist/src/shared/types.d.ts +90 -3
- package/dist/src/shared/types.d.ts.map +1 -1
- package/dist/src/shared/types.js.map +1 -1
- package/dist/src/shared/validation.d.ts +6 -0
- package/dist/src/shared/validation.d.ts.map +1 -0
- package/dist/src/shared/validation.js +87 -0
- package/dist/src/shared/validation.js.map +1 -0
- package/package.json +11 -7
|
@@ -1,7 +1,32 @@
|
|
|
1
1
|
import "@ydtb/core-layer-postgres";
|
|
2
2
|
import { z } from "zod";
|
|
3
|
+
import { type CaptureFormDocument } from "../../shared/document.ts";
|
|
3
4
|
import { evaluateQuizOutcome } from "../../shared/scoring.ts";
|
|
4
|
-
import type { CaptureActionConfig, CaptureActionRunResult, CaptureDefinitionSummary, CapturePublicationSecurity, CaptureSubmissionDetail, CaptureSubmissionSummary, CaptureWorkflowDefinitionOption } from "../../shared/types.ts";
|
|
5
|
+
import type { CaptureActionConfig, CaptureActionRunResult, CaptureDefinitionSummary, CaptureContactCustomFieldOption, CapturePublicationSecurity, CaptureSubmissionDetail, CaptureSubmissionSummary, CaptureValidationExpression, CaptureWorkflowDefinitionOption } from "../../shared/types.ts";
|
|
6
|
+
declare const filterConditionSchema: z.ZodObject<{
|
|
7
|
+
id: z.ZodString;
|
|
8
|
+
fieldKey: z.ZodString;
|
|
9
|
+
operator: z.ZodEnum<{
|
|
10
|
+
is: "is";
|
|
11
|
+
is_not: "is_not";
|
|
12
|
+
contains: "contains";
|
|
13
|
+
does_not_contain: "does_not_contain";
|
|
14
|
+
starts_with: "starts_with";
|
|
15
|
+
ends_with: "ends_with";
|
|
16
|
+
is_empty: "is_empty";
|
|
17
|
+
is_not_empty: "is_not_empty";
|
|
18
|
+
greater_than: "greater_than";
|
|
19
|
+
less_than: "less_than";
|
|
20
|
+
greater_than_or_equal: "greater_than_or_equal";
|
|
21
|
+
less_than_or_equal: "less_than_or_equal";
|
|
22
|
+
}>;
|
|
23
|
+
value: z.ZodOptional<z.ZodString>;
|
|
24
|
+
}, z.core.$strip>;
|
|
25
|
+
export type FilterGroupInput = {
|
|
26
|
+
id: string;
|
|
27
|
+
logic: "and" | "or";
|
|
28
|
+
conditions: Array<z.infer<typeof filterConditionSchema> | FilterGroupInput>;
|
|
29
|
+
};
|
|
5
30
|
declare const captureRouter: {
|
|
6
31
|
definitions: {
|
|
7
32
|
list: import("@orpc/server").DecoratedProcedure<import("@orpc/server").MergedInitialContext<import("@orpc/server").MergedInitialContext<{
|
|
@@ -33,6 +58,229 @@ declare const captureRouter: {
|
|
|
33
58
|
scopeType: string;
|
|
34
59
|
scopeChain: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
35
60
|
}>, import("@orpc/server").Schema<unknown, unknown>, import("@orpc/server").Schema<CaptureDefinitionSummary[], CaptureDefinitionSummary[]>, Record<never, never>, Record<never, never>>;
|
|
61
|
+
views: {
|
|
62
|
+
list: import("@orpc/server").DecoratedProcedure<import("@orpc/server").MergedInitialContext<import("@orpc/server").MergedInitialContext<{
|
|
63
|
+
headers: Headers;
|
|
64
|
+
} & Record<never, never>, {
|
|
65
|
+
headers: Headers;
|
|
66
|
+
} & Record<never, never>, {
|
|
67
|
+
headers: Headers;
|
|
68
|
+
}>, {
|
|
69
|
+
headers: Headers;
|
|
70
|
+
user: {
|
|
71
|
+
id: string;
|
|
72
|
+
};
|
|
73
|
+
scopeChain?: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
74
|
+
} & Record<never, never>, import("@orpc/server").MergedCurrentContext<{
|
|
75
|
+
headers: Headers;
|
|
76
|
+
}, {
|
|
77
|
+
headers: Headers;
|
|
78
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
79
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
80
|
+
}>>, import("@orpc/server").MergedCurrentContext<import("@orpc/server").MergedCurrentContext<{
|
|
81
|
+
headers: Headers;
|
|
82
|
+
}, {
|
|
83
|
+
headers: Headers;
|
|
84
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
85
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
86
|
+
}>, {
|
|
87
|
+
scopeId: string;
|
|
88
|
+
scopeType: string;
|
|
89
|
+
scopeChain: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
90
|
+
}>, import("@orpc/server").Schema<unknown, unknown>, import("@orpc/server").Schema<{
|
|
91
|
+
name: string;
|
|
92
|
+
icon: string;
|
|
93
|
+
filters: unknown;
|
|
94
|
+
sorts: unknown;
|
|
95
|
+
columns: unknown;
|
|
96
|
+
createdAt: Date;
|
|
97
|
+
updatedAt: Date;
|
|
98
|
+
scope: string;
|
|
99
|
+
scopeId: string;
|
|
100
|
+
id: string;
|
|
101
|
+
}[], {
|
|
102
|
+
name: string;
|
|
103
|
+
icon: string;
|
|
104
|
+
filters: unknown;
|
|
105
|
+
sorts: unknown;
|
|
106
|
+
columns: unknown;
|
|
107
|
+
createdAt: Date;
|
|
108
|
+
updatedAt: Date;
|
|
109
|
+
scope: string;
|
|
110
|
+
scopeId: string;
|
|
111
|
+
id: string;
|
|
112
|
+
}[]>, Record<never, never>, Record<never, never>>;
|
|
113
|
+
create: import("@orpc/server").DecoratedProcedure<import("@orpc/server").MergedInitialContext<import("@orpc/server").MergedInitialContext<{
|
|
114
|
+
headers: Headers;
|
|
115
|
+
} & Record<never, never>, {
|
|
116
|
+
headers: Headers;
|
|
117
|
+
} & Record<never, never>, {
|
|
118
|
+
headers: Headers;
|
|
119
|
+
}>, {
|
|
120
|
+
headers: Headers;
|
|
121
|
+
user: {
|
|
122
|
+
id: string;
|
|
123
|
+
};
|
|
124
|
+
scopeChain?: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
125
|
+
} & Record<never, never>, import("@orpc/server").MergedCurrentContext<{
|
|
126
|
+
headers: Headers;
|
|
127
|
+
}, {
|
|
128
|
+
headers: Headers;
|
|
129
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
130
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
131
|
+
}>>, import("@orpc/server").MergedCurrentContext<import("@orpc/server").MergedCurrentContext<{
|
|
132
|
+
headers: Headers;
|
|
133
|
+
}, {
|
|
134
|
+
headers: Headers;
|
|
135
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
136
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
137
|
+
}>, {
|
|
138
|
+
scopeId: string;
|
|
139
|
+
scopeType: string;
|
|
140
|
+
scopeChain: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
141
|
+
}>, z.ZodObject<{
|
|
142
|
+
name: z.ZodString;
|
|
143
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
144
|
+
filters: z.ZodNullable<z.ZodOptional<z.ZodType<FilterGroupInput, unknown, z.core.$ZodTypeInternals<FilterGroupInput, unknown>>>>;
|
|
145
|
+
sorts: z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
146
|
+
field: z.ZodString;
|
|
147
|
+
direction: z.ZodEnum<{
|
|
148
|
+
asc: "asc";
|
|
149
|
+
desc: "desc";
|
|
150
|
+
}>;
|
|
151
|
+
}, z.core.$strip>>>>;
|
|
152
|
+
columns: z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
153
|
+
fieldKey: z.ZodString;
|
|
154
|
+
visible: z.ZodBoolean;
|
|
155
|
+
position: z.ZodNumber;
|
|
156
|
+
}, z.core.$strip>>>>;
|
|
157
|
+
}, z.core.$strip>, import("@orpc/server").Schema<{
|
|
158
|
+
id: string;
|
|
159
|
+
scopeId: string;
|
|
160
|
+
name: string;
|
|
161
|
+
icon: string;
|
|
162
|
+
filters: unknown;
|
|
163
|
+
sorts: unknown;
|
|
164
|
+
columns: unknown;
|
|
165
|
+
createdAt: Date;
|
|
166
|
+
updatedAt: Date;
|
|
167
|
+
scope: string;
|
|
168
|
+
} | undefined, {
|
|
169
|
+
id: string;
|
|
170
|
+
scopeId: string;
|
|
171
|
+
name: string;
|
|
172
|
+
icon: string;
|
|
173
|
+
filters: unknown;
|
|
174
|
+
sorts: unknown;
|
|
175
|
+
columns: unknown;
|
|
176
|
+
createdAt: Date;
|
|
177
|
+
updatedAt: Date;
|
|
178
|
+
scope: string;
|
|
179
|
+
} | undefined>, Record<never, never>, Record<never, never>>;
|
|
180
|
+
update: import("@orpc/server").DecoratedProcedure<import("@orpc/server").MergedInitialContext<import("@orpc/server").MergedInitialContext<{
|
|
181
|
+
headers: Headers;
|
|
182
|
+
} & Record<never, never>, {
|
|
183
|
+
headers: Headers;
|
|
184
|
+
} & Record<never, never>, {
|
|
185
|
+
headers: Headers;
|
|
186
|
+
}>, {
|
|
187
|
+
headers: Headers;
|
|
188
|
+
user: {
|
|
189
|
+
id: string;
|
|
190
|
+
};
|
|
191
|
+
scopeChain?: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
192
|
+
} & Record<never, never>, import("@orpc/server").MergedCurrentContext<{
|
|
193
|
+
headers: Headers;
|
|
194
|
+
}, {
|
|
195
|
+
headers: Headers;
|
|
196
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
197
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
198
|
+
}>>, import("@orpc/server").MergedCurrentContext<import("@orpc/server").MergedCurrentContext<{
|
|
199
|
+
headers: Headers;
|
|
200
|
+
}, {
|
|
201
|
+
headers: Headers;
|
|
202
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
203
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
204
|
+
}>, {
|
|
205
|
+
scopeId: string;
|
|
206
|
+
scopeType: string;
|
|
207
|
+
scopeChain: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
208
|
+
}>, z.ZodObject<{
|
|
209
|
+
id: z.ZodString;
|
|
210
|
+
name: z.ZodOptional<z.ZodString>;
|
|
211
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
212
|
+
filters: z.ZodOptional<z.ZodNullable<z.ZodOptional<z.ZodType<FilterGroupInput, unknown, z.core.$ZodTypeInternals<FilterGroupInput, unknown>>>>>;
|
|
213
|
+
sorts: z.ZodOptional<z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
214
|
+
field: z.ZodString;
|
|
215
|
+
direction: z.ZodEnum<{
|
|
216
|
+
asc: "asc";
|
|
217
|
+
desc: "desc";
|
|
218
|
+
}>;
|
|
219
|
+
}, z.core.$strip>>>>>;
|
|
220
|
+
columns: z.ZodOptional<z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
221
|
+
fieldKey: z.ZodString;
|
|
222
|
+
visible: z.ZodBoolean;
|
|
223
|
+
position: z.ZodNumber;
|
|
224
|
+
}, z.core.$strip>>>>>;
|
|
225
|
+
}, z.core.$strip>, import("@orpc/server").Schema<{
|
|
226
|
+
name: string;
|
|
227
|
+
icon: string;
|
|
228
|
+
filters: unknown;
|
|
229
|
+
sorts: unknown;
|
|
230
|
+
columns: unknown;
|
|
231
|
+
createdAt: Date;
|
|
232
|
+
updatedAt: Date;
|
|
233
|
+
scope: string;
|
|
234
|
+
scopeId: string;
|
|
235
|
+
id: string;
|
|
236
|
+
}, {
|
|
237
|
+
name: string;
|
|
238
|
+
icon: string;
|
|
239
|
+
filters: unknown;
|
|
240
|
+
sorts: unknown;
|
|
241
|
+
columns: unknown;
|
|
242
|
+
createdAt: Date;
|
|
243
|
+
updatedAt: Date;
|
|
244
|
+
scope: string;
|
|
245
|
+
scopeId: string;
|
|
246
|
+
id: string;
|
|
247
|
+
}>, Record<never, never>, Record<never, never>>;
|
|
248
|
+
delete: import("@orpc/server").DecoratedProcedure<import("@orpc/server").MergedInitialContext<import("@orpc/server").MergedInitialContext<{
|
|
249
|
+
headers: Headers;
|
|
250
|
+
} & Record<never, never>, {
|
|
251
|
+
headers: Headers;
|
|
252
|
+
} & Record<never, never>, {
|
|
253
|
+
headers: Headers;
|
|
254
|
+
}>, {
|
|
255
|
+
headers: Headers;
|
|
256
|
+
user: {
|
|
257
|
+
id: string;
|
|
258
|
+
};
|
|
259
|
+
scopeChain?: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
260
|
+
} & Record<never, never>, import("@orpc/server").MergedCurrentContext<{
|
|
261
|
+
headers: Headers;
|
|
262
|
+
}, {
|
|
263
|
+
headers: Headers;
|
|
264
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
265
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
266
|
+
}>>, import("@orpc/server").MergedCurrentContext<import("@orpc/server").MergedCurrentContext<{
|
|
267
|
+
headers: Headers;
|
|
268
|
+
}, {
|
|
269
|
+
headers: Headers;
|
|
270
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
271
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
272
|
+
}>, {
|
|
273
|
+
scopeId: string;
|
|
274
|
+
scopeType: string;
|
|
275
|
+
scopeChain: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
276
|
+
}>, z.ZodObject<{
|
|
277
|
+
id: z.ZodString;
|
|
278
|
+
}, z.core.$strip>, import("@orpc/server").Schema<{
|
|
279
|
+
ok: boolean;
|
|
280
|
+
}, {
|
|
281
|
+
ok: boolean;
|
|
282
|
+
}>, Record<never, never>, Record<never, never>>;
|
|
283
|
+
};
|
|
36
284
|
create: import("@orpc/server").DecoratedProcedure<import("@orpc/server").MergedInitialContext<import("@orpc/server").MergedInitialContext<{
|
|
37
285
|
headers: Headers;
|
|
38
286
|
} & Record<never, never>, {
|
|
@@ -64,29 +312,33 @@ declare const captureRouter: {
|
|
|
64
312
|
}>, z.ZodObject<{
|
|
65
313
|
name: z.ZodDefault<z.ZodString>;
|
|
66
314
|
}, z.core.$strip>, import("@orpc/server").Schema<{
|
|
315
|
+
id: string;
|
|
67
316
|
scopeId: string;
|
|
68
317
|
name: string;
|
|
69
|
-
|
|
318
|
+
createdAt: Date;
|
|
319
|
+
updatedAt: Date;
|
|
320
|
+
scope: string;
|
|
70
321
|
surface: string;
|
|
71
322
|
slug: string;
|
|
72
323
|
status: string;
|
|
324
|
+
tags: string[];
|
|
73
325
|
fields: import("../../shared/types.ts").CaptureFieldDefinition[];
|
|
326
|
+
document: CaptureFormDocument | null;
|
|
74
327
|
actionConfig: CaptureActionConfig;
|
|
75
|
-
createdAt: Date;
|
|
76
|
-
updatedAt: Date;
|
|
77
|
-
scope: string;
|
|
78
328
|
}, {
|
|
329
|
+
id: string;
|
|
79
330
|
scopeId: string;
|
|
80
331
|
name: string;
|
|
81
|
-
|
|
332
|
+
createdAt: Date;
|
|
333
|
+
updatedAt: Date;
|
|
334
|
+
scope: string;
|
|
82
335
|
surface: string;
|
|
83
336
|
slug: string;
|
|
84
337
|
status: string;
|
|
338
|
+
tags: string[];
|
|
85
339
|
fields: import("../../shared/types.ts").CaptureFieldDefinition[];
|
|
340
|
+
document: CaptureFormDocument | null;
|
|
86
341
|
actionConfig: CaptureActionConfig;
|
|
87
|
-
createdAt: Date;
|
|
88
|
-
updatedAt: Date;
|
|
89
|
-
scope: string;
|
|
90
342
|
}>, Record<never, never>, Record<never, never>>;
|
|
91
343
|
get: import("@orpc/server").DecoratedProcedure<import("@orpc/server").MergedInitialContext<import("@orpc/server").MergedInitialContext<{
|
|
92
344
|
headers: Headers;
|
|
@@ -119,11 +371,14 @@ declare const captureRouter: {
|
|
|
119
371
|
}>, z.ZodObject<{
|
|
120
372
|
id: z.ZodString;
|
|
121
373
|
}, z.core.$strip>, import("@orpc/server").Schema<{
|
|
374
|
+
document: CaptureFormDocument;
|
|
375
|
+
publicationId: string | null;
|
|
122
376
|
publicationSlug: string | null;
|
|
123
377
|
surface: string;
|
|
124
378
|
name: string;
|
|
125
379
|
slug: string;
|
|
126
380
|
status: string;
|
|
381
|
+
tags: string[];
|
|
127
382
|
fields: import("../../shared/types.ts").CaptureFieldDefinition[];
|
|
128
383
|
actionConfig: CaptureActionConfig;
|
|
129
384
|
createdAt: Date;
|
|
@@ -132,11 +387,14 @@ declare const captureRouter: {
|
|
|
132
387
|
scopeId: string;
|
|
133
388
|
id: string;
|
|
134
389
|
}, {
|
|
390
|
+
document: CaptureFormDocument;
|
|
391
|
+
publicationId: string | null;
|
|
135
392
|
publicationSlug: string | null;
|
|
136
393
|
surface: string;
|
|
137
394
|
name: string;
|
|
138
395
|
slug: string;
|
|
139
396
|
status: string;
|
|
397
|
+
tags: string[];
|
|
140
398
|
fields: import("../../shared/types.ts").CaptureFieldDefinition[];
|
|
141
399
|
actionConfig: CaptureActionConfig;
|
|
142
400
|
createdAt: Date;
|
|
@@ -184,7 +442,8 @@ declare const captureRouter: {
|
|
|
184
442
|
required: z.ZodDefault<z.ZodBoolean>;
|
|
185
443
|
options: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
186
444
|
metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
187
|
-
|
|
445
|
+
hidden: z.ZodOptional<z.ZodBoolean>;
|
|
446
|
+
visibleWhen: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
188
447
|
fieldId: z.ZodString;
|
|
189
448
|
fieldKey: z.ZodString;
|
|
190
449
|
operator: z.ZodEnum<{
|
|
@@ -194,7 +453,209 @@ declare const captureRouter: {
|
|
|
194
453
|
isNotEmpty: "isNotEmpty";
|
|
195
454
|
}>;
|
|
196
455
|
value: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull, z.ZodArray<z.ZodString>]>>;
|
|
456
|
+
}, z.core.$strip>, z.ZodType<FilterGroupInput, unknown, z.core.$ZodTypeInternals<FilterGroupInput, unknown>>]>>;
|
|
457
|
+
validationRules: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
458
|
+
id: z.ZodString;
|
|
459
|
+
message: z.ZodString;
|
|
460
|
+
expression: z.ZodType<CaptureValidationExpression, unknown, z.core.$ZodTypeInternals<CaptureValidationExpression, unknown>>;
|
|
461
|
+
}, z.core.$strip>>>;
|
|
462
|
+
}, z.core.$strip>>;
|
|
463
|
+
document: z.ZodOptional<z.ZodObject<{
|
|
464
|
+
version: z.ZodLiteral<1>;
|
|
465
|
+
pages: z.ZodArray<z.ZodObject<{
|
|
466
|
+
id: z.ZodString;
|
|
467
|
+
title: z.ZodString;
|
|
468
|
+
preHeading: z.ZodOptional<z.ZodString>;
|
|
469
|
+
description: z.ZodOptional<z.ZodString>;
|
|
470
|
+
headerVisible: z.ZodOptional<z.ZodBoolean>;
|
|
471
|
+
headerContentInitialized: z.ZodOptional<z.ZodBoolean>;
|
|
472
|
+
hidden: z.ZodOptional<z.ZodBoolean>;
|
|
473
|
+
visibleWhen: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
474
|
+
fieldId: z.ZodString;
|
|
475
|
+
fieldKey: z.ZodString;
|
|
476
|
+
operator: z.ZodEnum<{
|
|
477
|
+
equals: "equals";
|
|
478
|
+
notEquals: "notEquals";
|
|
479
|
+
isEmpty: "isEmpty";
|
|
480
|
+
isNotEmpty: "isNotEmpty";
|
|
481
|
+
}>;
|
|
482
|
+
value: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull, z.ZodArray<z.ZodString>]>>;
|
|
483
|
+
}, z.core.$strip>, z.ZodType<FilterGroupInput, unknown, z.core.$ZodTypeInternals<FilterGroupInput, unknown>>]>>;
|
|
484
|
+
order: z.ZodNumber;
|
|
197
485
|
}, z.core.$strip>>;
|
|
486
|
+
items: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
487
|
+
id: z.ZodString;
|
|
488
|
+
key: z.ZodString;
|
|
489
|
+
label: z.ZodString;
|
|
490
|
+
type: z.ZodString;
|
|
491
|
+
required: z.ZodDefault<z.ZodBoolean>;
|
|
492
|
+
options: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
493
|
+
metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
494
|
+
hidden: z.ZodOptional<z.ZodBoolean>;
|
|
495
|
+
visibleWhen: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
496
|
+
fieldId: z.ZodString;
|
|
497
|
+
fieldKey: z.ZodString;
|
|
498
|
+
operator: z.ZodEnum<{
|
|
499
|
+
equals: "equals";
|
|
500
|
+
notEquals: "notEquals";
|
|
501
|
+
isEmpty: "isEmpty";
|
|
502
|
+
isNotEmpty: "isNotEmpty";
|
|
503
|
+
}>;
|
|
504
|
+
value: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull, z.ZodArray<z.ZodString>]>>;
|
|
505
|
+
}, z.core.$strip>, z.ZodType<FilterGroupInput, unknown, z.core.$ZodTypeInternals<FilterGroupInput, unknown>>]>>;
|
|
506
|
+
validationRules: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
507
|
+
id: z.ZodString;
|
|
508
|
+
message: z.ZodString;
|
|
509
|
+
expression: z.ZodType<CaptureValidationExpression, unknown, z.core.$ZodTypeInternals<CaptureValidationExpression, unknown>>;
|
|
510
|
+
}, z.core.$strip>>>;
|
|
511
|
+
kind: z.ZodLiteral<"input">;
|
|
512
|
+
pageId: z.ZodString;
|
|
513
|
+
order: z.ZodNumber;
|
|
514
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
515
|
+
id: z.ZodString;
|
|
516
|
+
kind: z.ZodLiteral<"content.text">;
|
|
517
|
+
pageId: z.ZodString;
|
|
518
|
+
order: z.ZodNumber;
|
|
519
|
+
title: z.ZodOptional<z.ZodString>;
|
|
520
|
+
body: z.ZodString;
|
|
521
|
+
hidden: z.ZodOptional<z.ZodBoolean>;
|
|
522
|
+
visibleWhen: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
523
|
+
fieldId: z.ZodString;
|
|
524
|
+
fieldKey: z.ZodString;
|
|
525
|
+
operator: z.ZodEnum<{
|
|
526
|
+
equals: "equals";
|
|
527
|
+
notEquals: "notEquals";
|
|
528
|
+
isEmpty: "isEmpty";
|
|
529
|
+
isNotEmpty: "isNotEmpty";
|
|
530
|
+
}>;
|
|
531
|
+
value: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull, z.ZodArray<z.ZodString>]>>;
|
|
532
|
+
}, z.core.$strip>, z.ZodType<FilterGroupInput, unknown, z.core.$ZodTypeInternals<FilterGroupInput, unknown>>]>>;
|
|
533
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
534
|
+
id: z.ZodString;
|
|
535
|
+
kind: z.ZodLiteral<"content.image">;
|
|
536
|
+
pageId: z.ZodString;
|
|
537
|
+
order: z.ZodNumber;
|
|
538
|
+
imageUrl: z.ZodString;
|
|
539
|
+
altText: z.ZodOptional<z.ZodString>;
|
|
540
|
+
caption: z.ZodOptional<z.ZodString>;
|
|
541
|
+
shape: z.ZodOptional<z.ZodEnum<{
|
|
542
|
+
square: "square";
|
|
543
|
+
circle: "circle";
|
|
544
|
+
}>>;
|
|
545
|
+
align: z.ZodOptional<z.ZodEnum<{
|
|
546
|
+
left: "left";
|
|
547
|
+
center: "center";
|
|
548
|
+
right: "right";
|
|
549
|
+
}>>;
|
|
550
|
+
size: z.ZodOptional<z.ZodEnum<{
|
|
551
|
+
small: "small";
|
|
552
|
+
medium: "medium";
|
|
553
|
+
large: "large";
|
|
554
|
+
full: "full";
|
|
555
|
+
}>>;
|
|
556
|
+
fit: z.ZodOptional<z.ZodEnum<{
|
|
557
|
+
cover: "cover";
|
|
558
|
+
contain: "contain";
|
|
559
|
+
}>>;
|
|
560
|
+
source: z.ZodOptional<z.ZodObject<{
|
|
561
|
+
type: z.ZodEnum<{
|
|
562
|
+
url: "url";
|
|
563
|
+
upload: "upload";
|
|
564
|
+
storage: "storage";
|
|
565
|
+
}>;
|
|
566
|
+
storageItemId: z.ZodOptional<z.ZodString>;
|
|
567
|
+
}, z.core.$strip>>;
|
|
568
|
+
hidden: z.ZodOptional<z.ZodBoolean>;
|
|
569
|
+
visibleWhen: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
570
|
+
fieldId: z.ZodString;
|
|
571
|
+
fieldKey: z.ZodString;
|
|
572
|
+
operator: z.ZodEnum<{
|
|
573
|
+
equals: "equals";
|
|
574
|
+
notEquals: "notEquals";
|
|
575
|
+
isEmpty: "isEmpty";
|
|
576
|
+
isNotEmpty: "isNotEmpty";
|
|
577
|
+
}>;
|
|
578
|
+
value: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull, z.ZodArray<z.ZodString>]>>;
|
|
579
|
+
}, z.core.$strip>, z.ZodType<FilterGroupInput, unknown, z.core.$ZodTypeInternals<FilterGroupInput, unknown>>]>>;
|
|
580
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
581
|
+
id: z.ZodString;
|
|
582
|
+
kind: z.ZodLiteral<"content.icon">;
|
|
583
|
+
pageId: z.ZodString;
|
|
584
|
+
order: z.ZodNumber;
|
|
585
|
+
icon: z.ZodString;
|
|
586
|
+
iconColor: z.ZodOptional<z.ZodString>;
|
|
587
|
+
align: z.ZodEnum<{
|
|
588
|
+
left: "left";
|
|
589
|
+
center: "center";
|
|
590
|
+
right: "right";
|
|
591
|
+
}>;
|
|
592
|
+
hidden: z.ZodOptional<z.ZodBoolean>;
|
|
593
|
+
visibleWhen: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
594
|
+
fieldId: z.ZodString;
|
|
595
|
+
fieldKey: z.ZodString;
|
|
596
|
+
operator: z.ZodEnum<{
|
|
597
|
+
equals: "equals";
|
|
598
|
+
notEquals: "notEquals";
|
|
599
|
+
isEmpty: "isEmpty";
|
|
600
|
+
isNotEmpty: "isNotEmpty";
|
|
601
|
+
}>;
|
|
602
|
+
value: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull, z.ZodArray<z.ZodString>]>>;
|
|
603
|
+
}, z.core.$strip>, z.ZodType<FilterGroupInput, unknown, z.core.$ZodTypeInternals<FilterGroupInput, unknown>>]>>;
|
|
604
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
605
|
+
id: z.ZodString;
|
|
606
|
+
kind: z.ZodLiteral<"content.divider">;
|
|
607
|
+
pageId: z.ZodString;
|
|
608
|
+
order: z.ZodNumber;
|
|
609
|
+
hidden: z.ZodOptional<z.ZodBoolean>;
|
|
610
|
+
visibleWhen: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
611
|
+
fieldId: z.ZodString;
|
|
612
|
+
fieldKey: z.ZodString;
|
|
613
|
+
operator: z.ZodEnum<{
|
|
614
|
+
equals: "equals";
|
|
615
|
+
notEquals: "notEquals";
|
|
616
|
+
isEmpty: "isEmpty";
|
|
617
|
+
isNotEmpty: "isNotEmpty";
|
|
618
|
+
}>;
|
|
619
|
+
value: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull, z.ZodArray<z.ZodString>]>>;
|
|
620
|
+
}, z.core.$strip>, z.ZodType<FilterGroupInput, unknown, z.core.$ZodTypeInternals<FilterGroupInput, unknown>>]>>;
|
|
621
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
622
|
+
id: z.ZodString;
|
|
623
|
+
kind: z.ZodLiteral<"content.page-header">;
|
|
624
|
+
pageId: z.ZodString;
|
|
625
|
+
order: z.ZodNumber;
|
|
626
|
+
preHeading: z.ZodOptional<z.ZodString>;
|
|
627
|
+
title: z.ZodString;
|
|
628
|
+
description: z.ZodOptional<z.ZodString>;
|
|
629
|
+
hidden: z.ZodOptional<z.ZodBoolean>;
|
|
630
|
+
visibleWhen: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
631
|
+
fieldId: z.ZodString;
|
|
632
|
+
fieldKey: z.ZodString;
|
|
633
|
+
operator: z.ZodEnum<{
|
|
634
|
+
equals: "equals";
|
|
635
|
+
notEquals: "notEquals";
|
|
636
|
+
isEmpty: "isEmpty";
|
|
637
|
+
isNotEmpty: "isNotEmpty";
|
|
638
|
+
}>;
|
|
639
|
+
value: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull, z.ZodArray<z.ZodString>]>>;
|
|
640
|
+
}, z.core.$strip>, z.ZodType<FilterGroupInput, unknown, z.core.$ZodTypeInternals<FilterGroupInput, unknown>>]>>;
|
|
641
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
642
|
+
id: z.ZodString;
|
|
643
|
+
kind: z.ZodLiteral<"content.page-progress">;
|
|
644
|
+
pageId: z.ZodString;
|
|
645
|
+
order: z.ZodNumber;
|
|
646
|
+
hidden: z.ZodOptional<z.ZodBoolean>;
|
|
647
|
+
visibleWhen: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
648
|
+
fieldId: z.ZodString;
|
|
649
|
+
fieldKey: z.ZodString;
|
|
650
|
+
operator: z.ZodEnum<{
|
|
651
|
+
equals: "equals";
|
|
652
|
+
notEquals: "notEquals";
|
|
653
|
+
isEmpty: "isEmpty";
|
|
654
|
+
isNotEmpty: "isNotEmpty";
|
|
655
|
+
}>;
|
|
656
|
+
value: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull, z.ZodArray<z.ZodString>]>>;
|
|
657
|
+
}, z.core.$strip>, z.ZodType<FilterGroupInput, unknown, z.core.$ZodTypeInternals<FilterGroupInput, unknown>>]>>;
|
|
658
|
+
}, z.core.$strip>], "kind">>;
|
|
198
659
|
}, z.core.$strip>>;
|
|
199
660
|
actionConfig: z.ZodDefault<z.ZodObject<{
|
|
200
661
|
contacts: z.ZodOptional<z.ZodObject<{
|
|
@@ -243,7 +704,9 @@ declare const captureRouter: {
|
|
|
243
704
|
name: string;
|
|
244
705
|
slug: string;
|
|
245
706
|
status: string;
|
|
707
|
+
tags: string[];
|
|
246
708
|
fields: import("../../shared/types.ts").CaptureFieldDefinition[];
|
|
709
|
+
document: CaptureFormDocument | null;
|
|
247
710
|
actionConfig: CaptureActionConfig;
|
|
248
711
|
createdAt: Date;
|
|
249
712
|
updatedAt: Date;
|
|
@@ -255,7 +718,9 @@ declare const captureRouter: {
|
|
|
255
718
|
name: string;
|
|
256
719
|
slug: string;
|
|
257
720
|
status: string;
|
|
721
|
+
tags: string[];
|
|
258
722
|
fields: import("../../shared/types.ts").CaptureFieldDefinition[];
|
|
723
|
+
document: CaptureFormDocument | null;
|
|
259
724
|
actionConfig: CaptureActionConfig;
|
|
260
725
|
createdAt: Date;
|
|
261
726
|
updatedAt: Date;
|
|
@@ -263,6 +728,111 @@ declare const captureRouter: {
|
|
|
263
728
|
scopeId: string;
|
|
264
729
|
id: string;
|
|
265
730
|
}>, Record<never, never>, Record<never, never>>;
|
|
731
|
+
updateTags: import("@orpc/server").DecoratedProcedure<import("@orpc/server").MergedInitialContext<import("@orpc/server").MergedInitialContext<{
|
|
732
|
+
headers: Headers;
|
|
733
|
+
} & Record<never, never>, {
|
|
734
|
+
headers: Headers;
|
|
735
|
+
} & Record<never, never>, {
|
|
736
|
+
headers: Headers;
|
|
737
|
+
}>, {
|
|
738
|
+
headers: Headers;
|
|
739
|
+
user: {
|
|
740
|
+
id: string;
|
|
741
|
+
};
|
|
742
|
+
scopeChain?: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
743
|
+
} & Record<never, never>, import("@orpc/server").MergedCurrentContext<{
|
|
744
|
+
headers: Headers;
|
|
745
|
+
}, {
|
|
746
|
+
headers: Headers;
|
|
747
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
748
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
749
|
+
}>>, import("@orpc/server").MergedCurrentContext<import("@orpc/server").MergedCurrentContext<{
|
|
750
|
+
headers: Headers;
|
|
751
|
+
}, {
|
|
752
|
+
headers: Headers;
|
|
753
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
754
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
755
|
+
}>, {
|
|
756
|
+
scopeId: string;
|
|
757
|
+
scopeType: string;
|
|
758
|
+
scopeChain: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
759
|
+
}>, z.ZodObject<{
|
|
760
|
+
id: z.ZodString;
|
|
761
|
+
tags: z.ZodArray<z.ZodString>;
|
|
762
|
+
}, z.core.$strip>, import("@orpc/server").Schema<CaptureDefinitionSummary, CaptureDefinitionSummary>, Record<never, never>, Record<never, never>>;
|
|
763
|
+
updateActionConfig: import("@orpc/server").DecoratedProcedure<import("@orpc/server").MergedInitialContext<import("@orpc/server").MergedInitialContext<{
|
|
764
|
+
headers: Headers;
|
|
765
|
+
} & Record<never, never>, {
|
|
766
|
+
headers: Headers;
|
|
767
|
+
} & Record<never, never>, {
|
|
768
|
+
headers: Headers;
|
|
769
|
+
}>, {
|
|
770
|
+
headers: Headers;
|
|
771
|
+
user: {
|
|
772
|
+
id: string;
|
|
773
|
+
};
|
|
774
|
+
scopeChain?: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
775
|
+
} & Record<never, never>, import("@orpc/server").MergedCurrentContext<{
|
|
776
|
+
headers: Headers;
|
|
777
|
+
}, {
|
|
778
|
+
headers: Headers;
|
|
779
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
780
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
781
|
+
}>>, import("@orpc/server").MergedCurrentContext<import("@orpc/server").MergedCurrentContext<{
|
|
782
|
+
headers: Headers;
|
|
783
|
+
}, {
|
|
784
|
+
headers: Headers;
|
|
785
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
786
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
787
|
+
}>, {
|
|
788
|
+
scopeId: string;
|
|
789
|
+
scopeType: string;
|
|
790
|
+
scopeChain: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
791
|
+
}>, z.ZodObject<{
|
|
792
|
+
id: z.ZodString;
|
|
793
|
+
actionConfig: z.ZodDefault<z.ZodObject<{
|
|
794
|
+
contacts: z.ZodOptional<z.ZodObject<{
|
|
795
|
+
enabled: z.ZodDefault<z.ZodBoolean>;
|
|
796
|
+
nameFieldKey: z.ZodOptional<z.ZodString>;
|
|
797
|
+
emailFieldKey: z.ZodOptional<z.ZodString>;
|
|
798
|
+
phoneFieldKey: z.ZodOptional<z.ZodString>;
|
|
799
|
+
customFieldMappings: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
800
|
+
}, z.core.$strip>>;
|
|
801
|
+
email: z.ZodOptional<z.ZodObject<{
|
|
802
|
+
enabled: z.ZodDefault<z.ZodBoolean>;
|
|
803
|
+
from: z.ZodOptional<z.ZodString>;
|
|
804
|
+
internalRecipientEmail: z.ZodOptional<z.ZodString>;
|
|
805
|
+
respondentEmailFieldKey: z.ZodOptional<z.ZodString>;
|
|
806
|
+
subjectTemplate: z.ZodDefault<z.ZodString>;
|
|
807
|
+
bodyTemplate: z.ZodDefault<z.ZodString>;
|
|
808
|
+
}, z.core.$strip>>;
|
|
809
|
+
workflow: z.ZodOptional<z.ZodObject<{
|
|
810
|
+
enabled: z.ZodDefault<z.ZodBoolean>;
|
|
811
|
+
workflowDefinitionId: z.ZodOptional<z.ZodString>;
|
|
812
|
+
triggerNodeId: z.ZodOptional<z.ZodString>;
|
|
813
|
+
execute: z.ZodDefault<z.ZodBoolean>;
|
|
814
|
+
}, z.core.$strip>>;
|
|
815
|
+
quiz: z.ZodOptional<z.ZodObject<{
|
|
816
|
+
enabled: z.ZodDefault<z.ZodBoolean>;
|
|
817
|
+
version: z.ZodDefault<z.ZodNumber>;
|
|
818
|
+
outcomes: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
819
|
+
id: z.ZodString;
|
|
820
|
+
key: z.ZodString;
|
|
821
|
+
label: z.ZodString;
|
|
822
|
+
description: z.ZodOptional<z.ZodString>;
|
|
823
|
+
bucket: z.ZodOptional<z.ZodString>;
|
|
824
|
+
minScore: z.ZodOptional<z.ZodNumber>;
|
|
825
|
+
}, z.core.$strip>>>;
|
|
826
|
+
rules: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
827
|
+
id: z.ZodString;
|
|
828
|
+
fieldKey: z.ZodString;
|
|
829
|
+
equals: z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull, z.ZodArray<z.ZodString>]>;
|
|
830
|
+
score: z.ZodOptional<z.ZodNumber>;
|
|
831
|
+
outcomeKey: z.ZodOptional<z.ZodString>;
|
|
832
|
+
}, z.core.$strip>>>;
|
|
833
|
+
}, z.core.$strip>>;
|
|
834
|
+
}, z.core.$strip>>;
|
|
835
|
+
}, z.core.$strip>, import("@orpc/server").Schema<CaptureDefinitionSummary, CaptureDefinitionSummary>, Record<never, never>, Record<never, never>>;
|
|
266
836
|
publish: import("@orpc/server").DecoratedProcedure<import("@orpc/server").MergedInitialContext<import("@orpc/server").MergedInitialContext<{
|
|
267
837
|
headers: Headers;
|
|
268
838
|
} & Record<never, never>, {
|
|
@@ -294,28 +864,63 @@ declare const captureRouter: {
|
|
|
294
864
|
}>, z.ZodObject<{
|
|
295
865
|
id: z.ZodString;
|
|
296
866
|
}, z.core.$strip>, import("@orpc/server").Schema<{
|
|
297
|
-
scopeId: string;
|
|
298
867
|
id: string;
|
|
299
|
-
|
|
300
|
-
status: string;
|
|
868
|
+
scopeId: string;
|
|
301
869
|
createdAt: Date;
|
|
302
870
|
updatedAt: Date;
|
|
303
871
|
scope: string;
|
|
872
|
+
slug: string;
|
|
873
|
+
status: string;
|
|
304
874
|
definitionId: string;
|
|
305
875
|
security: CapturePublicationSecurity;
|
|
306
876
|
revokedAt: Date | null;
|
|
307
877
|
} | undefined, {
|
|
308
|
-
scopeId: string;
|
|
309
878
|
id: string;
|
|
310
|
-
|
|
311
|
-
status: string;
|
|
879
|
+
scopeId: string;
|
|
312
880
|
createdAt: Date;
|
|
313
881
|
updatedAt: Date;
|
|
314
882
|
scope: string;
|
|
883
|
+
slug: string;
|
|
884
|
+
status: string;
|
|
315
885
|
definitionId: string;
|
|
316
886
|
security: CapturePublicationSecurity;
|
|
317
887
|
revokedAt: Date | null;
|
|
318
888
|
} | undefined>, Record<never, never>, Record<never, never>>;
|
|
889
|
+
resolveStorageImageUrl: import("@orpc/server").DecoratedProcedure<import("@orpc/server").MergedInitialContext<import("@orpc/server").MergedInitialContext<{
|
|
890
|
+
headers: Headers;
|
|
891
|
+
} & Record<never, never>, {
|
|
892
|
+
headers: Headers;
|
|
893
|
+
} & Record<never, never>, {
|
|
894
|
+
headers: Headers;
|
|
895
|
+
}>, {
|
|
896
|
+
headers: Headers;
|
|
897
|
+
user: {
|
|
898
|
+
id: string;
|
|
899
|
+
};
|
|
900
|
+
scopeChain?: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
901
|
+
} & Record<never, never>, import("@orpc/server").MergedCurrentContext<{
|
|
902
|
+
headers: Headers;
|
|
903
|
+
}, {
|
|
904
|
+
headers: Headers;
|
|
905
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
906
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
907
|
+
}>>, import("@orpc/server").MergedCurrentContext<import("@orpc/server").MergedCurrentContext<{
|
|
908
|
+
headers: Headers;
|
|
909
|
+
}, {
|
|
910
|
+
headers: Headers;
|
|
911
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
912
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
913
|
+
}>, {
|
|
914
|
+
scopeId: string;
|
|
915
|
+
scopeType: string;
|
|
916
|
+
scopeChain: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
917
|
+
}>, z.ZodObject<{
|
|
918
|
+
itemId: z.ZodString;
|
|
919
|
+
}, z.core.$strip>, import("@orpc/server").Schema<{
|
|
920
|
+
url: string;
|
|
921
|
+
}, {
|
|
922
|
+
url: string;
|
|
923
|
+
}>, Record<never, never>, Record<never, never>>;
|
|
319
924
|
updatePublication: import("@orpc/server").DecoratedProcedure<import("@orpc/server").MergedInitialContext<import("@orpc/server").MergedInitialContext<{
|
|
320
925
|
headers: Headers;
|
|
321
926
|
} & Record<never, never>, {
|
|
@@ -417,6 +1022,35 @@ declare const captureRouter: {
|
|
|
417
1022
|
scopeType: string;
|
|
418
1023
|
scopeChain: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
419
1024
|
}>, z.ZodObject<{}, z.core.$strip>, import("@orpc/server").Schema<CaptureWorkflowDefinitionOption[], CaptureWorkflowDefinitionOption[]>, Record<never, never>, Record<never, never>>;
|
|
1025
|
+
listContactCustomFields: import("@orpc/server").DecoratedProcedure<import("@orpc/server").MergedInitialContext<import("@orpc/server").MergedInitialContext<{
|
|
1026
|
+
headers: Headers;
|
|
1027
|
+
} & Record<never, never>, {
|
|
1028
|
+
headers: Headers;
|
|
1029
|
+
} & Record<never, never>, {
|
|
1030
|
+
headers: Headers;
|
|
1031
|
+
}>, {
|
|
1032
|
+
headers: Headers;
|
|
1033
|
+
user: {
|
|
1034
|
+
id: string;
|
|
1035
|
+
};
|
|
1036
|
+
scopeChain?: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
1037
|
+
} & Record<never, never>, import("@orpc/server").MergedCurrentContext<{
|
|
1038
|
+
headers: Headers;
|
|
1039
|
+
}, {
|
|
1040
|
+
headers: Headers;
|
|
1041
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
1042
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
1043
|
+
}>>, import("@orpc/server").MergedCurrentContext<import("@orpc/server").MergedCurrentContext<{
|
|
1044
|
+
headers: Headers;
|
|
1045
|
+
}, {
|
|
1046
|
+
headers: Headers;
|
|
1047
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
1048
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
1049
|
+
}>, {
|
|
1050
|
+
scopeId: string;
|
|
1051
|
+
scopeType: string;
|
|
1052
|
+
scopeChain: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
1053
|
+
}>, z.ZodObject<{}, z.core.$strip>, import("@orpc/server").Schema<CaptureContactCustomFieldOption[], CaptureContactCustomFieldOption[]>, Record<never, never>, Record<never, never>>;
|
|
420
1054
|
};
|
|
421
1055
|
submissions: {
|
|
422
1056
|
list: import("@orpc/server").DecoratedProcedure<import("@orpc/server").MergedInitialContext<import("@orpc/server").MergedInitialContext<{
|
|
@@ -448,6 +1082,238 @@ declare const captureRouter: {
|
|
|
448
1082
|
scopeType: string;
|
|
449
1083
|
scopeChain: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
450
1084
|
}>, import("@orpc/server").Schema<unknown, unknown>, import("@orpc/server").Schema<CaptureSubmissionSummary[], CaptureSubmissionSummary[]>, Record<never, never>, Record<never, never>>;
|
|
1085
|
+
views: {
|
|
1086
|
+
list: import("@orpc/server").DecoratedProcedure<import("@orpc/server").MergedInitialContext<import("@orpc/server").MergedInitialContext<{
|
|
1087
|
+
headers: Headers;
|
|
1088
|
+
} & Record<never, never>, {
|
|
1089
|
+
headers: Headers;
|
|
1090
|
+
} & Record<never, never>, {
|
|
1091
|
+
headers: Headers;
|
|
1092
|
+
}>, {
|
|
1093
|
+
headers: Headers;
|
|
1094
|
+
user: {
|
|
1095
|
+
id: string;
|
|
1096
|
+
};
|
|
1097
|
+
scopeChain?: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
1098
|
+
} & Record<never, never>, import("@orpc/server").MergedCurrentContext<{
|
|
1099
|
+
headers: Headers;
|
|
1100
|
+
}, {
|
|
1101
|
+
headers: Headers;
|
|
1102
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
1103
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
1104
|
+
}>>, import("@orpc/server").MergedCurrentContext<import("@orpc/server").MergedCurrentContext<{
|
|
1105
|
+
headers: Headers;
|
|
1106
|
+
}, {
|
|
1107
|
+
headers: Headers;
|
|
1108
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
1109
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
1110
|
+
}>, {
|
|
1111
|
+
scopeId: string;
|
|
1112
|
+
scopeType: string;
|
|
1113
|
+
scopeChain: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
1114
|
+
}>, z.ZodObject<{
|
|
1115
|
+
definitionId: z.ZodString;
|
|
1116
|
+
}, z.core.$strip>, import("@orpc/server").Schema<{
|
|
1117
|
+
definitionId: string;
|
|
1118
|
+
name: string;
|
|
1119
|
+
icon: string;
|
|
1120
|
+
filters: unknown;
|
|
1121
|
+
sorts: unknown;
|
|
1122
|
+
columns: unknown;
|
|
1123
|
+
createdAt: Date;
|
|
1124
|
+
updatedAt: Date;
|
|
1125
|
+
scope: string;
|
|
1126
|
+
scopeId: string;
|
|
1127
|
+
id: string;
|
|
1128
|
+
}[], {
|
|
1129
|
+
definitionId: string;
|
|
1130
|
+
name: string;
|
|
1131
|
+
icon: string;
|
|
1132
|
+
filters: unknown;
|
|
1133
|
+
sorts: unknown;
|
|
1134
|
+
columns: unknown;
|
|
1135
|
+
createdAt: Date;
|
|
1136
|
+
updatedAt: Date;
|
|
1137
|
+
scope: string;
|
|
1138
|
+
scopeId: string;
|
|
1139
|
+
id: string;
|
|
1140
|
+
}[]>, Record<never, never>, Record<never, never>>;
|
|
1141
|
+
create: import("@orpc/server").DecoratedProcedure<import("@orpc/server").MergedInitialContext<import("@orpc/server").MergedInitialContext<{
|
|
1142
|
+
headers: Headers;
|
|
1143
|
+
} & Record<never, never>, {
|
|
1144
|
+
headers: Headers;
|
|
1145
|
+
} & Record<never, never>, {
|
|
1146
|
+
headers: Headers;
|
|
1147
|
+
}>, {
|
|
1148
|
+
headers: Headers;
|
|
1149
|
+
user: {
|
|
1150
|
+
id: string;
|
|
1151
|
+
};
|
|
1152
|
+
scopeChain?: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
1153
|
+
} & Record<never, never>, import("@orpc/server").MergedCurrentContext<{
|
|
1154
|
+
headers: Headers;
|
|
1155
|
+
}, {
|
|
1156
|
+
headers: Headers;
|
|
1157
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
1158
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
1159
|
+
}>>, import("@orpc/server").MergedCurrentContext<import("@orpc/server").MergedCurrentContext<{
|
|
1160
|
+
headers: Headers;
|
|
1161
|
+
}, {
|
|
1162
|
+
headers: Headers;
|
|
1163
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
1164
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
1165
|
+
}>, {
|
|
1166
|
+
scopeId: string;
|
|
1167
|
+
scopeType: string;
|
|
1168
|
+
scopeChain: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
1169
|
+
}>, z.ZodObject<{
|
|
1170
|
+
definitionId: z.ZodString;
|
|
1171
|
+
name: z.ZodString;
|
|
1172
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
1173
|
+
filters: z.ZodNullable<z.ZodOptional<z.ZodType<FilterGroupInput, unknown, z.core.$ZodTypeInternals<FilterGroupInput, unknown>>>>;
|
|
1174
|
+
sorts: z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1175
|
+
field: z.ZodString;
|
|
1176
|
+
direction: z.ZodEnum<{
|
|
1177
|
+
asc: "asc";
|
|
1178
|
+
desc: "desc";
|
|
1179
|
+
}>;
|
|
1180
|
+
}, z.core.$strip>>>>;
|
|
1181
|
+
columns: z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1182
|
+
fieldKey: z.ZodString;
|
|
1183
|
+
visible: z.ZodBoolean;
|
|
1184
|
+
position: z.ZodNumber;
|
|
1185
|
+
}, z.core.$strip>>>>;
|
|
1186
|
+
}, z.core.$strip>, import("@orpc/server").Schema<{
|
|
1187
|
+
id: string;
|
|
1188
|
+
scopeId: string;
|
|
1189
|
+
name: string;
|
|
1190
|
+
icon: string;
|
|
1191
|
+
filters: unknown;
|
|
1192
|
+
sorts: unknown;
|
|
1193
|
+
columns: unknown;
|
|
1194
|
+
createdAt: Date;
|
|
1195
|
+
updatedAt: Date;
|
|
1196
|
+
scope: string;
|
|
1197
|
+
definitionId: string;
|
|
1198
|
+
} | undefined, {
|
|
1199
|
+
id: string;
|
|
1200
|
+
scopeId: string;
|
|
1201
|
+
name: string;
|
|
1202
|
+
icon: string;
|
|
1203
|
+
filters: unknown;
|
|
1204
|
+
sorts: unknown;
|
|
1205
|
+
columns: unknown;
|
|
1206
|
+
createdAt: Date;
|
|
1207
|
+
updatedAt: Date;
|
|
1208
|
+
scope: string;
|
|
1209
|
+
definitionId: string;
|
|
1210
|
+
} | undefined>, Record<never, never>, Record<never, never>>;
|
|
1211
|
+
update: import("@orpc/server").DecoratedProcedure<import("@orpc/server").MergedInitialContext<import("@orpc/server").MergedInitialContext<{
|
|
1212
|
+
headers: Headers;
|
|
1213
|
+
} & Record<never, never>, {
|
|
1214
|
+
headers: Headers;
|
|
1215
|
+
} & Record<never, never>, {
|
|
1216
|
+
headers: Headers;
|
|
1217
|
+
}>, {
|
|
1218
|
+
headers: Headers;
|
|
1219
|
+
user: {
|
|
1220
|
+
id: string;
|
|
1221
|
+
};
|
|
1222
|
+
scopeChain?: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
1223
|
+
} & Record<never, never>, import("@orpc/server").MergedCurrentContext<{
|
|
1224
|
+
headers: Headers;
|
|
1225
|
+
}, {
|
|
1226
|
+
headers: Headers;
|
|
1227
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
1228
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
1229
|
+
}>>, import("@orpc/server").MergedCurrentContext<import("@orpc/server").MergedCurrentContext<{
|
|
1230
|
+
headers: Headers;
|
|
1231
|
+
}, {
|
|
1232
|
+
headers: Headers;
|
|
1233
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
1234
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
1235
|
+
}>, {
|
|
1236
|
+
scopeId: string;
|
|
1237
|
+
scopeType: string;
|
|
1238
|
+
scopeChain: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
1239
|
+
}>, z.ZodObject<{
|
|
1240
|
+
id: z.ZodString;
|
|
1241
|
+
name: z.ZodOptional<z.ZodString>;
|
|
1242
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
1243
|
+
filters: z.ZodOptional<z.ZodNullable<z.ZodOptional<z.ZodType<FilterGroupInput, unknown, z.core.$ZodTypeInternals<FilterGroupInput, unknown>>>>>;
|
|
1244
|
+
sorts: z.ZodOptional<z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1245
|
+
field: z.ZodString;
|
|
1246
|
+
direction: z.ZodEnum<{
|
|
1247
|
+
asc: "asc";
|
|
1248
|
+
desc: "desc";
|
|
1249
|
+
}>;
|
|
1250
|
+
}, z.core.$strip>>>>>;
|
|
1251
|
+
columns: z.ZodOptional<z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1252
|
+
fieldKey: z.ZodString;
|
|
1253
|
+
visible: z.ZodBoolean;
|
|
1254
|
+
position: z.ZodNumber;
|
|
1255
|
+
}, z.core.$strip>>>>>;
|
|
1256
|
+
}, z.core.$strip>, import("@orpc/server").Schema<{
|
|
1257
|
+
definitionId: string;
|
|
1258
|
+
name: string;
|
|
1259
|
+
icon: string;
|
|
1260
|
+
filters: unknown;
|
|
1261
|
+
sorts: unknown;
|
|
1262
|
+
columns: unknown;
|
|
1263
|
+
createdAt: Date;
|
|
1264
|
+
updatedAt: Date;
|
|
1265
|
+
scope: string;
|
|
1266
|
+
scopeId: string;
|
|
1267
|
+
id: string;
|
|
1268
|
+
}, {
|
|
1269
|
+
definitionId: string;
|
|
1270
|
+
name: string;
|
|
1271
|
+
icon: string;
|
|
1272
|
+
filters: unknown;
|
|
1273
|
+
sorts: unknown;
|
|
1274
|
+
columns: unknown;
|
|
1275
|
+
createdAt: Date;
|
|
1276
|
+
updatedAt: Date;
|
|
1277
|
+
scope: string;
|
|
1278
|
+
scopeId: string;
|
|
1279
|
+
id: string;
|
|
1280
|
+
}>, Record<never, never>, Record<never, never>>;
|
|
1281
|
+
delete: import("@orpc/server").DecoratedProcedure<import("@orpc/server").MergedInitialContext<import("@orpc/server").MergedInitialContext<{
|
|
1282
|
+
headers: Headers;
|
|
1283
|
+
} & Record<never, never>, {
|
|
1284
|
+
headers: Headers;
|
|
1285
|
+
} & Record<never, never>, {
|
|
1286
|
+
headers: Headers;
|
|
1287
|
+
}>, {
|
|
1288
|
+
headers: Headers;
|
|
1289
|
+
user: {
|
|
1290
|
+
id: string;
|
|
1291
|
+
};
|
|
1292
|
+
scopeChain?: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
1293
|
+
} & Record<never, never>, import("@orpc/server").MergedCurrentContext<{
|
|
1294
|
+
headers: Headers;
|
|
1295
|
+
}, {
|
|
1296
|
+
headers: Headers;
|
|
1297
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
1298
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
1299
|
+
}>>, import("@orpc/server").MergedCurrentContext<import("@orpc/server").MergedCurrentContext<{
|
|
1300
|
+
headers: Headers;
|
|
1301
|
+
}, {
|
|
1302
|
+
headers: Headers;
|
|
1303
|
+
user: import("@ydtb/core-layer-auth").AuthUser;
|
|
1304
|
+
session: import("@ydtb/core-layer-auth").AuthSession;
|
|
1305
|
+
}>, {
|
|
1306
|
+
scopeId: string;
|
|
1307
|
+
scopeType: string;
|
|
1308
|
+
scopeChain: import("@ydtb/tk-scope-extension/orpc").ScopeChainEntry[];
|
|
1309
|
+
}>, z.ZodObject<{
|
|
1310
|
+
id: z.ZodString;
|
|
1311
|
+
}, z.core.$strip>, import("@orpc/server").Schema<{
|
|
1312
|
+
ok: boolean;
|
|
1313
|
+
}, {
|
|
1314
|
+
ok: boolean;
|
|
1315
|
+
}>, Record<never, never>, Record<never, never>>;
|
|
1316
|
+
};
|
|
451
1317
|
get: import("@orpc/server").DecoratedProcedure<import("@orpc/server").MergedInitialContext<import("@orpc/server").MergedInitialContext<{
|
|
452
1318
|
headers: Headers;
|
|
453
1319
|
} & Record<never, never>, {
|
|
@@ -570,6 +1436,7 @@ declare const captureRouter: {
|
|
|
570
1436
|
title: string;
|
|
571
1437
|
slug: string;
|
|
572
1438
|
fields: import("../../shared/types.ts").CaptureFieldDefinition[];
|
|
1439
|
+
document: CaptureFormDocument;
|
|
573
1440
|
security: {
|
|
574
1441
|
minSubmitSeconds: number | undefined;
|
|
575
1442
|
honeypotFieldName: string | undefined;
|
|
@@ -581,6 +1448,7 @@ declare const captureRouter: {
|
|
|
581
1448
|
title: string;
|
|
582
1449
|
slug: string;
|
|
583
1450
|
fields: import("../../shared/types.ts").CaptureFieldDefinition[];
|
|
1451
|
+
document: CaptureFormDocument;
|
|
584
1452
|
security: {
|
|
585
1453
|
minSubmitSeconds: number | undefined;
|
|
586
1454
|
honeypotFieldName: string | undefined;
|