diff --git a/client/public/dashboardHeader1080x280.png b/client/public/dashboardHeader1080x280.png new file mode 100644 index 0000000000..bf9000bc69 Binary files /dev/null and b/client/public/dashboardHeader1080x280.png differ diff --git a/client/public/dashboardHeader1920x280.png b/client/public/dashboardHeader1920x280.png new file mode 100644 index 0000000000..85b6fd919f Binary files /dev/null and b/client/public/dashboardHeader1920x280.png differ diff --git a/client/public/dashboardHeader2560x280.png b/client/public/dashboardHeader2560x280.png new file mode 100644 index 0000000000..dce88845ba Binary files /dev/null and b/client/public/dashboardHeader2560x280.png differ diff --git a/client/public/dashboardHeader3840x280.png b/client/public/dashboardHeader3840x280.png new file mode 100644 index 0000000000..04e2010657 Binary files /dev/null and b/client/public/dashboardHeader3840x280.png differ diff --git a/client/public/dashboardHeader640x200.png b/client/public/dashboardHeader640x200.png new file mode 100644 index 0000000000..597bae0b9f Binary files /dev/null and b/client/public/dashboardHeader640x200.png differ diff --git a/client/public/dashboardHeader750x200.png b/client/public/dashboardHeader750x200.png new file mode 100644 index 0000000000..ae5975abc2 Binary files /dev/null and b/client/public/dashboardHeader750x200.png differ diff --git a/client/src/features/dashboardV2/DashboardV2.module.scss b/client/src/features/dashboardV2/DashboardV2.module.scss new file mode 100644 index 0000000000..b5d373eaae --- /dev/null +++ b/client/src/features/dashboardV2/DashboardV2.module.scss @@ -0,0 +1,44 @@ +@import "~bootstrap/scss/functions"; +@import "~bootstrap/scss/variables"; +@import "~bootstrap/scss/variables-dark"; +@import "~bootstrap/scss/maps"; +@import "~bootstrap/scss/mixins"; + +.DashboardHeader { + height: auto; + + img { + height: 150px; + + @include media-breakpoint-up(md) { + height: 180px; + } + + @include media-breakpoint-up(lg) { + height: 130px; + } + } +} + +.AnonymousAvatar { + width: 64px; + height: 64px; +} + +.DashboardCard { + background-color: rgba(var(--bs-primary-rgb), 0.1) !important; + + &:hover { + background-color: var(--bs-primary-bg-subtle) !important; + } +} + +.FooterCard { + a svg { + transition: all 0.3s linear; + } + a:hover svg, + a:focus svg { + transform: scale(1.3); + } +} diff --git a/client/src/features/dashboardV2/DashboardV2.tsx b/client/src/features/dashboardV2/DashboardV2.tsx index 0738cc83e3..6e3f0dfc06 100644 --- a/client/src/features/dashboardV2/DashboardV2.tsx +++ b/client/src/features/dashboardV2/DashboardV2.tsx @@ -15,109 +15,212 @@ * See the License for the specific language governing permissions and * limitations under the License */ +import { SerializedError } from "@reduxjs/toolkit"; +import { FetchBaseQueryError } from "@reduxjs/toolkit/query"; import cx from "classnames"; -import { Folder, People, PlayCircle, PlusLg } from "react-bootstrap-icons"; -import { Link } from "react-router-dom-v5-compat"; -import { Card, CardBody, CardHeader, Col, ListGroup, Row } from "reactstrap"; - +import { ReactNode } from "react"; +import { + Calendar3Week, + Eye, + FileEarmarkText, + Folder, + Megaphone, + People, + PersonFillExclamation, + PlayCircle, + PlusLg, + PlusSquare, + Send, +} from "react-bootstrap-icons"; +import { generatePath, Link } from "react-router-dom-v5-compat"; +import { + Badge, + Card, + CardBody, + CardHeader, + Col, + ListGroup, + Row, +} from "reactstrap"; +import { useLoginUrl } from "../../authentication/useLoginUrl.hook.ts"; import { RtkOrNotebooksError } from "../../components/errors/RtkErrorAlert"; -import { ExternalLink } from "../../components/ExternalLinks"; import { Loader } from "../../components/Loader"; +import { ABSOLUTE_ROUTES } from "../../routing/routes.constants.ts"; +import useLegacySelector from "../../utils/customHooks/useLegacySelector.hook.ts"; import { - useGetGroupsQuery, + GetGroupsApiResponse, + GetProjectsApiResponse, useGetProjectsQuery, + useGetGroupsQuery, } from "../projectsV2/api/projectV2.enhanced-api"; import GroupShortHandDisplay from "../projectsV2/show/GroupShortHandDisplay"; import ProjectShortHandDisplay from "../projectsV2/show/ProjectShortHandDisplay"; +import SearchV2Bar from "../searchV2/components/SearchV2Bar.tsx"; +import { useGetSessionsQuery as useGetSessionsQueryV2 } from "../sessionsV2/sessionsV2.api.ts"; +import { useGetUserQuery } from "../usersV2/api/users.api.ts"; +import UserAvatar, { UserAvatarSize } from "../usersV2/show/UserAvatar.tsx"; +import DashboardStyles from "./DashboardV2.module.scss"; import DashboardV2Sessions from "./DashboardV2Sessions"; - export default function DashboardV2() { + const userLogged = useLegacySelector( + (state) => state.stateModel.user.logged + ); + + if (!userLogged) return ; + return ( -
- - - - - - - - - - +
+ +
+
+ + + + + + + + + + + +
+
); } -function DashboardWelcome() { +function HeaderDashboard() { return ( -
- - -

- Welcome to the Renku 2.0 beta preview!! -

- -
- - -

- Learn more about Renku 2.0 on our{" "} - {" "} - and see what’s ahead on our{" "} - - . Feedback?{" "} - We’d love to hear it! -

- -
+
+ + + + + + + Dashboard Header +
); } -function ProjectsDashboard() { +function FooterDashboard() { return ( - - -

- - Projects -

- + + + + Renku updates + + + + + + Documentation + + + + + + Community events + + + + + + Contact us + + + + ); +} + +interface FooterDashboardCardProps { + children: ReactNode; + url: string; +} +function FooterDashboardCard({ children, url }: FooterDashboardCardProps) { + return ( + + + - - -
- - - + {children} +
); } +function DashboardSearch() { + return ( + + + + +

Explore Renkulab

+

Explore projects on RenkuLab.

+
+ + + +
+ +
+ ); +} -function ProjectList() { +function ProjectsDashboard() { const { data, error, isLoading } = useGetProjectsQuery({ params: { page: 1, @@ -125,7 +228,47 @@ function ProjectList() { direct_member: true, }, }); + const hasProjects = data && data?.projects?.length > 0; + return ( + + +
+

+ + My projects +

+ {data?.total ?? 0} +
+ {hasProjects && ( + + + + )} +
+ + + +
+ ); +} + +interface ProjectListProps { + data: GetProjectsApiResponse | undefined; + error: FetchBaseQueryError | SerializedError | undefined; + isLoading: boolean; +} +function ProjectList({ data, error, isLoading }: ProjectListProps) { + const hasProjects = data && data?.projects?.length > 0; const noProjects = isLoading ? (
@@ -136,22 +279,28 @@ function ProjectList() {

Cannot show projects.

- ) : !data || data?.projects?.length === 0 ? ( -
No 2.0 projects.
+ ) : !hasProjects ? ( +
+ Collaborate on projects with anyone, with data, code, and compute together + in one place. +
) : null; - const viewLink = ( + const projectFooter = hasProjects ? ( + ) : ( + ); if (noProjects) return (
{noProjects} - {viewLink} + {projectFooter}
); @@ -159,56 +308,204 @@ function ProjectList() {
{data?.projects?.map((project) => ( - + ))} - {viewLink} + {projectFooter}
); } function GroupsDashboard() { + const { data, error, isLoading } = useGetGroupsQuery({ + params: { + page: 1, + per_page: 5, + direct_member: true, + }, + }); + const hasGroups = data && data?.groups?.length > 0; return ( -

- - Groups -

- - - +
+

+ + My groups +

+ {data?.total ?? 0} +
+ {hasGroups && ( + + + + )}
- +
); } -function GroupsList() { - const { data, error, isLoading } = useGetGroupsQuery({ - params: { - page: 1, - per_page: 5, - direct_member: true, - }, +function UserDashboard() { + const { data: userInfo, isLoading } = useGetUserQuery(); + + if (!userInfo?.isLoggedIn || isLoading) { + return null; + } + + const userPageUrl = generatePath(ABSOLUTE_ROUTES.v2.users.show, { + username: userInfo?.username ?? "", }); + return ( + + + +

+ {userInfo.first_name} {userInfo.last_name} +

+

+ + @{userInfo.username ?? "unknown"} + +

+
+
+ ); +} + +function AnonymousDashboard() { + return ( +
+ +
+
+ + + + + + + + + +
+
+
+ ); +} +function LoginCard() { + const userLogged = useLegacySelector( + (state) => state.stateModel.user.logged + ); + const loginUrl = useLoginUrl(); + if (userLogged) { + return null; + } + return ( + + +
+
+ +
+

You are not logged in.

+
+
+ + Log in + +

+ To create projects, groups and launch sessions. +

+
+
+
+ ); +} + +interface GroupListProps { + data: GetGroupsApiResponse | undefined; + error: FetchBaseQueryError | SerializedError | undefined; + isLoading: boolean; +} +function GroupsList({ data, error, isLoading }: GroupListProps) { + const hasGroups = data && data?.groups?.length > 0; const noGroups = isLoading ? (
@@ -219,19 +516,26 @@ function GroupsList() {

Cannot show groups.

- ) : !data || data == null || data?.groups?.length === 0 ? ( -
No 2.0 groups.
+ ) : !hasGroups ? ( +
Share and organize projects & data with your team.
) : null; - const viewLink = ( - + const groupFooter = hasGroups ? ( + + ) : ( +
+ + + Create my first group + +
); if (noGroups) return (
{noGroups} - {viewLink} + {groupFooter}
); @@ -246,23 +550,32 @@ function GroupsList() { /> ))} - {viewLink} + {groupFooter}
); } function SessionsDashboard() { + const { data: sessions, error, isLoading } = useGetSessionsQueryV2(); + const totalSessions = sessions ? sessions?.length : 0; return ( - -

- - Sessions -

+ +
+

+ + My sessions +

+ {totalSessions} +
- +
); @@ -271,9 +584,11 @@ function SessionsDashboard() { function ViewAllLink({ type, noItems, + total, }: { type: "project" | "group"; noItems: boolean; + total: number; }) { return noItems ? ( - View all my {type === "project" ? "projects" : "groups"} + View all my {total > 5 ? total : ""}{" "} + {type === "project" ? "projects" : "groups"} ); } + +function EmptyProjectsButtons() { + return ( +
+ + + Create my first project + + + + View existing projects + +
+ ); +} diff --git a/client/src/features/dashboardV2/DashboardV2Sessions.tsx b/client/src/features/dashboardV2/DashboardV2Sessions.tsx index bf87a58cbf..53d1dc48f7 100644 --- a/client/src/features/dashboardV2/DashboardV2Sessions.tsx +++ b/client/src/features/dashboardV2/DashboardV2Sessions.tsx @@ -25,7 +25,7 @@ import { Col, ListGroup, Row } from "reactstrap"; import { Loader } from "../../components/Loader"; import EnvironmentLogsV2 from "../../components/LogsV2"; import { RtkErrorAlert } from "../../components/errors/RtkErrorAlert"; -import { useGetSessionsQuery as useGetSessionsQueryV2 } from "../../features/sessionsV2/sessionsV2.api"; +import { useGetProjectSessionLauncherQuery } from "../../features/sessionsV2/sessionsV2.api"; import { ABSOLUTE_ROUTES } from "../../routing/routes.constants"; import useAppSelector from "../../utils/customHooks/useAppSelector.hook"; import { useGetProjectsByProjectIdQuery } from "../projectsV2/api/projectV2.enhanced-api"; @@ -41,9 +41,16 @@ import styles from "./DashboardV2Sessions.module.scss"; // Required for logs formatting import "../../notebooks/Notebooks.css"; -export default function DashboardV2Sessions() { - const { data: sessions, error, isLoading } = useGetSessionsQueryV2(); - +interface DashboardV2SessionsProps { + sessions?: SessionList; + error: FetchBaseQueryError | SerializedError | undefined; + isLoading: boolean; +} +export default function DashboardV2Sessions({ + sessions, + error, + isLoading, +}: DashboardV2SessionsProps) { if (isLoading) { return ; } @@ -75,14 +82,18 @@ function ErrorState({ }) { return (
-

Cannot show sessions.

+

Cannot show sessions.

); } function NoSessionsState() { - return
No running sessions.
; + return ( +

+ No running sessions. Create or explore projects to launch a session. +

+ ); } function SessionDashboardList({ @@ -106,10 +117,13 @@ function DashboardSession({ session }: DashboardSessionProps) { const displayModal = useAppSelector( ({ display }) => display.modals.sessionLogs ); - const { image, project_id: projectId, launcher_id: launcherId } = session; + const { project_id: projectId, launcher_id: launcherId } = session; const { data: project } = useGetProjectsByProjectIdQuery( projectId ? { projectId } : skipToken ); + const { data: launcher } = useGetProjectSessionLauncherQuery( + launcherId ? { id: launcherId } : skipToken + ); const projectUrl = project ? generatePath(ABSOLUTE_ROUTES.v2.projects.show.root, { @@ -148,16 +162,33 @@ function DashboardSession({ session }: DashboardSessionProps) { > -
-
- {project - ? project.namespace + "/" + project.slug - : projectId ?? "Unknown"} -
-

- Container image: {image} -

-
+ + +
+ {project && launcher ? ( + <> + {project.name} /{" "} + {launcher?.environment?.name} + + ) : ( + projectId ?? "Unknown" + )} +
+ + + + +
{/* NOTE: This is a placeholder for the session actions button */} @@ -165,15 +196,8 @@ function DashboardSession({ session }: DashboardSessionProps) {
- - - - - - - - - + + diff --git a/client/src/features/groupsV2/show/GroupV2Show.tsx b/client/src/features/groupsV2/show/GroupV2Show.tsx index 2ab236c4fe..5205e7d80b 100644 --- a/client/src/features/groupsV2/show/GroupV2Show.tsx +++ b/client/src/features/groupsV2/show/GroupV2Show.tsx @@ -43,7 +43,7 @@ import { import ProjectV2ListDisplay from "../../projectsV2/list/ProjectV2ListDisplay"; import GroupNotFound from "../../projectsV2/notFound/GroupNotFound"; import { EntityPill } from "../../searchV2/components/SearchV2Results"; -import UserAvatar from "../../usersV2/show/UserAvatar"; +import UserAvatar, { UserAvatarSize } from "../../usersV2/show/UserAvatar"; import GroupV2MemberListDisplay from "../members/GroupV2MemberListDisplay"; import useGroupPermissions from "../utils/useGroupPermissions.hook"; @@ -99,7 +99,10 @@ export default function GroupV2Show() {
- +

{group.name ?? "Unknown group"}

diff --git a/client/src/features/projectsV2/api/projectV2.enhanced-api.ts b/client/src/features/projectsV2/api/projectV2.enhanced-api.ts index a3a1af5303..95f650d9c0 100644 --- a/client/src/features/projectsV2/api/projectV2.enhanced-api.ts +++ b/client/src/features/projectsV2/api/projectV2.enhanced-api.ts @@ -20,7 +20,7 @@ import type { NamespaceResponseList, } from "./namespace.api"; -interface GetGroupsApiResponse extends AbstractKgPaginatedResponse { +export interface GetGroupsApiResponse extends AbstractKgPaginatedResponse { groups: GetGroupsApiResponseOrig; } @@ -37,7 +37,7 @@ export interface GetNamespacesApiResponse extends AbstractKgPaginatedResponse { namespaces: GetNamespacesApiResponseOrig; } -interface GetProjectsApiResponse extends AbstractKgPaginatedResponse { +export interface GetProjectsApiResponse extends AbstractKgPaginatedResponse { projects: GetProjectsApiResponseOrig; } diff --git a/client/src/features/projectsV2/show/GroupShortHandDisplay.tsx b/client/src/features/projectsV2/show/GroupShortHandDisplay.tsx index 8daf8411c9..7b130eaf7d 100644 --- a/client/src/features/projectsV2/show/GroupShortHandDisplay.tsx +++ b/client/src/features/projectsV2/show/GroupShortHandDisplay.tsx @@ -20,6 +20,7 @@ import cx from "classnames"; import { Link, generatePath } from "react-router-dom-v5-compat"; import { TimeCaption } from "../../../components/TimeCaption"; import { ABSOLUTE_ROUTES } from "../../../routing/routes.constants"; +import UserAvatar, { UserAvatarSize } from "../../usersV2/show/UserAvatar.tsx"; import { GroupResponse } from "../api/namespace.api"; interface GroupShortHandDisplayProps { @@ -39,14 +40,24 @@ export default function GroupShortHandDisplay({ )} data-cy="group-item" > -
-

{group.name}

- +
+ +
+

{group.name}

+ +
); diff --git a/client/src/features/projectsV2/show/ProjectShortHandDisplay.tsx b/client/src/features/projectsV2/show/ProjectShortHandDisplay.tsx index 776b1af868..fcf4ebe638 100644 --- a/client/src/features/projectsV2/show/ProjectShortHandDisplay.tsx +++ b/client/src/features/projectsV2/show/ProjectShortHandDisplay.tsx @@ -17,44 +17,61 @@ */ import cx from "classnames"; -import { Link, generatePath } from "react-router-dom-v5-compat"; +import { generatePath, Link } from "react-router-dom-v5-compat"; import VisibilityIcon from "../../../components/entities/VisibilityIcon"; import { TimeCaption } from "../../../components/TimeCaption"; import { ABSOLUTE_ROUTES } from "../../../routing/routes.constants"; +import UserAvatar, { UserAvatarSize } from "../../usersV2/show/UserAvatar.tsx"; import { Project } from "../api/projectV2.api"; interface ProjectShortHandDisplayProps { className?: string | string[]; - element: "card-body" | "list-item" | "plain"; project: Project; } export default function ProjectShortHandDisplay({ className, - element, project, }: ProjectShortHandDisplayProps) { const content = (
-
+

{project.name}

-
-
-

- @{project.namespace}/{project.slug} +

+ +

+ {project.namespace}

+
+ + {project.description && ( +
+

+ {project.description} +

+
+ )} + +
+ {project.updated_at ? ( ); - const elementClasses = - element === "card-body" - ? cx("card-body", "d-flex") - : element === "list-item" - ? cx("list-group-item", "list-group-item-action") - : ""; - return ( + } diff --git a/client/src/features/searchV2/components/SearchV2Bar.tsx b/client/src/features/searchV2/components/SearchV2Bar.tsx index 30e6cde5de..a35ad60914 100644 --- a/client/src/features/searchV2/components/SearchV2Bar.tsx +++ b/client/src/features/searchV2/components/SearchV2Bar.tsx @@ -17,8 +17,9 @@ */ import { useCallback, useEffect, useMemo } from "react"; import { useForm } from "react-hook-form"; +import { useLocation, useNavigate } from "react-router-dom-v5-compat"; import { Button, Form, InputGroup } from "reactstrap"; - +import { ABSOLUTE_ROUTES } from "../../../routing/routes.constants.ts"; import useAppDispatch from "../../../utils/customHooks/useAppDispatch.hook"; import useAppSelector from "../../../utils/customHooks/useAppSelector.hook"; import { setSearchBarQuery } from "../searchV2.slice"; @@ -26,6 +27,9 @@ import { setSearchBarQuery } from "../searchV2.slice"; export default function SearchV2Bar() { const dispatch = useAppDispatch(); const { searchBarQuery } = useAppSelector(({ searchV2 }) => searchV2); + const navigate = useNavigate(); + const location = useLocation(); + const isSearchPage = location.pathname === ABSOLUTE_ROUTES.v2.search; const { register, handleSubmit, setFocus, setValue } = useForm( { @@ -39,9 +43,19 @@ export default function SearchV2Bar() { const onSubmitInner = useCallback( (data: SearchBarForm) => { - dispatch(setSearchBarQuery(data.searchBarQuery)); + if (isSearchPage) { + dispatch(setSearchBarQuery(data.searchBarQuery)); + } else { + const search = new URLSearchParams({ + q: `type:project ${data.searchBarQuery}`, + }); + navigate({ + pathname: ABSOLUTE_ROUTES.v2.search, + search: search.toString(), + }); + } }, - [dispatch] + [dispatch, isSearchPage, navigate] ); const onSubmit = useMemo( () => handleSubmit(onSubmitInner), @@ -63,7 +77,9 @@ export default function SearchV2Bar() { id="search-input" placeholder="Search..." type="text" - {...register("searchBarQuery", { onBlur: onSubmit })} + {...register("searchBarQuery", { + onBlur: isSearchPage ? onSubmit : undefined, + })} />
diff --git a/tests/cypress/e2e/dashboardV2.spec.ts b/tests/cypress/e2e/dashboardV2.spec.ts index 79d60b7a1c..314a8ac93e 100644 --- a/tests/cypress/e2e/dashboardV2.spec.ts +++ b/tests/cypress/e2e/dashboardV2.spec.ts @@ -32,17 +32,19 @@ describe("View v2 landing page", () => { }); it("view dashboard", () => { - cy.contains("Sessions").should("be.visible"); - cy.contains("Projects").should("be.visible"); - cy.contains("Groups").should("be.visible"); + cy.contains("My sessions").should("be.visible"); + cy.contains("My projects").should("be.visible"); + cy.contains("My groups").should("be.visible"); }); it("view sessions", () => { - cy.contains("Sessions").should("be.visible"); + cy.contains("My sessions").should("be.visible"); cy.getDataCy("dashboard-session-list") .find("[data-cy=dashboard-session-list-item]") - .contains("user1-uuid/test-2-v2-project") + .contains("THEPROJECTULID26CHARACTERS") .should("be.visible"); + + cy.wait("@readProjectV2ById"); cy.getDataCy("dashboard-session-list") .find("[data-cy=dashboard-session-list-item]") .first() @@ -57,7 +59,7 @@ describe("View v2 landing page", () => { }); it("view projects", () => { - cy.contains("Projects").should("be.visible"); + cy.contains("My projects").should("be.visible"); cy.getDataCy("dashboard-project-list").children().should("have.length", 5); cy.getDataCy("dashboard-project-list").children().first().click(); cy.location("pathname").should( @@ -67,7 +69,7 @@ describe("View v2 landing page", () => { }); it("view groups", () => { - cy.contains("Groups").should("be.visible"); + cy.contains("My groups").should("be.visible"); cy.getDataCy("dashboard-group-list").children().should("have.length", 5); cy.getDataCy("group-item").first().click(); cy.location("pathname").should("contain", "/v2/groups/test-0-group-v2"); @@ -75,7 +77,7 @@ describe("View v2 landing page", () => { it("list groups", () => { cy.contains("View other groups").should("not.exist"); - cy.contains("View all my groups").should("be.visible").click(); + cy.contains("View all my 50 groups").should("be.visible").click(); cy.contains("Renku 2.0 Search").should("be.visible"); cy.getDataCy("search-filter-role-owner").should("be.checked"); cy.getDataCy("search-filter-role-editor").should("be.checked"); @@ -85,7 +87,7 @@ describe("View v2 landing page", () => { it("list projects", () => { cy.contains("View other projects").should("not.exist"); - cy.contains("View all my projects").should("be.visible").click(); + cy.contains("View all my 50 projects").should("be.visible").click(); cy.contains("Renku 2.0 Search").should("be.visible"); cy.getDataCy("search-filter-role-owner").should("be.checked"); cy.getDataCy("search-filter-role-editor").should("be.checked"); @@ -102,24 +104,20 @@ describe("View v2 landing page empty", () => { }); it("view dashboard", () => { - cy.contains("Sessions").should("be.visible"); - cy.contains("Projects").should("be.visible"); - cy.contains("Groups").should("be.visible"); + cy.contains("My sessions").should("be.visible"); + cy.contains("My projects").should("be.visible"); + cy.contains("My groups").should("be.visible"); }); it("list groups", () => { cy.contains("View all my groups").should("not.exist"); - cy.contains("View other groups").should("be.visible").click(); - cy.contains("Renku 2.0 Search").should("be.visible"); - cy.getDataCy("search-filter-role-owner").should("not.be.checked"); - cy.getDataCy("search-filter-role-editor").should("be.not.checked"); - cy.getDataCy("search-filter-role-viewer").should("be.not.checked"); - cy.getDataCy("search-filter-type-group").should("be.checked"); + cy.contains("Create my first group").should("be.visible"); }); it("list projects", () => { cy.contains("View all my projects").should("not.exist"); - cy.contains("View other projects").should("be.visible").click(); + cy.contains("Create my first project").should("be.visible"); + cy.contains("View existing projects").should("be.visible").click(); cy.contains("Renku 2.0 Search").should("be.visible"); cy.getDataCy("search-filter-role-owner").should("be.not.checked"); cy.getDataCy("search-filter-role-editor").should("be.not.checked"); diff --git a/tests/cypress/e2e/groupV2.spec.ts b/tests/cypress/e2e/groupV2.spec.ts index b7bd8cf9e5..d98ae4c3da 100644 --- a/tests/cypress/e2e/groupV2.spec.ts +++ b/tests/cypress/e2e/groupV2.spec.ts @@ -66,7 +66,7 @@ describe("List v2 groups", () => { }); it("list groups", () => { - cy.contains("Groups").should("be.visible"); + cy.contains("My groups").should("be.visible"); cy.contains("test 1 group-v2").should("exist"); cy.getDataCy("dashboard-group-list") .find("a") @@ -76,7 +76,7 @@ describe("List v2 groups", () => { it("shows groups", () => { fixtures.readGroupV2().readGroupV2Namespace(); - cy.contains("Groups").should("be.visible"); + cy.contains("My groups").should("be.visible"); cy.contains("test 2 group-v2").should("be.visible").click(); cy.wait("@readGroupV2"); cy.contains("test 2 group-v2").should("be.visible"); @@ -104,7 +104,7 @@ describe("Edit v2 group", () => { .listGroupV2Members() .listProjectV2ByNamespace() .listDataConnectors({ namespace: "test-2-group-v2" }); - cy.contains("Groups").should("be.visible"); + cy.contains("My groups").should("be.visible"); cy.contains("test 2 group-v2").should("be.visible").click(); cy.wait("@readGroupV2"); cy.contains("test 2 group-v2").should("be.visible"); @@ -118,7 +118,7 @@ describe("Edit v2 group", () => { .getGroupV2Permissions() .listGroupV2Members() .updateGroupV2(); - cy.contains("Groups").should("be.visible"); + cy.contains("My groups").should("be.visible"); cy.contains("test 2 group-v2").should("be.visible").click(); cy.wait("@readGroupV2"); cy.contains("test 2 group-v2").should("be.visible"); @@ -155,7 +155,7 @@ describe("Edit v2 group", () => { .readGroupV2() .readGroupV2Namespace(); - cy.contains("Groups").should("be.visible"); + cy.contains("My groups").should("be.visible"); cy.contains("test 2 group-v2").should("be.visible").click(); cy.wait("@readGroupV2"); cy.contains("test 2 group-v2").should("be.visible"); @@ -202,7 +202,7 @@ describe("Edit v2 group", () => { .getGroupV2Permissions() .listGroupV2Members() .deleteGroupV2(); - cy.contains("Groups").should("be.visible"); + cy.contains("My groups").should("be.visible"); cy.contains("test 2 group-v2").should("be.visible").click(); cy.wait("@readGroupV2"); cy.contains("test 2 group-v2").should("be.visible"); @@ -266,7 +266,7 @@ describe("Work with group data connectors", () => { .readProjectV2ById({ projectId: "PROJECT-ULID-1", name: "readProject1" }) .readProjectV2ById({ projectId: "PROJECT-ULID-2", name: "readProject2" }) .readProjectV2ById({ projectId: "PROJECT-ULID-3", name: "readProject2" }); - cy.contains("Groups").should("be.visible"); + cy.contains("My groups").should("be.visible"); cy.contains("test 2 group-v2").should("be.visible").click(); cy.wait("@readGroupV2"); cy.contains("test 2 group-v2").should("be.visible"); @@ -406,7 +406,7 @@ describe("Work with group data connectors, missing permissions", () => { .readProjectV2ById({ projectId: "PROJECT-ULID-1", name: "readProject1" }) .readProjectV2ById({ projectId: "PROJECT-ULID-2", name: "readProject2" }) .readProjectV2ById({ projectId: "PROJECT-ULID-3", name: "readProject2" }); - cy.contains("Groups").should("be.visible"); + cy.contains("My groups").should("be.visible"); cy.contains("test 2 group-v2").should("be.visible").click(); cy.wait("@readGroupV2"); cy.contains("test 2 group-v2").should("be.visible"); diff --git a/tests/cypress/e2e/projectV2.spec.ts b/tests/cypress/e2e/projectV2.spec.ts index 0597d85dd9..3e56c871fe 100644 --- a/tests/cypress/e2e/projectV2.spec.ts +++ b/tests/cypress/e2e/projectV2.spec.ts @@ -203,7 +203,7 @@ describe("Edit v2 project", () => { it("changes project metadata", () => { fixtures.readProjectV2().updateProjectV2().listNamespaceV2(); - cy.contains("Projects").should("be.visible"); + cy.contains("My projects").should("be.visible"); cy.getDataCy("dashboard-project-list") .contains("a", "test 2 v2-project") .should("be.visible") @@ -438,7 +438,7 @@ describe("Edit v2 project", () => { fixture: "projectV2/list-projectV2-post-delete.json", name: "listProjectV2PostDelete", }); - cy.contains("Projects"); + cy.contains("My projects"); cy.contains("Project deleted").should("be.visible"); }); });