From f920cfc738323e3648bddbb1ca804239ac427b76 Mon Sep 17 00:00:00 2001 From: Chaim Date: Wed, 27 May 2026 09:40:08 +0000 Subject: [PATCH] =?UTF-8?q?ui(precedents):=20edit=20sheet=20=E2=80=94=20ma?= =?UTF-8?q?ke=20citation=5Fformatted=20editable?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The "ערוך פרטים" sheet labeled the case_number field "מראה מקום" and marked it read-only — confusing because the formal citation IS supposed to be editable. Rename the read-only field to "מספר תיק (מזהה ייחודי)" to clarify it's the system key, and add a separate Textarea for the true formal citation (citation_formatted) with the same markdown-bold convention used by the inline editor on the detail page. Co-Authored-By: Claude Opus 4.7 (1M context) --- .../precedents/precedent-edit-sheet.tsx | 30 +++++++++++++++++-- 1 file changed, 27 insertions(+), 3 deletions(-) diff --git a/web-ui/src/components/precedents/precedent-edit-sheet.tsx b/web-ui/src/components/precedents/precedent-edit-sheet.tsx index 448a9e4..42f961d 100644 --- a/web-ui/src/components/precedents/precedent-edit-sheet.tsx +++ b/web-ui/src/components/precedents/precedent-edit-sheet.tsx @@ -36,6 +36,7 @@ type Props = { * happened in the background. */ type FormState = { citation: string; + citation_formatted: string; case_name: string; court: string; district: string; @@ -53,7 +54,8 @@ type FormState = { }; const EMPTY: FormState = { - citation: "", case_name: "", court: "", district: "", chair_name: "", + citation: "", citation_formatted: "", + case_name: "", court: "", district: "", chair_name: "", decision_date: "", practice_area: "", appeal_subtype: "", source_type: "", precedent_level: "", is_binding: true, subject_tags: "", summary: "", headnote: "", key_quote: "", @@ -75,6 +77,7 @@ export function PrecedentEditSheet({ caseLawId, onOpenChange }: Props) { setSyncedRecordId(record.id as string); setForm({ citation: record.case_number || "", + citation_formatted: record.citation_formatted || "", case_name: record.case_name || "", court: record.court || "", district: record.district || "", @@ -97,6 +100,7 @@ export function PrecedentEditSheet({ caseLawId, onOpenChange }: Props) { if (!caseLawId) return; try { const patch: Record = { + citation_formatted: form.citation_formatted.trim(), case_name: form.case_name.trim(), court: form.court.trim(), district: form.district.trim(), @@ -144,7 +148,7 @@ export function PrecedentEditSheet({ caseLawId, onOpenChange }: Props) { עריכת פרטי פסיקה - כל השדות ניתנים לעריכה חוץ ממראה המקום (מזהה ייחודי). + כל השדות ניתנים לעריכה חוץ ממספר התיק (מזהה ייחודי במערכת). כפתור "חלץ מטא-דאטה" שולח בקשה לתור מקומי שאני מרוקן מ-Claude Code (ה-LLM רץ מקומית עם claude session, לא ב-API). @@ -160,7 +164,7 @@ export function PrecedentEditSheet({ caseLawId, onOpenChange }: Props) {
-
מראה מקום (לא ניתן לעריכה)
+
מספר תיק (מזהה ייחודי — לא ניתן לעריכה)
{record.case_number}
@@ -177,6 +181,26 @@ export function PrecedentEditSheet({ caseLawId, onOpenChange }: Props) {
+
+ +