Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ShapeUp] Renku V2 Project Page #3108

Merged
merged 18 commits into from
May 22, 2024
Merged

[ShapeUp] Renku V2 Project Page #3108

merged 18 commits into from
May 22, 2024

Conversation

andre-code
Copy link
Contributor

@andre-code andre-code commented Apr 22, 2024

This PR adds a new project page for Renku v2. It includes:

  • Project information overview (name, namespace, description, visibility, keywords)
  • Add session launcher from custom image or existing global environment
  • Sessions launcher overview
  • Launch, stop, modify, pause a session
  • Add data source (cloud storage only)
  • Data sources overview
  • Link existing code repository
  • Code repositories overview
  • Edit project information
  • New colors for inputs, buttons, alerts, and fonts

fix #3098

/deploy renku=release-0.52.x

@RenkuBot
Copy link
Contributor

You can access the deployment of this PR at https://renku-ci-ui-3108.dev.renku.ch

andre-code and others added 7 commits May 13, 2024 10:37

Co-authored-by: Flora Thiebaut <flora.thiebaut@sdsc.ethz.ch>
Add project page header, menu and project info

---------

Co-authored-by: Flora Thiebaut <flora.thiebaut@sdsc.ethz.ch>
…options to add/edit/delete session launcher and add/delete code repositories
…vironments available, and fix the copyright year for new components.
…. Remove status and date for code repositories
@andre-code andre-code marked this pull request as ready for review May 17, 2024 12:24
Copy link
Member

@leafty leafty left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is mostly ready 👏 , some comments below.

The [design] items are non-blocking but need to be raised with design and fixed shortly.

@@ -212,6 +213,7 @@
"readme",
"readonly",
"Ravey",
"rcloud",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
"rcloud",

Comment on lines 49 to 52
import {
default as buttonStyles,
default as styles,
} from "./Buttons.module.scss";
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is no reason to import this twice:

Suggested change
import {
default as buttonStyles,
default as styles,
} from "./Buttons.module.scss";
import styles from "./Buttons.module.scss";

Comment on lines 88 to 90
const classesNames = props.className?.length
? props.className?.split(" ")
: [];
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please use cx() from classnames.

const options = props.children ? (
<>
<DropdownToggle
data-cy="more-menu"
className={`${props.className} ${classes}`}
className={cx(...classesNames, classes, "rounded-end-pill")}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
className={cx(...classesNames, classes, "rounded-end-pill")}
className={cx(props.classesName, classes, "rounded-end-pill")}

@@ -98,7 +111,7 @@ function ButtonWithMenu(props: ButtonWithMenuProps) {
return (
<ButtonDropdown
id={props.id}
className={`${props.className} btn-with-menu`}
className={cx("btn-with-menu", classesNames)}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
className={cx("btn-with-menu", classesNames)}
className={cx(props.className, "btn-with-menu")}

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[design]: Should use viewbox of 32x32.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[design]: Should use viewbox of 32x32.

const badge =
state === "running" && defaultImage ? (
<SessionBadge className="border border-warning bg-warning-subtle">
<ExclamationCircleFill className="text-warning" size={16} />
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For all bootstrap icons, use class "bi" to align them with the surrounding text. Also, you can handle the margin here:

Suggested change
<ExclamationCircleFill className="text-warning" size={16} />
<ExclamationCircleFill className={cx("bi", "me-1", "text-warning")} size={16} />

) : state === "starting" ? (
<SessionBadge className="border border-warning bg-warning-subtle">
<Loader size={16} className="text-warning" inline />
<span className="text-warning ml-2">Starting Session</span>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note: class ml-2 does not exist. Use ms-1, me-1, etc.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[design] same viewbox comment here

@andre-code
Copy link
Contributor Author

Thanks, @leafty. I've included your code suggestions in the latest commit.

@andre-code andre-code requested a review from leafty May 21, 2024 10:25
Copy link
Member

@leafty leafty left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be good after this.

@@ -80,7 +86,7 @@ function ButtonWithMenu(props: ButtonWithMenuProps) {
<>
<DropdownToggle
data-cy="more-menu"
className={`${props.className} ${classes}`}
className={cx(props.className || "", classes, "rounded-end-pill")}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why have || ""?

Suggested change
className={cx(props.className || "", classes, "rounded-end-pill")}
className={cx(props.className, classes, "rounded-end-pill")}

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It was a misunderstanding; the cx function can handle undefined values.

<>
<span ref={ref} className={buttonStyles.LinkUnderline}>
<Link className="text-decoration-none" to={to}>
{text} <ArrowRight />
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This probably looks better:

Suggested change
{text} <ArrowRight />
{text}
<ArrowRight className={cx("bi", "ms-1")} />

leafty
leafty previously approved these changes May 21, 2024
Copy link
Member

@leafty leafty left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🚀 👏

@andre-code andre-code merged commit 1e67198 into main May 22, 2024
17 checks passed
@andre-code andre-code deleted the build/project-page-2.0 branch May 22, 2024 09:39
@RenkuBot
Copy link
Contributor

Tearing down the temporary RenkuLab deplyoment for this PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[ShapeUp] Add project page
4 participants