-
Notifications
You must be signed in to change notification settings - Fork 283
✨ Add a custom callout block to the editor #892
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
✨ Add a custom callout block to the editor #892
Conversation
Great job! Just small UI considerations here. |
Hey thanks for your feedback Made some changes on the callout. And the emoji's background color transition on hover |
we need functionalities and data to implement a custom emoji picker component, as blocknote's emojipicker component triggers and uses cases are limited. add to \`package.json\` the following packages: - \`emoji-mart\`: provides functions and components for displaying, searching and selecting emojis. - `\@emoji-mart/data\`: offers pre-configured sets of emojis.
Add a custom emoji picker component to use in the editor
Add a custom block to the editor, the callout block.
Adapt modal export to include PDF and Docx export for the callout block.
Add translation for the callout component to be shown in the suggestion menu and slash menu. Add missing "Beautify" AI action in French.
Fix editor's callout block border corner, paddings and margins to match design docs, apply sam fix on paragraph and heading blocks to keep a visual consistency when highlighted.
e7dd4fa
to
1bc17a2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @ZouicheOmar this looks awesome ! Thanks a lot for your contribution.
Just one feedback, one thing I noticed in your screen capture is that by default the call out block has a white background.
How about we give it yellow background by default that people can change if they want to.
@ZouicheOmar |
Now the default bg for a callout is yellow. Democallout_default_bg.webmSolution is not quite elegant, would be cleaner with a custom side menu, or a change on blocknotejs. Will keep an eye on it. @virgile-dev I am definitely coming to the hack days ! Just waiting for my invite to be checked and I'll be all set. |
Refactor and add typing to callout block to fix lint issues.
Set the default background color to yellow on the callout block.
75adfd5
to
0a3f580
Compare
Purpose
This PR addresses issue #305. Add a new custom block to the editor, the callout block.
Proposal
emoji-mart
library, which is already used by blocknote. That's to have custom triggers and use of the component.Demo
callout.webm
PDF and Docx Exports
Would love any feedback if this needs improvements, corrections or any changes.