You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
⚠️ Breaking change: Removed the `imageBackgroundColor` prop from `River.Visual`, `RiverBreakout.Visual`, and `RiverBreakoutTabs.Visual`.
6
+
7
+
The `gridline` variant now applies the full-bleed visual background layout by default. Remove `imageBackgroundColor="subtle"` from `River.Visual` and `RiverBreakout.Visual` when using the `gridline` variant.
8
+
9
+
Remove `imageBackgroundColor` from `RiverBreakoutTabs.Visual` without replacement. Its default visual treatment is unchanged.
10
+
11
+
The background treatment is not applied to the default `River` or `RiverBreakout` variants.
12
+
13
+
Updated the River `gridline` variant tablet layout with a `618px` max-width and lateral gridlines.
-[Padding on all sides](https://stunning-chainsaw-j82glqz.pages.github.io/?path=/story/components-river-features-gridline-variants--grid-line-visual-padding-all)
-[Padding on all sides](https://stunning-chainsaw-j82glqz.pages.github.io/brand/storybook/?path=/story/components-river-features-gridline-variants--grid-line-visual-padding-all)
Copy file name to clipboardExpand all lines: apps/next-docs/content/components/River/react.mdx
+18-19Lines changed: 18 additions & 19 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -74,12 +74,12 @@ import {River, RiverBreakout} from '@primer/react-brand'
74
74
75
75
### GridLine variant
76
76
77
-
The `gridline` variant adds lateral padding for bordered layouts. Use `imageBackgroundColor` to add contrast, `position` to align media, and `padding` to control its inset.
77
+
The `gridline` variant adds lateral padding and applies a full-bleed visual background by default. Use `position` to align media and `padding` to control its inset.
78
78
79
79
```jsx live
80
80
<Stack style={{width:'100%'}}>
81
81
<River variant="gridline">
82
-
<River.Visual imageBackgroundColor="subtle">
82
+
<River.Visual>
83
83
<img src="/images/placeholder.png" alt="placeholder, blank area with a gray background color"/>
84
84
</River.Visual>
85
85
<River.Content>
@@ -89,7 +89,7 @@ The `gridline` variant adds lateral padding for bordered layouts. Use `imageBack
89
89
</River.Content>
90
90
</River>
91
91
<River variant="gridline" align="end">
92
-
<River.Visual imageBackgroundColor="subtle">
92
+
<River.Visual>
93
93
<img src="/images/placeholder.png" alt="placeholder, blank area with a gray background color"/>
94
94
</River.Visual>
95
95
<River.Content>
@@ -99,7 +99,7 @@ The `gridline` variant adds lateral padding for bordered layouts. Use `imageBack
|`fillMedia`|`boolean`| true | Automatically styles images and video to fill and fit the width of the parent. Disable this setting if you have bespoke styling requirements. |
270
-
|`children`|`ReactElement`|| Bring your own component (BYOC) `img` or `ReactElement` (E.g. Next.js `Image` component) |
271
-
|`imageBackgroundColor`|`'default'`, `'subtle'`|| Applies a background color around the media independently of visual position and padding controls. |
272
-
|`position`| <RiverVisualPositionProp /> |`'default'`| Positions media within the gridline visual region. Explicit positions remain fixed across viewports; `default` preserves responsive behavior. |
273
-
|`padding`| <RiverVisualPaddingProp /> |`'default'`| Controls media inset within the gridline visual region. `none` fills the visual region and removes corner radius regardless of `rounded`; `all` adds padding on every side. |
274
-
|`hasShadow`|`boolean`|`false`| Shadow applied to the `children`. Set be `false` when the child node has a transparent background. |
275
-
|`className`|`string`|| Sets a custom class on the root element |
276
-
|`id`|`string`|| Sets a custom id |
277
-
|`ref`|`React.RefObject`|| Forward a Ref to the underlying DOM node |
278
-
|`rounded`|`boolean`|`true`| Toggle visually rounded corners. Enabled by default. |
|`fillMedia`|`boolean`| true | Automatically styles images and video to fill and fit the width of the parent. Disable this setting if you have bespoke styling requirements. |
270
+
|`children`|`ReactElement`|| Bring your own component (BYOC) `img` or `ReactElement` (E.g. Next.js `Image` component) |
271
+
|`position`| <RiverVisualPositionProp /> |`'default'`| Positions media within the gridline visual region. Explicit positions remain fixed across viewports; `default` preserves responsive behavior. |
272
+
|`padding`| <RiverVisualPaddingProp /> |`'default'`| Controls media inset within the gridline visual region. `none` fills the visual region and removes corner radius regardless of `rounded`; `all` adds padding on every side. |
273
+
|`hasShadow`|`boolean`|`false`| Shadow applied to the `children`. Set be `false` when the child node has a transparent background. |
274
+
|`className`|`string`|| Sets a custom class on the root element |
275
+
|`id`|`string`|| Sets a custom id |
276
+
|`ref`|`React.RefObject`|| Forward a Ref to the underlying DOM node |
277
+
|`rounded`|`boolean`|`true`| Toggle visually rounded corners. Enabled by default. |
279
278
280
279
### RiverBreakout.Visual <Label>Required</Label>
281
280
282
-
`RiverBreakout.Visual` supports the `children`, `fillMedia`, `imageBackgroundColor`, `hasShadow`, `rounded`, and standard HTML props listed above. The `position` and `padding` props are specific to `River.Visual`.
281
+
`RiverBreakout.Visual` supports the `children`, `fillMedia`, `hasShadow`, `rounded`, and standard HTML props listed above. The `position` and `padding` props are specific to `River.Visual`.
283
282
284
283
### River.Content and RiverBreakout.Content <Label>Required</Label>
0 commit comments