@blocknote/mantine 0.34.0 → 0.36.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +1 -1
- package/dist/blocknote-mantine.cjs +1 -1
- package/dist/blocknote-mantine.cjs.map +1 -1
- package/dist/blocknote-mantine.js +62 -59
- package/dist/blocknote-mantine.js.map +1 -1
- package/dist/style.css +1 -1
- package/dist/webpack-stats.json +1 -1
- package/package.json +3 -3
- package/src/BlockNoteView.tsx +5 -3
- package/src/comments/Editor.tsx +4 -0
- package/types/src/BlockNoteView.d.ts +3 -2
package/dist/webpack-stats.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"builtAt":
|
|
1
|
+
{"builtAt":1756129046468,"assets":[{"name":"blocknote-mantine.cjs","size":20703},{"name":"blocknote-mantine.cjs.map","size":313147}],"chunks":[{"id":"ec22802","entry":true,"initial":true,"files":["blocknote-mantine.cjs"],"names":["blocknote-mantine"]}],"modules":[{"name":"./src/BlockNoteTheme.ts","size":2185,"chunks":["ec22802"]},{"name":"./src/toolbar/ToolbarButton.tsx","size":2674,"chunks":["ec22802"]},{"name":"./src/badge/Badge.tsx","size":1437,"chunks":["ec22802"]},{"name":"./src/comments/Card.tsx","size":1403,"chunks":["ec22802"]},{"name":"./src/comments/Comment.tsx","size":2137,"chunks":["ec22802"]},{"name":"./src/comments/Editor.tsx","size":1075,"chunks":["ec22802"]},{"name":"./src/form/TextInput.tsx","size":805,"chunks":["ec22802"]},{"name":"../../node_modules/.pnpm/react-icons@5.5.0_react@19.1.0/node_modules/react-icons/lib/iconContext.mjs","size":251,"chunks":["ec22802"]},{"name":"../../node_modules/.pnpm/react-icons@5.5.0_react@19.1.0/node_modules/react-icons/lib/iconBase.mjs","size":4003,"chunks":["ec22802"]},{"name":"../../node_modules/.pnpm/react-icons@5.5.0_react@19.1.0/node_modules/react-icons/hi/index.mjs","size":720,"chunks":["ec22802"]},{"name":"./src/menu/Menu.tsx","size":4109,"chunks":["ec22802"]},{"name":"./src/menu/Button.tsx","size":765,"chunks":["ec22802"]},{"name":"./src/panel/Panel.tsx","size":1015,"chunks":["ec22802"]},{"name":"./src/panel/PanelButton.tsx","size":345,"chunks":["ec22802"]},{"name":"./src/panel/PanelFileInput.tsx","size":367,"chunks":["ec22802"]},{"name":"./src/panel/PanelTab.tsx","size":209,"chunks":["ec22802"]},{"name":"./src/panel/PanelTextInput.tsx","size":392,"chunks":["ec22802"]},{"name":"./src/popover/Popover.tsx","size":679,"chunks":["ec22802"]},{"name":"./src/sideMenu/SideMenu.tsx","size":309,"chunks":["ec22802"]},{"name":"./src/sideMenu/SideMenuButton.tsx","size":773,"chunks":["ec22802"]},{"name":"./src/style.css","size":0,"chunks":["ec22802"]},{"name":"./src/suggestionMenu/SuggestionMenu.tsx","size":307,"chunks":["ec22802"]},{"name":"./src/suggestionMenu/SuggestionMenuEmptyItem.tsx","size":338,"chunks":["ec22802"]},{"name":"./src/suggestionMenu/SuggestionMenuItem.tsx","size":1911,"chunks":["ec22802"]},{"name":"./src/suggestionMenu/SuggestionMenuLabel.tsx","size":227,"chunks":["ec22802"]},{"name":"./src/suggestionMenu/SuggestionMenuLoader.tsx","size":233,"chunks":["ec22802"]},{"name":"./src/suggestionMenu/gridSuggestionMenu/GridSuggestionMenu.tsx","size":361,"chunks":["ec22802"]},{"name":"./src/suggestionMenu/gridSuggestionMenu/GridSuggestionMenuEmptyItem.tsx","size":436,"chunks":["ec22802"]},{"name":"./src/suggestionMenu/gridSuggestionMenu/GridSuggestionMenuItem.tsx","size":855,"chunks":["ec22802"]},{"name":"./src/suggestionMenu/gridSuggestionMenu/GridSuggestionMenuLoader.tsx","size":385,"chunks":["ec22802"]},{"name":"./src/tableHandle/ExtendButton.tsx","size":333,"chunks":["ec22802"]},{"name":"./src/tableHandle/TableHandle.tsx","size":452,"chunks":["ec22802"]},{"name":"./src/toolbar/Toolbar.tsx","size":666,"chunks":["ec22802"]},{"name":"./src/toolbar/ToolbarSelect.tsx","size":1785,"chunks":["ec22802"]},{"name":"./src/components.tsx","size":1540,"chunks":["ec22802"]},{"name":"./src/BlockNoteView.tsx","size":1638,"chunks":["ec22802"]},{"name":"./src/defaultThemes.ts","size":2023,"chunks":["ec22802"]},{"name":"./src/index.tsx","size":0,"chunks":["ec22802"]}]}
|
package/package.json
CHANGED
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
"directory": "packages/mantine"
|
|
12
12
|
},
|
|
13
13
|
"license": "MPL-2.0",
|
|
14
|
-
"version": "0.
|
|
14
|
+
"version": "0.36.0",
|
|
15
15
|
"files": [
|
|
16
16
|
"dist",
|
|
17
17
|
"types",
|
|
@@ -49,8 +49,8 @@
|
|
|
49
49
|
}
|
|
50
50
|
},
|
|
51
51
|
"dependencies": {
|
|
52
|
-
"@blocknote/core": "0.
|
|
53
|
-
"@blocknote/react": "0.
|
|
52
|
+
"@blocknote/core": "0.36.0",
|
|
53
|
+
"@blocknote/react": "0.36.0",
|
|
54
54
|
"@mantine/core": "^7.17.3",
|
|
55
55
|
"@mantine/hooks": "^7.17.3",
|
|
56
56
|
"@mantine/utils": "^6.0.21",
|
package/src/BlockNoteView.tsx
CHANGED
|
@@ -5,14 +5,13 @@ import {
|
|
|
5
5
|
StyleSchema,
|
|
6
6
|
} from "@blocknote/core";
|
|
7
7
|
import {
|
|
8
|
-
BlockNoteViewProps,
|
|
9
8
|
BlockNoteViewRaw,
|
|
10
9
|
ComponentsContext,
|
|
11
10
|
useBlockNoteContext,
|
|
12
11
|
usePrefersColorScheme,
|
|
13
12
|
} from "@blocknote/react";
|
|
14
13
|
import { MantineProvider } from "@mantine/core";
|
|
15
|
-
import { useCallback } from "react";
|
|
14
|
+
import React, { useCallback } from "react";
|
|
16
15
|
import {
|
|
17
16
|
applyBlockNoteCSSVariablesFromTheme,
|
|
18
17
|
removeBlockNoteCSSVariables,
|
|
@@ -31,7 +30,10 @@ export const BlockNoteView = <
|
|
|
31
30
|
ISchema extends InlineContentSchema,
|
|
32
31
|
SSchema extends StyleSchema,
|
|
33
32
|
>(
|
|
34
|
-
props: Omit<
|
|
33
|
+
props: Omit<
|
|
34
|
+
React.ComponentProps<typeof BlockNoteViewRaw<BSchema, ISchema, SSchema>>,
|
|
35
|
+
"theme"
|
|
36
|
+
> & {
|
|
35
37
|
theme?:
|
|
36
38
|
| "light"
|
|
37
39
|
| "dark"
|
package/src/comments/Editor.tsx
CHANGED
|
@@ -4,6 +4,7 @@ import {
|
|
|
4
4
|
FormattingToolbar,
|
|
5
5
|
FormattingToolbarController,
|
|
6
6
|
getFormattingToolbarItems,
|
|
7
|
+
useBlockNoteContext,
|
|
7
8
|
} from "@blocknote/react";
|
|
8
9
|
import { forwardRef } from "react";
|
|
9
10
|
import { BlockNoteView } from "../BlockNoteView.js";
|
|
@@ -17,6 +18,8 @@ export const Editor = forwardRef<
|
|
|
17
18
|
|
|
18
19
|
assertEmpty(rest, false);
|
|
19
20
|
|
|
21
|
+
const blockNoteContext = useBlockNoteContext();
|
|
22
|
+
|
|
20
23
|
return (
|
|
21
24
|
<BlockNoteView
|
|
22
25
|
autoFocus={autoFocus}
|
|
@@ -28,6 +31,7 @@ export const Editor = forwardRef<
|
|
|
28
31
|
filePanel={false}
|
|
29
32
|
formattingToolbar={false}
|
|
30
33
|
editable={editable}
|
|
34
|
+
theme={blockNoteContext?.colorSchemePreference}
|
|
31
35
|
ref={ref}
|
|
32
36
|
onFocus={onFocus}
|
|
33
37
|
onBlur={onBlur}
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { BlockSchema, InlineContentSchema, StyleSchema } from "@blocknote/core";
|
|
2
|
-
import {
|
|
2
|
+
import { BlockNoteViewRaw } from "@blocknote/react";
|
|
3
|
+
import React from "react";
|
|
3
4
|
import { Theme } from "./BlockNoteTheme.js";
|
|
4
5
|
import "./style.css";
|
|
5
|
-
export declare const BlockNoteView: <BSchema extends BlockSchema, ISchema extends InlineContentSchema, SSchema extends StyleSchema>(props: Omit<
|
|
6
|
+
export declare const BlockNoteView: <BSchema extends BlockSchema, ISchema extends InlineContentSchema, SSchema extends StyleSchema>(props: Omit<React.ComponentProps<typeof BlockNoteViewRaw<BSchema, ISchema, SSchema>>, "theme"> & {
|
|
6
7
|
theme?: "light" | "dark" | Theme | {
|
|
7
8
|
light: Theme;
|
|
8
9
|
dark: Theme;
|