Skip to content

docs: Updated custom UI example - #926

Merged
YousefED merged 7 commits into
mainfrom
pro-examples-update
Aug 6, 2024
Merged

docs: Updated custom UI example#926
YousefED merged 7 commits into
mainfrom
pro-examples-update

Conversation

@matthewlipski

@matthewlipski matthewlipski commented Jul 15, 2024

Copy link
Copy Markdown
Collaborator

This PR reworks the custom UI example and adds a non-pro example for how to make a static formatting toolbar. The new custom UI example uses Material UI to implement replacements for the default Mantine components, and is extensively commented to show users how to customize elements and use other component libraries that aren't MUI.

Closes #867

@vercel

vercel Bot commented Jul 15, 2024

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
blocknote ✅ Ready (Inspect) Visit Preview Jul 19, 2024 5:17pm
blocknote-website ✅ Ready (Inspect) Visit Preview Jul 19, 2024 5:17pm

@YousefED YousefED left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice. I think this looks good but we can make a couple of improvements. Mainly to explain to readers what the concepts are behind the code. What's the architecture?

Otherwise, we just provide them with some sample replacements that they can edit, but might not go beyond that or really understand it because the concepts aren't explained.

Specifically, I'd suggest:

  • For every component, link / explain which built-in component is replaced. e.g. something like: "The MUIFormattingToolbar replaces the default FormattingToolbar (link) with a MUI-based one. It includes the same components as the default FormattingToolbar, but renders them using MUI elements instead. You can also adjust this code to add or remove specific buttons."
  • Explain when a user would implement a new package (e.g.: "The approach in this example replaces individual components. Alternatively, you can .... This is how the default BlockNote UI layers for Mantine / ShadCN / Ariakit are created")

Comment thread examples/03-ui-components/12-custom-ui/App.tsx Outdated
Comment thread examples/03-ui-components/12-custom-ui/MUISideMenu.tsx Outdated
Comment thread examples/03-ui-components/12-custom-ui/README.md Outdated
# Conflicts:
#	package-lock.json
#	playground/package.json
@matthewlipski matthewlipski changed the title docs: Updated PDF and custom UI examples docs: Updated custom UI example Jul 19, 2024
@matthewlipski
matthewlipski requested a review from YousefED July 19, 2024 17:33
@YousefED

YousefED commented Aug 6, 2024

Copy link
Copy Markdown
Collaborator

Looks great!

@YousefED
YousefED merged commit 70b25b4 into main Aug 6, 2024
@nperez0111
nperez0111 deleted the pro-examples-update branch October 21, 2025 07:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

static toolbar example broken CSS?

2 participants