File tree Expand file tree Collapse file tree 3 files changed +6
-6
lines changed
03-formatting-toolbar-block-type-items/src
06-custom-schema/05-alert-block-full-ux/src Expand file tree Collapse file tree 3 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ import { BlockNoteView } from "@blocknote/mantine";
44import "@blocknote/mantine/style.css" ;
55import {
66 FormattingToolbarController ,
7- getDefaultBlockTypeSelectItems ,
7+ blockTypeSelectItems ,
88 useCreateBlockNote ,
99 BlockTypeSelectItem ,
1010 FormattingToolbar ,
@@ -60,7 +60,7 @@ export default function App() {
6060 // Sets the items in the Block Type Select.
6161 blockTypeSelectItems = { [
6262 // Gets the default Block Type Select items.
63- ...getDefaultBlockTypeSelectItems ( editor ) ,
63+ ...blockTypeSelectItems ( editor . dictionary ) ,
6464 // Adds an item for the Alert block.
6565 {
6666 name : "Alert" ,
Original file line number Diff line number Diff line change 11import { Block } from "@blocknote/core" ;
22import {
3- getDefaultBlockTypeSelectItems ,
3+ blockTypeSelectItems ,
44 useBlockNoteEditor ,
55 useEditorContentOrSelectionChange ,
66} from "@blocknote/react" ;
@@ -122,7 +122,7 @@ function MUIBlockTypeSelect() {
122122
123123 // Gets the default items for the select.
124124 const defaultBlockTypeSelectItems = useMemo (
125- ( ) => getDefaultBlockTypeSelectItems ( editor ) ,
125+ ( ) => blockTypeSelectItems ( editor . dictionary ) ,
126126 [ editor . dictionary ] ,
127127 ) ;
128128
Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ import {
1212 FormattingToolbar ,
1313 FormattingToolbarController ,
1414 SuggestionMenuController ,
15- getDefaultBlockTypeSelectItems ,
15+ blockTypeSelectItems ,
1616 getDefaultReactSlashMenuItems ,
1717 useCreateBlockNote ,
1818} from "@blocknote/react" ;
@@ -93,7 +93,7 @@ export default function App() {
9393 // Sets the items in the Block Type Select.
9494 blockTypeSelectItems = { [
9595 // Gets the default Block Type Select items.
96- ...getDefaultBlockTypeSelectItems ( editor ) ,
96+ ...blockTypeSelectItems ( editor . dictionary ) ,
9797 // Adds an item for the Alert block.
9898 {
9999 name : "Alert" ,
You can’t perform that action at this time.
0 commit comments