Skip to content

Commit 87f6c1b

Browse files
Refactor PremiumBadge component to support noLink prop and update documentation links for SSO activation
1 parent 55dcfad commit 87f6c1b

File tree

4 files changed

+26
-17
lines changed

4 files changed

+26
-17
lines changed

components/premium-badge.tsx

Lines changed: 22 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -3,22 +3,31 @@ import Link from "next/link";
33
import { Badge } from "./ui/badge";
44

55
export interface PremiumBadgeProps
6-
extends React.HTMLAttributes<HTMLDivElement> {}
6+
extends React.HTMLAttributes<HTMLDivElement> {
7+
noLink?: boolean;
8+
}
9+
10+
function PremiumBadge({ className, noLink, ...props }: PremiumBadgeProps) {
11+
const badge = (
12+
<Badge className="mx-3 sm:mx-6 rounded-lg px-1 w-fit flex-row gap-x-1 my-0" variant="warning">
13+
Premium
14+
<Image
15+
src="/bruno.png"
16+
alt="Bruno Logo"
17+
height={20}
18+
width={20}
19+
className="my-0 h-5 w-5 sm:h-5 sm:w-5 group-hover:animate-infinite group-hover:animate-wiggle"
20+
/>
21+
</Badge>
22+
);
23+
24+
if (noLink) {
25+
return badge;
26+
}
727

8-
function PremiumBadge({ className, ...props }: PremiumBadgeProps) {
928
return (
1029
<Link href="https://www.usebruno.com/pricing" target="_blank" className="my-0">
11-
<Badge className="mx-3 sm:mx-6 rounded-lg px-1 w-fit flex-row gap-x-1 my-0" variant="warning">
12-
Premium
13-
<Image
14-
src="/bruno.png"
15-
alt="Bruno Logo"
16-
height={16}
17-
width={16}
18-
className="my-0 h-5 w-5 sm:h-5 sm:w-5"
19-
style={{ margin: 0 }}
20-
/>
21-
</Badge>
30+
{badge}
2231
</Link>
2332
);
2433
}

content/license-administrators/saml-sso/overview.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ In the Bruno License Portal's SSO Settings, you'll find two fields under "Role M
192192
### License Activation Flow
193193

194194
**For User Role Users:**
195-
- Users can activate their Bruno license using SSO
195+
- [Users can activate their Bruno license using SSO](/license-end-users/activate-license#activating-with-sso)
196196
- They receive a license key via email on first login
197197
- They can use this key to activate Bruno on their local machine
198198
- They do NOT have access to the License Portal

content/license-end-users/activate-license.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ Once the license is activated, you will see a success message.
3434
<PremiumBadge />
3535

3636
<Callout type="info">
37-
SSO license activation is available for Ultimate Edition customers. Please see the [SAML SSO Overview](/license-administrators/sso-saml/overview) for more information.
37+
SSO license activation is available for Ultimate Edition customers. Please see the [SAML SSO Overview](/license-administrators/saml-sso/overview) for more information.
3838
</Callout>
3939

4040
### Step 1: Click on the Settings or Key icon in Bruno
@@ -48,7 +48,7 @@ If your company has configured SSO for Bruno, select `SSO` and click `Activate L
4848
![login](/screenshots/license-management/activate-sso.webp)
4949

5050
<Callout type="info">
51-
Your email needs to be part of the SSO configuration in order to activate your license, with the `User Role` mapped. See [Role Mapping](/license-administrators/sso-saml/overview#role-mapping) for details.
51+
Your email needs to be part of the SSO configuration in order to activate your license, with the `User Role` mapped. See [Role Mapping](/license-administrators/saml-sso/overview#role-mapping) for details.
5252
</Callout>
5353

5454
### Step 3: SSO Login

content/license-overview.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ For our open-source users, there is no concept of license management! Simply dow
66

77
Our commercial plans have different license management aspects. If you have any questions about what plan is best suited for you, please see our [pricing page <strong><sup>↗</sup></strong>](https://www.usebruno.com/pricing) or [contact us <strong><sup>↗</sup></strong>](mailto:[email protected]) to discuss.
88

9-
## License Management <PremiumBadge />
9+
## License Management <PremiumBadge noLink />
1010

1111
### For License Administrators
1212

0 commit comments

Comments
 (0)