Kaupvik KeelKaupvik Keel
← Back to Polaris UI Kit

Shopify Polaris 2 Production Engineering Spec

Verified rules for composing Shopify Polaris Web Components without box model regressions, icon clipping, or App Bridge overlay deadlocks.

1. Treat s-* Hosts as display: contents

Custom elements such as <s-button>, <s-text-field>, and <s-icon> often have no outer box. Wrap icon+label children in an inline-flex span and give grid/flex columns real <div> wrappers.

2. Icon Boxes & Valid Registry Names

Give <s-icon> explicit 20×20px boxes inside dense cards and verify every icon type name against polaris-2.js so glyphs never fail silently.

3. Modals, Drawers & App Bridge

Test opening, Escape dismissal, close button, and reopening inside active Shopify App Bridge iframes. Isolate backdrop state cleanly.

4. Native Read-Back & Full Pagination

Always run Preview → Confirm → Execute → Native Read-Back and paginate Shopify B2B lists via endCursor (never hardcode first: 5).

Full markdown spec in the open-source repository: github.com/Kaupvik/kaupvik-polaris/blob/main/docs/POLARIS-2-SPEC.md ↗