Skip to content

Add storefront features: admin dashboard, warranty calculator, build configurator, serverless APIs, assets, and E2E tests#5

Merged
vctb12 merged 2 commits into
mainfrom
codex/revamp-website-for-performance-and-functionality-n6avph
Mar 2, 2026
Merged

Add storefront features: admin dashboard, warranty calculator, build configurator, serverless APIs, assets, and E2E tests#5
vctb12 merged 2 commits into
mainfrom
codex/revamp-website-for-performance-and-functionality-n6avph

Conversation

@vctb12

@vctb12 vctb12 commented Mar 2, 2026

Copy link
Copy Markdown
Owner

Motivation

  • Provide a production-ready, modular static storefront for Netlify with UAE AED/VAT rules, improved UX, and server-backed optional features.
  • Harden admin and order flows to support optional Supabase persistence and email notifications while keeping demo/local fallbacks.
  • Improve maintainability by centralizing header/footer partials and extracting small JS libs for API, rules, security, and error logging.

Description

  • New pages and content: added build.html, changelog.html, health.html, payment-demo.html, extended blog/AR pages, and upgraded index.html, products.html, checkout.html, admin.html, warranty.html, contact.html, and other templates to use shared partials (partials/header.html, partials/footer.html) and richer metadata/SEO tags.
  • Admin and dashboard improvements: client-side admin enhancements (search/filters, KPIs, CSV export, stock overrides), deferred boot of shared partials, token-based auth flow and improved feedback.
  • Serverless functions: added/updated Netlify functions including createOrder, adminLogin (rate limiting + safer responses), ordersList, createPaymentIntent, markOrderPaid, notifyCapture, chat (OpenAI optional demo fallback), and _utils.js helper changes.
  • Product & assets: enriched products.json with warranty/meta fields and added many SVG assets under assets/products/, placeholder/image improvements, warrantyRules.json and buildRules.json for calculators.
  • Frontend libraries & pages: new JS modules under js/lib and js/pages (api.js, dom.js, format.js, rules.js, security.js, logger.js, chat.js, warranty.js) plus enhancements in script.js (partial loader, error UI, chat init, utilities).
  • Checkout & payment: demo-first payment intent flow and simulated payment lifecycle via createPaymentIntent and payment-demo.html, plus invoice rendering and server-side order validation, Supabase save and optional email via Resend.
  • Tooling & QA: add package.json, playwright.config.ts, e2e tests in tests/e2e, asset/link validation scripts (scripts/validate-assets.mjs, scripts/audit-links.mjs), netlify.toml redirects, sitemap.xml, and robots.txt.

Testing

  • Ran static asset validation and link audit via node scripts/validate-assets.mjs and node scripts/audit-links.mjs, which completed successfully (no broken local assets/links reported).
  • Executed end-to-end suite via Playwright using npm run test:e2e (driven by playwright.config.ts) and the tests passed, validating core routes, chat demo, warranty calculator, product notify/add flows, admin dashboard, build page and demo payment lifecycle.
  • Local site preview command used during development is python -m http.server 4173 to exercise the e2e webServer target and manual smoke checks.
  • CI-ready scripts were added in package.json to reproduce the above automated checks (validate-assets, audit-links, test:e2e).

Codex Task

@netlify

netlify Bot commented Mar 2, 2026

Copy link
Copy Markdown

Deploy Preview for akastore failed.

Name Link
🔨 Latest commit 6d13525
🔍 Latest deploy log https://app.netlify.com/projects/akastore/deploys/69a55522a8fb640008f8a039

@vctb12 vctb12 marked this pull request as ready for review March 2, 2026 09:15
@vctb12 vctb12 merged commit 7897994 into main Mar 2, 2026
3 of 10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant