-
-
-
Name
-
Context
-
Last Started
+
+ Search workspaces using workspace ID.
+
+
+
+
+
Name
+
Context
+
Last Started
+
+ {searchResult.rows.map((ws) => (
+
+ ))}
- {searchResult.rows.map((ws) => (
-
- ))}
+
-
>
);
}
diff --git a/components/dashboard/src/admin/admin-menu.ts b/components/dashboard/src/admin/admin.routes.ts
similarity index 60%
rename from components/dashboard/src/admin/admin-menu.ts
rename to components/dashboard/src/admin/admin.routes.ts
index cf9ee07aebf06a..d809ca032c0963 100644
--- a/components/dashboard/src/admin/admin-menu.ts
+++ b/components/dashboard/src/admin/admin.routes.ts
@@ -3,36 +3,38 @@
* Licensed under the GNU Affero General Public License (AGPL).
* See License.AGPL.txt in the project root for license information.
*/
+import { TabEntry } from "../components/Header";
-export function getAdminMenu() {
+export function getAdminTabs(): TabEntry[] {
return [
{
title: "Users",
- link: ["/admin/users", "/admin"],
+ link: "/admin/users",
+ alternatives: ["/admin"],
},
{
title: "Workspaces",
- link: ["/admin/workspaces"],
+ link: "/admin/workspaces",
},
{
title: "Projects",
- link: ["/admin/projects"],
+ link: "/admin/projects",
},
{
title: "Organizations",
- link: ["/admin/orgs"],
+ link: "/admin/orgs",
},
{
title: "Blocked Repositories",
- link: ["/admin/blocked-repositories"],
+ link: "/admin/blocked-repositories",
},
{
title: "License",
- link: ["/admin/license"],
+ link: "/admin/license",
},
{
title: "Settings",
- link: ["/admin/settings"],
+ link: "/admin/settings",
},
];
}
diff --git a/components/dashboard/src/menu/Menu.tsx b/components/dashboard/src/menu/Menu.tsx
index ebd8333da88b22..a02fe203b37de8 100644
--- a/components/dashboard/src/menu/Menu.tsx
+++ b/components/dashboard/src/menu/Menu.tsx
@@ -25,6 +25,7 @@ import { BillingMode } from "@gitpod/gitpod-protocol/lib/billing-mode";
import { useFeatureFlags } from "../contexts/FeatureFlagContext";
import OrganizationSelector from "./OrganizationSelector";
import { useOrgBillingMode } from "../data/billing-mode/org-billing-mode-query";
+import { getAdminTabs } from "../admin/admin.routes";
interface Entry {
title: string;
@@ -133,6 +134,12 @@ export default function Menu() {
userBillingMode,
]);
+ const adminMenu: Entry = {
+ title: "Admin",
+ link: "/admin",
+ alternatives: [...getAdminTabs().map((entry) => entry.link)],
+ };
+
const handleFeedbackFormClick = () => {
setFeedbackFormVisible(true);
};
@@ -172,7 +179,11 @@ export default function Menu() {
{user?.rolesOrPermissions?.includes("admin") && (
-
+
)}
{isGitpodIo() && (