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
Copy file name to clipboardExpand all lines: fern/products/docs/pages/component-library/default-components/cards.mdx
+62Lines changed: 62 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -77,6 +77,56 @@ You can use individual cards or [use the `CardGroup` component](/docs/writing-co
77
77
</Tab>
78
78
</Tabs>
79
79
80
+
## Adding images to cards
81
+
82
+
Cards support displaying images alongside content. The image automatically resizes to fit the card dimensions, so you typically don't need to specify `imageWidth` or `imageHeight` unless you want to override the default behavior.
Position of the image relative to the card content. Use `imagePosition` to control the layout.
158
+
</ParamField>
159
+
<ParamFieldpath="imageWidth"type="string">
160
+
Width of the image (e.g. `200px`, `50%`). Only use if you need to override the default sizing. The image automatically resizes to fit the card by default.
161
+
</ParamField>
162
+
<ParamFieldpath="imageHeight"type="string">
163
+
Height of the image (e.g. `150px`, `100%`). Only use if you need to override the default sizing. The image automatically resizes to fit the card by default.
0 commit comments