Skip to content

Add a 1×–4× batch control to the drink dialog#13

Open
Glitched wants to merge 2 commits into
mainfrom
claude/home-bar-menu-review-g4eys5
Open

Add a 1×–4× batch control to the drink dialog#13
Glitched wants to merge 2 commits into
mainfrom
claude/home-bar-menu-review-g4eys5

Conversation

@Glitched

@Glitched Glitched commented Jun 9, 2026

Copy link
Copy Markdown
Owner

Phone-friendly batching in the drink dialog, per the design discussed in chat.

Interaction

A chip leads the dialog's existing chip row (before the ABV/NA chip). Tapping it expands an inline 1×–4× segmented pill in place — no popover, and the chip row already scrolls horizontally so it works on small screens. Picking a factor collapses the pill and scales every ingredient amount; the chip renders inverted (filled) when a batch is active so a 2× spec can't be mistaken for the standard one. Uses the multiplication sign ×, not the letter "x".

State is per-opening: the factor resets to 1× every time a drink dialog opens, so it never leaks across drinks or repeat openings.

Scaling

New scaleAmount() util (reuses the fraction parser from drinkStrength.ts):

  • Mixed fractions render to the nearest eighth, the finest unit on the menu: 3/4 oz × 3 → 2 1/4 oz, 1 1/2 oz × 2 → 3 oz
  • Ranges scale both ends: 6-8 leaves × 2 → 12-16 leaves
  • Dashes and barspoons pluralize: 1 dash × 3 → 3 dashes
  • to taste and unmeasured ingredients pass through unchanged

The ABV chip is unaffected (strength is proportional), and DUs stay per-serving.

Verified with yarn build plus a standalone test of the scaling math across every amount format used in the menu.

https://claude.ai/code/session_01GQs3cjdNbTtp8RZfMsw4SS


Generated by Claude Code

claude added 2 commits June 9, 2026 21:56
A "1×" chip leads the dialog's chip row; tapping it expands an inline
1×-4× segmented pill, and picking a factor collapses it and scales
every ingredient amount via a new scaleAmount() util (mixed fractions
to the nearest eighth, ranges like "6-8 leaves" scale both ends,
dash/barspoon pluralize, "to taste" passes through). The chip renders
inverted when scaled so an active batch is obvious, and the factor
resets each time a dialog opens so it never leaks across drinks.

https://claude.ai/code/session_01GQs3cjdNbTtp8RZfMsw4SS
@netlify

netlify Bot commented Jun 9, 2026

Copy link
Copy Markdown

Deploy Preview for thenightlatch ready!

Name Link
🔨 Latest commit 5740630
🔍 Latest deploy log https://app.netlify.com/projects/thenightlatch/deploys/6a288c3ea688b10008fef9a1
😎 Deploy Preview https://deploy-preview-13--thenightlatch.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants