mirror of
https://github.com/HKUDS/nanobot.git
synced 2026-08-07 21:08:34 +03:00
style(webui): inset expanded preset editor
This commit is contained in:
@@ -3437,7 +3437,7 @@ function ModelsSettings({
|
|||||||
key={key}
|
key={key}
|
||||||
id="model-preset-editor"
|
id="model-preset-editor"
|
||||||
data-testid="model-preset-editor"
|
data-testid="model-preset-editor"
|
||||||
className="divide-y divide-border/45 bg-background/70 motion-reduce:animate-none animate-in fade-in-0 slide-in-from-top-1 duration-200"
|
className="mx-3 mb-3 divide-y divide-border/45 overflow-hidden rounded-[18px] border border-border/45 bg-background/80 shadow-sm motion-reduce:animate-none animate-in fade-in-0 slide-in-from-top-1 duration-200 sm:mx-5 lg:mx-auto lg:w-[calc(100%-2.5rem)] lg:max-w-6xl"
|
||||||
>
|
>
|
||||||
{creating ? (
|
{creating ? (
|
||||||
<div className="flex min-h-[52px] items-center px-4 py-3 sm:px-5">
|
<div className="flex min-h-[52px] items-center px-4 py-3 sm:px-5">
|
||||||
|
|||||||
@@ -2167,7 +2167,11 @@ describe("SettingsView Apps catalog", () => {
|
|||||||
expect(trigger).toHaveAttribute("aria-expanded", "true");
|
expect(trigger).toHaveAttribute("aria-expanded", "true");
|
||||||
expect(trigger).toHaveAttribute("aria-controls", "model-preset-editor");
|
expect(trigger).toHaveAttribute("aria-controls", "model-preset-editor");
|
||||||
expect(row.nextElementSibling).toBe(editor);
|
expect(row.nextElementSibling).toBe(editor);
|
||||||
expect(editor).toHaveClass("slide-in-from-top-1", "bg-background/70");
|
expect(editor).toHaveClass(
|
||||||
|
"slide-in-from-top-1",
|
||||||
|
"lg:max-w-6xl",
|
||||||
|
"rounded-[18px]",
|
||||||
|
);
|
||||||
expect(within(editor).getByDisplayValue("Primary")).toBeInTheDocument();
|
expect(within(editor).getByDisplayValue("Primary")).toBeInTheDocument();
|
||||||
const deleteButton = within(editor).getByRole("button", { name: "Delete" });
|
const deleteButton = within(editor).getByRole("button", { name: "Delete" });
|
||||||
expect(deleteButton).toBeDisabled();
|
expect(deleteButton).toBeDisabled();
|
||||||
|
|||||||
Reference in New Issue
Block a user