Spaces:
Sleeping
Sleeping
Commit ·
3a0fde4
1
Parent(s): 23b8fad
chore(cleanup): frontend — drop stale narrative comments (current-standard)
Browse filesComment-only: removed a dated KI mistake-narrative on the tts_error_code
type and trimmed a few "old hack / used to" history parentheticals in
page.tsx / globals.css to clean current-behaviour wording. No TS/JSX/CSS
behaviour change. Completes the codebase-wide stale-content purge
(history of record stays in ADR/KI/README only).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
- frontend/src/app/globals.css +2 -2
- frontend/src/app/page.tsx +5 -7
- frontend/src/lib/api.ts +3 -6
frontend/src/app/globals.css
CHANGED
|
@@ -662,8 +662,8 @@ body {
|
|
| 662 |
/* #47 — larger continuous slider variant for the merged Profile &
|
| 663 |
* premium money fields. Bigger track + thumb so the touch target clears
|
| 664 |
* the 44px guideline on phones (the wrapper row + thumb hit-area). */
|
| 665 |
-
/* Padding gives the ≥44px touch target; the track is
|
| 666 |
-
*
|
| 667 |
.app-range-lg { padding: 13px 0; }
|
| 668 |
.app-range-lg::-webkit-slider-runnable-track { height: 8px; }
|
| 669 |
.app-range-lg::-moz-range-track { height: 8px; }
|
|
|
|
| 662 |
/* #47 — larger continuous slider variant for the merged Profile &
|
| 663 |
* premium money fields. Bigger track + thumb so the touch target clears
|
| 664 |
* the 44px guideline on phones (the wrapper row + thumb hit-area). */
|
| 665 |
+
/* Padding gives the ≥44px touch target; the track is a pseudo-element so
|
| 666 |
+
* the padding does not hide it. */
|
| 667 |
.app-range-lg { padding: 13px 0; }
|
| 668 |
.app-range-lg::-webkit-slider-runnable-track { height: 8px; }
|
| 669 |
.app-range-lg::-moz-range-track { height: 8px; }
|
frontend/src/app/page.tsx
CHANGED
|
@@ -4316,10 +4316,9 @@ function SafeLink({ href, children, className, fallbackClassName }: {
|
|
| 4316 |
|
| 4317 |
// Jargon — inline component that wraps a term and shows an info popover
|
| 4318 |
// on click with a plain-language explanation. Bilingual via uiLang.
|
| 4319 |
-
//
|
| 4320 |
-
//
|
| 4321 |
-
// No click, no × close
|
| 4322 |
-
// overflowing across cards). The tooltip is width-constrained, sits ABOVE
|
| 4323 |
// the badge centered, and is pointer-events-none so it never blocks or
|
| 4324 |
// thrashes. Scoped group/jg so only the badge — not the whole label —
|
| 4325 |
// triggers it.
|
|
@@ -5723,9 +5722,8 @@ function PolicyDetailModal({ policy, onClose }: { policy: MarketplacePolicy; onC
|
|
| 5723 |
</div>
|
| 5724 |
|
| 5725 |
{/* 2 — SCORE (always rendered in this position; tri-state so a
|
| 5726 |
-
slow/failed scorecard fetch shows loading/Retry, never a
|
| 5727 |
-
gap
|
| 5728 |
-
used to disappear). */}
|
| 5729 |
<div className="pt-5 border-t border-[var(--border)]">
|
| 5730 |
<PanelEyebrow>How this policy scores {isPersonalized ? "for you" : "(generic buyer)"}</PanelEyebrow>
|
| 5731 |
{sc === undefined && (
|
|
|
|
| 4316 |
|
| 4317 |
// Jargon — inline component that wraps a term and shows an info popover
|
| 4318 |
// on click with a plain-language explanation. Bilingual via uiLang.
|
| 4319 |
+
// The "?" explainer is HOVER-only (and keyboard-focus for a11y): it
|
| 4320 |
+
// appears while you hover/focus the badge and disappears when you stop.
|
| 4321 |
+
// No click, no × close. The tooltip is width-constrained, sits ABOVE
|
|
|
|
| 4322 |
// the badge centered, and is pointer-events-none so it never blocks or
|
| 4323 |
// thrashes. Scoped group/jg so only the badge — not the whole label —
|
| 4324 |
// triggers it.
|
|
|
|
| 5722 |
</div>
|
| 5723 |
|
| 5724 |
{/* 2 — SCORE (always rendered in this position; tri-state so a
|
| 5725 |
+
slow/failed scorecard fetch shows loading/Retry, never a
|
| 5726 |
+
silent gap). */}
|
|
|
|
| 5727 |
<div className="pt-5 border-t border-[var(--border)]">
|
| 5728 |
<PanelEyebrow>How this policy scores {isPersonalized ? "for you" : "(generic buyer)"}</PanelEyebrow>
|
| 5729 |
{sc === undefined && (
|
frontend/src/lib/api.ts
CHANGED
|
@@ -31,12 +31,9 @@ export type ChatResponse = {
|
|
| 31 |
// frontend uses this when constructing the playback Blob URL so Safari
|
| 32 |
// doesn't refuse to play an mp4 payload labelled as wav.
|
| 33 |
audio_mime?: string | null;
|
| 34 |
-
//
|
| 35 |
-
//
|
| 36 |
-
//
|
| 37 |
-
// in reply. wtf?"). The backend now classifies the failure (closed enum,
|
| 38 |
-
// same contract as the STT path) and ships a user-facing message the
|
| 39 |
-
// chat UI renders inline under the bubble. Absent on the success path.
|
| 40 |
tts_error_code?:
|
| 41 |
| "rate_limit"
|
| 42 |
| "service_unavailable"
|
|
|
|
| 31 |
// frontend uses this when constructing the playback Blob URL so Safari
|
| 32 |
// doesn't refuse to play an mp4 payload labelled as wav.
|
| 33 |
audio_mime?: string | null;
|
| 34 |
+
// Closed-enum TTS failure code. When voice output fails the backend
|
| 35 |
+
// classifies it (same contract as the STT path) and ships a user-facing
|
| 36 |
+
// message the chat UI renders inline under the bubble. Absent on success.
|
|
|
|
|
|
|
|
|
|
| 37 |
tts_error_code?:
|
| 38 |
| "rate_limit"
|
| 39 |
| "service_unavailable"
|