Configurable background and text colour for ContentOverview and Testimonial#1487
Conversation
Mirror the OpportunitiesList pattern: the block exposes backgroundColor and textColor via colorSettingsField (defaults #fff / #000), and the component applies them on its root Box (background + color), replacing the hard-coded white background.
Mirror the OpportunitiesList/ContentOverview pattern: the block exposes backgroundColor and textColor via colorSettingsField (defaults #fff / #000), and the component applies them on its root Box (background + color), replacing the hard-coded white background.
|
@claude review |
|
Claude finished @koechkevin's task in 1m 43s —— View job Code Review
Overall the approach is clean and consistent with the
|
The headings and body copy hardcoded their own colour, so the inherited textColor on the root Box never applied. Derive their colour from textColor (the title already inherits) so the configurable value takes effect. The info card keeps its own colours as a distinct surface, mirroring how OpportunitiesList cards retain their brand colours.
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 17cfd1ad62
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
LocationAndDate hardcoded black/grey, so the location and divider stayed dark and could be unreadable on a dark background. Add an optional color prop (defaults preserve current behaviour for OpportunityCard and OpportunityOverview) and pass textColor from ContentOverview; the date keeps its muted secondary colour.
Summary
Extends the OpportunitiesList colour pattern to the ContentOverview and Testimonial blocks, so editors can set the section background and text colour from the CMS instead of relying on hard-coded values.
Changes
Each block now exposes
backgroundColorandtextColorvia the sharedcolorSettingsField(defaults#fff/#000, rendered by the nativeColourPicker), and each component applies them on its rootBox(background+color):payload/blocks/ContentOverview.jscolorSettingsField(bg#fff, text#000)components/ContentOverview/ContentOverview.jsbackgroundColor/textColor; apply on rootBox, replacing hard-codedcommon.whitecomponents/ContentOverview/ContentOverview.snap.jsBoxclass hash)payload/blocks/Testimonial.jscolorSettingsField(bg#fff, text#000)components/Testimonial/Testimonial.jsbackgroundColor/textColor; apply on rootBox, replacing hard-coded#fffScreenshots
Testing
eslintclean on all changed files.