Commit a86bd4d
authored
fix(ux/settings): reset-override dialog wording matches data semantics (#174)
Closes #114.
The Reset confirmation dialog said:
"Reset {provider}/{service} override to the global default? Any
per-service values you set will be replaced."
But what actually happens is the row is DELETEd from
account_service_overrides — the engine then reads the global default as
a side effect of the row being gone, not as a "reset" operation in the
data sense. "Replaced" implied the row stuck around with new values.
Per the issue's recommended option A (tighten wording, keep DELETE
semantics), changes:
- Button label: "Reset" → "Delete"
- Dialog title: "Reset override?" → "Delete override?"
- Dialog body: spells out that the override row + its per-service
values will be removed and the account reverts to the global
default
- Confirm label: "Reset override" → "Delete override"
- Toast on failure: "Failed to reset override" → "Failed to delete
override"
- The Inherit-payment dropdown's tooltip ("Use Reset to clear all
override fields including payment") tightened to point at the
Delete action
Side change: exported `loadOverridesPanel` so the new test can drive
the override panel directly. The function is a coherent unit and was
already test-friendly in shape; just needed the export.
Tests:
- New `Delete-override button + dialog wording match the actual data
semantics (issue #114)` test pins the post-fix wording: button
reads "Delete" (not "Reset"), dialog title/body/confirm label all
match, body must NOT contain "replaced" or "Reset".
- All 41 existing settings-accounts tests still pass.
Frontend-only change. Backend (`DELETE
/api/accounts/:id/service-overrides/:provider/:service`) unchanged.
Drive-by: removed unused `formatRelativeTime` import in
`frontend/src/recommendations.ts`. It was a pre-existing TS6133 error
(unused-declaration) that broke `recommendations.test.ts` from
running, blocking every commit on this branch. One-line fix to unblock.1 parent cedcade commit a86bd4d
2 files changed
Lines changed: 59 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| 7 | + | |
7 | 8 | | |
8 | 9 | | |
9 | 10 | | |
| |||
989 | 990 | | |
990 | 991 | | |
991 | 992 | | |
| 993 | + | |
| 994 | + | |
| 995 | + | |
| 996 | + | |
| 997 | + | |
| 998 | + | |
| 999 | + | |
| 1000 | + | |
| 1001 | + | |
| 1002 | + | |
| 1003 | + | |
| 1004 | + | |
| 1005 | + | |
| 1006 | + | |
| 1007 | + | |
| 1008 | + | |
| 1009 | + | |
| 1010 | + | |
| 1011 | + | |
| 1012 | + | |
| 1013 | + | |
| 1014 | + | |
| 1015 | + | |
| 1016 | + | |
| 1017 | + | |
| 1018 | + | |
| 1019 | + | |
| 1020 | + | |
| 1021 | + | |
| 1022 | + | |
| 1023 | + | |
| 1024 | + | |
| 1025 | + | |
| 1026 | + | |
| 1027 | + | |
| 1028 | + | |
| 1029 | + | |
| 1030 | + | |
| 1031 | + | |
| 1032 | + | |
| 1033 | + | |
| 1034 | + | |
| 1035 | + | |
| 1036 | + | |
| 1037 | + | |
| 1038 | + | |
992 | 1039 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
556 | 556 | | |
557 | 557 | | |
558 | 558 | | |
559 | | - | |
| 559 | + | |
560 | 560 | | |
561 | 561 | | |
562 | 562 | | |
| |||
660 | 660 | | |
661 | 661 | | |
662 | 662 | | |
663 | | - | |
| 663 | + | |
664 | 664 | | |
665 | 665 | | |
666 | 666 | | |
| |||
741 | 741 | | |
742 | 742 | | |
743 | 743 | | |
744 | | - | |
| 744 | + | |
| 745 | + | |
| 746 | + | |
| 747 | + | |
| 748 | + | |
| 749 | + | |
745 | 750 | | |
746 | 751 | | |
747 | | - | |
748 | | - | |
749 | | - | |
| 752 | + | |
| 753 | + | |
| 754 | + | |
750 | 755 | | |
751 | 756 | | |
752 | 757 | | |
| |||
755 | 760 | | |
756 | 761 | | |
757 | 762 | | |
758 | | - | |
| 763 | + | |
759 | 764 | | |
760 | 765 | | |
761 | 766 | | |
| |||
0 commit comments