feat(waiter): English-first texts, part b: table detail, ordering, options, payment (platform-v2 step 4.5b)
- Table detail (actions, item actions, split, price, discount, pay / revert / close, move / merge / transfer, guests, flags, assign, print), the order drawer (tabs, options, quick notes, price change, summary), add items (cart, totals, deals, search), the order summary and the summary before sending, the product picker. - Money everywhere here in the language's format (`money()` in waiter i18n.js for helpers shared by several components, useFormat() elsewhere). - The default quick notes are keys (the venue's own quick notes still win). - Variables named `t` (tables, tabs, timers) renamed so they don't shadow t(). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -4,6 +4,7 @@ import { useProductCache } from '../hooks/useProductCache'
|
||||
import useWaiterFavoritesStore from '../store/waiterFavoritesStore'
|
||||
import { assetUrl } from '../config/server'
|
||||
import { useFormat, useTranslation } from '@xenia/i18n'
|
||||
import { money } from '../i18n'
|
||||
|
||||
// ── Heart icon ────────────────────────────────────────────────────────────────
|
||||
function Heart({ filled, size = 22 }) {
|
||||
@@ -67,10 +68,10 @@ function AttrSection({ title, items, favIds, onToggle }) {
|
||||
{item.name}
|
||||
</div>
|
||||
{item.extra_cost != null && item.extra_cost !== 0 && (
|
||||
<div style={{ fontSize: 12, color: 'var(--muted)' }}>+{Number(item.extra_cost).toFixed(2)} €</div>
|
||||
<div style={{ fontSize: 12, color: 'var(--muted)' }}>+{money(item.extra_cost)}</div>
|
||||
)}
|
||||
{item.price != null && item.price !== 0 && (
|
||||
<div style={{ fontSize: 12, color: 'var(--muted)' }}>+{Number(item.price).toFixed(2)} €</div>
|
||||
<div style={{ fontSize: 12, color: 'var(--muted)' }}>+{money(item.price)}</div>
|
||||
)}
|
||||
</div>
|
||||
<button
|
||||
@@ -407,7 +408,7 @@ function FavoritesList({ items, products, onReorder }) {
|
||||
{product.name}
|
||||
</span>
|
||||
|
||||
<span style={{ fontSize: 12, color: 'var(--muted)', flexShrink: 0 }}>{Number(product.base_price).toFixed(2)} €</span>
|
||||
<span style={{ fontSize: 12, color: 'var(--muted)', flexShrink: 0 }}>{money(product.base_price)}</span>
|
||||
</div>
|
||||
|
||||
{dropIndex === idx + 1 && dragging != null && dragging !== idx && (
|
||||
|
||||
Reference in New Issue
Block a user