10000 refactor: update border-radius to match the new designs · coder/coder@a024d19 · GitHub
[go: up one dir, main page]

Skip to content

Commit a024d19

Browse files
committed
refactor: update border-radius to match the new designs
1 parent 91fd0c1 commit a024d19

File tree

4 files changed

+14
-9
lines changed

4 files changed

+14
-9
lines changed

site/src/components/Avatar/Avatar.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,13 @@ import { getExternalImageStylesFromUrl } from "theme/externalImages";
1818
import { cn } from "utils/cn";
1919

2020
const avatarVariants = cva(
21-
"relative flex shrink-0 overflow-hidden rounded border border-solid bg-surface-secondary text-content-secondary"< 8000 span class="pl-kos">,
21+
"relative flex shrink-0 overflow-hidden border border-solid bg-surface-secondary text-content-secondary",
2222
{
2323
variants: {
2424
size: {
25-
lg: "h-[--avatar-lg] w-[--avatar-lg] rounded-[6px] text-sm font-medium",
26-
md: "h-[--avatar-default] w-[--avatar-default] text-2xs",
27-
sm: "h-[--avatar-sm] w-[--avatar-sm] text-[8px]",
25+
lg: "h-[--avatar-lg] w-[--avatar-lg] text-sm font-medium rounded-sm",
26+
md: "h-[--avatar-default] w-[--avatar-default] text-2xs rounded-xs",
27+
sm: "h-[--avatar-sm] w-[--avatar-sm] text-[8px] rounded-xs",
2828
},
2929
variant: {
3030
default: null,

site/src/components/Button/Button.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import { cn } from "utils/cn";
99

1010
export const buttonVariants = cva(
1111
`inline-flex items-center justify-center gap-1 whitespace-nowrap
12-
border-solid rounded-md transition-colors min-w-20
12+
border-solid rounded-sm transition-colors min-w-20
1313
text-sm font-semibold font-medium cursor-pointer no-underline
1414
focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-content-link
1515
disabled:pointer-events-none disabled:text-content-disabled

site/src/index.css

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@
2727
--border-default: 240 6% 90%;
2828
--border-success: 142 76% 36%;
2929
--border-destructive: 0 84% 60%;
30-
--radius: 0.5rem;
3130
--chart-1: 12 76% 61%;
3231
--chart-2: 173 58% 39%;
3332
--chart-3: 197 37% 24%;

site/tailwind.config.js

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,15 @@ module.exports = {
1919
"3xl": ["2rem", "2.5rem"],
2020
},
2121
borderRadius: {
22-
lg: "var(--radius)",
23-
md: "calc(var(--radius) - 2px)",
24-
sm: "calc(var(--radius) - 4px)",
22+
// In Tailwind's border radius configuration, the default value differs
23+
// from the `md` size. In our setup, the default value should align with
24+
// `md`.
25+
DEFAULT: "0.5rem",
26+
lg: "0.75rem",
27+
md: "0.5rem",
28+
sm: "0.375rem",
29+
xs: "0.25rem",
30+
xxs: "0.125rem",
2531
},
2632
colors: {
2733
content: {

0 commit comments

Comments
 (0)
0