Repository navigation
feat(pos): redesign cart-first layout with order details drawer and scheduled orders toggle - #1458
Conversation
…cheduled orders toggle (#1456)
…g and POS cart details drawer
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the
|
PR Summary by QodoRedesign POS cart layout and add a scheduled-orders toggle
AI Description
Diagram
High-Level Assessment
Files changed (17)
|
Code Review by Qodo
1.
|
Intent
On the FloCafe POS page, clicking on Delivery or Takeaway expands large order-detail and kitchen-scheduling sections above the cart items, and on small screens those sections push the cart items out of view. Even proposed compact mockups still leave too much lost vertical space at the bottom of the cart and a little bit at the top. Redesign and implement a cart-first responsive layout in FloCafe POS that eliminates wasted space at both the top and bottom of the cart across all order types (Dine in, Takeaway, Delivery, Online), keeps order details accessible via a one-tap summary and slide-over details drawer, preserves all existing order data/validation/checkout behavior, and keeps cart items clearly visible on small and short screens. Also add an enable/disable toggle for Scheduled Orders (like Multi-Counter) so scheduled-order options and POS controls are only visible/configurable when enabled, keeping the POS clean when disabled.
What Changed
CartPanel.tsx) and a slide-overOrderDetailsDrawer(OrderDetailsDrawer.tsx), reducing cart header/footer chrome and lowering the short-viewport whole-cart scroll breakpoint to500px(globals.css).scheduled_orders_enabledstore setting (default'false') to/api/settings(main/routes/settings.ts) and Settings > POS (settings/page.tsx,Toggle.tsx), gating the POS topbar scheduled-orders button (PosTopbar.tsx), kitchen scheduling controls, andscheduled_forcheckout/cart-fingerprint state (pos/page.tsx).docs/) and expanded unit and Playwright E2E coverage for the order details drawer, compact cart layout, and scheduled-orders setting toggle (tests/,frontend/e2e/).Risk Assessment
✅ Low: The POS cart-first layout redesign, order-details drawer, and scheduled_orders_enabled setting toggle are well-bounded, preserve existing order/payment/scheduling behavior, and have thorough unit, SSR, and E2E coverage.
Testing
Ran the focused SSR and RTL regression suites (
test:ui-regressions-621-623-626,test:rtl-dashboard-pos-common), the backend/integration scheduled-orders suite (test:scheduled-orders), built the backend and static frontend, and drove the live Chromium Playwright E2E suites (scheduled-orders.spec.ts,multi-counter-ordering.spec.ts, and the short-viewport cart scroll describe block inlayout-integrity.spec.ts) against an isolated E2E server instance, capturing visual screenshot evidence in the evidence directory; all checks and live scenarios passed.Pipeline
Updates from git push no-mistakes
✅ **intent** - passed
✅ No issues found.
✅ **Rebase** - passed
✅ No issues found.
✅ **Review** - passed
✅ No issues found.
✅ **Test** - passed
✅ No issues found.
npm run test:ui-regressions-621-623-626npm run test:rtl-dashboard-pos-commonnpm run test:scheduled-ordersnpm run build && npm run build:frontendcd frontend && CI=1 E2E_BASE_URL=http://127.0.0.1:4301 E2E_KDS_BASE_URL=http://127.0.0.1:4302 E2E_SERVER_APP_BASE_URL=http://127.0.0.1:4303 EVIDENCE_DIR=~/.no-mistakes/evidence/01M6J3JNHMFG1QS15Y2M4BFX38 npx playwright test scheduled-orders.spec.ts multi-counter-ordering.spec.ts --config=playwright.config.ts --project=chromiumcd frontend && CI=1 E2E_BASE_URL=http://127.0.0.1:4301 E2E_KDS_BASE_URL=http://127.0.0.1:4302 E2E_SERVER_APP_BASE_URL=http://127.0.0.1:4303 npx playwright test layout-integrity.spec.ts -g "checkout controls stay visible while catalog and cart content scroll" --config=playwright.config.ts --project=chromium✅ **Document** - passed
✅ No issues found.
✅ **Lint** - passed
✅ No issues found.
✅ **Push** - passed
✅ No issues found.