Repository navigation
Build Grovia demo-to-alpha storefront #101
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,30 @@ | ||
| # Modern Grocery demo assets | ||
|
|
||
| The Modern Grocery starter uses twelve original generated product images. They | ||
| are bundled with the theme so the public Playground and local CI do not depend | ||
| on third-party media hosts. | ||
|
|
||
| Generated on 25 August 2026 with the OpenAI image generation tool using a | ||
| consistent product-catalog prompt: one unbranded grocery subject, warm paper | ||
| studio background, soft daylight, no text, logo, watermark, people, hands, or | ||
| competitor imagery. Each image was resized to a maximum 640px edge and saved as | ||
| WebP for the demo catalog. | ||
|
|
||
| | File | Product | License/source status | | ||
| | --- | --- | --- | | ||
| | `milk.webp` | Farm Fresh Milk | Original generated asset; Grovia redistribution permitted | | ||
| | `bread.webp` | Sourdough Bread | Original generated asset; Grovia redistribution permitted | | ||
| | `tomatoes.webp` | Vine Tomatoes | Original generated asset; Grovia redistribution permitted | | ||
| | `apples.webp` | Crisp Red Apples | Original generated asset; Grovia redistribution permitted | | ||
| | `bananas.webp` | Robusta Bananas | Original generated asset; Grovia redistribution permitted | | ||
| | `spinach.webp` | Baby Spinach | Original generated asset; Grovia redistribution permitted | | ||
| | `eggs.webp` | Free Range Eggs | Original generated asset; Grovia redistribution permitted | | ||
| | `yogurt.webp` | Plain Greek Yogurt | Original generated asset; Grovia redistribution permitted | | ||
| | `rice.webp` | Everyday Basmati Rice | Original generated asset; Grovia redistribution permitted | | ||
| | `lentils.webp` | Red Lentils | Original generated asset; Grovia redistribution permitted | | ||
| | `oil.webp` | Cold Pressed Groundnut Oil | Original generated asset; Grovia redistribution permitted | | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win Use consistent hyphenation for the oil product name.
🧰 Tools🪛 LanguageTool[uncategorized] ~25-~25: If this is a compound adjective that modifies the following noun, use a hyphen. (EN_COMPOUND_ADJECTIVE_INTERNAL) 📍 Affects 2 files
🤖 Prompt for AI AgentsSource: Linters/SAST tools |
||
| | `cereal.webp` | Toasted Oat Cereal | Original generated asset; Grovia redistribution permitted | | ||
|
|
||
| These are demo fixtures, not a promise that a production store has the same | ||
| catalog or product photography. Production merchants can replace them through | ||
| the normal WordPress media/product workflows. | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,50 @@ | ||
| # Grovia demo-to-alpha security review | ||
|
|
||
| Review date: 25 August 2026 | ||
|
|
||
| Scope: Blueprint changes, the `wp grovia seed-demo` command, bundled demo | ||
| media, canonical theme parts, and the homepage composition. | ||
|
|
||
| ## Findings | ||
|
|
||
| ### BLOCKER / HIGH | ||
|
|
||
| None identified in the reviewed change set. | ||
|
|
||
| ### MEDIUM | ||
|
|
||
| None identified. The seeder refuses WordPress environments other than local, | ||
| development, or staging, and the Blueprint explicitly declares its disposable | ||
| environment as local. | ||
|
|
||
| ### LOW / NOTE | ||
|
|
||
| - The public Blueprint still references the last published release ZIP until | ||
| the new `0.0.3-alpha` artifacts are uploaded. Updating those URLs before the | ||
| release exists would make a clean public launch fail, so this is a release | ||
| sequencing item rather than a code bypass. | ||
| - The browser/Playwright gate could not run in this workspace because the | ||
| pinned WordPress download timed out. CI must run the clean-browser and CLI | ||
| smoke checks before alpha release. | ||
|
|
||
| ## Boundary checks | ||
|
|
||
| - Demo command registration is conditional on `WP_CLI`; it is not exposed as a | ||
| web or REST action. | ||
| - `--reset` deletes only posts, product variations, attachments, marked product | ||
| categories, and the marked Grovia navigation menu. Products and variations | ||
| are deleted through WooCommerce CRUD; unrelated content is not selected. | ||
| - Demo image paths are fixed filenames resolved from the active theme. No | ||
| request value can choose a path, URL, callback, or executable file. | ||
| - Product, category, variation, page, media, and option writes use public | ||
| WordPress/WooCommerce APIs; no order/customer data or direct SQL is involved. | ||
| - Buy Again remains current-user scoped, status-bounded, and nonce-protected | ||
| through the existing REST and Store API contracts. | ||
| - Theme output uses escaped values at render boundaries; the custom product | ||
| unit block reads only bounded product metadata. | ||
|
|
||
| ## Required release follow-up | ||
|
|
||
| Publish the generated ZIPs, update the root Blueprint release URLs, then run | ||
| the clean Blueprint, existing E2E, extended accessibility checks, and this | ||
| review again against the published artifacts. |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,62 @@ | ||
| <?php | ||
| /** | ||
| * WP-CLI entry point for the disposable Grovia demo. | ||
| * | ||
| * @package StorefrontCore | ||
| */ | ||
|
|
||
| namespace StorefrontCore\Demo; | ||
|
|
||
| defined( 'ABSPATH' ) || exit; | ||
|
|
||
| final class Command { | ||
|
|
||
| /** | ||
| * Register the `wp grovia seed-demo` command. | ||
| */ | ||
| public static function register(): void { | ||
| if ( defined( 'WP_CLI' ) && WP_CLI ) { | ||
| call_user_func( array( 'WP_CLI', 'add_command' ), 'grovia seed-demo', new self() ); | ||
| } | ||
| } | ||
|
|
||
| /** | ||
| * Seed the deterministic Modern Grocery demo. | ||
| * | ||
| * ## OPTIONS | ||
| * | ||
| * [--reset] | ||
| * : Remove only records previously marked as Grovia demo content. | ||
| * | ||
| * ## EXAMPLES | ||
| * | ||
| * wp grovia seed-demo | ||
| * wp grovia seed-demo --reset | ||
| * | ||
| * @param array<string,mixed> $args Positional arguments. | ||
| * @param array<string,mixed> $assoc_args Associative arguments. | ||
| */ | ||
| public function seed_demo( array $args, array $assoc_args ): void { | ||
| if ( ! empty( $args ) ) { | ||
| call_user_func( array( 'WP_CLI', 'error' ), 'seed-demo does not accept positional arguments.' ); | ||
| return; | ||
| } | ||
|
|
||
| try { | ||
| $result = ( new DemoSeeder() )->seed( ! empty( $assoc_args['reset'] ) ); | ||
| } catch ( \Throwable $exception ) { | ||
| call_user_func( array( 'WP_CLI', 'error' ), $exception->getMessage() ); | ||
| return; | ||
| } | ||
|
|
||
| call_user_func( | ||
| array( 'WP_CLI', 'success' ), | ||
| sprintf( | ||
| 'Seeded Grovia demo: %d products, %d departments, %d pages.', | ||
| $result['products'], | ||
| $result['categories'], | ||
| $result['pages'] | ||
| ) | ||
| ); | ||
| } | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🩺 Stability & Availability | 🟡 Minor | ⚡ Quick win
🔎 Supported by static analysis
🏁 Script executed:
Repository: Spidy092/ecom-2.0
Length of output: 505
🏁 Script executed:
Repository: Spidy092/ecom-2.0
Length of output: 1686
Update the stale security review note. Both
v0.0.3-alphaassets are published, butdocs/SECURITY-REVIEW-DEMO-ALPHA.mdstill states that the Blueprint references the previous release. Update that note to matchblueprint.json.🤖 Prompt for AI Agents