Skip to content

Commit 8e98ba9

Browse files
committed
fix: properly center badge text
1 parent 74dc8c1 commit 8e98ba9

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

packages/website/src/components/CodeListing.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,17 +41,17 @@ export function CodeListing({
4141
{deprecation || readonly || optional ? (
4242
<div className="flex flex-row gap-1">
4343
{deprecation ? (
44-
<div className="h-5 place-content-center rounded-full bg-red-500 px-3 text-center text-xs font-semibold uppercase text-white">
44+
<div className="flex h-5 place-content-center place-items-center rounded-full bg-red-500 px-3 text-center text-xs font-semibold uppercase text-white">
4545
Deprecated
4646
</div>
4747
) : null}
4848
{readonly ? (
49-
<div className="bg-blurple h-5 place-content-center rounded-full px-3 text-center text-xs font-semibold uppercase text-white">
49+
<div className="bg-blurple flex h-5 place-content-center place-items-center rounded-full px-3 text-center text-xs font-semibold uppercase text-white">
5050
Readonly
5151
</div>
5252
) : null}
5353
{optional ? (
54-
<div className="bg-blurple h-5 place-content-center rounded-full px-3 text-center text-xs font-semibold uppercase text-white">
54+
<div className="bg-blurple flex h-5 place-content-center place-items-center rounded-full px-3 text-center text-xs font-semibold uppercase text-white">
5555
Optional
5656
</div>
5757
) : null}

packages/website/src/components/MethodItem.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,17 +37,17 @@ export function MethodItem({ data }: { data: ApiMethodJSON | ApiMethodSignatureJ
3737
(data.kind === 'Method' && method.static) ? (
3838
<div className="flex flex-row gap-1">
3939
{data.deprecated ? (
40-
<div className="h-5 place-content-center rounded-full bg-red-500 px-3 text-center text-xs font-semibold uppercase text-white">
40+
<div className="flex h-5 place-content-center place-items-center rounded-full bg-red-500 px-3 text-center text-xs font-semibold uppercase text-white">
4141
Deprecated
4242
</div>
4343
) : null}
4444
{data.kind === 'Method' && method.protected ? (
45-
<div className="bg-blurple h-5 place-content-center rounded-full px-3 text-center text-xs font-semibold uppercase text-white">
45+
<div className="bg-blurple flex h-5 place-content-center place-items-center rounded-full px-3 text-center text-xs font-semibold uppercase text-white">
4646
Protected
4747
</div>
4848
) : null}
4949
{data.kind === 'Method' && method.static ? (
50-
<div className="bg-blurple h-5 place-content-center rounded-full px-3 text-center text-xs font-semibold uppercase text-white">
50+
<div className="bg-blurple flex h-5 place-content-center place-items-center rounded-full px-3 text-center text-xs font-semibold uppercase text-white">
5151
Static
5252
</div>
5353
) : null}

packages/website/src/components/Sections.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,12 +66,12 @@ export function ConstructorSection({ data }: { data: ApiConstructorJSON }) {
6666
{data.deprecated || data.protected ? (
6767
<div className="flex flex-row gap-1">
6868
{data.deprecated ? (
69-
<div className="h-5 place-content-center rounded-full bg-red-500 px-3 text-center text-xs font-semibold uppercase text-white">
69+
<div className="flex h-5 place-content-center place-items-center rounded-full bg-red-500 px-3 text-center text-xs font-semibold uppercase text-white">
7070
Deprecated
7171
</div>
7272
) : null}
7373
{data.protected ? (
74-
<div className="bg-blurple h-5 place-content-center rounded-full px-3 text-center text-xs font-semibold uppercase text-white">
74+
<div className="bg-blurple flex h-5 place-content-center place-items-center rounded-full px-3 text-center text-xs font-semibold uppercase text-white">
7575
Protected
7676
</div>
7777
) : null}

0 commit comments

Comments
 (0)