mirror of
https://github.com/shumaiOne/shumai.git
synced 2026-11-23 23:17:14 +00:00
feat(fields): stop click propagation on fields and reduce middle column width
This commit is contained in:
@@ -377,7 +377,7 @@ export function FileCard({
|
||||
<label className="text-xs text-muted-foreground tracking-wide">
|
||||
{field.config?.name}
|
||||
</label>
|
||||
<div className="min-h-[28px]">
|
||||
<div className="min-h-[28px]" onClick={(e) => e.stopPropagation()}>
|
||||
<FieldRenderer
|
||||
config={field.config}
|
||||
value={itemFieldValueMap[field.id!]?.value}
|
||||
|
||||
@@ -280,6 +280,7 @@ export function FileListItem({
|
||||
width: columnSizing?.[field.id!] || 150,
|
||||
minWidth: columnSizing?.[field.id!] || 150,
|
||||
}}
|
||||
onClick={(e) => e.stopPropagation()}
|
||||
>
|
||||
<FieldRenderer
|
||||
config={field.config}
|
||||
|
||||
@@ -602,7 +602,7 @@ export function ManageFieldsDialog({ projectId, open, onOpenChange }: ManageFiel
|
||||
</div>
|
||||
|
||||
{/* Middle Column: Field List */}
|
||||
<div className="w-100 border-r flex flex-col">
|
||||
<div className="w-64 border-r flex flex-col">
|
||||
<div className="p-4 border-b flex items-center justify-between bg-background h-[57px]">
|
||||
<span className="font-medium text-sm">
|
||||
{groups.find((g) => g.id === selectedGroup)?.label}
|
||||
@@ -645,7 +645,7 @@ export function ManageFieldsDialog({ projectId, open, onOpenChange }: ManageFiel
|
||||
</div>
|
||||
|
||||
{/* Right Column: Config */}
|
||||
<div className="w-100 bg-background flex flex-col">
|
||||
<div className="flex-1 bg-background flex flex-col">
|
||||
<div className="flex-1 overflow-y-auto p-6">{renderConfigEditor()}</div>
|
||||
{(isCreating || (selectedField && !selectedField.readOnly)) && (
|
||||
<div className="p-4 border-t flex justify-end gap-2 bg-muted/10">
|
||||
|
||||
Reference in New Issue
Block a user