Shared task board where people and AI coding agents work as teammates. Source-available, self-hostable.
Go
fix(settings): keep property edit actions visible [ZIC-375] MUL-8331 (#9648)
ZIce7b6743a46fe5
diff --git a/e2e/property-settings-overflow.spec.ts b/e2e/property-settings-overflow.spec.tsnew file mode 100644index 0000000000..94213a1278--- /dev/null+++ b/e2e/property-settings-overflow.spec.ts@@ -0,0 +1,67 @@+import { expect, test } from "@playwright/test";+import { TestApiClient } from "./fixtures";++// #9639: viewport-based columns clipped the action menu when the settings+// content was narrower than the table, even though the admin could create.+test("admins can reach property actions in narrow settings and save edits", async ({ page }) => {+ const owner = new TestApiClient();+ const admin = new TestApiClient();+ const suffix = `${Date.now().toString(36)}-${test.info().workerIndex}`;+ const email = `property-admin-${suffix}@multica.ai`;+ let workspaceCreated = false;+ try {+ await owner.login(`property-owner-${suffix}@multica.ai`, "Property owner");+ const workspace = await owner.ensureWorkspace("Property settings", `properties-${suffix}`);+ workspaceCreated = true;+ await admin.login(email, "Property admin");+ await owner.addMemberByEmail(email, "admin");+ admin.setWorkspaceId(workspace.id);+ admin.setWorkspaceSlug(workspace.slug);+ await admin.markUserOnboarded();+ const name = `Segment ${suffix}`;+ const property = await admin.createProperty(name);+ const token = admin.getToken();+ if (!token) throw new Error("Admin login did not return a token");+ await page.addInitScript((value) => {+ localStorage.setItem("multica_token", value);+ localStorage.setItem("multica:chat:isOpen", "false");+ }, token);+ await page.setViewportSize({ width: 1024, height: 768 });+ await page.goto(`/${workspace.slug}/settings?tab=properties`);+ const actions = page.getByRole("button", { name: `Actions for ${name}`, exact: true });+ for (const width of [1024, 1280, 1600]) {+ await page.setViewportSize({ width, height: 768 });+ await expect(actions).toBeVisible();+ // Visibility alone passes for a button clipped by overflow:hidden.+ // Check actual pointer targeting before focus/scroll can mask clipping.+ await expect.poll(() => actions.evaluate((element) => {+ const box = element.getBoundingClientRect();+ return element.contains(document.elementFromPoint(+ box.x + box.width / 2, box.y + box.height / 2,+ ));+ })).toBe(true);+ }+ await page.setViewportSize({ width: 1024, height: 768 });+ await actions.focus();+ await page.keyboard.press("Enter");+ await page.getByRole("menuitem", { name: "Edit", exact: true }).focus();+ await page.keyboard.press("Enter");+ const dialog = page.getByRole("dialog", { name: "Edit property" });+ await expect(dialog).toBeVisible();+ const renamed = `${name} updated`;+ await dialog.getByLabel("Name", { exact: true }).fill(renamed);+ await expect(dialog.getByLabel("Name", { exact: true })).toHaveValue(renamed);+ const saved = page.waitForResponse((response) =>+ response.url().endsWith(`/api/properties/${property.id}`)+ && response.request().method() === "PATCH",+ );+ await dialog.getByRole("button", { name: "Save property" }).click();+ expect((await saved).ok()).toBe(true);+ await expect(dialog).not.toBeVisible();+ await page.reload();+ await expect(page.getByRole("button", { name: `Actions for ${renamed}`, exact: true })).toBeVisible();+ } finally {+ await admin.cleanup();+ if (workspaceCreated) await owner.deleteWorkspace();+ }+});diff --git a/packages/views/issues/components/issue-inbox-restore-button.tsx b/packages/views/issues/components/issue-inbox-restore-button.tsxindex 4ce070767e..de72d88752 100644--- a/packages/views/issues/components/issue-inbox-restore-button.tsx+++ b/packages/views/issues/components/issue-inbox-restore-button.tsx@@ -1,7 +1,7 @@"use client";import { focusManager, useQuery } from "@tanstack/react-query";-import { ArchiveRestore } from "lucide-react";+import { ArchiveRestore } from "@multica/ui/icons";import { toast } from "sonner";import { useWorkspaceId } from "@multica/core/hooks";import { archivedInboxLookupOptions, useUnarchiveInbox } from "@multica/core/inbox";diff --git a/packages/views/settings/components/properties-tab.tsx b/packages/views/settings/components/properties-tab.tsxindex 84ae610281..b1d3c2bb4d 100644--- a/packages/views/settings/components/properties-tab.tsx+++ b/packages/views/settings/components/properties-tab.tsx@@ -185,8 +185,8 @@ export function PropertiesTab() {</p>)}- <div className="overflow-hidden rounded-lg border border-surface-border bg-card">- <div className="hidden grid-cols-[minmax(10rem,1fr)_6rem_minmax(10rem,1.4fr)_6rem_7rem_2rem] gap-4 border-b border-surface-border bg-muted/20 px-4 py-2.5 text-caption font-medium text-muted-foreground md:grid">+ <div className="@container/properties overflow-hidden rounded-lg border border-surface-border bg-card">+ <div className="hidden grid-cols-[minmax(10rem,1fr)_6rem_minmax(10rem,1.4fr)_6rem_7rem_2rem] gap-4 border-b border-surface-border bg-muted/20 px-4 py-2.5 text-caption font-medium text-muted-foreground @min-[50rem]/properties:grid"><span>{t(($) => $.properties.columns.name)}</span><span>{t(($) => $.properties.columns.type)}</span><span>{t(($) => $.properties.columns.options)}</span>@@ -218,7 +218,7 @@ export function PropertiesTab() {{visible.map((property) => (<divkey={property.id}- className="grid gap-2 px-4 py-3 md:grid-cols-[minmax(10rem,1fr)_6rem_minmax(10rem,1.4fr)_6rem_7rem_2rem] md:items-center md:gap-4"+ className="grid gap-2 px-4 py-3 @min-[50rem]/properties:grid-cols-[minmax(10rem,1fr)_6rem_minmax(10rem,1.4fr)_6rem_7rem_2rem] @min-[50rem]/properties:items-center @min-[50rem]/properties:gap-4"><div className="flex min-w-0 items-center gap-2"><PropertyIcon property={property} />@@ -229,7 +229,7 @@ export function PropertiesTab() {</Badge>)}</div>- <span className="text-caption text-muted-foreground md:text-body">+ <span className="text-caption text-muted-foreground @min-[50rem]/properties:text-body"><PropertyTypeLabel type={property.type} /></span><div className="flex min-w-0 flex-wrap items-center gap-1">@@ -254,7 +254,7 @@ export function PropertiesTab() {<span className="text-caption text-muted-foreground">—</span>)}</div>- <span className="text-caption tabular-nums text-muted-foreground md:text-body">+ <span className="text-caption tabular-nums text-muted-foreground @min-[50rem]/properties:text-body">{t(($) => $.properties.usage_count, { count: property.usage_count ?? 0 })}</span><span className="text-caption text-muted-foreground">