# Quick Size Grid block

> Ecommerce product grid with hover quick-buy panel and in-stock-aware size picker

Shoppable 3-column product grid; cards reveal a hover quick-buy panel with a stock-aware size picker (sold-out sizes struck through), wishlist toggle, and Add to Bag. ReUI Badge, shadcn Item, Field, Checkbox, Button. Storefront catalog, shop listing.

- Type: Pro block
- Category: [Product Grid](https://web.dev.reui.io/blocks/ecommerce/product-grid.md)
- Page: https://web.dev.reui.io/blocks/ecommerce/product-grid/product-grid-5
- MCP: `get_block("product-grid-5")`
- Built with: Badge, Button, Checkbox, Field, Item
- Installs with a ReUI Pro or Ultimate license; setup: https://web.dev.reui.io/docs/license-setup

## Best for

Portrait photos with a hover quick-buy panel for XS to XL sizes, sold out ones struck, and a shipping line under the price

## Agent notes

- `handleAddToCart` only dispatches a `CustomEvent` named reui:add-to-cart carrying `productId` and `size`; wire your cart store there
- Stock comes from each `sizes` entry's `state` (`available`, `low`, `out`); `out` sizes are disabled and struck, `low` sizes tinted
- The Add to Bag button stays enabled without a size and then sends a null `size`; guard `handleAddToCart` or disable it

## When not to use

- One item with a photo gallery, variant picker and reviews on its own page: use the [Product Detail blocks](https://web.dev.reui.io/blocks/ecommerce/product-detail.md)

## Install

```bash
npx shadcn@latest add @reui/product-grid-5
```

## About Product Grid blocks

### When to use

- A collection or category page body of photo tiles with prices, sale strikethroughs and a wishlist save
- Comparing colorways through swatches, or buying from the listing with a hover size picker or cart button
- Editorial or lookbook edits whose tiles add a story and specs, or fade to an on model photo on hover

### When not to use

- Dashboard tiles for KPIs, people or records in an app, with no price or buy control: use the [Card blocks](https://web.dev.reui.io/blocks/application/card.md)
- A bordered panel surface with header, body and footer slots for content not for sale: use [Frame](https://web.dev.reui.io/components/frame.md) (`get_component("frame")`)
- A listing with its own heading, sort and filter toolbar, breadcrumb or carousel rail: use the [Product Card blocks](https://web.dev.reui.io/blocks/ecommerce/product-card.md)

### Agent notes

- `ProductGrid` takes no props and maps `PRODUCTS` from data.ts, where each `price` is a preformatted string and every `href` is a hash placeholder
- The wishlist toggle only flips the local `likedProducts` set seeded from `DEFAULT_LIKED_PRODUCT_IDS`; persist it to your own wishlist store
- Each page.tsx adds a `min-h-svh` main and `ProductGrid` sets `max-w-6xl` with its own padding; drop both inside your storefront layout

Every ReUI item has a twin like this one; the index is https://web.dev.reui.io/llms.txt. Agents with the ReUI MCP (https://web.dev.reui.io/docs/mcp) get the same guidance from the getters named above.
