Elffuss BraidHub

kikocis/continue public

update defaultBorderRadius and use rem instead of px
Changeset7c6ce8e62540745e106cdf91d9d7eee22f4ac48307544ad1b915c058a39eb895
AuthorNate <sestinj@gmail.com> · 2025-06-27 00:26 -07:00
CommitterNate <sestinj@gmail.com> · 2025-06-27 00:26 -07:00
Parents040cf01a16a5

Browse the files at this changeset

7 files changed

added .continue/rules/css-units.md +5 −0
@@ -0,0 +1,5 @@
1+---
2+globs: "gui/**/*.tsx"
3+---
4+
5+You should try to use the `rem` CSS unit whenever possible for scalability instead of `px`.
modified gui/src/components/Layout.tsx +1 −2
@@ -2,7 +2,7 @@
22 import { useContext, useEffect } from "react";
33 import { Outlet, useLocation, useNavigate } from "react-router-dom";
44 import styled from "styled-components";
5-import { CustomScrollbarDiv, defaultBorderRadius } from ".";
5+import { CustomScrollbarDiv } from ".";
66 import { AuthProvider } from "../context/Auth";
77 import { IdeMessengerContext } from "../context/IdeMessenger";
88 import { LocalStorageProvider } from "../context/LocalStorage";
@@ -30,7 +30,6 @@
3030
3131 const LayoutTopDiv = styled(CustomScrollbarDiv)`
3232 height: 100%;
33- border-radius: ${defaultBorderRadius};
3433 position: relative;
3534 overflow-x: hidden;
3635 `;
modified gui/src/components/StyledMarkdownPreview/index.tsx +1 −1
@@ -76,7 +76,7 @@
7676 display: none;
7777 }
7878 word-wrap: break-word;
79- border-radius: ${defaultBorderRadius};
79+ border-radius: 0.3125rem;
8080 background-color: var(--vscode-textCodeBlock-background);
8181 font-size: ${getFontSize() - 2}px;
8282 font-family: var(--vscode-editor-font-family);
modified gui/src/components/index.ts +1 −1
@@ -1,7 +1,7 @@
11 import styled from "styled-components";
22 import { varWithFallback } from "../styles/theme";
33
4-export const defaultBorderRadius = "5px";
4+export const defaultBorderRadius = "0.5rem";
55 export const lightGray = "#999998";
66 export const greenButtonColor = "#189e72";
77
modified gui/src/components/mainInput/InputToolbar/EnterButton.tsx +1 −2
@@ -1,6 +1,5 @@
11 import styled from "styled-components";
22 import {
3- defaultBorderRadius,
43 lightGray,
54 vscButtonBackground,
65 vscButtonForeground,
@@ -18,7 +17,7 @@
1817 !props.disabled && props.isPrimary
1918 ? vscButtonBackground
2019 : lightGray + "33"};
21- border-radius: ${defaultBorderRadius};
20+ border-radius: 0.3125rem;
2221 color: ${(props) =>
2322 !props.disabled && props.isPrimary ? vscButtonForeground : vscForeground};
2423 cursor: pointer;
modified gui/src/components/mainInput/TipTapEditor/components/StyledComponents.ts +1 −2
@@ -1,6 +1,5 @@
11 import styled from "styled-components";
22 import {
3- defaultBorderRadius,
43 lightGray,
54 vscBadgeBackground,
65 vscCommandCenterActiveBorder,
@@ -14,7 +13,7 @@
1413 export const InputBoxDiv = styled.div<{}>`
1514 resize: none;
1615 font-family: inherit;
17- border-radius: ${defaultBorderRadius};
16+ border-radius: 0.5rem;
1817 padding-bottom: 1px;
1918 margin: 0;
2019 height: auto;
modified gui/tailwind.config.cjs +1 −1
@@ -27,7 +27,7 @@
2727 "spin-slow": "spin 6s linear infinite",
2828 },
2929 borderRadius: {
30- default: "5px",
30+ default: "0.5rem",
3131 },
3232 colors: {
3333 background: varWithFallback("background"),