@orion-studios/payload-studio 0.5.0-beta.98 → 0.6.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +58 -68
- package/dist/admin/client.d.mts +5 -0
- package/dist/admin/client.d.ts +5 -0
- package/dist/admin/client.js +4491 -736
- package/dist/admin/client.mjs +3367 -752
- package/dist/admin/index.d.mts +2 -1
- package/dist/admin/index.d.ts +2 -1
- package/dist/admin/index.js +498 -53
- package/dist/admin/index.mjs +2 -1
- package/dist/admin-app/client.d.mts +1 -0
- package/dist/admin-app/client.d.ts +1 -0
- package/dist/admin-app/client.js +285 -109
- package/dist/admin-app/client.mjs +59 -871
- package/dist/admin-app/index.d.mts +2 -1
- package/dist/admin-app/index.d.ts +2 -1
- package/dist/admin-app/index.mjs +5 -3
- package/dist/admin-app/styles.css +1708 -56
- package/dist/admin.css +158 -35
- package/dist/blocks/index.js +415 -200
- package/dist/blocks/index.mjs +2 -2
- package/dist/{chunk-XK3K5GRP.mjs → chunk-JQAHXYAM.mjs} +271 -67
- package/dist/chunk-KPIX7OSV.mjs +1051 -0
- package/dist/chunk-OQSEJXC4.mjs +166 -0
- package/dist/{chunk-XHWQJUX5.mjs → chunk-OTHERBGX.mjs} +3 -3
- package/dist/chunk-PF3EBZXF.mjs +326 -0
- package/dist/chunk-Q2HGC67S.mjs +904 -0
- package/dist/{chunk-XVH5SCBD.mjs → chunk-RKTIFEUY.mjs} +4 -19
- package/dist/chunk-W2UOCJDX.mjs +32 -0
- package/dist/{chunk-C4J35SPJ.mjs → chunk-XKUTZ7IU.mjs} +257 -452
- package/dist/{index-ZbOx4OCF.d.ts → index-52HdVLQq.d.ts} +12 -22
- package/dist/index-BMitiKK8.d.ts +435 -0
- package/dist/index-Crx_MtPw.d.ts +223 -0
- package/dist/index-Cv-6qnrw.d.mts +223 -0
- package/dist/{index-ZbOx4OCF.d.mts → index-DEQC3Dwj.d.mts} +12 -22
- package/dist/{index-BIwu3qIH.d.mts → index-DWmudwDm.d.mts} +2 -1
- package/dist/{index-BIwu3qIH.d.ts → index-DWmudwDm.d.ts} +2 -1
- package/dist/index-D_b24Gef.d.mts +435 -0
- package/dist/index.d.mts +5 -4
- package/dist/index.d.ts +5 -4
- package/dist/index.js +1968 -1198
- package/dist/index.mjs +10 -8
- package/dist/nextjs/index.js +5 -684
- package/dist/nextjs/index.mjs +2 -3
- package/dist/sitePreviewTypes-BkHCWxNW.d.mts +58 -0
- package/dist/sitePreviewTypes-BkHCWxNW.d.ts +58 -0
- package/dist/studio/index.d.mts +1 -1
- package/dist/studio/index.d.ts +1 -1
- package/dist/studio-pages/builder.css +125 -83
- package/dist/studio-pages/client.d.mts +58 -1
- package/dist/studio-pages/client.d.ts +58 -1
- package/dist/studio-pages/client.js +450 -241
- package/dist/studio-pages/client.mjs +455 -247
- package/dist/studio-pages/index.d.mts +3 -2
- package/dist/studio-pages/index.d.ts +3 -2
- package/dist/studio-pages/index.js +418 -183
- package/dist/studio-pages/index.mjs +15 -6
- package/package.json +19 -5
- package/dist/chunk-2FO2ROW4.mjs +0 -468
- package/dist/chunk-SIL2J5MF.mjs +0 -155
- package/dist/index-BFXZue5i.d.ts +0 -178
- package/dist/index-CoYRBbf6.d.mts +0 -178
- package/dist/index-R7hA134j.d.mts +0 -140
- package/dist/index-vjrjy0P4.d.ts +0 -140
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { FC } from 'react'
|
|
1
|
+
import type { ComponentType, CSSProperties, FC, ReactNode } from 'react'
|
|
2
2
|
import type {
|
|
3
3
|
BuilderBlockSettingsV2,
|
|
4
4
|
BuilderSettingsPanelMode,
|
|
@@ -18,15 +18,72 @@ export type SectionPreset = {
|
|
|
18
18
|
blocks: BuilderBlock[]
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
+
export type BuilderRenderWithSectionShell = (
|
|
22
|
+
block: {
|
|
23
|
+
blockType?: string
|
|
24
|
+
[key: string]: unknown
|
|
25
|
+
},
|
|
26
|
+
className: string,
|
|
27
|
+
content: ReactNode,
|
|
28
|
+
options?: {
|
|
29
|
+
inheritProjectStyles?: boolean
|
|
30
|
+
},
|
|
31
|
+
) => ReactNode
|
|
32
|
+
|
|
33
|
+
export type BuilderInlineTextComponentProps = {
|
|
34
|
+
as?: 'h1' | 'h2' | 'h3' | 'p' | 'span'
|
|
35
|
+
className?: string
|
|
36
|
+
multiline?: boolean
|
|
37
|
+
onCommit: (value: string) => void
|
|
38
|
+
placeholder?: string
|
|
39
|
+
style?: CSSProperties
|
|
40
|
+
value?: string
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
export type BuilderPreviewTextFieldOptions = Omit<
|
|
44
|
+
BuilderInlineTextComponentProps,
|
|
45
|
+
'onCommit' | 'value'
|
|
46
|
+
>
|
|
47
|
+
|
|
48
|
+
export type BuilderPreviewEditingHelpers = {
|
|
49
|
+
InlineText: ComponentType<BuilderInlineTextComponentProps>
|
|
50
|
+
readText: (value: unknown, fallback?: string) => string
|
|
51
|
+
updateArrayItemText: (
|
|
52
|
+
arrayField: string,
|
|
53
|
+
itemIndex: number,
|
|
54
|
+
fieldName: string,
|
|
55
|
+
value: string,
|
|
56
|
+
) => void
|
|
57
|
+
updateBlockText: (fieldName: string, value: string) => void
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
export type BuilderBlockPreviewRenderArgs = {
|
|
61
|
+
block: {
|
|
62
|
+
blockType?: string
|
|
63
|
+
[key: string]: unknown
|
|
64
|
+
}
|
|
65
|
+
editing: BuilderPreviewEditingHelpers
|
|
66
|
+
index: number
|
|
67
|
+
renderWithSectionShell: BuilderRenderWithSectionShell
|
|
68
|
+
resolvedThemeTokens: BuilderThemeTokens
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
export type BuilderBlockPreviewRenderer = (args: BuilderBlockPreviewRenderArgs) => ReactNode | null
|
|
72
|
+
|
|
21
73
|
export declare const BuilderPageEditor: FC<{
|
|
22
74
|
featureFlags?: {
|
|
23
75
|
settingsPanelV2?: boolean
|
|
24
76
|
}
|
|
25
77
|
initialDoc?: Record<string, unknown>
|
|
26
78
|
pageID: string
|
|
79
|
+
renderBlockPreview?: (args: BuilderBlockPreviewRenderArgs) => ReactNode | null
|
|
27
80
|
siteThemeTokens?: BuilderThemeTokenOverrides
|
|
28
81
|
}>
|
|
29
82
|
|
|
83
|
+
export declare const registerBuilderBlockPreviewRenderer: (
|
|
84
|
+
renderer: BuilderBlockPreviewRenderer | null,
|
|
85
|
+
) => void
|
|
86
|
+
|
|
30
87
|
export type {
|
|
31
88
|
BuilderBlockSettingsV2,
|
|
32
89
|
BuilderSettingsPanelMode,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { FC } from 'react'
|
|
1
|
+
import type { ComponentType, CSSProperties, FC, ReactNode } from 'react'
|
|
2
2
|
import type {
|
|
3
3
|
BuilderBlockSettingsV2,
|
|
4
4
|
BuilderSettingsPanelMode,
|
|
@@ -18,15 +18,72 @@ export type SectionPreset = {
|
|
|
18
18
|
blocks: BuilderBlock[]
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
+
export type BuilderRenderWithSectionShell = (
|
|
22
|
+
block: {
|
|
23
|
+
blockType?: string
|
|
24
|
+
[key: string]: unknown
|
|
25
|
+
},
|
|
26
|
+
className: string,
|
|
27
|
+
content: ReactNode,
|
|
28
|
+
options?: {
|
|
29
|
+
inheritProjectStyles?: boolean
|
|
30
|
+
},
|
|
31
|
+
) => ReactNode
|
|
32
|
+
|
|
33
|
+
export type BuilderInlineTextComponentProps = {
|
|
34
|
+
as?: 'h1' | 'h2' | 'h3' | 'p' | 'span'
|
|
35
|
+
className?: string
|
|
36
|
+
multiline?: boolean
|
|
37
|
+
onCommit: (value: string) => void
|
|
38
|
+
placeholder?: string
|
|
39
|
+
style?: CSSProperties
|
|
40
|
+
value?: string
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
export type BuilderPreviewTextFieldOptions = Omit<
|
|
44
|
+
BuilderInlineTextComponentProps,
|
|
45
|
+
'onCommit' | 'value'
|
|
46
|
+
>
|
|
47
|
+
|
|
48
|
+
export type BuilderPreviewEditingHelpers = {
|
|
49
|
+
InlineText: ComponentType<BuilderInlineTextComponentProps>
|
|
50
|
+
readText: (value: unknown, fallback?: string) => string
|
|
51
|
+
updateArrayItemText: (
|
|
52
|
+
arrayField: string,
|
|
53
|
+
itemIndex: number,
|
|
54
|
+
fieldName: string,
|
|
55
|
+
value: string,
|
|
56
|
+
) => void
|
|
57
|
+
updateBlockText: (fieldName: string, value: string) => void
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
export type BuilderBlockPreviewRenderArgs = {
|
|
61
|
+
block: {
|
|
62
|
+
blockType?: string
|
|
63
|
+
[key: string]: unknown
|
|
64
|
+
}
|
|
65
|
+
editing: BuilderPreviewEditingHelpers
|
|
66
|
+
index: number
|
|
67
|
+
renderWithSectionShell: BuilderRenderWithSectionShell
|
|
68
|
+
resolvedThemeTokens: BuilderThemeTokens
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
export type BuilderBlockPreviewRenderer = (args: BuilderBlockPreviewRenderArgs) => ReactNode | null
|
|
72
|
+
|
|
21
73
|
export declare const BuilderPageEditor: FC<{
|
|
22
74
|
featureFlags?: {
|
|
23
75
|
settingsPanelV2?: boolean
|
|
24
76
|
}
|
|
25
77
|
initialDoc?: Record<string, unknown>
|
|
26
78
|
pageID: string
|
|
79
|
+
renderBlockPreview?: (args: BuilderBlockPreviewRenderArgs) => ReactNode | null
|
|
27
80
|
siteThemeTokens?: BuilderThemeTokenOverrides
|
|
28
81
|
}>
|
|
29
82
|
|
|
83
|
+
export declare const registerBuilderBlockPreviewRenderer: (
|
|
84
|
+
renderer: BuilderBlockPreviewRenderer | null,
|
|
85
|
+
) => void
|
|
86
|
+
|
|
30
87
|
export type {
|
|
31
88
|
BuilderBlockSettingsV2,
|
|
32
89
|
BuilderSettingsPanelMode,
|