@prismicio/editor-fields 0.4.52-jp-onboarding-guide-triggers.1 → 0.4.52-jp-onboarding-guide-triggers-highlight
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/EditorConfig.d.ts +15 -9
- package/dist/FieldContext.d.ts +27 -0
- package/dist/constants/framework.d.ts +5 -0
- package/dist/core/MediaLibrary/hooks/mediaLibraryData.d.ts +61 -61
- package/dist/core/MediaLibrary/hooks/tagData.d.ts +3 -3
- package/dist/core/MediaLibrary/hooks/useSelectedMedia.d.ts +6 -6
- package/dist/core/OnboardingGuide/OnboardingGuide.d.ts +4 -3
- package/dist/core/OnboardingGuide/components/OnboardingCard.d.ts +2 -2
- package/dist/core/OnboardingGuide/components/OnboardingProgressStepper.d.ts +2 -2
- package/dist/core/OnboardingGuide/components/OnboardingStepDialog.d.ts +4 -4
- package/dist/core/OnboardingGuide/content.d.ts +8 -1
- package/dist/core/OnboardingGuide/index.d.ts +1 -1
- package/dist/core/UnsplashLibrary/unsplashData.d.ts +18 -18
- package/dist/core/service/customType.d.ts +6 -6
- package/dist/core/service/repository.d.ts +1 -1
- package/dist/fields/IntegrationField/integrationData.d.ts +5 -5
- package/dist/fields/LinkField/useLinkField.d.ts +1 -1
- package/dist/index.cjs.js +33 -33
- package/dist/index.d.ts +2 -2
- package/dist/index.es.js +14268 -14191
- package/package.json +1 -1
package/dist/EditorConfig.d.ts
CHANGED
|
@@ -47,14 +47,14 @@ type IntegrationFields = {
|
|
|
47
47
|
integrationFieldsApiBaseUrl: URL;
|
|
48
48
|
repository: string;
|
|
49
49
|
};
|
|
50
|
-
|
|
51
|
-
/**
|
|
50
|
+
interface LayoutConfig {
|
|
51
|
+
/**
|
|
52
52
|
* Teaches fields about their containing scrolling element.
|
|
53
53
|
*/
|
|
54
54
|
scrollOffsetTop?: number;
|
|
55
55
|
}
|
|
56
|
-
|
|
57
|
-
(event: "Media Library Search", args: {
|
|
56
|
+
interface OnAnalyticsEvent {
|
|
57
|
+
(event: "Media Library Search", args: {
|
|
58
58
|
assetType: MediaAssetType;
|
|
59
59
|
mode: "browse" | "select";
|
|
60
60
|
searchQuery: string;
|
|
@@ -62,7 +62,7 @@ type OnAnalyticsEvent = {
|
|
|
62
62
|
numberOfResults: string;
|
|
63
63
|
timeToGetResults: string;
|
|
64
64
|
tags: string;
|
|
65
|
-
}): void;
|
|
65
|
+
}): void;
|
|
66
66
|
(event: "Media Added To Page", args: {
|
|
67
67
|
assetType: MediaAssetType;
|
|
68
68
|
searchQuery: string;
|
|
@@ -73,13 +73,19 @@ type OnAnalyticsEvent = {
|
|
|
73
73
|
timeToAddMediaToPage: string;
|
|
74
74
|
tags: string;
|
|
75
75
|
}): void;
|
|
76
|
+
(event: "Generic Link Added", args: {
|
|
77
|
+
type: "web" | "media" | "document";
|
|
78
|
+
isInSlice: string;
|
|
79
|
+
isInGroup: string;
|
|
80
|
+
customTypeFormat: "page" | "custom";
|
|
81
|
+
}): void;
|
|
76
82
|
(event: "Unsplash Image Searched" | "Unsplash Image Added"): void;
|
|
77
83
|
}
|
|
78
|
-
|
|
79
|
-
onAnalyticsEvent?: OnAnalyticsEvent;
|
|
84
|
+
interface Analytics {
|
|
85
|
+
onAnalyticsEvent?: OnAnalyticsEvent;
|
|
80
86
|
}
|
|
81
|
-
|
|
82
|
-
/** Asks the editor to track this Error in its Error monitoring solution. */
|
|
87
|
+
interface ErrorTracking {
|
|
88
|
+
/** Asks the editor to track this Error in its Error monitoring solution. */
|
|
83
89
|
onTrackError?: (error: Error) => void;
|
|
84
90
|
}
|
|
85
91
|
export type AuthStrategy = "cookie" | "token";
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import type { CustomType } from "@prismicio/types-internal/lib/customtypes";
|
|
2
|
+
import { type PropsWithChildren, type ReactNode } from "react";
|
|
3
|
+
type CustomTypeFormat = CustomType["format"];
|
|
4
|
+
interface FieldContextValue {
|
|
5
|
+
customTypeFormat: CustomTypeFormat;
|
|
6
|
+
isInSlice: boolean;
|
|
7
|
+
isInGroup: boolean;
|
|
8
|
+
}
|
|
9
|
+
interface RootFieldContextProviderProps {
|
|
10
|
+
customTypeFormat: CustomTypeFormat;
|
|
11
|
+
children: ReactNode;
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* Provides extra context to the fields below.
|
|
15
|
+
* Use it only once at the root of the fields tree.
|
|
16
|
+
*/
|
|
17
|
+
export declare function RootFieldContextProvider(props: RootFieldContextProviderProps): JSX.Element;
|
|
18
|
+
/**
|
|
19
|
+
* Overrides the field context to indicate that the field is in a slice.
|
|
20
|
+
*/
|
|
21
|
+
export declare function FieldInSliceContextProvider(props: PropsWithChildren): JSX.Element;
|
|
22
|
+
/**
|
|
23
|
+
* Overrides the field context to indicate that the field is in a group.
|
|
24
|
+
*/
|
|
25
|
+
export declare function FieldInGroupContextProvider(props: PropsWithChildren): JSX.Element;
|
|
26
|
+
export declare function useFieldContext(): FieldContextValue | undefined;
|
|
27
|
+
export {};
|
|
@@ -4,3 +4,8 @@ export declare const frameworkLabels: {
|
|
|
4
4
|
readonly sveltekit: "SvelteKit";
|
|
5
5
|
readonly other: "Other";
|
|
6
6
|
};
|
|
7
|
+
export declare const frameworkCreateProjectCodeSnippet: {
|
|
8
|
+
readonly next: "npx create-next-app@latest";
|
|
9
|
+
readonly nuxt: "npx nuxi@latest init";
|
|
10
|
+
readonly sveltekit: "npx sv create";
|
|
11
|
+
};
|
|
@@ -41,33 +41,33 @@ export declare const mediaAssetType: z.ZodObject<{
|
|
|
41
41
|
}, "strip", z.ZodTypeAny, {
|
|
42
42
|
id: string;
|
|
43
43
|
name: string;
|
|
44
|
-
created_at: number;
|
|
45
44
|
last_modified: number;
|
|
45
|
+
created_at: number;
|
|
46
46
|
count: number;
|
|
47
47
|
uploader_id?: string | undefined;
|
|
48
48
|
}, {
|
|
49
49
|
id: string;
|
|
50
50
|
name: string;
|
|
51
|
-
created_at: number;
|
|
52
51
|
last_modified: number;
|
|
52
|
+
created_at: number;
|
|
53
53
|
uploader_id?: string | undefined;
|
|
54
54
|
count?: number | undefined;
|
|
55
55
|
}>, "many">;
|
|
56
56
|
}, "strip", z.ZodTypeAny, {
|
|
57
|
+
id: string;
|
|
58
|
+
kind: string;
|
|
59
|
+
url: string;
|
|
60
|
+
size: number;
|
|
57
61
|
tags: {
|
|
58
62
|
id: string;
|
|
59
63
|
name: string;
|
|
60
|
-
created_at: number;
|
|
61
64
|
last_modified: number;
|
|
65
|
+
created_at: number;
|
|
62
66
|
count: number;
|
|
63
67
|
uploader_id?: string | undefined;
|
|
64
68
|
}[];
|
|
65
|
-
id: string;
|
|
66
|
-
url: string;
|
|
67
|
-
size: number;
|
|
68
|
-
kind: string;
|
|
69
|
-
last_modified: number;
|
|
70
69
|
filename: string;
|
|
70
|
+
last_modified: number;
|
|
71
71
|
extension?: string | undefined;
|
|
72
72
|
width?: number | undefined;
|
|
73
73
|
height?: number | undefined;
|
|
@@ -82,20 +82,20 @@ export declare const mediaAssetType: z.ZodObject<{
|
|
|
82
82
|
credits?: string | undefined;
|
|
83
83
|
} | undefined;
|
|
84
84
|
}, {
|
|
85
|
+
id: string;
|
|
86
|
+
kind: string;
|
|
87
|
+
url: string;
|
|
88
|
+
size: number;
|
|
85
89
|
tags: {
|
|
86
90
|
id: string;
|
|
87
91
|
name: string;
|
|
88
|
-
created_at: number;
|
|
89
92
|
last_modified: number;
|
|
93
|
+
created_at: number;
|
|
90
94
|
uploader_id?: string | undefined;
|
|
91
95
|
count?: number | undefined;
|
|
92
96
|
}[];
|
|
93
|
-
id: string;
|
|
94
|
-
url: string;
|
|
95
|
-
size: number;
|
|
96
|
-
kind: string;
|
|
97
|
-
last_modified: number;
|
|
98
97
|
filename: string;
|
|
98
|
+
last_modified: number;
|
|
99
99
|
extension?: string | undefined;
|
|
100
100
|
width?: number | undefined;
|
|
101
101
|
height?: number | undefined;
|
|
@@ -156,33 +156,33 @@ export declare const mediaSearchResponse: z.ZodObject<{
|
|
|
156
156
|
}, "strip", z.ZodTypeAny, {
|
|
157
157
|
id: string;
|
|
158
158
|
name: string;
|
|
159
|
-
created_at: number;
|
|
160
159
|
last_modified: number;
|
|
160
|
+
created_at: number;
|
|
161
161
|
count: number;
|
|
162
162
|
uploader_id?: string | undefined;
|
|
163
163
|
}, {
|
|
164
164
|
id: string;
|
|
165
165
|
name: string;
|
|
166
|
-
created_at: number;
|
|
167
166
|
last_modified: number;
|
|
167
|
+
created_at: number;
|
|
168
168
|
uploader_id?: string | undefined;
|
|
169
169
|
count?: number | undefined;
|
|
170
170
|
}>, "many">;
|
|
171
171
|
}, "strip", z.ZodTypeAny, {
|
|
172
|
+
id: string;
|
|
173
|
+
kind: string;
|
|
174
|
+
url: string;
|
|
175
|
+
size: number;
|
|
172
176
|
tags: {
|
|
173
177
|
id: string;
|
|
174
178
|
name: string;
|
|
175
|
-
created_at: number;
|
|
176
179
|
last_modified: number;
|
|
180
|
+
created_at: number;
|
|
177
181
|
count: number;
|
|
178
182
|
uploader_id?: string | undefined;
|
|
179
183
|
}[];
|
|
180
|
-
id: string;
|
|
181
|
-
url: string;
|
|
182
|
-
size: number;
|
|
183
|
-
kind: string;
|
|
184
|
-
last_modified: number;
|
|
185
184
|
filename: string;
|
|
185
|
+
last_modified: number;
|
|
186
186
|
extension?: string | undefined;
|
|
187
187
|
width?: number | undefined;
|
|
188
188
|
height?: number | undefined;
|
|
@@ -197,20 +197,20 @@ export declare const mediaSearchResponse: z.ZodObject<{
|
|
|
197
197
|
credits?: string | undefined;
|
|
198
198
|
} | undefined;
|
|
199
199
|
}, {
|
|
200
|
+
id: string;
|
|
201
|
+
kind: string;
|
|
202
|
+
url: string;
|
|
203
|
+
size: number;
|
|
200
204
|
tags: {
|
|
201
205
|
id: string;
|
|
202
206
|
name: string;
|
|
203
|
-
created_at: number;
|
|
204
207
|
last_modified: number;
|
|
208
|
+
created_at: number;
|
|
205
209
|
uploader_id?: string | undefined;
|
|
206
210
|
count?: number | undefined;
|
|
207
211
|
}[];
|
|
208
|
-
id: string;
|
|
209
|
-
url: string;
|
|
210
|
-
size: number;
|
|
211
|
-
kind: string;
|
|
212
|
-
last_modified: number;
|
|
213
212
|
filename: string;
|
|
213
|
+
last_modified: number;
|
|
214
214
|
extension?: string | undefined;
|
|
215
215
|
width?: number | undefined;
|
|
216
216
|
height?: number | undefined;
|
|
@@ -226,22 +226,21 @@ export declare const mediaSearchResponse: z.ZodObject<{
|
|
|
226
226
|
} | undefined;
|
|
227
227
|
}>, "many">;
|
|
228
228
|
}, "strip", z.ZodTypeAny, {
|
|
229
|
-
total: number;
|
|
230
229
|
items: {
|
|
230
|
+
id: string;
|
|
231
|
+
kind: string;
|
|
232
|
+
url: string;
|
|
233
|
+
size: number;
|
|
231
234
|
tags: {
|
|
232
235
|
id: string;
|
|
233
236
|
name: string;
|
|
234
|
-
created_at: number;
|
|
235
237
|
last_modified: number;
|
|
238
|
+
created_at: number;
|
|
236
239
|
count: number;
|
|
237
240
|
uploader_id?: string | undefined;
|
|
238
241
|
}[];
|
|
239
|
-
id: string;
|
|
240
|
-
url: string;
|
|
241
|
-
size: number;
|
|
242
|
-
kind: string;
|
|
243
|
-
last_modified: number;
|
|
244
242
|
filename: string;
|
|
243
|
+
last_modified: number;
|
|
245
244
|
extension?: string | undefined;
|
|
246
245
|
width?: number | undefined;
|
|
247
246
|
height?: number | undefined;
|
|
@@ -256,24 +255,24 @@ export declare const mediaSearchResponse: z.ZodObject<{
|
|
|
256
255
|
credits?: string | undefined;
|
|
257
256
|
} | undefined;
|
|
258
257
|
}[];
|
|
258
|
+
total: number;
|
|
259
259
|
cursor?: string | undefined;
|
|
260
260
|
}, {
|
|
261
|
-
total: number;
|
|
262
261
|
items: {
|
|
262
|
+
id: string;
|
|
263
|
+
kind: string;
|
|
264
|
+
url: string;
|
|
265
|
+
size: number;
|
|
263
266
|
tags: {
|
|
264
267
|
id: string;
|
|
265
268
|
name: string;
|
|
266
|
-
created_at: number;
|
|
267
269
|
last_modified: number;
|
|
270
|
+
created_at: number;
|
|
268
271
|
uploader_id?: string | undefined;
|
|
269
272
|
count?: number | undefined;
|
|
270
273
|
}[];
|
|
271
|
-
id: string;
|
|
272
|
-
url: string;
|
|
273
|
-
size: number;
|
|
274
|
-
kind: string;
|
|
275
|
-
last_modified: number;
|
|
276
274
|
filename: string;
|
|
275
|
+
last_modified: number;
|
|
277
276
|
extension?: string | undefined;
|
|
278
277
|
width?: number | undefined;
|
|
279
278
|
height?: number | undefined;
|
|
@@ -288,6 +287,7 @@ export declare const mediaSearchResponse: z.ZodObject<{
|
|
|
288
287
|
credits?: string[] | undefined;
|
|
289
288
|
} | undefined;
|
|
290
289
|
}[];
|
|
290
|
+
total: number;
|
|
291
291
|
cursor?: string | undefined;
|
|
292
292
|
}>;
|
|
293
293
|
export type MediaAsset = z.TypeOf<typeof mediaAssetType>;
|
|
@@ -306,22 +306,21 @@ export declare function searchMedia(baseUrl: URL | undefined, repository: string
|
|
|
306
306
|
uploaderId: string | undefined;
|
|
307
307
|
tags: string;
|
|
308
308
|
page: number;
|
|
309
|
-
total: number;
|
|
310
309
|
items: {
|
|
310
|
+
id: string;
|
|
311
|
+
kind: string;
|
|
312
|
+
url: string;
|
|
313
|
+
size: number;
|
|
311
314
|
tags: {
|
|
312
315
|
id: string;
|
|
313
316
|
name: string;
|
|
314
|
-
created_at: number;
|
|
315
317
|
last_modified: number;
|
|
318
|
+
created_at: number;
|
|
316
319
|
count: number;
|
|
317
320
|
uploader_id?: string | undefined;
|
|
318
321
|
}[];
|
|
319
|
-
id: string;
|
|
320
|
-
url: string;
|
|
321
|
-
size: number;
|
|
322
|
-
kind: string;
|
|
323
|
-
last_modified: number;
|
|
324
322
|
filename: string;
|
|
323
|
+
last_modified: number;
|
|
325
324
|
extension?: string | undefined;
|
|
326
325
|
width?: number | undefined;
|
|
327
326
|
height?: number | undefined;
|
|
@@ -336,6 +335,7 @@ export declare function searchMedia(baseUrl: URL | undefined, repository: string
|
|
|
336
335
|
credits?: string | undefined;
|
|
337
336
|
} | undefined;
|
|
338
337
|
}[];
|
|
338
|
+
total: number;
|
|
339
339
|
cursor?: string | undefined;
|
|
340
340
|
}>;
|
|
341
341
|
interface UseMediaLibrarySearchArgs {
|
|
@@ -357,20 +357,20 @@ export declare function useMediaSearch(args: UseMediaLibrarySearchArgs): {
|
|
|
357
357
|
setFilters: (filters: Partial<MediaLibraryFilters>) => void;
|
|
358
358
|
resetFilters: () => void;
|
|
359
359
|
media: {
|
|
360
|
+
id: string;
|
|
361
|
+
kind: string;
|
|
362
|
+
url: string;
|
|
363
|
+
size: number;
|
|
360
364
|
tags: {
|
|
361
365
|
id: string;
|
|
362
366
|
name: string;
|
|
363
|
-
created_at: number;
|
|
364
367
|
last_modified: number;
|
|
368
|
+
created_at: number;
|
|
365
369
|
count: number;
|
|
366
370
|
uploader_id?: string | undefined;
|
|
367
371
|
}[];
|
|
368
|
-
id: string;
|
|
369
|
-
url: string;
|
|
370
|
-
size: number;
|
|
371
|
-
kind: string;
|
|
372
|
-
last_modified: number;
|
|
373
372
|
filename: string;
|
|
373
|
+
last_modified: number;
|
|
374
374
|
extension?: string | undefined;
|
|
375
375
|
width?: number | undefined;
|
|
376
376
|
height?: number | undefined;
|
|
@@ -407,20 +407,20 @@ declare function deleteMedia(mediaIds: string[]): void;
|
|
|
407
407
|
declare function deleteSearchData(args: MediaLibraryFilters): void;
|
|
408
408
|
type MediaPage = Awaited<ReturnType<typeof searchMedia>>;
|
|
409
409
|
export declare function getMedia(allPages: MediaPage[], keyword: string, assetType: MediaAssetType, uploaderId: string | undefined, tags: string): {
|
|
410
|
+
id: string;
|
|
411
|
+
kind: string;
|
|
412
|
+
url: string;
|
|
413
|
+
size: number;
|
|
410
414
|
tags: {
|
|
411
415
|
id: string;
|
|
412
416
|
name: string;
|
|
413
|
-
created_at: number;
|
|
414
417
|
last_modified: number;
|
|
418
|
+
created_at: number;
|
|
415
419
|
count: number;
|
|
416
420
|
uploader_id?: string | undefined;
|
|
417
421
|
}[];
|
|
418
|
-
id: string;
|
|
419
|
-
url: string;
|
|
420
|
-
size: number;
|
|
421
|
-
kind: string;
|
|
422
|
-
last_modified: number;
|
|
423
422
|
filename: string;
|
|
423
|
+
last_modified: number;
|
|
424
424
|
extension?: string | undefined;
|
|
425
425
|
width?: number | undefined;
|
|
426
426
|
height?: number | undefined;
|
|
@@ -3,8 +3,8 @@ export declare function useTagSearch(): {
|
|
|
3
3
|
tags: {
|
|
4
4
|
id: string;
|
|
5
5
|
name: string;
|
|
6
|
-
created_at: number;
|
|
7
6
|
last_modified: number;
|
|
7
|
+
created_at: number;
|
|
8
8
|
count: number;
|
|
9
9
|
uploader_id?: string | undefined;
|
|
10
10
|
}[];
|
|
@@ -22,15 +22,15 @@ export declare const tagSchema: z.ZodObject<{
|
|
|
22
22
|
}, "strip", z.ZodTypeAny, {
|
|
23
23
|
id: string;
|
|
24
24
|
name: string;
|
|
25
|
-
created_at: number;
|
|
26
25
|
last_modified: number;
|
|
26
|
+
created_at: number;
|
|
27
27
|
count: number;
|
|
28
28
|
uploader_id?: string | undefined;
|
|
29
29
|
}, {
|
|
30
30
|
id: string;
|
|
31
31
|
name: string;
|
|
32
|
-
created_at: number;
|
|
33
32
|
last_modified: number;
|
|
33
|
+
created_at: number;
|
|
34
34
|
uploader_id?: string | undefined;
|
|
35
35
|
count?: number | undefined;
|
|
36
36
|
}>;
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
export declare function useSelectedMedia(): {
|
|
2
|
+
id: string;
|
|
3
|
+
kind: string;
|
|
4
|
+
url: string;
|
|
5
|
+
size: number;
|
|
2
6
|
tags: {
|
|
3
7
|
id: string;
|
|
4
8
|
name: string;
|
|
5
|
-
created_at: number;
|
|
6
9
|
last_modified: number;
|
|
10
|
+
created_at: number;
|
|
7
11
|
count: number;
|
|
8
12
|
uploader_id?: string | undefined;
|
|
9
13
|
}[];
|
|
10
|
-
id: string;
|
|
11
|
-
url: string;
|
|
12
|
-
size: number;
|
|
13
|
-
kind: string;
|
|
14
|
-
last_modified: number;
|
|
15
14
|
filename: string;
|
|
15
|
+
last_modified: number;
|
|
16
16
|
extension?: string | undefined;
|
|
17
17
|
width?: number | undefined;
|
|
18
18
|
height?: number | undefined;
|
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
import { type ReactNode } from "react";
|
|
2
2
|
import type { OnboardingState, OnboardingStepId, OnboardingTracking } from "../service";
|
|
3
|
-
interface OnboardingGuideProps {
|
|
3
|
+
export interface OnboardingGuideProps {
|
|
4
4
|
onboardingState: OnboardingState;
|
|
5
5
|
tracking: OnboardingTracking;
|
|
6
6
|
onToggleStep: (stepId: OnboardingStepId) => Promise<string[]>;
|
|
7
7
|
onToggleGuide: () => Promise<void>;
|
|
8
8
|
fallback?: ReactNode;
|
|
9
9
|
/** This allows consumers of the onboarding to do something else for certain steps other than opening the modal. */
|
|
10
|
-
|
|
10
|
+
stepOverrides?: Partial<Record<OnboardingStepId, () => void>>;
|
|
11
|
+
repositoryName?: string;
|
|
12
|
+
projectName?: string;
|
|
11
13
|
}
|
|
12
14
|
export declare function OnboardingGuide(props: OnboardingGuideProps): JSX.Element | null;
|
|
13
|
-
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
/// <reference types="react" />
|
|
2
2
|
import type { OnboardingStep, OnboardingStepId, OnboardingTracking } from "../../service";
|
|
3
3
|
interface OnboardingCardProps {
|
|
4
4
|
steps: OnboardingStep[];
|
|
@@ -7,7 +7,7 @@ interface OnboardingCardProps {
|
|
|
7
7
|
tracking: OnboardingTracking;
|
|
8
8
|
onToggleStep: (step: OnboardingStep) => Promise<void>;
|
|
9
9
|
onClose?: () => void;
|
|
10
|
-
|
|
10
|
+
stepOverrides?: Partial<Record<OnboardingStepId, () => void>>;
|
|
11
11
|
}
|
|
12
12
|
export declare function OnboardingCard(props: OnboardingCardProps): JSX.Element;
|
|
13
13
|
export {};
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
|
|
1
|
+
/// <reference types="react" />
|
|
2
2
|
import type { OnboardingStep, OnboardingStepId, OnboardingTracking } from "../../service";
|
|
3
3
|
interface OnboardingProgressStepperProps {
|
|
4
4
|
steps: OnboardingStep[];
|
|
5
5
|
completedSteps: string[];
|
|
6
6
|
onToggleStep: (step: OnboardingStep) => Promise<void>;
|
|
7
7
|
tracking: OnboardingTracking;
|
|
8
|
-
|
|
8
|
+
stepOverrides?: Partial<Record<OnboardingStepId, () => void>>;
|
|
9
9
|
}
|
|
10
10
|
export declare function OnboardingProgressStepper(props: OnboardingProgressStepperProps): JSX.Element | null;
|
|
11
11
|
export {};
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { type
|
|
2
|
-
import type { OnboardingStep
|
|
1
|
+
import { type RefObject } from "react";
|
|
2
|
+
import type { OnboardingStep } from "../../service";
|
|
3
3
|
interface OnboardingStepDialogProps {
|
|
4
4
|
isOpen: boolean;
|
|
5
5
|
step: OnboardingStep;
|
|
6
6
|
stepIndex: number;
|
|
7
7
|
isStepComplete: boolean;
|
|
8
|
-
onActionClick: () => Promise<void>;
|
|
8
|
+
onActionClick: (isUndo?: boolean) => Promise<void>;
|
|
9
9
|
onClose: () => void;
|
|
10
|
-
|
|
10
|
+
contentRef: RefObject<HTMLDivElement>;
|
|
11
11
|
}
|
|
12
12
|
export declare function OnboardingStepDialog(props: OnboardingStepDialogProps): JSX.Element;
|
|
13
13
|
export {};
|
|
@@ -1,6 +1,13 @@
|
|
|
1
1
|
import type { OnboardingFramework, OnboardingStep } from "../service/onboarding";
|
|
2
|
-
|
|
2
|
+
type Context = {
|
|
3
|
+
framework?: OnboardingFramework;
|
|
4
|
+
starter?: string | null;
|
|
5
|
+
repositoryName?: string;
|
|
6
|
+
projectName?: string;
|
|
7
|
+
};
|
|
8
|
+
export declare function getOnboardingContent(context: Context): {
|
|
3
9
|
steps: OnboardingStep[];
|
|
4
10
|
defaultCompletedStepIds: ("createPrismicProject" | "chooseLocale" | "createProject" | "setupSliceMachine" | "createPageType" | "codePage" | "createSlice" | "reviewAndPush" | "createContent" | "renderPage")[];
|
|
5
11
|
tutorialLink: string | undefined;
|
|
6
12
|
};
|
|
13
|
+
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { OnboardingGuide } from "./OnboardingGuide";
|
|
1
|
+
export { OnboardingGuide, type OnboardingGuideProps } from "./OnboardingGuide";
|
|
@@ -17,9 +17,9 @@ declare const unsplashImage: import("zod").ZodObject<{
|
|
|
17
17
|
description: import("zod").ZodNullable<import("zod").ZodString>;
|
|
18
18
|
}, "strip", import("zod").ZodTypeAny, {
|
|
19
19
|
id: string;
|
|
20
|
-
description: string | null;
|
|
21
|
-
width: number;
|
|
22
20
|
height: number;
|
|
21
|
+
width: number;
|
|
22
|
+
description: string | null;
|
|
23
23
|
urls: {
|
|
24
24
|
small: string;
|
|
25
25
|
full: string;
|
|
@@ -27,9 +27,9 @@ declare const unsplashImage: import("zod").ZodObject<{
|
|
|
27
27
|
alt_description?: string | undefined;
|
|
28
28
|
}, {
|
|
29
29
|
id: string;
|
|
30
|
-
description: string | null;
|
|
31
|
-
width: number;
|
|
32
30
|
height: number;
|
|
31
|
+
width: number;
|
|
32
|
+
description: string | null;
|
|
33
33
|
urls: {
|
|
34
34
|
small: string;
|
|
35
35
|
full: string;
|
|
@@ -55,9 +55,9 @@ export declare const unsplashSearchApiType: import("zod").ZodEffects<import("zod
|
|
|
55
55
|
description: import("zod").ZodNullable<import("zod").ZodString>;
|
|
56
56
|
}, "strip", import("zod").ZodTypeAny, {
|
|
57
57
|
id: string;
|
|
58
|
-
description: string | null;
|
|
59
|
-
width: number;
|
|
60
58
|
height: number;
|
|
59
|
+
width: number;
|
|
60
|
+
description: string | null;
|
|
61
61
|
urls: {
|
|
62
62
|
small: string;
|
|
63
63
|
full: string;
|
|
@@ -65,9 +65,9 @@ export declare const unsplashSearchApiType: import("zod").ZodEffects<import("zod
|
|
|
65
65
|
alt_description?: string | undefined;
|
|
66
66
|
}, {
|
|
67
67
|
id: string;
|
|
68
|
-
description: string | null;
|
|
69
|
-
width: number;
|
|
70
68
|
height: number;
|
|
69
|
+
width: number;
|
|
70
|
+
description: string | null;
|
|
71
71
|
urls: {
|
|
72
72
|
small: string;
|
|
73
73
|
full: string;
|
|
@@ -77,9 +77,9 @@ export declare const unsplashSearchApiType: import("zod").ZodEffects<import("zod
|
|
|
77
77
|
}, "strip", import("zod").ZodTypeAny, {
|
|
78
78
|
results: {
|
|
79
79
|
id: string;
|
|
80
|
-
description: string | null;
|
|
81
|
-
width: number;
|
|
82
80
|
height: number;
|
|
81
|
+
width: number;
|
|
82
|
+
description: string | null;
|
|
83
83
|
urls: {
|
|
84
84
|
small: string;
|
|
85
85
|
full: string;
|
|
@@ -89,9 +89,9 @@ export declare const unsplashSearchApiType: import("zod").ZodEffects<import("zod
|
|
|
89
89
|
}, {
|
|
90
90
|
results: {
|
|
91
91
|
id: string;
|
|
92
|
-
description: string | null;
|
|
93
|
-
width: number;
|
|
94
92
|
height: number;
|
|
93
|
+
width: number;
|
|
94
|
+
description: string | null;
|
|
95
95
|
urls: {
|
|
96
96
|
small: string;
|
|
97
97
|
full: string;
|
|
@@ -100,9 +100,9 @@ export declare const unsplashSearchApiType: import("zod").ZodEffects<import("zod
|
|
|
100
100
|
}[];
|
|
101
101
|
}>, {
|
|
102
102
|
id: string;
|
|
103
|
-
description: string | null;
|
|
104
|
-
width: number;
|
|
105
103
|
height: number;
|
|
104
|
+
width: number;
|
|
105
|
+
description: string | null;
|
|
106
106
|
urls: {
|
|
107
107
|
small: string;
|
|
108
108
|
full: string;
|
|
@@ -111,9 +111,9 @@ export declare const unsplashSearchApiType: import("zod").ZodEffects<import("zod
|
|
|
111
111
|
}[], {
|
|
112
112
|
results: {
|
|
113
113
|
id: string;
|
|
114
|
-
description: string | null;
|
|
115
|
-
width: number;
|
|
116
114
|
height: number;
|
|
115
|
+
width: number;
|
|
116
|
+
description: string | null;
|
|
117
117
|
urls: {
|
|
118
118
|
small: string;
|
|
119
119
|
full: string;
|
|
@@ -125,9 +125,9 @@ export type UnplashSearchApi = TypeOf<typeof unsplashSearchApiType>;
|
|
|
125
125
|
export type UnsplashImage = TypeOf<typeof unsplashImage>;
|
|
126
126
|
export declare function useUnsplashSearch(baseUrl: URL, term: string): {
|
|
127
127
|
id: string;
|
|
128
|
-
description: string | null;
|
|
129
|
-
width: number;
|
|
130
128
|
height: number;
|
|
129
|
+
width: number;
|
|
130
|
+
description: string | null;
|
|
131
131
|
urls: {
|
|
132
132
|
small: string;
|
|
133
133
|
full: string;
|
|
@@ -6,21 +6,21 @@ declare const customTypeResponse: z.ZodObject<{
|
|
|
6
6
|
repeatable: z.ZodBoolean;
|
|
7
7
|
status: z.ZodBoolean;
|
|
8
8
|
}, "strip", z.ZodTypeAny, {
|
|
9
|
-
label: string;
|
|
10
9
|
id: string;
|
|
11
|
-
|
|
10
|
+
label: string;
|
|
12
11
|
repeatable: boolean;
|
|
12
|
+
status: boolean;
|
|
13
13
|
}, {
|
|
14
|
-
label: string;
|
|
15
14
|
id: string;
|
|
16
|
-
|
|
15
|
+
label: string;
|
|
17
16
|
repeatable: boolean;
|
|
17
|
+
status: boolean;
|
|
18
18
|
}>;
|
|
19
19
|
export type CustomTypeResponse = z.TypeOf<typeof customTypeResponse>;
|
|
20
20
|
export declare function getRepositoryCustomTypes(baseUrl: URL, repository: string, authStrategy: AuthStrategy): Promise<{
|
|
21
|
-
label: string;
|
|
22
21
|
id: string;
|
|
23
|
-
|
|
22
|
+
label: string;
|
|
24
23
|
repeatable: boolean;
|
|
24
|
+
status: boolean;
|
|
25
25
|
}[]>;
|
|
26
26
|
export {};
|
|
@@ -93,6 +93,7 @@ declare const repositorySchema: z.ZodEffects<z.ZodObject<{
|
|
|
93
93
|
}>;
|
|
94
94
|
uploadedAvatar: z.ZodOptional<z.ZodString>;
|
|
95
95
|
}, "strip", z.ZodTypeAny, {
|
|
96
|
+
framework: "next" | "nuxt" | "sveltekit" | "other";
|
|
96
97
|
authors: {
|
|
97
98
|
id: string;
|
|
98
99
|
email: string;
|
|
@@ -108,7 +109,6 @@ declare const repositorySchema: z.ZodEffects<z.ZodObject<{
|
|
|
108
109
|
quotas: {
|
|
109
110
|
slicemachineEnabled: boolean;
|
|
110
111
|
};
|
|
111
|
-
framework: "next" | "nuxt" | "sveltekit" | "other";
|
|
112
112
|
storageVersion: {
|
|
113
113
|
major: number;
|
|
114
114
|
minor: number;
|