fix: plan clarification in ui popup

This commit is contained in:
Piyush Gupta
2025-10-27 19:49:32 +05:30
parent 7a31ea6eda
commit 614a725e6f
44 changed files with 199 additions and 89 deletions
@@ -33,7 +33,8 @@ export const GroupsSection = () => {
if (!subscription?.groups) {
handlePopUpOpen("upgradePlan", {
description:
"You can manage users more efficiently with groups if you upgrade your Infisical plan to an Enterprise license."
"You can manage users more efficiently with groups if you switch to Infisical's Enterprise plan.",
isEnterpriseFeature: true
});
} else {
handlePopUpOpen("group");
@@ -100,6 +101,9 @@ export const GroupsSection = () => {
isOpen={popUp.upgradePlan.isOpen}
onOpenChange={(isOpen) => handlePopUpToggle("upgradePlan", isOpen)}
text={(popUp.upgradePlan?.data as { description: string })?.description}
isEnterpriseFeature={
(popUp.upgradePlan?.data as { isEnterpriseFeature: boolean })?.isEnterpriseFeature
}
/>
</div>
);
@@ -191,7 +191,7 @@ export const Page = () => {
onOpenUpgradeModal={() =>
handlePopUpOpen("upgradePlan", {
description:
"You can assign custom roles to members if you upgrade your Infisical plan."
"You can assign custom roles to members if you switch to Infisical's Pro plan."
})
}
/>
@@ -60,7 +60,7 @@ type TRoleForm = z.infer<typeof roleFormSchema>;
type Props = {
projectMember: TWorkspaceUser;
onOpenUpgradeModal: (title: string) => void;
onOpenUpgradeModal: () => void;
};
export const MemberRoleModify = ({ projectMember, onOpenUpgradeModal }: Props) => {
@@ -122,9 +122,7 @@ export const MemberRoleModify = ({ projectMember, onOpenUpgradeModal }: Props) =
);
if (hasCustomRoleSelected && subscription && !subscription?.rbac) {
onOpenUpgradeModal(
"You can assign custom roles to members if you upgrade your Infisical plan."
);
onOpenUpgradeModal();
return;
}
@@ -42,7 +42,8 @@ export const AuditLogsRetentionSection = () => {
try {
if (!subscription?.auditLogs) {
handlePopUpOpen("upgradePlan", {
description: "You can only configure audit logs retention if you upgrade your plan."
description:
"You can only configure audit logs retention if you switch to Infisical's Pro plan."
});
return;
@@ -51,7 +52,7 @@ export const AuditLogsRetentionSection = () => {
if (subscription && auditLogsRetentionDays > subscription?.auditLogsRetentionDays) {
handlePopUpOpen("upgradePlan", {
description:
"To update your audit logs retention period to a higher value, upgrade your plan."
"To update your audit logs retention period to a higher value, switch to Infisical's Pro plan."
});
return;