Skip to content

Rallly is an open-source scheduling and collaboration tool designed to make organizing events and meetings easier.

💄 Hide pro badge in pro space (#2034)

Luke Vellabd5df8e9a99a
diff --git a/apps/web/src/components/forms/poll-settings.tsx b/apps/web/src/components/forms/poll-settings.tsx
index f0dc873dd..1bcdc28b3 100644
--- a/apps/web/src/components/forms/poll-settings.tsx
+++ b/apps/web/src/components/forms/poll-settings.tsx
@@ -119,7 +119,7 @@ export const PollSettingsForm = ({ children }: React.PropsWithChildren) => {
<Setting>
<AtSignIcon className="size-5 shrink-0 translate-y-0.5" />
<SettingContent>
- <SettingTitle pro>
+ <SettingTitle pro={isFree}>
<Trans
i18nKey="requireParticipantEmailLabel"
defaults="Make email address required for participants"
@@ -150,7 +150,7 @@ export const PollSettingsForm = ({ children }: React.PropsWithChildren) => {
<Setting>
<EyeIcon className="size-5 shrink-0 translate-y-0.5" />
<SettingContent>
- <SettingTitle pro>
+ <SettingTitle pro={isFree}>
<Trans
i18nKey="hideParticipantsLabel"
defaults="Hide participants from each other"
@@ -181,7 +181,7 @@ export const PollSettingsForm = ({ children }: React.PropsWithChildren) => {
<Setting>
<VoteIcon className="size-5 shrink-0 translate-y-0.5" />
<SettingContent>
- <SettingTitle htmlFor={field.name} pro>
+ <SettingTitle htmlFor={field.name} pro={isFree}>
<Trans
i18nKey="hideScoresLabel"
defaults="Hide scores until after a participant has voted"
diff --git a/apps/web/src/components/poll/manage-poll.tsx b/apps/web/src/components/poll/manage-poll.tsx
index 66a521978..7b34575da 100644
--- a/apps/web/src/components/poll/manage-poll.tsx
+++ b/apps/web/src/components/poll/manage-poll.tsx
@@ -217,7 +217,7 @@ const ManagePoll: React.FunctionComponent<{
<CalendarCheck2Icon />
</Icon>
<Trans i18nKey="finishPoll" defaults="Finalize" />
- <ProBadge />
+ {space.data.tier !== "pro" ? <ProBadge /> : null}
</DropdownMenuItem>
<PauseResumeToggle />
</>
@@ -244,7 +244,7 @@ const ManagePoll: React.FunctionComponent<{
>
<DropdownMenuItemIconLabel icon={CopyIcon}>
<Trans i18nKey="duplicate" defaults="Duplicate" />
- <ProBadge />
+ {space.data.tier !== "pro" ? <ProBadge /> : null}
</DropdownMenuItemIconLabel>
</DropdownMenuItem>
<DropdownMenuSeparator />