#182
Flex, Stack and Box
A Stack with a wrapping Flex row of three chips above a single padded Box.
Hand this to your AI. It names the exact library parts, timings and accessibility promises of this demo.
Build the "Flex, Stack and Box" pattern (@codeatlasdev/ui demo #182, layout/layout-primitives) in my app.
Call get_demo({ ids: ["#182"] }) first and keep its structure. It needs @codeatlasdev/[email protected].
Use: Composing small layouts with spacing props instead of custom CSS.
Keep these library parts, with the props and tokens the demo uses:
- Stack, Flex, Box from "@codeatlasdev/ui"
Behaviour to keep:
- `<Stack gap="4" p="4">` is the root
- `<Flex gap="3" align="center" justify="between" wrap>` holds 3 `<Box class="chip" px="3" py="1">` items
- Chip labels: Flex, space between; gap 3; wraps
- A last `<Box class="chip" p="4">` reads Stack gap 4, Box padding 4
Reduced motion: the demo handles it; keep that branch.
Keyboard: not an interactive control.
Change only the copy and the data. Use the theme tokens (--ca-*), never raw colours. Library parts
- Stack
@codeatlasdev/ui - Flex
@codeatlasdev/ui - Box
@codeatlasdev/ui
How it is built
- `<Stack gap="4" p="4">` is the root
- `<Flex gap="3" align="center" justify="between" wrap>` holds 3 `<Box class="chip" px="3" py="1">` items
- Chip labels: Flex, space between; gap 3; wraps
- A last `<Box class="chip" p="4">` reads Stack gap 4, Box padding 4
Related
Loading source.