Repository navigation
Suggest mode 8/9: architecture documentation - #82047
adamsilverstein wants to merge 103 commits into
Conversation
Describe how a suggestion is captured, stored, marked inline and reviewed, so the subsystem has a written explanation alongside the code rather than only in the pull requests that built it.
|
Warning: Type of PR label mismatch To merge this PR, it requires exactly 1 label indicating the type of PR. Other labels are optional and not being checked here.
Read more about Type labels in Gutenberg. Don't worry if you don't have the required permissions to add labels; the PR reviewer should be able to help with the task. |
|
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message. To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
The document was added to docs/explanations/architecture but never listed in docs/toc.json, so it did not reach the generated manifest or the developer docs handbook. Add the toc entry, regenerate the manifest, and link it from the architecture index alongside the other editor docs.
Cascade the trunk refresh up the Suggest mode stack.
|
Flaky tests detected in 17466ed. 🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/33117847764 refuses the drop and uploads nothing in
|
…the overview Attribute suggestions now live on the block's metadata.suggestion marker instead of an in-memory overlay, and the provider sits behind a SuggestionStore with submission and decision hooks. Both landed in #80433, so the overview's tables, diagrams and open findings described a model the code no longer has. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01USLfaxhwoVRBZ7QFP5XoeU
The overview claimed the Note collector restores a Note on redo for every marker. End to end, a redone attribute proposal is saved as a new Note instead: auto-save finds the linked Note trashed and opens another. Describe that so a reviewer is not sent looking for a restore that does not happen. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017NSEHmsqyXW8Yf62bJ3ckf
The architecture doc said only that the note collector restores a note when redo brings an inline marker back. It now covers the redo of a decision, the structural restore, and that deleting a block with a pending move proposes the removal from the move's origin. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011GLh3wdWJSgU3NLobNDk6x
Replace the title-only section with how every post-level field is either proposed (held in the editor store, shown in place, one note each) or locked (read-only, refused at `editPost`, at the entity guard and at save), plus the server-side validation and the new limitations. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011GLh3wdWJSgU3NLobNDk6x
getEditedPostAttribute is public, and while suggesting it returns a field's pending suggested value rather than the post's. That is what lets every panel and plugin show the proposal, so it stays, but its docblock now says so and where to read the post's own value. The architecture doc and the changelog cover it along with new term suggestions, restoring proposals after a reload, and the trash and site settings locks. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011GLh3wdWJSgU3NLobNDk6x
… the marker The render strip resolved a format marker's note against the block's postId context, which inside a Query Loop names each queried post rather than the post whose content holds the marker. Track the post whose content the_content is expanding instead, so blocks of a loop resolve against the content that holds the loop while a nested post-content block resolves against its own post. The lookup now also requires that the post's stored content (or the current user's autosave in a preview) holds the marker, that the post is not password protected, that the note is not trashed or spam, and that the suggestion is neither applied nor rejected. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011GLh3wdWJSgU3NLobNDk6x
Records the decision lifecycle: the status table and state diagram, the save pass that finalizes and outdates, the refusal of client writes of a final status, how the sidebar presents each state, and that the note collector now only trashes the current user's own notes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011GLh3wdWJSgU3NLobNDk6x
The architecture doc now describes the marker contract as it is: one format and class per kind, the class authoritative, the canonical nesting order, and no migration of the retired single class. A new Overlapping suggestions section covers the overlap matrix, the resolution rule with a diagram, the sidebar's context and consequence lines, the RTC guard and how the render strip resolves nesting. Known limitations add same-kind refusal and outdated notes waiting for the save pass. The reviewer overview follows. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011GLh3wdWJSgU3NLobNDk6x
Describe how the save pass keeps proposals out of the stored post: the anchor each proposal leaves, where the originals are stored, when the editor gets them back, the fail-closed rules and the residuals, plus the legacy marker strip and post-field finalizing on wp_after_insert_post. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011GLh3wdWJSgU3NLobNDk6x
…ze notice Say which post a format marker resolves against when blocks come from a synced pattern, a template part, a menu or Latest Posts, that spam notes are not inflated, and that the sidebar flags a suggestion too large to move out of the post. Layer: docs. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011GLh3wdWJSgU3NLobNDk6x
Layer: docs. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011GLh3wdWJSgU3NLobNDk6x
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011GLh3wdWJSgU3NLobNDk6x
Carries the changelog section fix up from suggest/inline-wiring. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011GLh3wdWJSgU3NLobNDk6x
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011GLh3wdWJSgU3NLobNDk6x
Part of #73411
Claude drafted this description from the docs it helped write:
Suggestion mode stack
This rebuilds the manually-stacked Suggestion mode work (#73411) as a GitHub Stack of 9 small, independently reviewable PRs, each building on the one below it:
Each follow up fix now sits in the layer that owns the code it changes, rather than piling onto the top of the stack. The whole feature can be exercised end-to-end via the combined testing branch #78994 (Playground). Behind the "Suggestion Mode" experiment (Gutenberg > Experiments).
AI Use
Both documents and this description came out of a conversation with 🤖 Claude Code. Docs only, no code in this PR. I will review them for accuracy.
🤖 Generated with Claude Code
https://claude.ai/code/session_016nxoTjV6e8hn6YUb7AEioP