BlockNote
BlockNote copied to clipboard
Programmable Visibility for Format Toolbar
Currently, there is no way to control the visibility state of the format toolbar in Blocknotejs. This becomes a problem in situations where we have a custom formatting toolbar with a button, which, when clicked, displays a control component that needs to have focus on an input or a textarea, or the new component no longer needs the toolbar to be present for UI/UX reasons
I would like for Blocknotejs to offer an option to programmatically control the visibility of the format toolbar.
Here, I present a use case in which I have a custom formatting toolbar, with an AI-style button, similar to Notion. It can be seen how the custom formatting tool blocks the command component.
https://github.com/TypeCellOS/BlockNote/assets/44955121/2b1de3dc-a8a2-45ff-a5c6-4309be989c01
In this case, it would be appropriate to hide the custom formatting toolbar once the AI button has been clicked and the command component rendered.