Skip to content

Record the rich text editor contract in the specification - #2726

Merged
pournasserian merged 2 commits into
mainfrom
feat/2725-spec-rich-text-contract-6730cf
Nov 2, 2026
Merged

pournasserian merged 2 commits into
mainfrom
feat/2725-spec-rich-text-contract-6730cf

Conversation

@pournasserian

@pournasserian pournasserian commented Nov 2, 2026 •

Copy link
Copy Markdown
Member

Closes #2725

Section 4.1 now lists the rich text contracts (IRichTextRenderer, IRichTextNodeRenderer, IRichTextNodeContext, RichTextRenderOptions, RichTextFormats) in the FluentCMS.Schema row. Section 4.2 gains a "Rich text editor contract" paragraph: the stored node and mark names follow Tiptap, documents using stock ProseMirror names (image, bullet_list, strong) are rejected by validation, and the three FluentCMS additions (media, inlineBlock, entryLink) are listed with their attributes as read from RichTextParser. The sample now uses [Relation(Reverse = "articles")] and the FormerNames mention uses [FormerNames("subtitle")].

Choices beyond the issue:

  • Reverse relation: a plain string "articles", because it is unambiguous inside Article; the attribute reader camel-cases the value, so it gives the same schema as nameof(Samples.Author.Articles).
  • The paragraph also lists the standard attributes (level, start, language, href, title, target), not only the three additions, and the stock names rejected, so the editor team has the full set in one place.
  • The paragraph sits after "Blocks" and before "Validation" in 4.2.
  • Appendix A: video_url moved to cms_article because the sample's VideoUrl is not localizable.

Verification: the 4.2 sample classes were copied into a scratch file in tests/FluentCMS.Core.Tests (with stub Author, Tag, ArticleCategory, QuoteBlock, GalleryBlock) and dotnet build -c Release -warnaserror passed with 0 warnings and 0 errors. With the old nameof(Author.Articles) the same build fails with CS1061. The scratch file is deleted and not committed.

Dependencies: none.

  • Section 4.1 lists the rich text contracts
  • Section 4.2 names every stored node and mark type and the three FluentCMS nodes
  • The section 4.2 sample compiles against the SDK as merged
  • Markdown lint passes

@pournasserian
pournasserian merged commit a9eace1 into main Nov 2, 2026
5 checks passed
@pournasserian
pournasserian deleted the feat/2725-spec-rich-text-contract-6730cf branch November 2, 2026 14:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Record the rich text editor contract and fix the schema sample in the specification

1 participant