datocms-plugin-sdk 2.1.1 → 3.0.0-alpha.0
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/cjs/manifest.js +36 -25
- package/dist/cjs/manifest.js.map +1 -1
- package/dist/esm/ctx/base.d.ts +126 -2
- package/dist/esm/manifest.js +36 -25
- package/dist/esm/manifest.js.map +1 -1
- package/dist/types/ctx/base.d.ts +126 -2
- package/manifest.json +37 -26
- package/package.json +2 -2
- package/src/ctx/base.ts +175 -2
- package/src/manifest.ts +38 -25
package/manifest.json
CHANGED
|
@@ -3109,13 +3109,24 @@
|
|
|
3109
3109
|
},
|
|
3110
3110
|
"theme": {
|
|
3111
3111
|
"comment": {
|
|
3112
|
-
"markdownText": "An object containing the theme colors for the current DatoCMS project."
|
|
3112
|
+
"markdownText": "An object containing the theme colors for the current DatoCMS project.",
|
|
3113
|
+
"deprecatedMarkdownText": "Use `semanticColorTokensTheme` instead. This property is kept\nfor backward compatibility with third-party plugins."
|
|
3113
3114
|
},
|
|
3114
3115
|
"location": {
|
|
3115
3116
|
"filePath": "src/ctx/base.ts",
|
|
3116
|
-
"lineNumber":
|
|
3117
|
+
"lineNumber": 92
|
|
3117
3118
|
},
|
|
3118
3119
|
"type": "Theme"
|
|
3120
|
+
},
|
|
3121
|
+
"semanticColorTokensTheme": {
|
|
3122
|
+
"comment": {
|
|
3123
|
+
"markdownText": "Semantic color tokens for the current DatoCMS project, pre-computed by\nthe host. Only available on DatoCMS hosts that support the new token\nsystem."
|
|
3124
|
+
},
|
|
3125
|
+
"location": {
|
|
3126
|
+
"filePath": "src/ctx/base.ts",
|
|
3127
|
+
"lineNumber": 99
|
|
3128
|
+
},
|
|
3129
|
+
"type": "SemanticColorTokensTheme"
|
|
3119
3130
|
}
|
|
3120
3131
|
}
|
|
3121
3132
|
},
|
|
@@ -3131,7 +3142,7 @@
|
|
|
3131
3142
|
},
|
|
3132
3143
|
"location": {
|
|
3133
3144
|
"filePath": "src/ctx/base.ts",
|
|
3134
|
-
"lineNumber":
|
|
3145
|
+
"lineNumber": 109
|
|
3135
3146
|
},
|
|
3136
3147
|
"type": "Partial<Record<string, ItemType>>"
|
|
3137
3148
|
},
|
|
@@ -3141,7 +3152,7 @@
|
|
|
3141
3152
|
},
|
|
3142
3153
|
"location": {
|
|
3143
3154
|
"filePath": "src/ctx/base.ts",
|
|
3144
|
-
"lineNumber":
|
|
3155
|
+
"lineNumber": 116
|
|
3145
3156
|
},
|
|
3146
3157
|
"type": "Partial<Record<string, Field>>"
|
|
3147
3158
|
},
|
|
@@ -3151,7 +3162,7 @@
|
|
|
3151
3162
|
},
|
|
3152
3163
|
"location": {
|
|
3153
3164
|
"filePath": "src/ctx/base.ts",
|
|
3154
|
-
"lineNumber":
|
|
3165
|
+
"lineNumber": 123
|
|
3155
3166
|
},
|
|
3156
3167
|
"type": "Partial<Record<string, Fieldset>>"
|
|
3157
3168
|
},
|
|
@@ -3161,7 +3172,7 @@
|
|
|
3161
3172
|
},
|
|
3162
3173
|
"location": {
|
|
3163
3174
|
"filePath": "src/ctx/base.ts",
|
|
3164
|
-
"lineNumber":
|
|
3175
|
+
"lineNumber": 130
|
|
3165
3176
|
},
|
|
3166
3177
|
"type": "Partial<Record<string, User>>"
|
|
3167
3178
|
},
|
|
@@ -3171,7 +3182,7 @@
|
|
|
3171
3182
|
},
|
|
3172
3183
|
"location": {
|
|
3173
3184
|
"filePath": "src/ctx/base.ts",
|
|
3174
|
-
"lineNumber":
|
|
3185
|
+
"lineNumber": 137
|
|
3175
3186
|
},
|
|
3176
3187
|
"type": "Partial<Record<string, SsoUser>>"
|
|
3177
3188
|
}
|
|
@@ -3192,7 +3203,7 @@
|
|
|
3192
3203
|
},
|
|
3193
3204
|
"location": {
|
|
3194
3205
|
"filePath": "src/ctx/base.ts",
|
|
3195
|
-
"lineNumber":
|
|
3206
|
+
"lineNumber": 341
|
|
3196
3207
|
},
|
|
3197
3208
|
"type": "(itemTypeId: string) => Promise<Field[]>"
|
|
3198
3209
|
},
|
|
@@ -3203,7 +3214,7 @@
|
|
|
3203
3214
|
},
|
|
3204
3215
|
"location": {
|
|
3205
3216
|
"filePath": "src/ctx/base.ts",
|
|
3206
|
-
"lineNumber":
|
|
3217
|
+
"lineNumber": 360
|
|
3207
3218
|
},
|
|
3208
3219
|
"type": "(itemTypeId: string) => Promise<Fieldset[]>"
|
|
3209
3220
|
},
|
|
@@ -3214,7 +3225,7 @@
|
|
|
3214
3225
|
},
|
|
3215
3226
|
"location": {
|
|
3216
3227
|
"filePath": "src/ctx/base.ts",
|
|
3217
|
-
"lineNumber":
|
|
3228
|
+
"lineNumber": 377
|
|
3218
3229
|
},
|
|
3219
3230
|
"type": "() => Promise<Field[]>"
|
|
3220
3231
|
},
|
|
@@ -3225,7 +3236,7 @@
|
|
|
3225
3236
|
},
|
|
3226
3237
|
"location": {
|
|
3227
3238
|
"filePath": "src/ctx/base.ts",
|
|
3228
|
-
"lineNumber":
|
|
3239
|
+
"lineNumber": 390
|
|
3229
3240
|
},
|
|
3230
3241
|
"type": "() => Promise<User[]>"
|
|
3231
3242
|
},
|
|
@@ -3236,7 +3247,7 @@
|
|
|
3236
3247
|
},
|
|
3237
3248
|
"location": {
|
|
3238
3249
|
"filePath": "src/ctx/base.ts",
|
|
3239
|
-
"lineNumber":
|
|
3250
|
+
"lineNumber": 403
|
|
3240
3251
|
},
|
|
3241
3252
|
"type": "() => Promise<SsoUser[]>"
|
|
3242
3253
|
}
|
|
@@ -3255,7 +3266,7 @@
|
|
|
3255
3266
|
},
|
|
3256
3267
|
"location": {
|
|
3257
3268
|
"filePath": "src/ctx/base.ts",
|
|
3258
|
-
"lineNumber":
|
|
3269
|
+
"lineNumber": 425
|
|
3259
3270
|
},
|
|
3260
3271
|
"type": "(params: Record<string, unknown>) => Promise<void>"
|
|
3261
3272
|
},
|
|
@@ -3266,7 +3277,7 @@
|
|
|
3266
3277
|
},
|
|
3267
3278
|
"location": {
|
|
3268
3279
|
"filePath": "src/ctx/base.ts",
|
|
3269
|
-
"lineNumber":
|
|
3280
|
+
"lineNumber": 476
|
|
3270
3281
|
},
|
|
3271
3282
|
"type": "(\n fieldId: string,\n changes: FieldAppearanceChange[],\n ) => Promise<void>"
|
|
3272
3283
|
}
|
|
@@ -3285,7 +3296,7 @@
|
|
|
3285
3296
|
},
|
|
3286
3297
|
"location": {
|
|
3287
3298
|
"filePath": "src/ctx/base.ts",
|
|
3288
|
-
"lineNumber":
|
|
3299
|
+
"lineNumber": 581
|
|
3289
3300
|
},
|
|
3290
3301
|
"type": "(message: string) => Promise<void>"
|
|
3291
3302
|
},
|
|
@@ -3296,7 +3307,7 @@
|
|
|
3296
3307
|
},
|
|
3297
3308
|
"location": {
|
|
3298
3309
|
"filePath": "src/ctx/base.ts",
|
|
3299
|
-
"lineNumber":
|
|
3310
|
+
"lineNumber": 596
|
|
3300
3311
|
},
|
|
3301
3312
|
"type": "(message: string) => Promise<void>"
|
|
3302
3313
|
},
|
|
@@ -3307,7 +3318,7 @@
|
|
|
3307
3318
|
},
|
|
3308
3319
|
"location": {
|
|
3309
3320
|
"filePath": "src/ctx/base.ts",
|
|
3310
|
-
"lineNumber":
|
|
3321
|
+
"lineNumber": 620
|
|
3311
3322
|
},
|
|
3312
3323
|
"type": "<CtaValue = unknown>(\n toast: Toast<CtaValue>,\n ) => Promise<CtaValue | null>"
|
|
3313
3324
|
}
|
|
@@ -3326,7 +3337,7 @@
|
|
|
3326
3337
|
},
|
|
3327
3338
|
"location": {
|
|
3328
3339
|
"filePath": "src/ctx/base.ts",
|
|
3329
|
-
"lineNumber":
|
|
3340
|
+
"lineNumber": 506
|
|
3330
3341
|
},
|
|
3331
3342
|
"type": "(itemTypeId: string) => Promise<Item | null>"
|
|
3332
3343
|
},
|
|
@@ -3337,7 +3348,7 @@
|
|
|
3337
3348
|
},
|
|
3338
3349
|
"location": {
|
|
3339
3350
|
"filePath": "src/ctx/base.ts",
|
|
3340
|
-
"lineNumber":
|
|
3351
|
+
"lineNumber": 527
|
|
3341
3352
|
},
|
|
3342
3353
|
"type": "{\n (\n itemTypeId: string,\n options: { multiple: true; initialLocationQuery?: ItemListLocationQuery },\n ): Promise<Item[] | null>;\n (\n itemTypeId: string,\n options?: {\n multiple: false;\n initialLocationQuery?: ItemListLocationQuery;\n },\n ): Promise<Item | null>;\n }"
|
|
3343
3354
|
},
|
|
@@ -3348,7 +3359,7 @@
|
|
|
3348
3359
|
},
|
|
3349
3360
|
"location": {
|
|
3350
3361
|
"filePath": "src/ctx/base.ts",
|
|
3351
|
-
"lineNumber":
|
|
3362
|
+
"lineNumber": 559
|
|
3352
3363
|
},
|
|
3353
3364
|
"type": "(itemId: string) => Promise<Item | null>"
|
|
3354
3365
|
}
|
|
@@ -3367,7 +3378,7 @@
|
|
|
3367
3378
|
},
|
|
3368
3379
|
"location": {
|
|
3369
3380
|
"filePath": "src/ctx/base.ts",
|
|
3370
|
-
"lineNumber":
|
|
3381
|
+
"lineNumber": 647
|
|
3371
3382
|
},
|
|
3372
3383
|
"type": "{\n (options: { multiple: true }): Promise<Upload[] | null>;\n (options?: { multiple: false }): Promise<Upload | null>;\n }"
|
|
3373
3384
|
},
|
|
@@ -3378,7 +3389,7 @@
|
|
|
3378
3389
|
},
|
|
3379
3390
|
"location": {
|
|
3380
3391
|
"filePath": "src/ctx/base.ts",
|
|
3381
|
-
"lineNumber":
|
|
3392
|
+
"lineNumber": 675
|
|
3382
3393
|
},
|
|
3383
3394
|
"type": "(\n uploadId: string,\n ) => Promise<(Upload & { deleted?: true }) | null>"
|
|
3384
3395
|
},
|
|
@@ -3389,7 +3400,7 @@
|
|
|
3389
3400
|
},
|
|
3390
3401
|
"location": {
|
|
3391
3402
|
"filePath": "src/ctx/base.ts",
|
|
3392
|
-
"lineNumber":
|
|
3403
|
+
"lineNumber": 703
|
|
3393
3404
|
},
|
|
3394
3405
|
"type": "(\n /** The \"single asset\" field structure */\n fileFieldValue: FileFieldValue,\n /** Shows metadata information for a specific locale */\n locale?: string,\n ) => Promise<FileFieldValue | null>"
|
|
3395
3406
|
}
|
|
@@ -3408,7 +3419,7 @@
|
|
|
3408
3419
|
},
|
|
3409
3420
|
"location": {
|
|
3410
3421
|
"filePath": "src/ctx/base.ts",
|
|
3411
|
-
"lineNumber":
|
|
3422
|
+
"lineNumber": 734
|
|
3412
3423
|
},
|
|
3413
3424
|
"type": "(modal: Modal) => Promise<unknown>"
|
|
3414
3425
|
},
|
|
@@ -3419,7 +3430,7 @@
|
|
|
3419
3430
|
},
|
|
3420
3431
|
"location": {
|
|
3421
3432
|
"filePath": "src/ctx/base.ts",
|
|
3422
|
-
"lineNumber":
|
|
3433
|
+
"lineNumber": 771
|
|
3423
3434
|
},
|
|
3424
3435
|
"type": "(options: ConfirmOptions) => Promise<unknown>"
|
|
3425
3436
|
}
|
|
@@ -3438,7 +3449,7 @@
|
|
|
3438
3449
|
},
|
|
3439
3450
|
"location": {
|
|
3440
3451
|
"filePath": "src/ctx/base.ts",
|
|
3441
|
-
"lineNumber":
|
|
3452
|
+
"lineNumber": 785
|
|
3442
3453
|
},
|
|
3443
3454
|
"type": "(path: string) => Promise<void>"
|
|
3444
3455
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "datocms-plugin-sdk",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "3.0.0-alpha.0",
|
|
4
4
|
"description": "DatoCMS Plugin SDK",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"datocms",
|
|
@@ -46,5 +46,5 @@
|
|
|
46
46
|
"glob": "^11.0.0",
|
|
47
47
|
"typescript": "^5.6.2"
|
|
48
48
|
},
|
|
49
|
-
"gitHead": "
|
|
49
|
+
"gitHead": "01c46332e40377d305c3abd262c3d1840385ec49"
|
|
50
50
|
}
|
package/src/ctx/base.ts
CHANGED
|
@@ -83,8 +83,20 @@ type ProjectProperties = {
|
|
|
83
83
|
locale: string;
|
|
84
84
|
};
|
|
85
85
|
|
|
86
|
-
/**
|
|
86
|
+
/**
|
|
87
|
+
* An object containing the theme colors for the current DatoCMS project
|
|
88
|
+
*
|
|
89
|
+
* @deprecated Use `semanticColorTokensTheme` instead. This property is kept
|
|
90
|
+
* for backward compatibility with third-party plugins.
|
|
91
|
+
*/
|
|
87
92
|
theme: Theme;
|
|
93
|
+
|
|
94
|
+
/**
|
|
95
|
+
* Semantic color tokens for the current DatoCMS project, pre-computed by
|
|
96
|
+
* the host. Only available on DatoCMS hosts that support the new token
|
|
97
|
+
* system.
|
|
98
|
+
*/
|
|
99
|
+
semanticColorTokensTheme: SemanticColorTokensTheme;
|
|
88
100
|
};
|
|
89
101
|
|
|
90
102
|
/**
|
|
@@ -125,7 +137,12 @@ type EntityReposProperties = {
|
|
|
125
137
|
ssoUsers: Partial<Record<string, SsoUser>>;
|
|
126
138
|
};
|
|
127
139
|
|
|
128
|
-
/**
|
|
140
|
+
/**
|
|
141
|
+
* An object containing the theme colors for the current DatoCMS project
|
|
142
|
+
*
|
|
143
|
+
* @deprecated Use `SemanticColorTokensTheme` instead. This type is kept for
|
|
144
|
+
* backward compatibility with third-party plugins.
|
|
145
|
+
*/
|
|
129
146
|
export type Theme = {
|
|
130
147
|
primaryColor: string;
|
|
131
148
|
accentColor: string;
|
|
@@ -134,6 +151,162 @@ export type Theme = {
|
|
|
134
151
|
darkColor: string;
|
|
135
152
|
};
|
|
136
153
|
|
|
154
|
+
/**
|
|
155
|
+
* Known semantic color tokens provided by the DatoCMS host.
|
|
156
|
+
* All properties are optional — the host may not send all of them.
|
|
157
|
+
*
|
|
158
|
+
* camelCase keys are converted to kebab-case CSS custom properties via
|
|
159
|
+
* `camelToDash`. For example, `colorRaisedSurface` becomes
|
|
160
|
+
* `--color-raised-surface`.
|
|
161
|
+
*/
|
|
162
|
+
type KnownSemanticColorTokens = {
|
|
163
|
+
/* --- Standalone --- */
|
|
164
|
+
colorSurface?: string;
|
|
165
|
+
colorSurfaceHover?: string;
|
|
166
|
+
colorSurfaceMuted?: string;
|
|
167
|
+
colorInk?: string;
|
|
168
|
+
colorInkSubtle?: string;
|
|
169
|
+
colorInkHover?: string;
|
|
170
|
+
colorInkMuted?: string;
|
|
171
|
+
colorInkPlaceholder?: string;
|
|
172
|
+
colorInkPrimary?: string;
|
|
173
|
+
colorInkAccent?: string;
|
|
174
|
+
colorInkDisabled?: string;
|
|
175
|
+
colorBorder?: string;
|
|
176
|
+
colorBorderHover?: string;
|
|
177
|
+
|
|
178
|
+
/* --- Context: raised --- */
|
|
179
|
+
colorRaisedSurface?: string;
|
|
180
|
+
colorRaisedSurfaceHover?: string;
|
|
181
|
+
colorRaisedSurfaceActive?: string;
|
|
182
|
+
|
|
183
|
+
/* --- Context: primary --- */
|
|
184
|
+
colorPrimarySurface?: string;
|
|
185
|
+
colorPrimarySurfaceHover?: string;
|
|
186
|
+
colorPrimarySurfaceActive?: string;
|
|
187
|
+
colorPrimarySurfaceMuted?: string;
|
|
188
|
+
colorPrimaryInk?: string;
|
|
189
|
+
colorPrimaryBorder?: string;
|
|
190
|
+
|
|
191
|
+
/* --- Context: tinted --- */
|
|
192
|
+
colorTintedSurface?: string;
|
|
193
|
+
colorTintedSurfaceHover?: string;
|
|
194
|
+
colorTintedSurfaceActive?: string;
|
|
195
|
+
colorTintedInk?: string;
|
|
196
|
+
|
|
197
|
+
/* --- Context: accent --- */
|
|
198
|
+
colorAccentSurface?: string;
|
|
199
|
+
colorAccentInk?: string;
|
|
200
|
+
|
|
201
|
+
/* --- Context: selected --- */
|
|
202
|
+
colorSelectedSurface?: string;
|
|
203
|
+
colorSelectedInk?: string;
|
|
204
|
+
colorSelectedBorder?: string;
|
|
205
|
+
|
|
206
|
+
/* --- Context: disabled --- */
|
|
207
|
+
colorDisabledSurface?: string;
|
|
208
|
+
colorDisabledInk?: string;
|
|
209
|
+
|
|
210
|
+
/* --- Context: danger --- */
|
|
211
|
+
colorDangerSurface?: string;
|
|
212
|
+
colorDangerInk?: string;
|
|
213
|
+
|
|
214
|
+
/* --- Context: enterprise --- */
|
|
215
|
+
colorEnterpriseSurface?: string;
|
|
216
|
+
|
|
217
|
+
/* --- Context: focus --- */
|
|
218
|
+
colorFocusBorder?: string;
|
|
219
|
+
colorFocusOutline?: string;
|
|
220
|
+
|
|
221
|
+
/* --- Feedback --- */
|
|
222
|
+
colorFeedbackFailInk?: string;
|
|
223
|
+
colorFeedbackFailBorder?: string;
|
|
224
|
+
colorFeedbackFailOutline?: string;
|
|
225
|
+
colorFeedbackWarningInk?: string;
|
|
226
|
+
colorFeedbackWarningSurface?: string;
|
|
227
|
+
colorFeedbackSuccessInk?: string;
|
|
228
|
+
colorFeedbackWarningBorder?: string;
|
|
229
|
+
colorFeedbackSuccessBorder?: string;
|
|
230
|
+
|
|
231
|
+
/* --- Context: highlight --- */
|
|
232
|
+
colorHighlightSurface?: string;
|
|
233
|
+
|
|
234
|
+
/* --- Diffs --- */
|
|
235
|
+
colorDiffAddedSurface?: string;
|
|
236
|
+
colorDiffRemovedSurface?: string;
|
|
237
|
+
colorDiffChangedSurface?: string;
|
|
238
|
+
colorDiffAddedSurfaceSubtle?: string;
|
|
239
|
+
colorDiffRemovedSurfaceSubtle?: string;
|
|
240
|
+
colorDiffChangedSurfaceSubtle?: string;
|
|
241
|
+
colorDiffAddedOutlineSubtle?: string;
|
|
242
|
+
colorDiffRemovedOutlineSubtle?: string;
|
|
243
|
+
colorDiffChangedOutlineSubtle?: string;
|
|
244
|
+
colorDiffChangedBorder?: string;
|
|
245
|
+
colorDiffChangedBorderNegative?: string;
|
|
246
|
+
|
|
247
|
+
/* --- Status --- */
|
|
248
|
+
colorStatusDraftInk?: string;
|
|
249
|
+
colorStatusOutdatedInk?: string;
|
|
250
|
+
colorStatusPublishedInk?: string;
|
|
251
|
+
|
|
252
|
+
/* --- Backdrop --- */
|
|
253
|
+
colorBackdropSurface?: string;
|
|
254
|
+
colorBackdropInk?: string;
|
|
255
|
+
|
|
256
|
+
/* --- Overlay --- */
|
|
257
|
+
colorOverlaySurface?: string;
|
|
258
|
+
colorOverlaySurfaceSubtle?: string;
|
|
259
|
+
colorOverlayInk?: string;
|
|
260
|
+
|
|
261
|
+
/* --- Stacked --- */
|
|
262
|
+
colorStackedSurfaceBase?: string;
|
|
263
|
+
colorStackedSurface?: string;
|
|
264
|
+
colorStackedSurfaceRaised?: string;
|
|
265
|
+
colorStackedInk?: string;
|
|
266
|
+
colorStackedInkSubtle?: string;
|
|
267
|
+
colorStackedBorder?: string;
|
|
268
|
+
colorStackedSurfaceHover?: string;
|
|
269
|
+
colorStackedSurfaceTranslucent?: string;
|
|
270
|
+
colorStackedSurfaceButton?: string;
|
|
271
|
+
colorStackedSurfaceButtonActive?: string;
|
|
272
|
+
|
|
273
|
+
/* --- Progress --- */
|
|
274
|
+
colorProgressTrack?: string;
|
|
275
|
+
colorProgressFill?: string;
|
|
276
|
+
colorProgressFillHover?: string;
|
|
277
|
+
|
|
278
|
+
/* --- Tooltip --- */
|
|
279
|
+
colorTooltipSurface?: string;
|
|
280
|
+
colorTooltipSurfaceHover?: string;
|
|
281
|
+
colorTooltipInk?: string;
|
|
282
|
+
colorTooltipInkSubtle?: string;
|
|
283
|
+
|
|
284
|
+
/* --- Code --- */
|
|
285
|
+
colorCodeSurface?: string;
|
|
286
|
+
colorCodeInk?: string;
|
|
287
|
+
|
|
288
|
+
/* --- Shadows --- */
|
|
289
|
+
colorShadowSubtle?: string;
|
|
290
|
+
colorShadow?: string;
|
|
291
|
+
colorShadowStrong?: string;
|
|
292
|
+
|
|
293
|
+
/* --- Scrollbar --- */
|
|
294
|
+
colorScrollbar?: string;
|
|
295
|
+
|
|
296
|
+
/* --- Shadow composites --- */
|
|
297
|
+
shadowElevated?: string;
|
|
298
|
+
shadowFloat?: string;
|
|
299
|
+
shadowAmbient?: string;
|
|
300
|
+
};
|
|
301
|
+
|
|
302
|
+
/**
|
|
303
|
+
* Semantic color tokens for the current DatoCMS project, pre-computed by the
|
|
304
|
+
* host. Known tokens get autocomplete; unknown tokens are accepted via the
|
|
305
|
+
* index signature for forward compatibility.
|
|
306
|
+
*/
|
|
307
|
+
export type SemanticColorTokensTheme = KnownSemanticColorTokens &
|
|
308
|
+
Record<string, string>;
|
|
309
|
+
|
|
137
310
|
export type BaseMethods = LoadDataMethods &
|
|
138
311
|
UpdatePluginParametersMethods &
|
|
139
312
|
ToastMethods &
|
package/src/manifest.ts
CHANGED
|
@@ -3340,13 +3340,26 @@ export const manifest: Manifest = {
|
|
|
3340
3340
|
comment: {
|
|
3341
3341
|
markdownText:
|
|
3342
3342
|
'An object containing the theme colors for the current DatoCMS project.',
|
|
3343
|
+
deprecatedMarkdownText:
|
|
3344
|
+
'Use `semanticColorTokensTheme` instead. This property is kept\nfor backward compatibility with third-party plugins.',
|
|
3343
3345
|
},
|
|
3344
3346
|
location: {
|
|
3345
3347
|
filePath: 'src/ctx/base.ts',
|
|
3346
|
-
lineNumber:
|
|
3348
|
+
lineNumber: 92,
|
|
3347
3349
|
},
|
|
3348
3350
|
type: 'Theme',
|
|
3349
3351
|
},
|
|
3352
|
+
semanticColorTokensTheme: {
|
|
3353
|
+
comment: {
|
|
3354
|
+
markdownText:
|
|
3355
|
+
'Semantic color tokens for the current DatoCMS project, pre-computed by\nthe host. Only available on DatoCMS hosts that support the new token\nsystem.',
|
|
3356
|
+
},
|
|
3357
|
+
location: {
|
|
3358
|
+
filePath: 'src/ctx/base.ts',
|
|
3359
|
+
lineNumber: 99,
|
|
3360
|
+
},
|
|
3361
|
+
type: 'SemanticColorTokensTheme',
|
|
3362
|
+
},
|
|
3350
3363
|
},
|
|
3351
3364
|
},
|
|
3352
3365
|
{
|
|
@@ -3363,7 +3376,7 @@ export const manifest: Manifest = {
|
|
|
3363
3376
|
},
|
|
3364
3377
|
location: {
|
|
3365
3378
|
filePath: 'src/ctx/base.ts',
|
|
3366
|
-
lineNumber:
|
|
3379
|
+
lineNumber: 109,
|
|
3367
3380
|
},
|
|
3368
3381
|
type: 'Partial<Record<string, ItemType>>',
|
|
3369
3382
|
},
|
|
@@ -3374,7 +3387,7 @@ export const manifest: Manifest = {
|
|
|
3374
3387
|
},
|
|
3375
3388
|
location: {
|
|
3376
3389
|
filePath: 'src/ctx/base.ts',
|
|
3377
|
-
lineNumber:
|
|
3390
|
+
lineNumber: 116,
|
|
3378
3391
|
},
|
|
3379
3392
|
type: 'Partial<Record<string, Field>>',
|
|
3380
3393
|
},
|
|
@@ -3385,7 +3398,7 @@ export const manifest: Manifest = {
|
|
|
3385
3398
|
},
|
|
3386
3399
|
location: {
|
|
3387
3400
|
filePath: 'src/ctx/base.ts',
|
|
3388
|
-
lineNumber:
|
|
3401
|
+
lineNumber: 123,
|
|
3389
3402
|
},
|
|
3390
3403
|
type: 'Partial<Record<string, Fieldset>>',
|
|
3391
3404
|
},
|
|
@@ -3396,7 +3409,7 @@ export const manifest: Manifest = {
|
|
|
3396
3409
|
},
|
|
3397
3410
|
location: {
|
|
3398
3411
|
filePath: 'src/ctx/base.ts',
|
|
3399
|
-
lineNumber:
|
|
3412
|
+
lineNumber: 130,
|
|
3400
3413
|
},
|
|
3401
3414
|
type: 'Partial<Record<string, User>>',
|
|
3402
3415
|
},
|
|
@@ -3407,7 +3420,7 @@ export const manifest: Manifest = {
|
|
|
3407
3420
|
},
|
|
3408
3421
|
location: {
|
|
3409
3422
|
filePath: 'src/ctx/base.ts',
|
|
3410
|
-
lineNumber:
|
|
3423
|
+
lineNumber: 137,
|
|
3411
3424
|
},
|
|
3412
3425
|
type: 'Partial<Record<string, SsoUser>>',
|
|
3413
3426
|
},
|
|
@@ -3431,7 +3444,7 @@ export const manifest: Manifest = {
|
|
|
3431
3444
|
},
|
|
3432
3445
|
location: {
|
|
3433
3446
|
filePath: 'src/ctx/base.ts',
|
|
3434
|
-
lineNumber:
|
|
3447
|
+
lineNumber: 341,
|
|
3435
3448
|
},
|
|
3436
3449
|
type: '(itemTypeId: string) => Promise<Field[]>',
|
|
3437
3450
|
},
|
|
@@ -3444,7 +3457,7 @@ export const manifest: Manifest = {
|
|
|
3444
3457
|
},
|
|
3445
3458
|
location: {
|
|
3446
3459
|
filePath: 'src/ctx/base.ts',
|
|
3447
|
-
lineNumber:
|
|
3460
|
+
lineNumber: 360,
|
|
3448
3461
|
},
|
|
3449
3462
|
type: '(itemTypeId: string) => Promise<Fieldset[]>',
|
|
3450
3463
|
},
|
|
@@ -3457,7 +3470,7 @@ export const manifest: Manifest = {
|
|
|
3457
3470
|
},
|
|
3458
3471
|
location: {
|
|
3459
3472
|
filePath: 'src/ctx/base.ts',
|
|
3460
|
-
lineNumber:
|
|
3473
|
+
lineNumber: 377,
|
|
3461
3474
|
},
|
|
3462
3475
|
type: '() => Promise<Field[]>',
|
|
3463
3476
|
},
|
|
@@ -3470,7 +3483,7 @@ export const manifest: Manifest = {
|
|
|
3470
3483
|
},
|
|
3471
3484
|
location: {
|
|
3472
3485
|
filePath: 'src/ctx/base.ts',
|
|
3473
|
-
lineNumber:
|
|
3486
|
+
lineNumber: 390,
|
|
3474
3487
|
},
|
|
3475
3488
|
type: '() => Promise<User[]>',
|
|
3476
3489
|
},
|
|
@@ -3483,7 +3496,7 @@ export const manifest: Manifest = {
|
|
|
3483
3496
|
},
|
|
3484
3497
|
location: {
|
|
3485
3498
|
filePath: 'src/ctx/base.ts',
|
|
3486
|
-
lineNumber:
|
|
3499
|
+
lineNumber: 403,
|
|
3487
3500
|
},
|
|
3488
3501
|
type: '() => Promise<SsoUser[]>',
|
|
3489
3502
|
},
|
|
@@ -3505,7 +3518,7 @@ export const manifest: Manifest = {
|
|
|
3505
3518
|
},
|
|
3506
3519
|
location: {
|
|
3507
3520
|
filePath: 'src/ctx/base.ts',
|
|
3508
|
-
lineNumber:
|
|
3521
|
+
lineNumber: 425,
|
|
3509
3522
|
},
|
|
3510
3523
|
type: '(params: Record<string, unknown>) => Promise<void>',
|
|
3511
3524
|
},
|
|
@@ -3518,7 +3531,7 @@ export const manifest: Manifest = {
|
|
|
3518
3531
|
},
|
|
3519
3532
|
location: {
|
|
3520
3533
|
filePath: 'src/ctx/base.ts',
|
|
3521
|
-
lineNumber:
|
|
3534
|
+
lineNumber: 476,
|
|
3522
3535
|
},
|
|
3523
3536
|
type: '(\n fieldId: string,\n changes: FieldAppearanceChange[],\n ) => Promise<void>',
|
|
3524
3537
|
},
|
|
@@ -3540,7 +3553,7 @@ export const manifest: Manifest = {
|
|
|
3540
3553
|
},
|
|
3541
3554
|
location: {
|
|
3542
3555
|
filePath: 'src/ctx/base.ts',
|
|
3543
|
-
lineNumber:
|
|
3556
|
+
lineNumber: 581,
|
|
3544
3557
|
},
|
|
3545
3558
|
type: '(message: string) => Promise<void>',
|
|
3546
3559
|
},
|
|
@@ -3553,7 +3566,7 @@ export const manifest: Manifest = {
|
|
|
3553
3566
|
},
|
|
3554
3567
|
location: {
|
|
3555
3568
|
filePath: 'src/ctx/base.ts',
|
|
3556
|
-
lineNumber:
|
|
3569
|
+
lineNumber: 596,
|
|
3557
3570
|
},
|
|
3558
3571
|
type: '(message: string) => Promise<void>',
|
|
3559
3572
|
},
|
|
@@ -3566,7 +3579,7 @@ export const manifest: Manifest = {
|
|
|
3566
3579
|
},
|
|
3567
3580
|
location: {
|
|
3568
3581
|
filePath: 'src/ctx/base.ts',
|
|
3569
|
-
lineNumber:
|
|
3582
|
+
lineNumber: 620,
|
|
3570
3583
|
},
|
|
3571
3584
|
type: '<CtaValue = unknown>(\n toast: Toast<CtaValue>,\n ) => Promise<CtaValue | null>',
|
|
3572
3585
|
},
|
|
@@ -3588,7 +3601,7 @@ export const manifest: Manifest = {
|
|
|
3588
3601
|
},
|
|
3589
3602
|
location: {
|
|
3590
3603
|
filePath: 'src/ctx/base.ts',
|
|
3591
|
-
lineNumber:
|
|
3604
|
+
lineNumber: 506,
|
|
3592
3605
|
},
|
|
3593
3606
|
type: '(itemTypeId: string) => Promise<Item | null>',
|
|
3594
3607
|
},
|
|
@@ -3601,7 +3614,7 @@ export const manifest: Manifest = {
|
|
|
3601
3614
|
},
|
|
3602
3615
|
location: {
|
|
3603
3616
|
filePath: 'src/ctx/base.ts',
|
|
3604
|
-
lineNumber:
|
|
3617
|
+
lineNumber: 527,
|
|
3605
3618
|
},
|
|
3606
3619
|
type: '{\n (\n itemTypeId: string,\n options: { multiple: true; initialLocationQuery?: ItemListLocationQuery },\n ): Promise<Item[] | null>;\n (\n itemTypeId: string,\n options?: {\n multiple: false;\n initialLocationQuery?: ItemListLocationQuery;\n },\n ): Promise<Item | null>;\n }',
|
|
3607
3620
|
},
|
|
@@ -3614,7 +3627,7 @@ export const manifest: Manifest = {
|
|
|
3614
3627
|
},
|
|
3615
3628
|
location: {
|
|
3616
3629
|
filePath: 'src/ctx/base.ts',
|
|
3617
|
-
lineNumber:
|
|
3630
|
+
lineNumber: 559,
|
|
3618
3631
|
},
|
|
3619
3632
|
type: '(itemId: string) => Promise<Item | null>',
|
|
3620
3633
|
},
|
|
@@ -3636,7 +3649,7 @@ export const manifest: Manifest = {
|
|
|
3636
3649
|
},
|
|
3637
3650
|
location: {
|
|
3638
3651
|
filePath: 'src/ctx/base.ts',
|
|
3639
|
-
lineNumber:
|
|
3652
|
+
lineNumber: 647,
|
|
3640
3653
|
},
|
|
3641
3654
|
type: '{\n (options: { multiple: true }): Promise<Upload[] | null>;\n (options?: { multiple: false }): Promise<Upload | null>;\n }',
|
|
3642
3655
|
},
|
|
@@ -3649,7 +3662,7 @@ export const manifest: Manifest = {
|
|
|
3649
3662
|
},
|
|
3650
3663
|
location: {
|
|
3651
3664
|
filePath: 'src/ctx/base.ts',
|
|
3652
|
-
lineNumber:
|
|
3665
|
+
lineNumber: 675,
|
|
3653
3666
|
},
|
|
3654
3667
|
type: '(\n uploadId: string,\n ) => Promise<(Upload & { deleted?: true }) | null>',
|
|
3655
3668
|
},
|
|
@@ -3662,7 +3675,7 @@ export const manifest: Manifest = {
|
|
|
3662
3675
|
},
|
|
3663
3676
|
location: {
|
|
3664
3677
|
filePath: 'src/ctx/base.ts',
|
|
3665
|
-
lineNumber:
|
|
3678
|
+
lineNumber: 703,
|
|
3666
3679
|
},
|
|
3667
3680
|
type: '(\n /** The "single asset" field structure */\n fileFieldValue: FileFieldValue,\n /** Shows metadata information for a specific locale */\n locale?: string,\n ) => Promise<FileFieldValue | null>',
|
|
3668
3681
|
},
|
|
@@ -3684,7 +3697,7 @@ export const manifest: Manifest = {
|
|
|
3684
3697
|
},
|
|
3685
3698
|
location: {
|
|
3686
3699
|
filePath: 'src/ctx/base.ts',
|
|
3687
|
-
lineNumber:
|
|
3700
|
+
lineNumber: 734,
|
|
3688
3701
|
},
|
|
3689
3702
|
type: '(modal: Modal) => Promise<unknown>',
|
|
3690
3703
|
},
|
|
@@ -3697,7 +3710,7 @@ export const manifest: Manifest = {
|
|
|
3697
3710
|
},
|
|
3698
3711
|
location: {
|
|
3699
3712
|
filePath: 'src/ctx/base.ts',
|
|
3700
|
-
lineNumber:
|
|
3713
|
+
lineNumber: 771,
|
|
3701
3714
|
},
|
|
3702
3715
|
type: '(options: ConfirmOptions) => Promise<unknown>',
|
|
3703
3716
|
},
|
|
@@ -3718,7 +3731,7 @@ export const manifest: Manifest = {
|
|
|
3718
3731
|
},
|
|
3719
3732
|
location: {
|
|
3720
3733
|
filePath: 'src/ctx/base.ts',
|
|
3721
|
-
lineNumber:
|
|
3734
|
+
lineNumber: 785,
|
|
3722
3735
|
},
|
|
3723
3736
|
type: '(path: string) => Promise<void>',
|
|
3724
3737
|
},
|