Blocks attributes
Question
const blocktext = blockManager.get('text').set({ label: 'Modified text', attributes: { } })
I want to add an attribute to the original text block, I want the attribute to give the user the option of giving the component, time to appear and disappear at another time.
My question is, what are the attributes that I can make use of? and does it work if I refer in the attribute to a javascript that allows him to do this function?
Answers (1)
You can do this editor.Blocks.get('text').set({ attributes: { class: 'my-custom-class' } })
Related Questions and Answers
Continue research with similar issue discussions.
Issue #2417
API in Component not working after Deployment
Block.js => Component.js => We are able to call the API and it works in Deployment when we are passing the whole html with script, body, st...
Issue #894
Add a custom attribute
Hi everyone, I am creating new blocks, when I use the following method: editor.BlockManager.add(blockId, { label: blockLabel, content: {......
Issue #1545
[Question] How I Get ID From Block?
Hi, i have my block and I get print in Div id results from my javascript class component... How i get ID from my block ??? editor.BlockMana...
Issue #3207
Form is not submitting
I am trying to create as custom block. But the form is not submitting when i use components inside content. I am able to get all the form d...
Paid Plugins That Match This Issue
Curated by issue keywords and label relevance to help you ship faster.
Loading paid plugin recommendations...
Browse Plugin Categories
Jump directly to plugin category pages on the marketplace.