style(ui): system-wide UX/UI polish pass — design-system conformance + copy cleanup (#835)

* style(ui): system-wide UX/UI polish pass — design-system conformance + copy cleanup

Multi-agent scan of all 404 UI files against the locked design system, then
141 verified surgical fixes across 109 files (net -32 lines):

- Remove forbidden elevation/motion: shadow-* and rounded-xl on cards, active:scale
  bounce, hover:shadow on list items, transition-all -> transition-colors.
- Drop font-medium from single-weight Hedvig display headings/numerals.
- Replace raw rainbow Tailwind status colors with Badge variants / brand tokens /
  neutral surfaces (achromatic chrome, semantic colors stay data-only).
- Route raw dates through formatDate(), hand-rolled currency through formatCurrency(),
  add tabular-nums to financial figures; text-gray-* -> text-foreground tokens.
- Swap hand-rolled skeletons for the Skeleton primitive; off-scale spacing -> token scale.
- Fix copy: mislabeled "Leverantörsfakturor" -> "Utgifter" on bank-import outflow total,
  collapse no-op identical-branch ternaries, broken Swedish diacritics (mojibake),
  correct mismatch-password toast, correct supplier currency-field label.
- Remove PII-leaking debug console.log on register, stray console.logs.

Verified: tsc clean on all changed files, eslint clean, production build passes.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

* fix(auth): sanitize residual error logs in register flow

Follow-up to PR review (compliance swarm V16 / GDPR Art.5(1)(f)): the
remaining console.error calls in the register flow passed raw error
objects, which Supabase may populate with PII (email) in nested fields.
Log only sanitized message strings instead.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
Jakob Wennberg
2026-06-30 13:14:13 +02:00
committed by GitHub
co-authored by Claude Opus 4.8
parent a8072f6423
commit b800dcd403
109 changed files with 270 additions and 302 deletions
+2 -2
View File
@@ -690,7 +690,7 @@ export function AGIPanel(props: AGIPanelProps) {
<span>Arbetsgivardeklaration (AGI)</span>
<span className="flex items-center gap-2 text-xs font-normal text-muted-foreground">
<span className="flex items-center gap-1">
<CheckCircle2 className="h-3.5 w-3.5 text-emerald-600" />
<CheckCircle2 className="h-3.5 w-3.5 text-success" />
Ansluten
</span>
{!readOnly && (
@@ -1005,7 +1005,7 @@ function StatusRow({
return (
<div className="flex items-center gap-2">
{ok ? (
<CheckCircle2 className="h-4 w-4 text-emerald-600" />
<CheckCircle2 className="h-4 w-4 text-success" />
) : (
<Link2Off className="h-4 w-4 text-muted-foreground" />
)}
+2 -2
View File
@@ -101,7 +101,7 @@ export function PaymentFilePanel({
<CardContent className="space-y-4">
{paymentFileFormat && paymentFileGeneratedAt && (
<div className="flex items-start gap-2 text-sm text-muted-foreground">
<CheckCircle2 className="h-4 w-4 mt-0.5 text-emerald-600 dark:text-emerald-400" />
<CheckCircle2 className="h-4 w-4 mt-0.5 text-success" />
<div>
Senast genererad:{' '}
<span className="text-foreground">
@@ -158,7 +158,7 @@ export function PaymentFilePanel({
</div>
))}
<p className="pt-1 text-muted-foreground border-t mt-2">
Filen innehåller både lön till anställda och beloppen är förberedda — bankens BankID-signering är det enda steget kvar.
Beloppen är förifyllda — kvar är att signera med BankID i banken.
</p>
</div>
)}
+2 -2
View File
@@ -139,7 +139,7 @@ export function TaxPaymentPanel({
{paymentFileGeneratedAt && (
<div className="flex items-start gap-2 text-sm text-muted-foreground">
<CheckCircle2 className="h-4 w-4 mt-0.5 text-emerald-600 dark:text-emerald-400" />
<CheckCircle2 className="h-4 w-4 mt-0.5 text-success" />
<div>
Betalfil senast genererad{' '}
<span className="text-foreground">
@@ -150,7 +150,7 @@ export function TaxPaymentPanel({
)}
{taxPaidAt && (
<div className="flex items-start gap-2 text-sm text-emerald-700 dark:text-emerald-400">
<div className="flex items-start gap-2 text-sm text-success">
<CheckCircle2 className="h-4 w-4 mt-0.5" />
<div>
Markerad som betald{' '}