Skip to content

Commit a8423de

Browse files
committed
feat(richtext-lexical): add disableListColumn to lexicalHTMLField args
1 parent c29e1f0 commit a8423de

File tree

1 file changed

+15
-1
lines changed
  • packages/richtext-lexical/src/features/converters/lexicalToHtml/async/field

1 file changed

+15
-1
lines changed

packages/richtext-lexical/src/features/converters/lexicalToHtml/async/field/index.ts

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,12 @@ import { convertLexicalToHTMLAsync } from '../index.js'
88

99
type Args = {
1010
converters?: HTMLConvertersAsync | HTMLConvertersFunctionAsync
11+
/**
12+
* Whether the lexicalHTML field should appear in the list view filter options.
13+
*
14+
* @default true
15+
*/
16+
disableListColumn?: boolean
1117
/**
1218
* Whether the lexicalHTML field should be hidden in the admin panel
1319
*
@@ -36,11 +42,19 @@ type Args = {
3642
* @todo will be renamed to lexicalHTML in 4.0, replacing the deprecated `lexicalHTML` converter
3743
*/
3844
export const lexicalHTMLField: (args: Args) => Field = (args) => {
39-
const { converters, hidden = true, htmlFieldName, lexicalFieldName, storeInDB = false } = args
45+
const {
46+
converters,
47+
disableListColumn = true,
48+
hidden = true,
49+
htmlFieldName,
50+
lexicalFieldName,
51+
storeInDB = false,
52+
} = args
4053
const field: Field = {
4154
name: htmlFieldName,
4255
type: 'code',
4356
admin: {
57+
disableListColumn,
4458
editorOptions: {
4559
language: 'html',
4660
},

0 commit comments

Comments
 (0)