Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
"jsx": "react-jsx",
"composite": true
},
"include": [".", "src/test.ts"],
"include": ["."],
"__ADD_FOR_LOCAL_DEV_references": [
{
"path": "../../../packages/core/"
Expand Down
10 changes: 10 additions & 0 deletions examples/07-collaboration/14-suggestion-gallery/.bnexample.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"playground": true,
"docs": false,
"author": "yousefed",
"tags": ["Advanced", "Development", "Collaboration"],
"dependencies": {
"@y/protocols": "^1.0.6-rc.1",
"@y/y": "^14.0.0-rc.16"
}
}
18 changes: 18 additions & 0 deletions examples/07-collaboration/14-suggestion-gallery/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Suggestion Scenarios Gallery

Browse the suggestion (track-changes) rendering scenarios interactively. Each
entry sets up a base document and applies a change in suggestion mode, so you can
see how insertions, deletions and type changes are visualized as a diff.

The **Base** pane (left) is read-only and shows the document before the change.
The **Suggestion** pane (right) is editable — keep typing to create more
suggestions on top.

These are the same scenarios covered by the y-prosemirror visual tests; the
per-scenario definitions live in `src/scenarios.ts` so the tests and this gallery
stay in sync.

**Relevant Docs:**

- [Editor Setup](/docs/editor-basics/setup)
- [Collaboration](/docs/collaboration/real-time-collaboration)
14 changes: 14 additions & 0 deletions examples/07-collaboration/14-suggestion-gallery/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Suggestion Scenarios Gallery</title>
<script>
<!-- AUTO-GENERATED FILE, DO NOT EDIT DIRECTLY -->
</script>
</head>
<body>
<div id="root"></div>
<script type="module" src="./main.tsx"></script>
</body>
</html>
11 changes: 11 additions & 0 deletions examples/07-collaboration/14-suggestion-gallery/main.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
// AUTO-GENERATED FILE, DO NOT EDIT DIRECTLY
import React from "react";
import { createRoot } from "react-dom/client";
import App from "./src/App.jsx";

const root = createRoot(document.getElementById("root")!);
root.render(
<React.StrictMode>
<App />
</React.StrictMode>,
);
32 changes: 32 additions & 0 deletions examples/07-collaboration/14-suggestion-gallery/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
{
"name": "@blocknote/example-collaboration-suggestion-gallery",
"description": "AUTO-GENERATED FILE, DO NOT EDIT DIRECTLY",
"type": "module",
"private": true,
"version": "0.12.4",
"scripts": {
"start": "vp dev",
"dev": "vp dev",
"build:prod": "tsc && vp build",
"preview": "vp preview"
},
"dependencies": {
"@blocknote/ariakit": "latest",
"@blocknote/core": "latest",
"@blocknote/mantine": "latest",
"@blocknote/react": "latest",
"@blocknote/shadcn": "latest",
"@mantine/core": "^9.0.2",
"@mantine/hooks": "^9.0.2",
"react": "^19.2.3",
"react-dom": "^19.2.3",
"@y/protocols": "^1.0.6-rc.1",
"@y/y": "^14.0.0-rc.16"
},
"devDependencies": {
"@types/react": "^19.2.3",
"@types/react-dom": "^19.2.3",
"@vitejs/plugin-react": "^6.0.1",
"vite-plus": "catalog:"
}
}
Loading
Loading