0
Fork 0
mirror of https://github.com/penpot/penpot.git synced 2025-03-24 05:31:25 -05:00

🐛 Fix click on the project name goes to blank dashboard from workspace (#5668)

This commit is contained in:
Alejandro 2025-01-27 12:16:52 +01:00 committed by GitHub
parent 74bdd72d2f
commit ea6c679b21
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 20 additions and 1 deletions

View file

@ -320,3 +320,20 @@ test("[Taiga #9929] Paste text in workspace", async ({ page, context }) => {
.getByRole("textbox")
.getByText("Lorem ipsum dolor");
});
test("Bug 9877, user navigation to dashboard from header goes to blank page", async ({
page,
}) => {
const workspacePage = new WorkspacePage(page);
await workspacePage.setupEmptyFile(page);
await workspacePage.goToWorkspace();
const popupPromise = page.waitForEvent("popup");
await page.getByText("Drafts").click();
const popup = await popupPromise;
await expect(popup).toHaveURL(
/&project-id=c7ce0794-0992-8105-8004-38e630f7920b/,
);
});

View file

@ -32,6 +32,7 @@
(let [profile (mf/deref refs/profile)
file-id (:id file)
file-name (:name file)
project-id (:id project)
team-id (:team-id project)
shared? (:is-shared file)
@ -78,7 +79,8 @@
nav-to-project
(mf/use-fn
#(st/emit! (dcm/go-to-dashboard-files ::rt/new-window true)))]
(mf/deps project-id)
#(st/emit! (dcm/go-to-dashboard-files ::rt/new-window true :project-id project-id)))]
(mf/with-effect [editing?]
(when ^boolean editing?