# 5.20 Size a component by its slot

> Chapter 5, Adapt across sizes. Section: Use the space. Guide: https://www.designguide.dev/md/05-adapt-across-sizes.md#size-a-component-by-its-slot

Default

**Rule:** Size a component by the width of its slot, not by the width of the window.

**Why:** A card in a narrow side pane is narrow, even in a wide window.

- Use the window class for the shell and the panes.
- Use the slot width for cards, rows, and charts.
- Test each component in the narrowest slot that it can fill.

**Picture:** Figure: The narrow card shows a title. The wide card adds a detail line.
