Skip to content

Commit b4eee3d

Browse files
fix: issues with tab rendering for tenant management
1 parent ba43413 commit b4eee3d

File tree

1 file changed

+11
-9
lines changed

1 file changed

+11
-9
lines changed

packages/tenants-react/src/pages/tenant-management/tenant-management.tsx

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { TenantDetails } from "@shared/tenants";
2-
import { SelectInput, TabGroup, Tab } from "@shared/ui";
2+
import { SelectInput, TabGroup, Tab, TabPanel } from "@shared/ui";
33
// import { BaseFormSection } from "@supertokens-plugin-profile/common-details-shared";
44
import classNames from "classnames/bind";
55
import { useState, useEffect, useCallback } from "react";
@@ -114,14 +114,17 @@ export const TenantManagement = ({ section }: { section: any }) => {
114114
{/* Tab Navigation */}
115115
<div>
116116
<TabGroup>
117-
<Tab panel={t("PL_TB_USERS_TAB_LABEL")}>
117+
<Tab panel="users">{t("PL_TB_USERS_TAB_LABEL")}</Tab>
118+
<Tab panel="invitations">{t("PL_TB_INVITATIONS_TAB_LABEL")}</Tab>
119+
<Tab panel="requests">{t("PL_TB_REQUESTS_TAB_LABEL")}</Tab>
120+
121+
{/* Tab Content */}
122+
<TabPanel name="users">
118123
<TenantTab description="List of users that are part of your tenant">
119-
<TenantUsers
120-
onFetch={onFetchUsers}
121-
/>
124+
<TenantUsers onFetch={onFetchUsers} />
122125
</TenantTab>
123-
</Tab>
124-
<Tab panel={t("PL_TB_INVITATIONS_TAB_LABEL")}>
126+
</TabPanel>
127+
<TabPanel name="invitations">
125128
<InvitationsWrapper
126129
section={{
127130
id: "tenant-invitations",
@@ -134,8 +137,7 @@ export const TenantManagement = ({ section }: { section: any }) => {
134137
onCreate={onCreateInvite}
135138
selectedTenantId={selectedTenantId}
136139
/>
137-
</Tab>
138-
<Tab panel={t("PL_TB_REQUESTS_TAB_LABEL")}></Tab>
140+
</TabPanel>
139141
</TabGroup>
140142
</div>
141143
</div>

0 commit comments

Comments
 (0)