Skip to content

Commit 82bb78a

Browse files
authored
docs: rename Proofing to Spell check (SD-2895) (#3059)
* docs: rename customer-facing 'Proofing' to 'Spell check' (SD-2895) Both shipped provider examples advertise ["spelling"] capabilities only and filter responses to kind: 'spelling' before returning. The v1 UI renders only spelling underlines (the proofing.css file's own comments call grammar and style 'future, stored but not rendered'). Calling the feature 'Proofing' in customer copy oversells what ships. This is a docs terminology change only. The public config remains proofing; the visible product feature is now documented as Spell check. Visible labels renamed: - Sidebar group Proofing -> Spell check - Page title Spell Check & Proofing -> Spell check - Custom proofing provider -> Custom spell-check provider - Built-in UI overview card Proofing -> Spell check - Context menu doc 'Proofing items' -> 'Spell-check items' - Accessibility note 'proofing in web layout' -> 'spell check in web layout' - Configuration page section heading Proofing -> Spell check Folder renames (with redirects so old links keep working): - apps/docs/editor/proofing -> apps/docs/editor/spell-check - examples/editor/proofing -> examples/editor/spell-check Kept as-is (real API surface): - proofing config key - ProofingProvider / ProofingConfig / ProofingIssue / etc. type names - proofing.enabled / proofing.provider / proofing.ignoredWords params - onProofingError callback name Page rewrites lead with mechanism (extract -> map -> render -> right-click) per brand voice rule 11. Honest scope-of-v1 callout names what's not shipped (grammar, style, headers/footers) per brand rule 8. * fix(docs): scope rename to docs only + fix redirect chains (SD-2895) Address review feedback on PR #3059. The original commit overreached by renaming the examples folder along with the docs folder. Examples folders are internal codebase paths, not user-facing surface; renaming them touches CI, package.json names, and external-facing GitHub URLs without customer benefit. Reverts: - examples/editor/spell-check back to examples/editor/proofing. Internal folder name stays as it was; only the docs surface is renamed for customer-facing language. - Doc cross-references to GitHub example folders updated back to /examples/editor/proofing/ paths. Fixes review findings: - Two pre-existing redirects in docs.json had destinations pointing at /editor/proofing/* (now redirected onward to /editor/spell-check/*). Updated /guides/general/proofing and /guides/general/custom-proofing- provider to point at the final /editor/spell-check/* destinations directly. Avoids redirect chains per the team's no-chains rule established on PR #3054. - examples/README.md still had a Proofing section heading + GitHub link to ./editor/proofing (the link is fine after this commit since the folder is back at proofing/, but the section heading should reflect the user-facing name). Renamed heading to Spell check; link target stays at ./editor/proofing. - Two semicolons in apps/docs/editor/superdoc/configuration.mdx introduced by the rename. Brand voice rule: 'if there's a semicolon, definitely split it.' Both split into two sentences.
1 parent 73afdb6 commit 82bb78a

9 files changed

Lines changed: 152 additions & 130 deletions

File tree

apps/docs/docs.json

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -140,8 +140,8 @@
140140
]
141141
},
142142
{
143-
"group": "Proofing",
144-
"pages": ["editor/proofing/overview", "editor/proofing/custom-provider"]
143+
"group": "Spell check",
144+
"pages": ["editor/spell-check/overview", "editor/spell-check/custom-provider"]
145145
},
146146
{
147147
"group": "Theming",
@@ -293,6 +293,18 @@
293293
"dismissible": true
294294
},
295295
"redirects": [
296+
{
297+
"source": "/editor/proofing/overview",
298+
"destination": "/editor/spell-check/overview"
299+
},
300+
{
301+
"source": "/editor/proofing/custom-provider",
302+
"destination": "/editor/spell-check/custom-provider"
303+
},
304+
{
305+
"source": "/editor/proofing/:path*",
306+
"destination": "/editor/spell-check/:path*"
307+
},
296308
{
297309
"source": "/document-engine/sdk-diffing",
298310
"destination": "/document-engine/diffing"
@@ -311,11 +323,11 @@
311323
},
312324
{
313325
"source": "/guides/general/proofing",
314-
"destination": "/editor/proofing/overview"
326+
"destination": "/editor/spell-check/overview"
315327
},
316328
{
317329
"source": "/guides/general/custom-proofing-provider",
318-
"destination": "/editor/proofing/custom-provider"
330+
"destination": "/editor/spell-check/custom-provider"
319331
},
320332
{
321333
"source": "/guides/migration/document-api",

apps/docs/editor/built-in-ui/context-menu.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ Items shown depend on document context.
6969
| Paste | `clipboard` | Always |
7070

7171
<Note>
72-
Proofing items appear automatically when top-level [proofing](/editor/superdoc/configuration#proofing) is enabled and the clicked text has a spelling issue. Suggestion items are taken directly from the provider's `replacements` array.
72+
Spell-check items appear automatically when top-level [proofing](/editor/superdoc/configuration#proofing) is enabled and the clicked text has a spelling issue. Suggestion items come from the provider's `replacements` array.
7373
</Note>
7474

7575
## Custom items

apps/docs/editor/built-in-ui/overview.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ Each surface is configured via `modules.<name>` in the [SuperDoc configuration](
5353
<Card title="Collaboration" icon="users" href="/editor/collaboration/overview">
5454
Real-time multi-user editing with Yjs (separate top-level section)
5555
</Card>
56-
<Card title="Proofing" icon="check-check" href="/editor/proofing/overview">
56+
<Card title="Spell check" icon="check-check" href="/editor/spell-check/overview">
5757
Provider-based spell check on the layout-engine editor surface
5858
</Card>
5959
</CardGroup>

apps/docs/editor/proofing/overview.mdx

Lines changed: 0 additions & 110 deletions
This file was deleted.

apps/docs/editor/proofing/custom-provider.mdx renamed to apps/docs/editor/spell-check/custom-provider.mdx

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,14 @@
11
---
2-
title: Custom proofing provider
2+
title: Custom spell-check provider
33
sidebarTitle: Custom provider
4-
keywords: "custom proofing provider, spellcheck api, proofing provider, spelling api"
4+
keywords: "custom spell-check provider, custom proofing provider, spellcheck api, proofing provider, spelling api"
55
---
66

7-
SuperDoc uses a provider-agnostic proofing contract. Your provider receives text segments and returns structured issues. SuperDoc owns the editor UI and document-range mapping.
7+
A spell-check provider receives text segments and returns spelling issues. SuperDoc owns the editor UI and document-range mapping.
8+
9+
<Note>
10+
The TypeScript types use `Proofing*` names because the provider contract is broader than spelling. The current UI renders `kind: 'spelling'` only.
11+
</Note>
812

913
## Provider shape
1014

@@ -18,7 +22,7 @@ const provider = {
1822
};
1923
```
2024

21-
If you want TypeScript help, the proofing types are available from `superdoc/super-editor`.
25+
If you want TypeScript help, the `Proofing*` types are available from `superdoc/super-editor`.
2226

2327
## Request model
2428

@@ -137,7 +141,7 @@ const provider = {
137141

138142
## Troubleshooting
139143

140-
If proofing markers do not appear:
144+
If spelling underlines do not appear:
141145

142146
- Confirm `proofing.enabled` is `true`
143147
- Confirm the provider returns `kind: 'spelling'`
Lines changed: 116 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,116 @@
1+
---
2+
title: Spell check
3+
sidebarTitle: Overview
4+
keywords: "spell check, spellcheck, proofing, spelling suggestions, custom proofing provider, typo.js, languagetool, hunspell"
5+
---
6+
7+
SuperDoc can show spelling issues in the editor without browser-native spellcheck. You provide a spell-check provider. SuperDoc extracts document text, maps returned spelling issues back to document ranges, renders underlines, and shows right-click replacements.
8+
9+
<Note>
10+
The configuration key is `proofing` because the provider contract is designed to support spelling, grammar, and style issues. The current UI renders spelling issues only.
11+
</Note>
12+
13+
## Quick setup
14+
15+
```javascript
16+
const provider = {
17+
id: 'my-spell-check',
18+
async check({ segments, maxSuggestions, signal }) {
19+
const response = await fetch('/api/spell-check', {
20+
method: 'POST',
21+
headers: { 'Content-Type': 'application/json' },
22+
body: JSON.stringify({ segments, maxSuggestions }),
23+
signal,
24+
});
25+
26+
if (!response.ok) {
27+
throw new Error(`Spell-check request failed: ${response.status}`);
28+
}
29+
30+
return response.json();
31+
},
32+
};
33+
34+
new SuperDoc({
35+
selector: '#editor',
36+
document: 'contract.docx',
37+
proofing: {
38+
enabled: true,
39+
provider,
40+
defaultLanguage: 'en-US',
41+
maxSuggestions: 3,
42+
allowIgnoreWord: true,
43+
},
44+
});
45+
```
46+
47+
## What SuperDoc handles
48+
49+
- Extracts text segments from body and table-cell paragraphs
50+
- Schedules visible pages first, continues in the background
51+
- Hashes segments and only rechecks the ones that changed
52+
- Maps provider offsets back to editor positions
53+
- Paints spelling underlines after each render
54+
- Shows replacements and Ignore in the right-click menu
55+
- Suppresses the word under the caret while you type
56+
57+
## What your provider handles
58+
59+
- The dictionary or spell-check engine
60+
- Language behavior and per-segment language hints
61+
- Where checking runs (local, on-device, remote)
62+
- Persisting ignored words if you want them to survive reloads
63+
64+
<Note>
65+
SuperDoc does not bundle a dictionary or send your text anywhere. The provider is the data engine. Local options like Typo.js or Hunspell-WASM run entirely in the browser. Remote options like LanguageTool or your own API send segments over the network.
66+
</Note>
67+
68+
## Current scope
69+
70+
- Spelling issues render in v1
71+
- Grammar and style issue kinds are accepted by the provider contract but not rendered yet
72+
- Headers and footers are not checked in v1
73+
- Spell-check state is runtime UI state, not written into the DOCX
74+
- Spell check is not part of the Document API
75+
76+
<Note>
77+
Ignore is local SuperDoc suppression. It survives reloads only if your app stores the ignored words and passes them back through `proofing.ignoredWords`.
78+
</Note>
79+
80+
## Where it works
81+
82+
Spell check runs inside the layout-engine editor surface.
83+
84+
- Standard print layout works out of the box
85+
- For web layout, set `layoutEngineOptions.flowMode: 'semantic'` so the layout engine stays active
86+
87+
```javascript
88+
new SuperDoc({
89+
selector: '#editor',
90+
document: 'contract.docx',
91+
viewOptions: { layout: 'web' },
92+
layoutEngineOptions: { flowMode: 'semantic' },
93+
proofing: {
94+
enabled: true,
95+
provider,
96+
},
97+
});
98+
```
99+
100+
## Provider options
101+
102+
SuperDoc does not include a spell-check engine. You bring your own.
103+
104+
- [Typo.js](https://github.com/cfinke/Typo.js) - local browser spell check. Good for lightweight demos, privacy-sensitive flows, and no-backend setups. See the [Typo.js example](https://github.com/superdoc-dev/superdoc/tree/main/examples/editor/proofing/typo-js).
105+
- [LanguageTool](https://languagetool.org/) - API or self-hosted spell check with broader language support. See the [LanguageTool self-hosted example](https://github.com/superdoc-dev/superdoc/tree/main/examples/editor/proofing/language-tool-self-hosted).
106+
- [hunspell-asm](https://www.npmjs.com/package/hunspell-asm) - local WebAssembly Hunspell. A stronger on-device option than pure-JS dictionaries.
107+
108+
## Examples
109+
110+
- [Typo.js example](https://github.com/superdoc-dev/superdoc/tree/main/examples/editor/proofing/typo-js) - browser-only, no backend
111+
- [LanguageTool self-hosted example](https://github.com/superdoc-dev/superdoc/tree/main/examples/editor/proofing/language-tool-self-hosted) - HTTP spell check with Docker
112+
113+
## Next steps
114+
115+
- See [Configuration](/editor/superdoc/configuration#proofing) for all options
116+
- See [Custom spell-check provider](/editor/spell-check/custom-provider) to wire your own service

apps/docs/editor/superdoc/configuration.mdx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -343,9 +343,9 @@ See [Surfaces](/editor/superdoc/surfaces) for the full API and examples.
343343
<Warning>**Deprecated**: Use `modules.contextMenu` instead. See the [Context Menu module](/editor/built-in-ui/context-menu) for configuration options.</Warning>
344344
</ParamField>
345345

346-
## Proofing
346+
## Spell check
347347

348-
Provider-based spell check and proofing for the layout-engine editor surface.
348+
Provider-based spell check for the layout-engine editor surface. The configuration key is `proofing` because the provider contract is designed to support spelling, grammar, and style. The current UI renders spelling only.
349349

350350
```javascript
351351
new SuperDoc({
@@ -361,19 +361,19 @@ new SuperDoc({
361361
```
362362

363363
<Note>
364-
Bring your own provider. SuperDoc handles the editor UI, while your app controls the proofing engine or API. See [Proofing](/editor/proofing/overview) and [Custom proofing provider](/editor/proofing/custom-provider).
364+
Bring your own provider. SuperDoc handles the editor UI. Your app controls the spell-check engine or API. See [Spell check](/editor/spell-check/overview) and [Custom spell-check provider](/editor/spell-check/custom-provider).
365365
</Note>
366366

367367
<Info>
368-
Proofing is available when the layout engine is active. In `print` layout this works out of the box. In `web` layout, keep the layout engine enabled with `layoutEngineOptions.flowMode: 'semantic'`.
368+
Spell check runs when the layout engine is active. In `print` layout this works out of the box. In `web` layout, keep the layout engine enabled with `layoutEngineOptions.flowMode: 'semantic'`.
369369
</Info>
370370

371371
<Note>
372-
In the current UI, only spelling issues are rendered. Grammar and style issues can still be returned by your provider, but they are not shown yet.
372+
Only spelling issues render in v1. Grammar and style issues can still be returned by your provider but are not shown yet.
373373
</Note>
374374

375375
<ParamField path="proofing" type="Object">
376-
Proofing configuration
376+
Spell-check configuration
377377

378378
<Expandable title="properties" defaultOpen>
379379
<ParamField path="proofing.enabled" type="boolean" default="false">

apps/docs/guides/general/accessibility.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ This enables:
4141
- Document structure (headings, lists, tables) remains intact
4242
- Ideal for mobile devices and responsive web applications
4343

44-
<Note>If you also need layout-engine-powered features such as proofing in web layout, set `layoutEngineOptions.flowMode: 'semantic'`.</Note>
44+
<Note>If you also need layout-engine-powered features such as spell check in web layout, set `layoutEngineOptions.flowMode: 'semantic'`.</Note>
4545

4646
## Keyboard navigation
4747

examples/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,11 +35,11 @@ Patterns for the browser editor surface.
3535
|---------|------|
3636
| [theming](./editor/theming) | [docs](https://docs.superdoc.dev/editor/theming/overview) |
3737

38-
### Proofing
38+
### Spell check
3939

4040
| Example | Docs |
4141
|---------|------|
42-
| [proofing](./editor/proofing) | [docs](https://docs.superdoc.dev/editor/proofing/overview) |
42+
| [proofing](./editor/proofing) | [docs](https://docs.superdoc.dev/editor/spell-check/overview) |
4343

4444
### Collaboration
4545

0 commit comments

Comments
 (0)