Files
payloadcms/test/lexical/payload-types.ts
Alessio Gravili 59414bd8f1 feat(richtext-lexical): support copy & pasting and drag & dopping files/images into the editor (#13868)
This PR adds support for inserting images into the rich text editor via
both **copy & paste** and **drag & drop**, whether from local files or
image DOM nodes.

It leverages the bulk uploads UI to provide a smooth workflow for:
- Selecting the target collection
- Filling in any required fields defined on the uploads collection
- Uploading multiple images at once

This significantly improves the UX for adding images to rich text, and
also works seamlessly when pasting images from external editors like
Google Docs or Microsoft Word.

Test pre-release: `3.57.0-internal.801ab5a`

## Showcase - drag & drop images from computer


https://github.com/user-attachments/assets/c558c034-d2e4-40d8-9035-c0681389fb7b

## Showcase - copy & paste images from computer


https://github.com/user-attachments/assets/f36faf94-5274-4151-b141-00aff2b0efa4

## Showcase - copy & paste image DOM nodes


https://github.com/user-attachments/assets/2839ed0f-3f28-4e8d-8b47-01d0cb947edc

---
- To see the specific tasks where the Asana app for GitHub is being
used, see below:
  - https://app.asana.com/0/0/1211217132290841
2025-09-24 15:04:46 +00:00

1610 lines
38 KiB
TypeScript

/* tslint:disable */
/* eslint-disable */
/**
* This file was automatically generated by Payload.
* DO NOT MODIFY IT BY HAND. Instead, modify your source Payload config,
* and re-run `payload generate:types` to regenerate this file.
*/
/**
* Supported timezones in IANA format.
*
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "supportedTimezones".
*/
export type SupportedTimezones =
| 'Pacific/Midway'
| 'Pacific/Niue'
| 'Pacific/Honolulu'
| 'Pacific/Rarotonga'
| 'America/Anchorage'
| 'Pacific/Gambier'
| 'America/Los_Angeles'
| 'America/Tijuana'
| 'America/Denver'
| 'America/Phoenix'
| 'America/Chicago'
| 'America/Guatemala'
| 'America/New_York'
| 'America/Bogota'
| 'America/Caracas'
| 'America/Santiago'
| 'America/Buenos_Aires'
| 'America/Sao_Paulo'
| 'Atlantic/South_Georgia'
| 'Atlantic/Azores'
| 'Atlantic/Cape_Verde'
| 'Europe/London'
| 'Europe/Berlin'
| 'Africa/Lagos'
| 'Europe/Athens'
| 'Africa/Cairo'
| 'Europe/Moscow'
| 'Asia/Riyadh'
| 'Asia/Dubai'
| 'Asia/Baku'
| 'Asia/Karachi'
| 'Asia/Tashkent'
| 'Asia/Calcutta'
| 'Asia/Dhaka'
| 'Asia/Almaty'
| 'Asia/Jakarta'
| 'Asia/Bangkok'
| 'Asia/Shanghai'
| 'Asia/Singapore'
| 'Asia/Tokyo'
| 'Asia/Seoul'
| 'Australia/Brisbane'
| 'Australia/Sydney'
| 'Pacific/Guam'
| 'Pacific/Noumea'
| 'Pacific/Auckland'
| 'Pacific/Fiji';
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "BlockColumns".
*/
export type BlockColumns =
| {
text?: string | null;
subArray?:
| {
requiredText: string;
id?: string | null;
}[]
| null;
id?: string | null;
}[]
| null;
export interface Config {
auth: {
users: UserAuthOperations;
};
blocks: {};
collections: {
'lexical-fully-featured': LexicalFullyFeatured;
'lexical-link-feature': LexicalLinkFeature;
'lexical-heading-feature': LexicalHeadingFeature;
'lexical-jsx-converter': LexicalJsxConverter;
'lexical-fields': LexicalField;
'lexical-migrate-fields': LexicalMigrateField;
'lexical-localized-fields': LexicalLocalizedField;
lexicalObjectReferenceBug: LexicalObjectReferenceBug;
LexicalInBlock: LexicalInBlock;
'lexical-access-control': LexicalAccessControl;
'lexical-relationship-fields': LexicalRelationshipField;
'rich-text-fields': RichTextField;
'text-fields': TextField;
uploads: Upload;
uploads2: Uploads2;
'array-fields': ArrayField;
OnDemandForm: OnDemandForm;
OnDemandOutsideForm: OnDemandOutsideForm;
users: User;
'payload-locked-documents': PayloadLockedDocument;
'payload-preferences': PayloadPreference;
'payload-migrations': PayloadMigration;
};
collectionsJoins: {};
collectionsSelect: {
'lexical-fully-featured': LexicalFullyFeaturedSelect<false> | LexicalFullyFeaturedSelect<true>;
'lexical-link-feature': LexicalLinkFeatureSelect<false> | LexicalLinkFeatureSelect<true>;
'lexical-heading-feature': LexicalHeadingFeatureSelect<false> | LexicalHeadingFeatureSelect<true>;
'lexical-jsx-converter': LexicalJsxConverterSelect<false> | LexicalJsxConverterSelect<true>;
'lexical-fields': LexicalFieldsSelect<false> | LexicalFieldsSelect<true>;
'lexical-migrate-fields': LexicalMigrateFieldsSelect<false> | LexicalMigrateFieldsSelect<true>;
'lexical-localized-fields': LexicalLocalizedFieldsSelect<false> | LexicalLocalizedFieldsSelect<true>;
lexicalObjectReferenceBug: LexicalObjectReferenceBugSelect<false> | LexicalObjectReferenceBugSelect<true>;
LexicalInBlock: LexicalInBlockSelect<false> | LexicalInBlockSelect<true>;
'lexical-access-control': LexicalAccessControlSelect<false> | LexicalAccessControlSelect<true>;
'lexical-relationship-fields': LexicalRelationshipFieldsSelect<false> | LexicalRelationshipFieldsSelect<true>;
'rich-text-fields': RichTextFieldsSelect<false> | RichTextFieldsSelect<true>;
'text-fields': TextFieldsSelect<false> | TextFieldsSelect<true>;
uploads: UploadsSelect<false> | UploadsSelect<true>;
uploads2: Uploads2Select<false> | Uploads2Select<true>;
'array-fields': ArrayFieldsSelect<false> | ArrayFieldsSelect<true>;
OnDemandForm: OnDemandFormSelect<false> | OnDemandFormSelect<true>;
OnDemandOutsideForm: OnDemandOutsideFormSelect<false> | OnDemandOutsideFormSelect<true>;
users: UsersSelect<false> | UsersSelect<true>;
'payload-locked-documents': PayloadLockedDocumentsSelect<false> | PayloadLockedDocumentsSelect<true>;
'payload-preferences': PayloadPreferencesSelect<false> | PayloadPreferencesSelect<true>;
'payload-migrations': PayloadMigrationsSelect<false> | PayloadMigrationsSelect<true>;
};
db: {
defaultIDType: number;
};
globals: {
tabsWithRichText: TabsWithRichText;
};
globalsSelect: {
tabsWithRichText: TabsWithRichTextSelect<false> | TabsWithRichTextSelect<true>;
};
locale: 'en' | 'es';
user: User & {
collection: 'users';
};
jobs: {
tasks: unknown;
workflows: unknown;
};
}
export interface UserAuthOperations {
forgotPassword: {
email: string;
password: string;
};
login: {
email: string;
password: string;
};
registerFirstUser: {
email: string;
password: string;
};
unlock: {
email: string;
password: string;
};
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "lexical-fully-featured".
*/
export interface LexicalFullyFeatured {
id: number;
richText?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
updatedAt: string;
createdAt: string;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "lexical-link-feature".
*/
export interface LexicalLinkFeature {
id: number;
richText?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
updatedAt: string;
createdAt: string;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "lexical-heading-feature".
*/
export interface LexicalHeadingFeature {
id: string;
richText?: {
root: {
type: string;
children: {
type: string;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
updatedAt: string;
createdAt: string;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "lexical-jsx-converter".
*/
export interface LexicalJsxConverter {
id: number;
richText?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
updatedAt: string;
createdAt: string;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "lexical-fields".
*/
export interface LexicalField {
id: number;
title: string;
lexicalRootEditor?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
lexicalSimple?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
lexicalWithBlocks: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
};
lexicalWithBlocks_markdown?: string | null;
updatedAt: string;
createdAt: string;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "lexical-migrate-fields".
*/
export interface LexicalMigrateField {
id: number;
title: string;
lexicalWithLexicalPluginData?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
lexicalWithSlateData?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
lexicalSimple?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
lexicalSimple_html?: string | null;
groupWithLexicalField?: {
lexicalInGroupField?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
lexicalInGroupField_html?: string | null;
};
arrayWithLexicalField?:
| {
lexicalInArrayField?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
lexicalInArrayField_html?: string | null;
id?: string | null;
}[]
| null;
updatedAt: string;
createdAt: string;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "lexical-localized-fields".
*/
export interface LexicalLocalizedField {
id: number;
title: string;
/**
* Non-localized field with localized block subfields
*/
lexicalBlocksSubLocalized?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
/**
* Localized field with localized block subfields
*/
lexicalBlocksLocalized?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
updatedAt: string;
createdAt: string;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "lexicalObjectReferenceBug".
*/
export interface LexicalObjectReferenceBug {
id: number;
lexicalDefault?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
lexicalEditor?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
updatedAt: string;
createdAt: string;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "LexicalInBlock".
*/
export interface LexicalInBlock {
id: number;
content?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
blocks?:
| {
lexical?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
id?: string | null;
blockName?: string | null;
blockType: 'lexicalInBlock2';
}[]
| null;
updatedAt: string;
createdAt: string;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "lexical-access-control".
*/
export interface LexicalAccessControl {
id: number;
title?: string | null;
richText?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
updatedAt: string;
createdAt: string;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "lexical-relationship-fields".
*/
export interface LexicalRelationshipField {
id: number;
richText?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
richText2?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
updatedAt: string;
createdAt: string;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "rich-text-fields".
*/
export interface RichTextField {
id: number;
title: string;
lexicalCustomFields: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
};
lexicalCustomFields_html?: string | null;
/**
* This rich text field uses the lexical editor.
*/
lexical?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
/**
* This select field is rendered here to ensure its options dropdown renders above the rich text toolbar.
*/
selectHasMany?: ('one' | 'two' | 'three' | 'four' | 'five' | 'six')[] | null;
richText: {
[k: string]: unknown;
}[];
richTextCustomFields?:
| {
[k: string]: unknown;
}[]
| null;
richTextReadOnly?:
| {
[k: string]: unknown;
}[]
| null;
blocks?:
| (
| {
text?: string | null;
id?: string | null;
blockName?: string | null;
blockType: 'textBlock';
}
| {
text?:
| {
[k: string]: unknown;
}[]
| null;
id?: string | null;
blockName?: string | null;
blockType: 'richTextBlockSlate';
}
)[]
| null;
updatedAt: string;
createdAt: string;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "text-fields".
*/
export interface TextField {
id: number;
text: string;
hiddenTextField?: string | null;
/**
* This field should be hidden
*/
adminHiddenTextField?: string | null;
/**
* This field should be disabled
*/
disabledTextField?: string | null;
localizedText?: string | null;
/**
* en description
*/
i18nText?: string | null;
defaultString?: string | null;
defaultEmptyString?: string | null;
defaultFunction?: string | null;
defaultAsync?: string | null;
overrideLength?: string | null;
fieldWithDefaultValue?: string | null;
dependentOnFieldWithDefaultValue?: string | null;
hasMany?: string[] | null;
readOnlyHasMany?: string[] | null;
validatesHasMany?: string[] | null;
localizedHasMany?: string[] | null;
withMinRows?: string[] | null;
withMaxRows?: string[] | null;
defaultValueFromReq?: string | null;
array?:
| {
texts?: string[] | null;
id?: string | null;
}[]
| null;
blocks?:
| {
texts?: string[] | null;
id?: string | null;
blockName?: string | null;
blockType: 'blockWithText';
}[]
| null;
updatedAt: string;
createdAt: string;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "uploads".
*/
export interface Upload {
id: number;
text?: string | null;
media?: (number | null) | Upload;
updatedAt: string;
createdAt: string;
url?: string | null;
thumbnailURL?: string | null;
filename?: string | null;
mimeType?: string | null;
filesize?: number | null;
width?: number | null;
height?: number | null;
focalX?: number | null;
focalY?: number | null;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "uploads2".
*/
export interface Uploads2 {
id: string;
text?: string | null;
media?: (string | null) | Upload;
altText?: string | null;
updatedAt: string;
createdAt: string;
url?: string | null;
thumbnailURL?: string | null;
filename?: string | null;
mimeType?: string | null;
filesize?: number | null;
width?: number | null;
height?: number | null;
focalX?: number | null;
focalY?: number | null;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "array-fields".
*/
export interface ArrayField {
id: number;
title?: string | null;
items: {
text: string;
anotherText?: string | null;
localizedText?: string | null;
subArray?:
| {
text?: string | null;
textTwo: string;
textInRow: string;
id?: string | null;
}[]
| null;
id?: string | null;
}[];
collapsedArray?:
| {
text: string;
id?: string | null;
}[]
| null;
localized: {
text: string;
id?: string | null;
}[];
readOnly?:
| {
text?: string | null;
id?: string | null;
}[]
| null;
potentiallyEmptyArray?:
| {
text?: string | null;
groupInRow?: {
textInGroupInRow?: string | null;
};
id?: string | null;
}[]
| null;
/**
* Row labels rendered as react components.
*/
rowLabelAsComponent?:
| {
title?: string | null;
id?: string | null;
}[]
| null;
arrayWithMinRows?:
| {
text?: string | null;
id?: string | null;
}[]
| null;
disableSort?:
| {
text: string;
id?: string | null;
}[]
| null;
nestedArrayLocalized?:
| {
array?:
| {
text?: string | null;
id?: string | null;
}[]
| null;
id?: string | null;
}[]
| null;
externallyUpdatedArray?:
| {
id?: string | null;
}[]
| null;
customArrayField?:
| {
text?: string | null;
id?: string | null;
}[]
| null;
arrayWithLabels?:
| {
text?: string | null;
id?: string | null;
}[]
| null;
updatedAt: string;
createdAt: string;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "OnDemandForm".
*/
export interface OnDemandForm {
id: number;
json?:
| {
[k: string]: unknown;
}
| unknown[]
| string
| number
| boolean
| null;
updatedAt: string;
createdAt: string;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "OnDemandOutsideForm".
*/
export interface OnDemandOutsideForm {
id: number;
json?:
| {
[k: string]: unknown;
}
| unknown[]
| string
| number
| boolean
| null;
hiddenAnchor?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
updatedAt: string;
createdAt: string;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "users".
*/
export interface User {
id: number;
updatedAt: string;
createdAt: string;
email: string;
resetPasswordToken?: string | null;
resetPasswordExpiration?: string | null;
salt?: string | null;
hash?: string | null;
loginAttempts?: number | null;
lockUntil?: string | null;
sessions?:
| {
id: string;
createdAt?: string | null;
expiresAt: string;
}[]
| null;
password?: string | null;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "payload-locked-documents".
*/
export interface PayloadLockedDocument {
id: number;
document?:
| ({
relationTo: 'lexical-fully-featured';
value: number | LexicalFullyFeatured;
} | null)
| ({
relationTo: 'lexical-link-feature';
value: number | LexicalLinkFeature;
} | null)
| ({
relationTo: 'lexical-heading-feature';
value: string | LexicalHeadingFeature;
} | null)
| ({
relationTo: 'lexical-jsx-converter';
value: number | LexicalJsxConverter;
} | null)
| ({
relationTo: 'lexical-fields';
value: number | LexicalField;
} | null)
| ({
relationTo: 'lexical-migrate-fields';
value: number | LexicalMigrateField;
} | null)
| ({
relationTo: 'lexical-localized-fields';
value: number | LexicalLocalizedField;
} | null)
| ({
relationTo: 'lexicalObjectReferenceBug';
value: number | LexicalObjectReferenceBug;
} | null)
| ({
relationTo: 'LexicalInBlock';
value: number | LexicalInBlock;
} | null)
| ({
relationTo: 'lexical-access-control';
value: number | LexicalAccessControl;
} | null)
| ({
relationTo: 'lexical-relationship-fields';
value: number | LexicalRelationshipField;
} | null)
| ({
relationTo: 'rich-text-fields';
value: number | RichTextField;
} | null)
| ({
relationTo: 'text-fields';
value: number | TextField;
} | null)
| ({
relationTo: 'uploads';
value: number | Upload;
} | null)
| ({
relationTo: 'uploads2';
value: string | Uploads2;
} | null)
| ({
relationTo: 'array-fields';
value: number | ArrayField;
} | null)
| ({
relationTo: 'OnDemandForm';
value: number | OnDemandForm;
} | null)
| ({
relationTo: 'OnDemandOutsideForm';
value: number | OnDemandOutsideForm;
} | null)
| ({
relationTo: 'users';
value: number | User;
} | null);
globalSlug?: string | null;
user: {
relationTo: 'users';
value: number | User;
};
updatedAt: string;
createdAt: string;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "payload-preferences".
*/
export interface PayloadPreference {
id: number;
user: {
relationTo: 'users';
value: number | User;
};
key?: string | null;
value?:
| {
[k: string]: unknown;
}
| unknown[]
| string
| number
| boolean
| null;
updatedAt: string;
createdAt: string;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "payload-migrations".
*/
export interface PayloadMigration {
id: number;
name?: string | null;
batch?: number | null;
updatedAt: string;
createdAt: string;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "lexical-fully-featured_select".
*/
export interface LexicalFullyFeaturedSelect<T extends boolean = true> {
richText?: T;
updatedAt?: T;
createdAt?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "lexical-link-feature_select".
*/
export interface LexicalLinkFeatureSelect<T extends boolean = true> {
richText?: T;
updatedAt?: T;
createdAt?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "lexical-heading-feature_select".
*/
export interface LexicalHeadingFeatureSelect<T extends boolean = true> {
richText?: T;
updatedAt?: T;
createdAt?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "lexical-jsx-converter_select".
*/
export interface LexicalJsxConverterSelect<T extends boolean = true> {
richText?: T;
updatedAt?: T;
createdAt?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "lexical-fields_select".
*/
export interface LexicalFieldsSelect<T extends boolean = true> {
title?: T;
lexicalRootEditor?: T;
lexicalSimple?: T;
lexicalWithBlocks?: T;
lexicalWithBlocks_markdown?: T;
updatedAt?: T;
createdAt?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "lexical-migrate-fields_select".
*/
export interface LexicalMigrateFieldsSelect<T extends boolean = true> {
title?: T;
lexicalWithLexicalPluginData?: T;
lexicalWithSlateData?: T;
lexicalSimple?: T;
lexicalSimple_html?: T;
groupWithLexicalField?:
| T
| {
lexicalInGroupField?: T;
lexicalInGroupField_html?: T;
};
arrayWithLexicalField?:
| T
| {
lexicalInArrayField?: T;
lexicalInArrayField_html?: T;
id?: T;
};
updatedAt?: T;
createdAt?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "lexical-localized-fields_select".
*/
export interface LexicalLocalizedFieldsSelect<T extends boolean = true> {
title?: T;
lexicalBlocksSubLocalized?: T;
lexicalBlocksLocalized?: T;
updatedAt?: T;
createdAt?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "lexicalObjectReferenceBug_select".
*/
export interface LexicalObjectReferenceBugSelect<T extends boolean = true> {
lexicalDefault?: T;
lexicalEditor?: T;
updatedAt?: T;
createdAt?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "LexicalInBlock_select".
*/
export interface LexicalInBlockSelect<T extends boolean = true> {
content?: T;
blocks?:
| T
| {
lexicalInBlock2?:
| T
| {
lexical?: T;
id?: T;
blockName?: T;
};
};
updatedAt?: T;
createdAt?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "lexical-access-control_select".
*/
export interface LexicalAccessControlSelect<T extends boolean = true> {
title?: T;
richText?: T;
updatedAt?: T;
createdAt?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "lexical-relationship-fields_select".
*/
export interface LexicalRelationshipFieldsSelect<T extends boolean = true> {
richText?: T;
richText2?: T;
updatedAt?: T;
createdAt?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "rich-text-fields_select".
*/
export interface RichTextFieldsSelect<T extends boolean = true> {
title?: T;
lexicalCustomFields?: T;
lexicalCustomFields_html?: T;
lexical?: T;
selectHasMany?: T;
richText?: T;
richTextCustomFields?: T;
richTextReadOnly?: T;
blocks?:
| T
| {
textBlock?:
| T
| {
text?: T;
id?: T;
blockName?: T;
};
richTextBlockSlate?:
| T
| {
text?: T;
id?: T;
blockName?: T;
};
};
updatedAt?: T;
createdAt?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "text-fields_select".
*/
export interface TextFieldsSelect<T extends boolean = true> {
text?: T;
hiddenTextField?: T;
adminHiddenTextField?: T;
disabledTextField?: T;
localizedText?: T;
i18nText?: T;
defaultString?: T;
defaultEmptyString?: T;
defaultFunction?: T;
defaultAsync?: T;
overrideLength?: T;
fieldWithDefaultValue?: T;
dependentOnFieldWithDefaultValue?: T;
hasMany?: T;
readOnlyHasMany?: T;
validatesHasMany?: T;
localizedHasMany?: T;
withMinRows?: T;
withMaxRows?: T;
defaultValueFromReq?: T;
array?:
| T
| {
texts?: T;
id?: T;
};
blocks?:
| T
| {
blockWithText?:
| T
| {
texts?: T;
id?: T;
blockName?: T;
};
};
updatedAt?: T;
createdAt?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "uploads_select".
*/
export interface UploadsSelect<T extends boolean = true> {
text?: T;
media?: T;
updatedAt?: T;
createdAt?: T;
url?: T;
thumbnailURL?: T;
filename?: T;
mimeType?: T;
filesize?: T;
width?: T;
height?: T;
focalX?: T;
focalY?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "uploads2_select".
*/
export interface Uploads2Select<T extends boolean = true> {
text?: T;
media?: T;
altText?: T;
updatedAt?: T;
createdAt?: T;
url?: T;
thumbnailURL?: T;
filename?: T;
mimeType?: T;
filesize?: T;
width?: T;
height?: T;
focalX?: T;
focalY?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "array-fields_select".
*/
export interface ArrayFieldsSelect<T extends boolean = true> {
title?: T;
items?:
| T
| {
text?: T;
anotherText?: T;
localizedText?: T;
subArray?:
| T
| {
text?: T;
textTwo?: T;
textInRow?: T;
id?: T;
};
id?: T;
};
collapsedArray?:
| T
| {
text?: T;
id?: T;
};
localized?:
| T
| {
text?: T;
id?: T;
};
readOnly?:
| T
| {
text?: T;
id?: T;
};
potentiallyEmptyArray?:
| T
| {
text?: T;
groupInRow?:
| T
| {
textInGroupInRow?: T;
};
id?: T;
};
rowLabelAsComponent?:
| T
| {
title?: T;
id?: T;
};
arrayWithMinRows?:
| T
| {
text?: T;
id?: T;
};
disableSort?:
| T
| {
text?: T;
id?: T;
};
nestedArrayLocalized?:
| T
| {
array?:
| T
| {
text?: T;
id?: T;
};
id?: T;
};
externallyUpdatedArray?:
| T
| {
id?: T;
};
customArrayField?:
| T
| {
text?: T;
id?: T;
};
arrayWithLabels?:
| T
| {
text?: T;
id?: T;
};
updatedAt?: T;
createdAt?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "OnDemandForm_select".
*/
export interface OnDemandFormSelect<T extends boolean = true> {
json?: T;
updatedAt?: T;
createdAt?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "OnDemandOutsideForm_select".
*/
export interface OnDemandOutsideFormSelect<T extends boolean = true> {
json?: T;
hiddenAnchor?: T;
updatedAt?: T;
createdAt?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "users_select".
*/
export interface UsersSelect<T extends boolean = true> {
updatedAt?: T;
createdAt?: T;
email?: T;
resetPasswordToken?: T;
resetPasswordExpiration?: T;
salt?: T;
hash?: T;
loginAttempts?: T;
lockUntil?: T;
sessions?:
| T
| {
id?: T;
createdAt?: T;
expiresAt?: T;
};
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "payload-locked-documents_select".
*/
export interface PayloadLockedDocumentsSelect<T extends boolean = true> {
document?: T;
globalSlug?: T;
user?: T;
updatedAt?: T;
createdAt?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "payload-preferences_select".
*/
export interface PayloadPreferencesSelect<T extends boolean = true> {
user?: T;
key?: T;
value?: T;
updatedAt?: T;
createdAt?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "payload-migrations_select".
*/
export interface PayloadMigrationsSelect<T extends boolean = true> {
name?: T;
batch?: T;
updatedAt?: T;
createdAt?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "tabsWithRichText".
*/
export interface TabsWithRichText {
id: number;
tab1?: {
rt1?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
};
tab2?: {
rt2?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
};
updatedAt?: string | null;
createdAt?: string | null;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "tabsWithRichText_select".
*/
export interface TabsWithRichTextSelect<T extends boolean = true> {
tab1?:
| T
| {
rt1?: T;
};
tab2?:
| T
| {
rt2?: T;
};
updatedAt?: T;
createdAt?: T;
globalType?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "LexicalBlocksRadioButtonsBlock".
*/
export interface LexicalBlocksRadioButtonsBlock {
radioButtons?: ('option1' | 'option2' | 'option3') | null;
id?: string | null;
blockName?: string | null;
blockType: 'radioButtons';
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "AvatarGroupBlock".
*/
export interface AvatarGroupBlock {
avatars?:
| {
image?: (number | null) | Upload;
id?: string | null;
}[]
| null;
id?: string | null;
blockName?: string | null;
blockType: 'AvatarGroup';
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "auth".
*/
export interface Auth {
[k: string]: unknown;
}
declare module 'payload' {
// @ts-ignore
export interface GeneratedTypes extends Config {}
}