Skip to content

fix: clearer unequal-split language and prevent silent save failure#676

Open
mvanhorn wants to merge 4 commits into
oss-apps:mainfrom
mvanhorn:fix/645-2026-06-12-1741-fix-unequal-split-silent-save
Open

fix: clearer unequal-split language and prevent silent save failure#676
mvanhorn wants to merge 4 commits into
oss-apps:mainfrom
mvanhorn:fix/645-2026-06-12-1741-fix-unequal-split-silent-save

Conversation

@mvanhorn

Copy link
Copy Markdown
Contributor

Description

Scopes the fix for #645 to the two things @krokosik was receptive to in the thread: the silent save failure and the ambiguous "paid for/by you" wording.

When a split left one person owed the full amount, the secondary screen's Save could no-op and the expense would silently disappear. This adds a blocking validation guard in addStore so Save is prevented with an inline message instead of discarding the expense, and rewords the directional labels so the direction of money is explicit. Split-definition semantics are unchanged — this only clarifies labels and adds the missing guard, staying inside the scope @krokosik agreed to (no rework of the core split modal to show money flows).

Fixes #645

Demo

Non-visual validation + wording change, covered by unit tests. src/tests/addStore.test.ts adds cases for the one-person-owed split's canSplitScreenClosed/validity flag and the adjustment-exceeds-total guard; the previously-vanishing expense now blocks Save with a validation error. SKIP_ENV_VALIDATION=true pnpm test passes (49/49). No jest config change is needed — CI's check.yml already exports SKIP_ENV_VALIDATION.

Checklist

  • I have read CONTRIBUTING.md in its entirety
  • I have performed a self-review of my own code
  • I have added unit tests to cover my changes
  • The last commit successfully passed pre-commit checks
  • Any AI code was thoroughly reviewed by me

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.

Improve confusing language for unequal splits

1 participant