payload-canvas 0.6.3 → 0.6.4
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/LICENSE +21 -21
- package/README.md +6 -5
- package/dist/admin/aiKeyField.scss +58 -58
- package/dist/admin/diff/layoutDiff.scss +181 -181
- package/dist/admin/editor/assistant/assistant.scss +944 -944
- package/dist/admin/editor/classes/manager.scss +262 -262
- package/dist/admin/editor/comments/comments.scss +539 -539
- package/dist/admin/editor/dnd/dnd.scss +261 -261
- package/dist/admin/editor/editor.scss +2629 -2629
- package/dist/admin/editor/empty/empty.scss +92 -92
- package/dist/admin/editor/fields/fields.scss +778 -778
- package/dist/admin/editor/generate/generate.scss +276 -276
- package/dist/admin/editor/layout/layout.scss +240 -240
- package/dist/admin/editor/live/presence.scss +24 -24
- package/dist/admin/editor/locale/locale.scss +154 -154
- package/dist/admin/editor/media/media.scss +233 -233
- package/dist/admin/editor/menu/menu.scss +132 -132
- package/dist/admin/editor/motion/motion.scss +84 -84
- package/dist/admin/editor/sections/components.scss +238 -238
- package/dist/admin/editor/sections/variants.scss +90 -90
- package/dist/admin/editor/styles/ClassCss.js +3 -3
- package/dist/admin/editor/styles/classes.scss +381 -381
- package/dist/admin/editor/styles/styles.scss +1123 -1123
- package/dist/admin/editor/styles/tokens.js +2 -1
- package/dist/admin/editor/templates/templates.scss +654 -654
- package/dist/admin/editor/tooltip/tooltip.scss +39 -39
- package/dist/admin/editor/topbar/DocumentActions.js +1 -1
- package/dist/admin/editor/topbar/contentMode.scss +26 -26
- package/dist/admin/editor/topbar/screens/screens.scss +134 -134
- package/dist/admin/editor/topbar/settingsDrawer.scss +32 -32
- package/dist/admin/editor/topbar/topbar.scss +645 -645
- package/dist/admin/editor/ui/controls.scss +320 -320
- package/dist/admin/forms/submissions.scss +197 -197
- package/dist/admin/layoutField.scss +69 -69
- package/dist/admin/templateConditions.scss +24 -24
- package/dist/ai/prompt.js +40 -40
- package/dist/blocks/client/marquee.js +14 -14
- package/dist/blocks/payload.js +13 -3
- package/dist/core/responseError.d.ts +5 -0
- package/dist/core/responseError.js +8 -0
- package/dist/css/index.d.ts +6 -0
- package/dist/css/index.js +40 -1
- package/dist/css/shared.js +2 -2
- package/dist/live/session.js +18 -0
- package/dist/live/storage.d.ts +5 -0
- package/dist/live/storage.js +20 -0
- package/dist/mcp/shared.js +16 -16
- package/dist/plugin/index.d.ts +14 -1
- package/dist/plugin/index.js +46 -8
- package/dist/react/canvas/BuilderCanvas.js +4 -3
- package/dist/react/canvas/thumbnail/ThumbnailCanvas.js +2 -1
- package/dist/theme/admin/fields.scss +363 -363
- package/package.json +1 -1
|
@@ -1,238 +1,238 @@
|
|
|
1
|
-
// Components in the inspector: property buttons and chips in a saved section, the properties of a
|
|
2
|
-
// copy, and the component banner. Payload CSS variables only, inside Payload's own layer.
|
|
3
|
-
|
|
4
|
-
@layer payload-default {
|
|
5
|
-
// ---------------------------------------------------------------------------
|
|
6
|
-
// Properties in a saved section
|
|
7
|
-
// ---------------------------------------------------------------------------
|
|
8
|
-
|
|
9
|
-
.builder-prop {
|
|
10
|
-
display: flex;
|
|
11
|
-
flex-direction: column;
|
|
12
|
-
gap: 6px;
|
|
13
|
-
min-width: 0;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
// Next to a bind button, the property button moves one step in.
|
|
17
|
-
.builder-editor .builder-prop__button--offset {
|
|
18
|
-
right: 26px;
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
.builder-prop__chip {
|
|
22
|
-
display: flex;
|
|
23
|
-
align-items: center;
|
|
24
|
-
gap: 6px;
|
|
25
|
-
min-width: 0;
|
|
26
|
-
min-height: 28px;
|
|
27
|
-
padding: 2px 2px 2px 8px;
|
|
28
|
-
border: 1px solid color-mix(in srgb, var(--be-accent) 45%, transparent);
|
|
29
|
-
border-radius: var(--style-radius-s, 4px);
|
|
30
|
-
background: color-mix(in srgb, var(--be-accent) 10%, var(--theme-input-bg, var(--theme-elevation-0)));
|
|
31
|
-
color: var(--theme-text);
|
|
32
|
-
font-size: var(--be-text-m);
|
|
33
|
-
|
|
34
|
-
> svg:first-child {
|
|
35
|
-
flex: none;
|
|
36
|
-
color: var(--theme-success-600);
|
|
37
|
-
}
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
.builder-prop__chip-label {
|
|
41
|
-
min-width: 0;
|
|
42
|
-
overflow: hidden;
|
|
43
|
-
font-weight: var(--be-weight-medium);
|
|
44
|
-
text-overflow: ellipsis;
|
|
45
|
-
white-space: nowrap;
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
.builder-prop__chip-kind {
|
|
49
|
-
flex: 1;
|
|
50
|
-
color: var(--theme-elevation-500);
|
|
51
|
-
font-size: var(--be-text-s);
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
.builder-prop--visible {
|
|
55
|
-
padding-top: 10px;
|
|
56
|
-
border-top: 1px solid var(--theme-elevation-100);
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
.builder-prop__row-label {
|
|
60
|
-
color: var(--theme-elevation-800);
|
|
61
|
-
font-size: var(--be-text-m);
|
|
62
|
-
line-height: 22px;
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
.builder-prop__popover.builder-styles__popover {
|
|
66
|
-
width: 260px;
|
|
67
|
-
}
|
|
68
|
-
|
|
69
|
-
.builder-prop__form {
|
|
70
|
-
display: flex;
|
|
71
|
-
flex-direction: column;
|
|
72
|
-
gap: 8px;
|
|
73
|
-
padding: 12px;
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
.builder-prop__form-label {
|
|
77
|
-
color: var(--theme-elevation-800);
|
|
78
|
-
font-size: var(--be-text-m);
|
|
79
|
-
font-weight: var(--be-weight-medium);
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
.builder-prop__input {
|
|
83
|
-
width: 100%;
|
|
84
|
-
min-height: 32px;
|
|
85
|
-
padding: 4px 8px;
|
|
86
|
-
border: 1px solid var(--theme-elevation-150);
|
|
87
|
-
border-radius: var(--style-radius-s, 4px);
|
|
88
|
-
background: var(--theme-input-bg, var(--theme-elevation-0));
|
|
89
|
-
color: var(--theme-text);
|
|
90
|
-
font: inherit;
|
|
91
|
-
font-size: var(--be-text-m);
|
|
92
|
-
|
|
93
|
-
&:focus-visible {
|
|
94
|
-
border-color: var(--theme-elevation-400);
|
|
95
|
-
outline: 2px solid color-mix(in srgb, var(--be-accent) 40%, transparent);
|
|
96
|
-
outline-offset: 0;
|
|
97
|
-
}
|
|
98
|
-
|
|
99
|
-
&[aria-invalid='true'] {
|
|
100
|
-
border-color: var(--theme-error-500);
|
|
101
|
-
}
|
|
102
|
-
}
|
|
103
|
-
|
|
104
|
-
.builder-prop__error {
|
|
105
|
-
margin: 0;
|
|
106
|
-
color: var(--theme-error-500);
|
|
107
|
-
font-size: var(--be-text-s);
|
|
108
|
-
}
|
|
109
|
-
|
|
110
|
-
.builder-prop__submit,
|
|
111
|
-
.builder-comp__edit {
|
|
112
|
-
min-height: 30px;
|
|
113
|
-
padding: 4px 10px;
|
|
114
|
-
border: 1px solid var(--theme-elevation-150);
|
|
115
|
-
border-radius: var(--style-radius-s, 4px);
|
|
116
|
-
background: var(--theme-elevation-50);
|
|
117
|
-
color: var(--theme-text);
|
|
118
|
-
font: inherit;
|
|
119
|
-
font-size: var(--be-text-m);
|
|
120
|
-
font-weight: var(--be-weight-medium);
|
|
121
|
-
cursor: pointer;
|
|
122
|
-
|
|
123
|
-
&:hover {
|
|
124
|
-
border-color: var(--theme-elevation-250);
|
|
125
|
-
background: var(--theme-elevation-100);
|
|
126
|
-
}
|
|
127
|
-
|
|
128
|
-
&:focus-visible {
|
|
129
|
-
outline: 2px solid color-mix(in srgb, var(--be-accent) 40%, transparent);
|
|
130
|
-
outline-offset: 1px;
|
|
131
|
-
}
|
|
132
|
-
}
|
|
133
|
-
|
|
134
|
-
.builder-prop__submit {
|
|
135
|
-
align-self: flex-end;
|
|
136
|
-
}
|
|
137
|
-
|
|
138
|
-
// ---------------------------------------------------------------------------
|
|
139
|
-
// A copy: the component's properties
|
|
140
|
-
// ---------------------------------------------------------------------------
|
|
141
|
-
|
|
142
|
-
.builder-comp {
|
|
143
|
-
display: flex;
|
|
144
|
-
flex-direction: column;
|
|
145
|
-
gap: 12px;
|
|
146
|
-
padding: 12px var(--builder-inspector-pad, 12px) 16px;
|
|
147
|
-
border-top: 1px solid var(--theme-elevation-100);
|
|
148
|
-
}
|
|
149
|
-
|
|
150
|
-
.builder-comp__head {
|
|
151
|
-
display: flex;
|
|
152
|
-
align-items: center;
|
|
153
|
-
gap: 8px;
|
|
154
|
-
min-width: 0;
|
|
155
|
-
|
|
156
|
-
> svg {
|
|
157
|
-
flex: none;
|
|
158
|
-
color: var(--theme-success-600);
|
|
159
|
-
}
|
|
160
|
-
}
|
|
161
|
-
|
|
162
|
-
.builder-comp__title {
|
|
163
|
-
display: flex;
|
|
164
|
-
flex: 1;
|
|
165
|
-
flex-direction: column;
|
|
166
|
-
min-width: 0;
|
|
167
|
-
}
|
|
168
|
-
|
|
169
|
-
.builder-comp__name {
|
|
170
|
-
overflow: hidden;
|
|
171
|
-
font-size: var(--be-text-l);
|
|
172
|
-
font-weight: var(--be-weight-strong);
|
|
173
|
-
text-overflow: ellipsis;
|
|
174
|
-
white-space: nowrap;
|
|
175
|
-
}
|
|
176
|
-
|
|
177
|
-
.builder-comp__meta {
|
|
178
|
-
color: var(--theme-elevation-500);
|
|
179
|
-
font-size: var(--be-text-s);
|
|
180
|
-
}
|
|
181
|
-
|
|
182
|
-
.builder-comp__edit {
|
|
183
|
-
flex: none;
|
|
184
|
-
}
|
|
185
|
-
|
|
186
|
-
.builder-comp__missing {
|
|
187
|
-
display: flex;
|
|
188
|
-
align-items: flex-start;
|
|
189
|
-
gap: 8px;
|
|
190
|
-
margin: 12px var(--builder-inspector-pad, 12px);
|
|
191
|
-
padding: 8px 10px;
|
|
192
|
-
border-radius: var(--style-radius-m, 6px);
|
|
193
|
-
background: color-mix(in srgb, var(--theme-warning-500, var(--theme-error-500)) 12%, transparent);
|
|
194
|
-
color: var(--theme-elevation-800);
|
|
195
|
-
font-size: var(--be-text-m);
|
|
196
|
-
|
|
197
|
-
> svg {
|
|
198
|
-
flex: none;
|
|
199
|
-
margin-top: 2px;
|
|
200
|
-
color: var(--theme-warning-600, var(--theme-error-500));
|
|
201
|
-
}
|
|
202
|
-
}
|
|
203
|
-
|
|
204
|
-
// ---------------------------------------------------------------------------
|
|
205
|
-
// A saved section with properties: the banner on top of the inspector
|
|
206
|
-
// ---------------------------------------------------------------------------
|
|
207
|
-
|
|
208
|
-
.builder-comp__banner {
|
|
209
|
-
display: flex;
|
|
210
|
-
align-items: flex-start;
|
|
211
|
-
gap: 8px;
|
|
212
|
-
margin: 8px 8px 0;
|
|
213
|
-
padding: 8px 10px;
|
|
214
|
-
border-radius: var(--style-radius-m, 6px);
|
|
215
|
-
background: color-mix(in srgb, var(--be-accent) 10%, var(--theme-elevation-0));
|
|
216
|
-
color: var(--theme-elevation-800);
|
|
217
|
-
font-size: var(--be-text-m);
|
|
218
|
-
line-height: 1.45;
|
|
219
|
-
|
|
220
|
-
> svg {
|
|
221
|
-
flex: none;
|
|
222
|
-
margin-top: 2px;
|
|
223
|
-
color: var(--theme-success-600);
|
|
224
|
-
}
|
|
225
|
-
|
|
226
|
-
p {
|
|
227
|
-
margin: 0;
|
|
228
|
-
}
|
|
229
|
-
}
|
|
230
|
-
}
|
|
231
|
-
|
|
232
|
-
@layer payload-default {
|
|
233
|
-
.builder-editor__card-component {
|
|
234
|
-
margin-right: 4px;
|
|
235
|
-
color: var(--theme-success-600);
|
|
236
|
-
vertical-align: -1px;
|
|
237
|
-
}
|
|
238
|
-
}
|
|
1
|
+
// Components in the inspector: property buttons and chips in a saved section, the properties of a
|
|
2
|
+
// copy, and the component banner. Payload CSS variables only, inside Payload's own layer.
|
|
3
|
+
|
|
4
|
+
@layer payload-default {
|
|
5
|
+
// ---------------------------------------------------------------------------
|
|
6
|
+
// Properties in a saved section
|
|
7
|
+
// ---------------------------------------------------------------------------
|
|
8
|
+
|
|
9
|
+
.builder-prop {
|
|
10
|
+
display: flex;
|
|
11
|
+
flex-direction: column;
|
|
12
|
+
gap: 6px;
|
|
13
|
+
min-width: 0;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
// Next to a bind button, the property button moves one step in.
|
|
17
|
+
.builder-editor .builder-prop__button--offset {
|
|
18
|
+
right: 26px;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.builder-prop__chip {
|
|
22
|
+
display: flex;
|
|
23
|
+
align-items: center;
|
|
24
|
+
gap: 6px;
|
|
25
|
+
min-width: 0;
|
|
26
|
+
min-height: 28px;
|
|
27
|
+
padding: 2px 2px 2px 8px;
|
|
28
|
+
border: 1px solid color-mix(in srgb, var(--be-accent) 45%, transparent);
|
|
29
|
+
border-radius: var(--style-radius-s, 4px);
|
|
30
|
+
background: color-mix(in srgb, var(--be-accent) 10%, var(--theme-input-bg, var(--theme-elevation-0)));
|
|
31
|
+
color: var(--theme-text);
|
|
32
|
+
font-size: var(--be-text-m);
|
|
33
|
+
|
|
34
|
+
> svg:first-child {
|
|
35
|
+
flex: none;
|
|
36
|
+
color: var(--theme-success-600);
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
.builder-prop__chip-label {
|
|
41
|
+
min-width: 0;
|
|
42
|
+
overflow: hidden;
|
|
43
|
+
font-weight: var(--be-weight-medium);
|
|
44
|
+
text-overflow: ellipsis;
|
|
45
|
+
white-space: nowrap;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
.builder-prop__chip-kind {
|
|
49
|
+
flex: 1;
|
|
50
|
+
color: var(--theme-elevation-500);
|
|
51
|
+
font-size: var(--be-text-s);
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.builder-prop--visible {
|
|
55
|
+
padding-top: 10px;
|
|
56
|
+
border-top: 1px solid var(--theme-elevation-100);
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
.builder-prop__row-label {
|
|
60
|
+
color: var(--theme-elevation-800);
|
|
61
|
+
font-size: var(--be-text-m);
|
|
62
|
+
line-height: 22px;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
.builder-prop__popover.builder-styles__popover {
|
|
66
|
+
width: 260px;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
.builder-prop__form {
|
|
70
|
+
display: flex;
|
|
71
|
+
flex-direction: column;
|
|
72
|
+
gap: 8px;
|
|
73
|
+
padding: 12px;
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
.builder-prop__form-label {
|
|
77
|
+
color: var(--theme-elevation-800);
|
|
78
|
+
font-size: var(--be-text-m);
|
|
79
|
+
font-weight: var(--be-weight-medium);
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
.builder-prop__input {
|
|
83
|
+
width: 100%;
|
|
84
|
+
min-height: 32px;
|
|
85
|
+
padding: 4px 8px;
|
|
86
|
+
border: 1px solid var(--theme-elevation-150);
|
|
87
|
+
border-radius: var(--style-radius-s, 4px);
|
|
88
|
+
background: var(--theme-input-bg, var(--theme-elevation-0));
|
|
89
|
+
color: var(--theme-text);
|
|
90
|
+
font: inherit;
|
|
91
|
+
font-size: var(--be-text-m);
|
|
92
|
+
|
|
93
|
+
&:focus-visible {
|
|
94
|
+
border-color: var(--theme-elevation-400);
|
|
95
|
+
outline: 2px solid color-mix(in srgb, var(--be-accent) 40%, transparent);
|
|
96
|
+
outline-offset: 0;
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
&[aria-invalid='true'] {
|
|
100
|
+
border-color: var(--theme-error-500);
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
.builder-prop__error {
|
|
105
|
+
margin: 0;
|
|
106
|
+
color: var(--theme-error-500);
|
|
107
|
+
font-size: var(--be-text-s);
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
.builder-prop__submit,
|
|
111
|
+
.builder-comp__edit {
|
|
112
|
+
min-height: 30px;
|
|
113
|
+
padding: 4px 10px;
|
|
114
|
+
border: 1px solid var(--theme-elevation-150);
|
|
115
|
+
border-radius: var(--style-radius-s, 4px);
|
|
116
|
+
background: var(--theme-elevation-50);
|
|
117
|
+
color: var(--theme-text);
|
|
118
|
+
font: inherit;
|
|
119
|
+
font-size: var(--be-text-m);
|
|
120
|
+
font-weight: var(--be-weight-medium);
|
|
121
|
+
cursor: pointer;
|
|
122
|
+
|
|
123
|
+
&:hover {
|
|
124
|
+
border-color: var(--theme-elevation-250);
|
|
125
|
+
background: var(--theme-elevation-100);
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
&:focus-visible {
|
|
129
|
+
outline: 2px solid color-mix(in srgb, var(--be-accent) 40%, transparent);
|
|
130
|
+
outline-offset: 1px;
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
.builder-prop__submit {
|
|
135
|
+
align-self: flex-end;
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
// ---------------------------------------------------------------------------
|
|
139
|
+
// A copy: the component's properties
|
|
140
|
+
// ---------------------------------------------------------------------------
|
|
141
|
+
|
|
142
|
+
.builder-comp {
|
|
143
|
+
display: flex;
|
|
144
|
+
flex-direction: column;
|
|
145
|
+
gap: 12px;
|
|
146
|
+
padding: 12px var(--builder-inspector-pad, 12px) 16px;
|
|
147
|
+
border-top: 1px solid var(--theme-elevation-100);
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
.builder-comp__head {
|
|
151
|
+
display: flex;
|
|
152
|
+
align-items: center;
|
|
153
|
+
gap: 8px;
|
|
154
|
+
min-width: 0;
|
|
155
|
+
|
|
156
|
+
> svg {
|
|
157
|
+
flex: none;
|
|
158
|
+
color: var(--theme-success-600);
|
|
159
|
+
}
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
.builder-comp__title {
|
|
163
|
+
display: flex;
|
|
164
|
+
flex: 1;
|
|
165
|
+
flex-direction: column;
|
|
166
|
+
min-width: 0;
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
.builder-comp__name {
|
|
170
|
+
overflow: hidden;
|
|
171
|
+
font-size: var(--be-text-l);
|
|
172
|
+
font-weight: var(--be-weight-strong);
|
|
173
|
+
text-overflow: ellipsis;
|
|
174
|
+
white-space: nowrap;
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
.builder-comp__meta {
|
|
178
|
+
color: var(--theme-elevation-500);
|
|
179
|
+
font-size: var(--be-text-s);
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
.builder-comp__edit {
|
|
183
|
+
flex: none;
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
.builder-comp__missing {
|
|
187
|
+
display: flex;
|
|
188
|
+
align-items: flex-start;
|
|
189
|
+
gap: 8px;
|
|
190
|
+
margin: 12px var(--builder-inspector-pad, 12px);
|
|
191
|
+
padding: 8px 10px;
|
|
192
|
+
border-radius: var(--style-radius-m, 6px);
|
|
193
|
+
background: color-mix(in srgb, var(--theme-warning-500, var(--theme-error-500)) 12%, transparent);
|
|
194
|
+
color: var(--theme-elevation-800);
|
|
195
|
+
font-size: var(--be-text-m);
|
|
196
|
+
|
|
197
|
+
> svg {
|
|
198
|
+
flex: none;
|
|
199
|
+
margin-top: 2px;
|
|
200
|
+
color: var(--theme-warning-600, var(--theme-error-500));
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
// ---------------------------------------------------------------------------
|
|
205
|
+
// A saved section with properties: the banner on top of the inspector
|
|
206
|
+
// ---------------------------------------------------------------------------
|
|
207
|
+
|
|
208
|
+
.builder-comp__banner {
|
|
209
|
+
display: flex;
|
|
210
|
+
align-items: flex-start;
|
|
211
|
+
gap: 8px;
|
|
212
|
+
margin: 8px 8px 0;
|
|
213
|
+
padding: 8px 10px;
|
|
214
|
+
border-radius: var(--style-radius-m, 6px);
|
|
215
|
+
background: color-mix(in srgb, var(--be-accent) 10%, var(--theme-elevation-0));
|
|
216
|
+
color: var(--theme-elevation-800);
|
|
217
|
+
font-size: var(--be-text-m);
|
|
218
|
+
line-height: 1.45;
|
|
219
|
+
|
|
220
|
+
> svg {
|
|
221
|
+
flex: none;
|
|
222
|
+
margin-top: 2px;
|
|
223
|
+
color: var(--theme-success-600);
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
p {
|
|
227
|
+
margin: 0;
|
|
228
|
+
}
|
|
229
|
+
}
|
|
230
|
+
}
|
|
231
|
+
|
|
232
|
+
@layer payload-default {
|
|
233
|
+
.builder-editor__card-component {
|
|
234
|
+
margin-right: 4px;
|
|
235
|
+
color: var(--theme-success-600);
|
|
236
|
+
vertical-align: -1px;
|
|
237
|
+
}
|
|
238
|
+
}
|
|
@@ -1,90 +1,90 @@
|
|
|
1
|
-
// Section variants: the ‹ 2 / 3 › arrows on a library card and the switch on the canvas action bar.
|
|
2
|
-
// Payload CSS variables only (and the editor's --be-* variables, which map to them).
|
|
3
|
-
|
|
4
|
-
@layer payload-default {
|
|
5
|
-
.builder-variants {
|
|
6
|
-
display: inline-flex;
|
|
7
|
-
align-items: center;
|
|
8
|
-
gap: 2px;
|
|
9
|
-
min-width: 0;
|
|
10
|
-
margin: 0;
|
|
11
|
-
padding: 0;
|
|
12
|
-
border: 0;
|
|
13
|
-
white-space: nowrap;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
.builder-variants__text {
|
|
17
|
-
min-width: 0;
|
|
18
|
-
overflow: hidden;
|
|
19
|
-
text-overflow: ellipsis;
|
|
20
|
-
font-size: var(--be-text-s);
|
|
21
|
-
font-variant-numeric: tabular-nums;
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
.builder-variants__arrow {
|
|
25
|
-
display: grid;
|
|
26
|
-
place-items: center;
|
|
27
|
-
width: 20px;
|
|
28
|
-
height: 20px;
|
|
29
|
-
padding: 0;
|
|
30
|
-
border: 0;
|
|
31
|
-
border-radius: 4px;
|
|
32
|
-
background: transparent;
|
|
33
|
-
color: inherit;
|
|
34
|
-
cursor: pointer;
|
|
35
|
-
|
|
36
|
-
&:hover {
|
|
37
|
-
background: var(--theme-elevation-100);
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
&:focus-visible {
|
|
41
|
-
outline: 2px solid var(--theme-success-500);
|
|
42
|
-
outline-offset: 1px;
|
|
43
|
-
}
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
// On a library card: a small pill at the top right of the picture. Saved sections have no
|
|
47
|
-
// variants, so it never meets their "…" menu there.
|
|
48
|
-
.builder-variants--card {
|
|
49
|
-
position: absolute;
|
|
50
|
-
top: 6px;
|
|
51
|
-
right: 6px;
|
|
52
|
-
z-index: 1;
|
|
53
|
-
max-width: calc(100% - 12px);
|
|
54
|
-
padding: 1px;
|
|
55
|
-
border-radius: 6px;
|
|
56
|
-
background: var(--theme-bg);
|
|
57
|
-
box-shadow: 0 1px 3px rgb(0 0 0 / 0.18);
|
|
58
|
-
color: var(--theme-text);
|
|
59
|
-
|
|
60
|
-
.builder-variants__text {
|
|
61
|
-
padding: 0 2px;
|
|
62
|
-
color: var(--be-muted);
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
// On the canvas action bar: white on the accent color, like the bar's other buttons.
|
|
67
|
-
.builder-variants--bar {
|
|
68
|
-
max-width: 180px;
|
|
69
|
-
|
|
70
|
-
.builder-variants__text {
|
|
71
|
-
max-width: 120px;
|
|
72
|
-
padding: 0 2px;
|
|
73
|
-
color: var(--be-accent-fg);
|
|
74
|
-
}
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
// A library card with versions keeps one height while the arrows flip it: one label line and
|
|
78
|
-
// room for two description lines, whatever the version shown.
|
|
79
|
-
.builder-editor__card-wrap[data-versions] {
|
|
80
|
-
.builder-editor__card-label {
|
|
81
|
-
overflow: hidden;
|
|
82
|
-
text-overflow: ellipsis;
|
|
83
|
-
white-space: nowrap;
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
.builder-editor__card-desc {
|
|
87
|
-
min-height: 2lh;
|
|
88
|
-
}
|
|
89
|
-
}
|
|
90
|
-
}
|
|
1
|
+
// Section variants: the ‹ 2 / 3 › arrows on a library card and the switch on the canvas action bar.
|
|
2
|
+
// Payload CSS variables only (and the editor's --be-* variables, which map to them).
|
|
3
|
+
|
|
4
|
+
@layer payload-default {
|
|
5
|
+
.builder-variants {
|
|
6
|
+
display: inline-flex;
|
|
7
|
+
align-items: center;
|
|
8
|
+
gap: 2px;
|
|
9
|
+
min-width: 0;
|
|
10
|
+
margin: 0;
|
|
11
|
+
padding: 0;
|
|
12
|
+
border: 0;
|
|
13
|
+
white-space: nowrap;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.builder-variants__text {
|
|
17
|
+
min-width: 0;
|
|
18
|
+
overflow: hidden;
|
|
19
|
+
text-overflow: ellipsis;
|
|
20
|
+
font-size: var(--be-text-s);
|
|
21
|
+
font-variant-numeric: tabular-nums;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
.builder-variants__arrow {
|
|
25
|
+
display: grid;
|
|
26
|
+
place-items: center;
|
|
27
|
+
width: 20px;
|
|
28
|
+
height: 20px;
|
|
29
|
+
padding: 0;
|
|
30
|
+
border: 0;
|
|
31
|
+
border-radius: 4px;
|
|
32
|
+
background: transparent;
|
|
33
|
+
color: inherit;
|
|
34
|
+
cursor: pointer;
|
|
35
|
+
|
|
36
|
+
&:hover {
|
|
37
|
+
background: var(--theme-elevation-100);
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
&:focus-visible {
|
|
41
|
+
outline: 2px solid var(--theme-success-500);
|
|
42
|
+
outline-offset: 1px;
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
// On a library card: a small pill at the top right of the picture. Saved sections have no
|
|
47
|
+
// variants, so it never meets their "…" menu there.
|
|
48
|
+
.builder-variants--card {
|
|
49
|
+
position: absolute;
|
|
50
|
+
top: 6px;
|
|
51
|
+
right: 6px;
|
|
52
|
+
z-index: 1;
|
|
53
|
+
max-width: calc(100% - 12px);
|
|
54
|
+
padding: 1px;
|
|
55
|
+
border-radius: 6px;
|
|
56
|
+
background: var(--theme-bg);
|
|
57
|
+
box-shadow: 0 1px 3px rgb(0 0 0 / 0.18);
|
|
58
|
+
color: var(--theme-text);
|
|
59
|
+
|
|
60
|
+
.builder-variants__text {
|
|
61
|
+
padding: 0 2px;
|
|
62
|
+
color: var(--be-muted);
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
// On the canvas action bar: white on the accent color, like the bar's other buttons.
|
|
67
|
+
.builder-variants--bar {
|
|
68
|
+
max-width: 180px;
|
|
69
|
+
|
|
70
|
+
.builder-variants__text {
|
|
71
|
+
max-width: 120px;
|
|
72
|
+
padding: 0 2px;
|
|
73
|
+
color: var(--be-accent-fg);
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
// A library card with versions keeps one height while the arrows flip it: one label line and
|
|
78
|
+
// room for two description lines, whatever the version shown.
|
|
79
|
+
.builder-editor__card-wrap[data-versions] {
|
|
80
|
+
.builder-editor__card-label {
|
|
81
|
+
overflow: hidden;
|
|
82
|
+
text-overflow: ellipsis;
|
|
83
|
+
white-space: nowrap;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
.builder-editor__card-desc {
|
|
87
|
+
min-height: 2lh;
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
}
|
|
@@ -5,9 +5,9 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
5
5
|
import { useId } from 'react';
|
|
6
6
|
import { cssProblem } from '../../../classes/shared.js';
|
|
7
7
|
import { useRuntime } from '../runtime.js';
|
|
8
|
-
const PLACEHOLDER = `background: linear-gradient(135deg, …), radial-gradient(…);
|
|
9
|
-
&::before {
|
|
10
|
-
content: "";
|
|
8
|
+
const PLACEHOLDER = `background: linear-gradient(135deg, …), radial-gradient(…);
|
|
9
|
+
&::before {
|
|
10
|
+
content: "";
|
|
11
11
|
}`;
|
|
12
12
|
export function ClassCss({ item }) {
|
|
13
13
|
const runtime = useRuntime();
|