mirror of https://github.com/artf/grapesjs.git
nocodeframeworkdrag-and-dropsite-buildersite-generatortemplate-builderui-builderweb-builderweb-builder-frameworkwebsite-builderno-codepage-builder
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
1.9 KiB
1.9 KiB
Block
Properties
labelString Block label, eg.My blockcontent(String | Object) The content of the block. Might be an HTML string or a Component DefinitionmediaString? HTML string for the media/icon of the block, eg.<svg ...,<img ..., etc.categoryString? Block category, eg.Basic blocksactivateBoolean? If true, triggers theactiveevent on the dropped component.selectBoolean? If true, the dropped component will be selected.resetIdBoolean? If true, all IDs of dropped components and their styles will be changed.disableBoolean? Disable the block from being interactedonClickFunction? Custom behavior on click, eg.(block, editor) => editor.getWrapper().append(block.get('content'))attributesObject? Block attributes to apply in the view element
getId
Get block id
Returns String
getLabel
Get block label
Returns String
getMedia
Get block media
Returns String
getContent
Get block content
Returns (Object | String | Array<(Object | String)>)
getDragDef
Get block component dragDef
Returns ComponentDefinition
getCategoryLabel
Get block category label
Returns String