Improvements to teams for self hosters (#7753)

* Write slug when no team billing

* Remove recommended actions for invites
This commit is contained in:
Joe Au-Yeung authored and GitHub committed 2023-03-15 15:09:43 -04:00
1 parent e88716758e
commit 9568e16ef6
3 files changed
+6 -3

No files matched your search

@@ -1,7 +1,8 @@
import { useState } from "react";
import { useLocale } from "@calcom/lib/hooks/useLocale";
import { RouterOutputs, trpc } from "@calcom/trpc/react";
import type { RouterOutputs } from "@calcom/trpc/react";
import { trpc } from "@calcom/trpc/react";
import { Card, showToast } from "@calcom/ui";
import { FiUserPlus, FiUsers, FiEdit } from "@calcom/ui/components/icon";
@@ -9,6 +10,7 @@ import TeamListItem from "./TeamListItem";
interface Props {
teams: RouterOutputs["viewer"]["teams"]["list"];
pending?: boolean;
}
export default function TeamList(props: Props) {
@@ -54,7 +56,7 @@ export default function TeamList(props: Props) {
))}
{/* only show recommended steps when there is only one team */}
{props.teams.length === 1 && (
{!props.pending && props.teams.length === 1 && (
<>
{props.teams.map(
(team, i) =>
@@ -90,7 +90,7 @@ export function TeamsListing() {
<Label className="dark:text-darkgray-900 pb-2 font-semibold text-gray-900">
{t("pending_invites")}
</Label>
<TeamList teams={invites} />
<TeamList teams={invites} pending />
</div>
)}
{teams.length > 0 && <TeamList teams={teams} />}