Add color option to big_number block#1714
Merged
Merged
Conversation
The color option was dropped when #1703 turned big-number from a rich-text feature into a StreamField block. Re-add it as a named blue/green/orange ChoiceBlock, matching the flex-renderer's existing text-${color} class implementation (no renderer change needed). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
Pull request overview
Restores the color option on the big_number StreamField block so authors can select a named brand color (blue/green/orange), aligning the CMS block schema with the flex-renderer’s existing text-${color} styling support.
Changes:
- Added optional
colorChoiceBlock(blue/green/orange) to thebig_numberStructBlock definition. - Regenerated the
RootPage.bodyStreamField migration to persist the updated block schema.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
pages/models/constants.py |
Adds an optional color ChoiceBlock to the big_number block definition used by RootPage.body. |
pages/migrations/0181_alter_rootpage_body.py |
Updates the StreamField schema in the database to include the new big_number.color field. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
mwvolo
added a commit
that referenced
this pull request
Jun 26, 2026
Resolves the duplicate 0181_alter_rootpage_body conflict with main (#1714). Keeps main's 0181 (big_number color) and renumbers the content_card StreamField change to 0182, depending on 0181. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Re-adds the
coloroption to thebig_numberStreamField block as a named blue / green / orangeChoiceBlock.Why
When #1703 turned big-number from a Draftail rich-text feature into a StreamField block, the color option was dropped. The flex-renderer's
BigNumberBlockalready supportscolorvia atext-${color}CSS class (blue|green|orange), so this restores parity with no renderer change required.Notes
0181_alter_rootpage_body.pyregenerated;makemigrations --checkis clean.big_numberblock ships (currently the deployed renderer,renderer-1.1.17-rc.2, predatesbig_numberand falls back to a raw<pre>JSON dump). Tracked separately.🤖 Generated with Claude Code