API > @blocksuite/blocks > ListBlockSchema
Variable: ListBlockSchema ​
const
ListBlockSchema:object
Type declaration ​
model
​
model: {
flavour
:"affine:list"
;props
:PropsGetter
< {checked
:boolean
;collapsed
:ListCollapsed
;text
:Text
;type
:ListType
;} >;role
:"root"
|"hub"
|"content"
;} & {parent
:string
[];role
:"content"
;version
:number
;}
model.flavour
​flavour:
"affine:list"
model.props
​props:
PropsGetter
< {checked
:boolean
;collapsed
:ListCollapsed
;text
:Text
;type
:ListType
;} >
model.role
​role:
"root"
|"hub"
|"content"
model.parent
​parent:
string
[]
model.role
​role:
"content"
='content'
model.version
​version:
number
=1
onUpgrade
​
optional
onUpgrade:function
Parameters ​
Parameter | Type |
---|---|
data | object |
data.checked | boolean |
data.collapsed | ListCollapsed |
data.text | Text |
data.type | ListType |
previousVersion | number |
latestVersion | number |
Returns ​
void
transformer
​
optional
transformer:function
Returns ​
BaseBlockTransformer
< {checked
: boolean
; collapsed
: ListCollapsed
; text
: Text
; type
: ListType
;} >
version
​
version:
number
Defined In ​
packages/blocks/src/list-block/list-model.ts:12