-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
[dashboard] add "with-options" buttons #15668
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -398,26 +398,29 @@ export default function () { | |
</a> | ||
<ItemFieldContextMenu | ||
className="py-0.5" | ||
menuEntries={ | ||
menuEntries={[ | ||
{ | ||
title: "New Workspace ...", | ||
href: gitpodHostUrl | ||
.withContext(`${branch.url}`, { showOptions: true }) | ||
.toString(), | ||
separator: true, | ||
}, | ||
Comment on lines
+402
to
+408
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. praise: Nice and much needed addition! ✨ |
||
prebuild?.status === "queued" || prebuild?.status === "building" | ||
? [ | ||
{ | ||
title: "Cancel Prebuild", | ||
customFontStyle: | ||
"text-red-600 dark:text-red-400 hover:text-red-800 dark:hover:text-red-300", | ||
onClick: () => | ||
prebuild && cancelPrebuild(prebuild.info.id), | ||
}, | ||
] | ||
: [ | ||
{ | ||
title: `${prebuild ? "Rerun" : "Run"} Prebuild (${ | ||
branch.name | ||
})`, | ||
onClick: () => triggerPrebuild(branch), | ||
}, | ||
] | ||
} | ||
? { | ||
title: "Cancel Prebuild", | ||
customFontStyle: | ||
"text-red-600 dark:text-red-400 hover:text-red-800 dark:hover:text-red-300", | ||
onClick: () => | ||
prebuild && cancelPrebuild(prebuild.info.id), | ||
} | ||
: { | ||
title: `${prebuild ? "Rerun" : "Run"} Prebuild (${ | ||
branch.name | ||
})`, | ||
onClick: () => triggerPrebuild(branch), | ||
}, | ||
]} | ||
/> | ||
</ItemField> | ||
</Item> | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,6 +13,7 @@ import { useCurrentTeam } from "../teams/teams-context"; | |
import { RemoveProjectModal } from "./RemoveProjectModal"; | ||
import { toRemoteURL } from "./render-utils"; | ||
import { prebuildStatusIcon } from "./Prebuilds"; | ||
import { gitpodHostUrl } from "../service/service"; | ||
|
||
type ProjectListItemProps = { | ||
project: Project; | ||
|
@@ -40,7 +41,14 @@ export const ProjectListItem: FunctionComponent<ProjectListItemProps> = ({ proje | |
menuEntries={[ | ||
{ | ||
title: "New Workspace", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. question(non-blocking): Could we measure how much this |
||
href: `/#${project.cloneUrl}`, | ||
href: gitpodHostUrl.withContext(`${project.cloneUrl}`).toString(), | ||
separator: true, | ||
}, | ||
Comment on lines
42
to
+46
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
||
{ | ||
title: "New Workspace ...", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. praise: Excellent ... 🥯 |
||
href: gitpodHostUrl | ||
.withContext(`${project.cloneUrl}`, { showOptions: true }) | ||
.toString(), | ||
separator: true, | ||
}, | ||
{ | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💭 thought: Next steps could include improving the modal to allow branch selection as mentioned in #5372, #12591, #10168, and a relevant discussion (internal).