From 1d42671659af3ed85f9e301fbd82e01337049a73 Mon Sep 17 00:00:00 2001 From: oobabooga <112222186+oobabooga@users.noreply.github.com> Date: Wed, 24 Jun 2026 16:11:34 -0300 Subject: [PATCH] match Train page slider/number-input style; restore card background on image rail --- .../src/features/images/images-page.tsx | 75 +++++++++++++++---- 1 file changed, 61 insertions(+), 14 deletions(-) diff --git a/studio/frontend/src/features/images/images-page.tsx b/studio/frontend/src/features/images/images-page.tsx index bac3001deb..ac700b21ae 100644 --- a/studio/frontend/src/features/images/images-page.tsx +++ b/studio/frontend/src/features/images/images-page.tsx @@ -17,6 +17,7 @@ import { import { Slider } from "@/components/ui/slider"; import { Spinner } from "@/components/ui/spinner"; import { Textarea } from "@/components/ui/textarea"; +import { SectionCard } from "@/components/section-card"; import { ModelSelector } from "@/components/assistant-ui/model-selector"; import type { ModelOption, @@ -107,6 +108,49 @@ function progressView(p: DiffusionLoadProgress): { }; } +// Mirrors the Train page's SliderRow (studio/sections/params-section.tsx): +// label + standard Slider + number input, same classes. +function SliderField({ + label, + value, + min, + max, + step, + onChange, +}: { + label: string; + value: number; + min: number; + max: number; + step: number; + onChange: (v: number) => void; +}) { + return ( +
+ {label} +
+ onChange(v)} + min={min} + max={max} + step={step} + className="w-32" + /> + onChange(Number(e.target.value))} + min={min} + max={max} + step={step} + className="w-12 text-right font-mono text-xs font-medium bg-muted/50 border border-border rounded-lg px-1.5 py-0.5 focus:outline-none focus:ring-1 focus:ring-primary/30 [&::-webkit-inner-spin-button]:appearance-none" + /> +
+
+ ); +} + // Matches the field-label style used across Studio (export/chat settings). function Field({ label, children }: { label: string; children: ReactNode }) { return ( @@ -311,7 +355,13 @@ export function ImagesPage() { {/* ── Controls rail + preview canvas ─────────────────── */}
-
+ } + title="Generate" + description="Prompt and settings" + accent="indigo" + className="w-[340px] shrink-0 gap-4 overflow-y-auto" + >