whisper-money/resources/js
Víctor Falcón b1f01e4a8f
feat(automation-rules): simplify smart rules UI, fix re-evaluation, and localize amounts (#161)
## Why

**Problem:** Bulk re-evaluation of transactions against smart rules was
broken because the code required an encryption key that no longer exists
in the app. Additionally, the rule builder UI had unnecessary complexity
(priority field, labels/tags, date/category/notes conditions) that added
cognitive load without value. Currency amounts were also always
formatted with US conventions regardless of the user's locale.

## What

**Automation rules – re-evaluation fix:**
- Remove encryption key requirement from `evaluateRules`,
`evaluateRulesForTransactions`, `evaluateRulesForNewTransaction`, and
`prepareTransactionData` (accept `CryptoKey | null`)
- Drop `isKeySet` guards from single-transaction and bulk re-evaluate
handlers in `transaction-list.tsx` and `transaction-actions-menu.tsx`
- Simplify `use-re-evaluate-all-transactions.tsx` to pass `null` as key
directly

**Automation rules – UI cleanup:**
- Hide priority field from create/edit dialogs (still sends `priority:
0` / `rule.priority` to satisfy backend validation)
- Remove labels/tags from create/edit dialogs, actions column, and table
display
- Remove `date`, `category`, and `notes` from rule condition field
options in `rule-builder-utils.ts`
- Add `opacity-30` to disabled X button when only one condition/group
remains

**Amount localization:**
- Replace hardcoded `'en-US'` with `useLocale()` in `AmountDisplay` so
symbol position and number format follow the user's locale (e.g.
`89.705,00 €` in Spanish)

## Verification

- 38/38 `AutomationRuleTest` + `AutomationRuleEvaluationTest` tests pass
- Re-evaluation works without an encryption key set
- Spanish locale users see `89.705,00 €` instead of `€89,705.00`
2026-02-28 13:24:57 +00:00
..
components feat(automation-rules): simplify smart rules UI, fix re-evaluation, and localize amounts (#161) 2026-02-28 13:24:57 +00:00
contexts Move transaction filtering from client-side to server-side (#126) 2026-02-16 12:49:04 +01:00
hooks feat(automation-rules): simplify smart rules UI, fix re-evaluation, and localize amounts (#161) 2026-02-28 13:24:57 +00:00
layouts feat: Decrypt encrypted transactions on key unlock (#123) 2026-02-16 10:37:43 +01:00
lib feat(automation-rules): simplify smart rules UI, fix re-evaluation, and localize amounts (#161) 2026-02-28 13:24:57 +00:00
pages feat(automation-rules): simplify smart rules UI, fix re-evaluation, and localize amounts (#161) 2026-02-28 13:24:57 +00:00
providers fix: Discord link 2026-02-18 13:00:30 +01:00
services feat: Decrypt encrypted transactions on key unlock (#123) 2026-02-16 10:37:43 +01:00
types Add chart color scheme setting (#101) 2026-02-28 12:58:21 +01:00
utils feat: Add daily balance chart with area visualization for account pages (#135) 2026-02-19 14:55:05 +01:00
app.tsx Add chart color scheme setting (#101) 2026-02-28 12:58:21 +01:00
ssr.tsx Remove plaintext-transactions feature flag & E2E references (#116) 2026-02-13 11:10:21 +01:00