StorefrontLayout (am-storefront-layout)
StorefrontLayout 支援 collection 與 product 兩種 mode,涵蓋 shop listing、filters、product gallery、variants 與 reviews 插槽。它只提供展示與表單語意,不會直接建立購物車、庫存或付款效果。
Collection
Section titled “Collection”---import StorefrontLayout from "@astromer/core/components/StorefrontLayout.astro";---
<StorefrontLayout brandLabel="Fernweg Supply" navItems={[{ label: "Shop", href: "/shop", current: true }]} title="Shop all" filters={[{ label: "Category", options: [{ label: "Field gear", value: "field" }] }]} products={[{ title: "Trail mug", href: "/shop/trail-mug", price: "NT$680", category: "Drinkware" }]} cartCount={2}/>Product detail
Section titled “Product detail”將 mode="product" 與 product data 傳入即可切換到 gallery/detail shell;product-extra slot 適合放 reviews、shipping 與 returns 說明。