Documentation
¶
Overview ¶
Package themestorefront is the official storefront theme module: the embedded layouts, static assets, template funcs, and standalone commerce pages (cart, checkout, order tracking) the site-ssr engine consumes. The commerce edition registers it in place of the default blog theme.
Index ¶
- Constants
- func Files() fs.FS
- type Module
- func (m *Module) AdminManifest() kernel.AdminExtensionManifest
- func (m *Module) Init(_ kernel.Kernel) error
- func (m *Module) Name() string
- func (m *Module) Optional() []string
- func (m *Module) Requires() []string
- func (m *Module) Shutdown() error
- func (m *Module) ThemeFiles() fs.FS
- func (m *Module) ThemeFuncs() template.FuncMap
- func (m *Module) ThemePages() []string
- func (m *Module) Version() string
Constants ¶
const ( // Name is the registry key for this module. Name = "theme-storefront" // Version is the module version reported via Module.Version. Version = "0.1.0" )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Module ¶
type Module struct{}
Module is the theme-storefront kernel module.
func New ¶
func New() *Module
New builds the module. The theme artifact is static; construction takes no options.
func (*Module) AdminManifest ¶
func (m *Module) AdminManifest() kernel.AdminExtensionManifest
AdminManifest declares this module's admin-shell extensions. A theme ships no admin UI of its own, so the manifest is empty.
func (*Module) Requires ¶
Requires lists hard dependencies. The theme is a leaf artifact consumed by the site-ssr engine, so nothing is required.
func (*Module) ThemeFiles ¶
ThemeFiles returns the storefront artifact filesystem (layouts under pages/, static assets under static/). The site-ssr engine resolves THEME_DIR overrides over it.
func (*Module) ThemeFuncs ¶
ThemeFuncs returns the template funcs this theme contributes beyond the engine's own. lines() turns a gallery field — legacy newline-separated or canonical gallery array — into a URL list without pushing parsing into templates.
func (*Module) ThemePages ¶
ThemePages declares the standalone commerce shells this theme ships. The engine renders them through the shared layout at the matching public paths and falls through to content/404 when a template is missing.
Directories
¶
| Path | Synopsis |
|---|---|
|
Package admin owns this module's admin-shell manifest: the declarative UI the single admin SPA renders for the storefront theme.
|
Package admin owns this module's admin-shell manifest: the declarative UI the single admin SPA renders for the storefront theme. |
|
Package testutil provides the kernel fixture module tests run against.
|
Package testutil provides the kernel fixture module tests run against. |