feat: POS UI improvements — dev-server, frontend submodule update - #6
Merged
Conversation
- Added build/appx/ with all 30 required tile assets (6 types × 5 scales) sourced from assets/icon-512.png (actual Flo brand identity) - Fixed assets/icon.png which was a plain blue square placeholder; replaced with the real Flo logo (copied from icon-256.png) - Tile assets: StoreLogo, Square44x44Logo, SmallTile, Square150x150Logo, Wide310x150Logo, LargeTile — all scale variants (100%-400%)
- Add sidebar toggle button to show/hide cart panel - Implement responsive product grid: 4 boxes when sidebar open, 5 when closed - Fix cart item number cut-off by adjusting positioning - Add -0+ quantity buttons with proper cursor pointer styling - Fix addon button clickability by converting span to button - Update package dependencies
khaira777
added a commit
that referenced
this pull request
Jun 30, 2026
Replace execSync with execFileSync in thermal.ts to prevent shell interpretation of printer names on macOS, Linux, and Windows. Add regex validation on printer name input to reject shell metacharacters. Add .gstack/ to .gitignore to keep security reports local. Closes CSO Finding #6
khaira777
added a commit
that referenced
this pull request
Jul 5, 2026
…ts/discounts/tax/loyalty) Integration tests (7 files, 123 assertions): - Happy path: order→discount→bill→payment→completed - Tax correctness: India GST calculation and recalculation - Payment integrity: split payments, wallet double-spend, zero-amount rejection - Order lifecycle: status transitions, cancel with PIN - Bill reconciliation: discount sync, add-items sync - Loyalty points: cashback, idempotency, wallet balance - Discount edge cases: combined discounts, max limits, addon prices Bug fixes: - #3: Add-items filters cancelled items from total recalculation - #4: Add-items syncs bill after updating order total - #5: Cancel/restore round-off formula corrected - #6: Discount endpoint wrapped in withTxn (race condition) - #7: Infinity passes validation (NaN/isFinite check) - #8: Missing amount defaults to remaining balance - #9: Amount capped at remaining balance - #11: Removing discount restores original tax - #12: Add-items preserves order-level discount - #13: Cancel/restore preserves order-level discount - #14: Item-level discount checks max settings - #15: Item-level discount syncs to bill - #17: Cancel/restore wrapped in withTxn - #20: Cashback calculated on discounted subtotal - #23: Quantity/price validation on order creation Shared test helper (tests/helpers/test-setup.ts): - Extracts 40 lines of boilerplate per test file - Provides: initTestDb, createApp, startServer, seed helpers, assert utilities Co-Authored-By: Claude <noreply@anthropic.com>
khaira777
pushed a commit
that referenced
this pull request
Jul 6, 2026
feat: POS UI improvements — dev-server, frontend submodule update
khaira777
added a commit
that referenced
this pull request
Jul 6, 2026
Replace execSync with execFileSync in thermal.ts to prevent shell interpretation of printer names on macOS, Linux, and Windows. Add regex validation on printer name input to reject shell metacharacters. Add .gstack/ to .gitignore to keep security reports local. Closes CSO Finding #6
7 tasks
carvalab
added a commit
to carvalab/FloCafe
that referenced
this pull request
Jul 31, 2026
Scope (approved before this draft): - Merchant: IVA-registered restaurants (Responsable Inscripto), domestic sales of standard supplies. - Tax: one IVA rule at the general rate of 21%, applied across every category (product, addon, packaging, delivery, service_charge, unclassified). - Default pricing is tax-inclusive to match Argentina's consumer- price-display rule (Res. 4/2025); individual products can still be set exclusive per-item for B2B use. Source: Ley de Impuesto al Valor Agregado, texto ordenado en 1997 (Ley 23.349 t.o. Decreto 280/1997, Anexo I), Articulo 28 — 'La alicuota del impuesto sera del veintiuno por ciento (21%)'. Continuously in force since BO 15/04/1997. Cross-references: ARCA biblioteca cuadro legislativo Articulo 28; InfoLeg norma 42701. Intentionally unsupported (do not add to this pack without a scope bump): IIBB (provincial, registration-dependent); reduced 10.5%; incremented 27% (utilities); 2.5% and 0%; Monotributo; withholding and perception regimes; ARCA CAE fiscal-invoice authorization (belongs to the capability-plugin seam FreeOpenSourcePOS#142). Tests added/extended: - tests/tax-engine.test.ts: ARS 100 exclusive -> 21 -> 121; ARS 121 inclusive -> net 100 / IVA 21; all charge kinds apply the rule; unclassified never silently zero. - tests/tax-pack-management.test.ts: installs AR alongside IN/TH and confirms the 24-point activation checklist accepts it (only check FreeOpenSourcePOS#6, signed artifact, fails pre-signing, same as the unsigned IN/TH seeds). - tests/integration-tax.test.ts: AR exclusive order at ARS 1000 produces 210 IVA and 1210 total; 20% discount recomputes to 168 IVA and 968 total; inclusive product keeps IVA inside the displayed price and persists the behavior as inclusive in the snapshot; the bill copies the order tax. Every breakdown is asserted to contain no IIBB or Ingresos Brutos component. Docs: docs/tax-packs.md gains a 'Country pack scopes' section pinning the approved merchant scope, the IVA source, every excluded area, and the upgrade path for provincial IIBB (only after FloCafe models province + activity code + customer registration status). Companion e2e-server fix (unblocks CI for this PR): Commit 3a75876 ('publish country packs separately') moved India and Thailand from BUNDLED_COUNTRY_PACKS to catalog-only delivery, and the e2e-server fixture seeds country='TH' without simulating the post- first-run owner action of installing Thailand from Settings → Tax Configuration. The active pack for country=TH then falls back to the zero-rules generic pack, and the checkout throws 'no tax rules apply to category standard for business type restaurant' → 400. The Playwright spec at prepaid-payment-reconciliation.spec.ts:13/55 times out waiting for 'Tax ฿4.20'. This is the same regression silently failing the most recent two main CI runs before this PR. Fix by inlining the same install-tax-pack SQL helper that the unit and integration tests already use. Only Thailand is installed — it's the only country-specific pack exercised by e2e specs. Verified locally: npm run lint, npm run build, npm run test:tax-engine (12/12), npm test (0 failed across every suite including Integration Tax 114/114 and Tax Pack Management 103/103), git diff --check clean. Publishing (tag, push to upstream, CI sign) is not part of this PR. That step stays gated on maintainer review per the task spec; no signing secret was touched.
carvalab
added a commit
to carvalab/FloCafe
that referenced
this pull request
Jul 31, 2026
Scope (approved before this draft): - Merchant: IVA-registered restaurants (Responsable Inscripto), domestic sales of standard supplies. - Tax: one IVA rule at the general rate of 21%, applied across every category (product, addon, packaging, delivery, service_charge, unclassified). - Default pricing is tax-inclusive to match Argentina's consumer- price-display rule (Res. 4/2025); individual products can still be set exclusive per-item for B2B use. Source: Ley de Impuesto al Valor Agregado, texto ordenado en 1997 (Ley 23.349 t.o. Decreto 280/1997, Anexo I), Articulo 28 -- 'La alicuota del impuesto sera del veintiuno por ciento (21%)'. Continuously in force since BO 15/04/1997. Cross-references: ARCA biblioteca cuadro legislativo Articulo 28; InfoLeg norma 42701. Intentionally unsupported (do not add to this pack without a scope bump): IIBB (provincial, registration-dependent); reduced 10.5%; incremented 27% (utilities); 2.5% and 0%; Monotributo; withholding and perception regimes; ARCA CAE fiscal-invoice authorization (belongs to the capability-plugin seam FreeOpenSourcePOS#142). Tests: - tests/tax-engine.test.ts: ARS 100 exclusive -> 21 -> 121; ARS 121 inclusive -> net 100 / IVA 21; all charge kinds apply the rule; unclassified never silently zero. - tests/tax-pack-management.test.ts: installs AR alongside IN/TH and confirms the 24-point activation checklist accepts it (only check FreeOpenSourcePOS#6, signed artifact, fails pre-signing, same as IN/TH seeds). - tests/integration-tax.test.ts: AR exclusive order (ARS 1000 -> 210 IVA -> 1210 total); 20% discount recompute (168/968); inclusive product keeps IVA inside the displayed price and persists behavior as inclusive; bill copies the order tax; every breakdown asserted to contain no IIBB/Ingresos Brutos component. Docs: docs/tax-packs.md gains a 'Country pack scopes' section pinning the approved merchant scope, the IVA source, every excluded area, and the upgrade path for provincial IIBB (only after FloCafe models province + activity code + customer registration status).
carvalab
added a commit
to carvalab/FloCafe
that referenced
this pull request
Jul 31, 2026
Scope (approved before this draft): - Merchant: IVA-registered restaurants (Responsable Inscripto), domestic sales of standard supplies. - Tax: one IVA rule at the general rate of 21%, applied across every category (product, addon, packaging, delivery, service_charge, unclassified). - Default pricing is tax-inclusive to match Argentina's consumer- price-display rule (Res. 4/2025); individual products can still be set exclusive per-item for B2B use. Source: Ley de Impuesto al Valor Agregado, texto ordenado en 1997 (Ley 23.349 t.o. Decreto 280/1997, Anexo I), Articulo 28 -- 'La alicuota del impuesto sera del veintiuno por ciento (21%)'. Continuously in force since BO 15/04/1997. Cross-references: ARCA biblioteca cuadro legislativo Articulo 28; InfoLeg norma 42701. Intentionally unsupported (do not add to this pack without a scope bump): IIBB (provincial, registration-dependent); reduced 10.5%; incremented 27% (utilities); 2.5% and 0%; Monotributo; withholding and perception regimes; ARCA CAE fiscal-invoice authorization (belongs to the capability-plugin seam FreeOpenSourcePOS#142). Tests: - tests/tax-engine.test.ts: ARS 100 exclusive -> 21 -> 121; ARS 121 inclusive -> net 100 / IVA 21; all charge kinds apply the rule; unclassified never silently zero. - tests/tax-pack-management.test.ts: installs AR alongside IN/TH and confirms the 24-point activation checklist accepts it (only check FreeOpenSourcePOS#6, signed artifact, fails pre-signing, same as IN/TH seeds). - tests/integration-tax.test.ts: AR exclusive order (ARS 1000 -> 210 IVA -> 1210 total); 20% discount recompute (168/968); inclusive product keeps IVA inside the displayed price and persists behavior as inclusive; bill copies the order tax; every breakdown asserted to contain no IIBB/Ingresos Brutos component. Docs: docs/tax-packs.md gains a 'Country pack scopes' section pinning the approved merchant scope, the IVA source, every excluded area, and the upgrade path for provincial IIBB (only after FloCafe models province + activity code + customer registration status).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR updates the FloCafe Electron app with the latest frontend (FloUI) changes and adds a standalone dev server.
Changes
Frontend Submodule
Dev Server
dev-server.js— a standalone Express + SQLite backend that runs without ElectronRelated PR