Changesets · Branches · Tags · Compare
| Changeset | 7c6ce8e62540745e106cdf91d9d7eee22f4ac48307544ad1b915c058a39eb895 |
|---|---|
| Author | Nate <sestinj@gmail.com> · 2025-06-27 00:26 -07:00 |
| Committer | Nate <sestinj@gmail.com> · 2025-06-27 00:26 -07:00 |
| Parents | 040cf01a16a5 |
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 @@ | ||
| 2 | 2 | import { useContext, useEffect } from "react"; |
| 3 | 3 | import { Outlet, useLocation, useNavigate } from "react-router-dom"; |
| 4 | 4 | import styled from "styled-components"; |
| 5 | -import { CustomScrollbarDiv, defaultBorderRadius } from "."; | |
| 5 | +import { CustomScrollbarDiv } from "."; | |
| 6 | 6 | import { AuthProvider } from "../context/Auth"; |
| 7 | 7 | import { IdeMessengerContext } from "../context/IdeMessenger"; |
| 8 | 8 | import { LocalStorageProvider } from "../context/LocalStorage"; |
| @@ -30,7 +30,6 @@ | ||
| 30 | 30 | |
| 31 | 31 | const LayoutTopDiv = styled(CustomScrollbarDiv)` |
| 32 | 32 | height: 100%; |
| 33 | - border-radius: ${defaultBorderRadius}; | |
| 34 | 33 | position: relative; |
| 35 | 34 | overflow-x: hidden; |
| 36 | 35 | `; |
modified gui/src/components/StyledMarkdownPreview/index.tsx +1 −1
| @@ -76,7 +76,7 @@ | ||
| 76 | 76 | display: none; |
| 77 | 77 | } |
| 78 | 78 | word-wrap: break-word; |
| 79 | - border-radius: ${defaultBorderRadius}; | |
| 79 | + border-radius: 0.3125rem; | |
| 80 | 80 | background-color: var(--vscode-textCodeBlock-background); |
| 81 | 81 | font-size: ${getFontSize() - 2}px; |
| 82 | 82 | font-family: var(--vscode-editor-font-family); |
modified gui/src/components/index.ts +1 −1
| @@ -1,7 +1,7 @@ | ||
| 1 | 1 | import styled from "styled-components"; |
| 2 | 2 | import { varWithFallback } from "../styles/theme"; |
| 3 | 3 | |
| 4 | -export const defaultBorderRadius = "5px"; | |
| 4 | +export const defaultBorderRadius = "0.5rem"; | |
| 5 | 5 | export const lightGray = "#999998"; |
| 6 | 6 | export const greenButtonColor = "#189e72"; |
| 7 | 7 |
modified gui/src/components/mainInput/InputToolbar/EnterButton.tsx +1 −2
| @@ -1,6 +1,5 @@ | ||
| 1 | 1 | import styled from "styled-components"; |
| 2 | 2 | import { |
| 3 | - defaultBorderRadius, | |
| 4 | 3 | lightGray, |
| 5 | 4 | vscButtonBackground, |
| 6 | 5 | vscButtonForeground, |
| @@ -18,7 +17,7 @@ | ||
| 18 | 17 | !props.disabled && props.isPrimary |
| 19 | 18 | ? vscButtonBackground |
| 20 | 19 | : lightGray + "33"}; |
| 21 | - border-radius: ${defaultBorderRadius}; | |
| 20 | + border-radius: 0.3125rem; | |
| 22 | 21 | color: ${(props) => |
| 23 | 22 | !props.disabled && props.isPrimary ? vscButtonForeground : vscForeground}; |
| 24 | 23 | cursor: pointer; |
modified gui/src/components/mainInput/TipTapEditor/components/StyledComponents.ts +1 −2
| @@ -1,6 +1,5 @@ | ||
| 1 | 1 | import styled from "styled-components"; |
| 2 | 2 | import { |
| 3 | - defaultBorderRadius, | |
| 4 | 3 | lightGray, |
| 5 | 4 | vscBadgeBackground, |
| 6 | 5 | vscCommandCenterActiveBorder, |
| @@ -14,7 +13,7 @@ | ||
| 14 | 13 | export const InputBoxDiv = styled.div<{}>` |
| 15 | 14 | resize: none; |
| 16 | 15 | font-family: inherit; |
| 17 | - border-radius: ${defaultBorderRadius}; | |
| 16 | + border-radius: 0.5rem; | |
| 18 | 17 | padding-bottom: 1px; |
| 19 | 18 | margin: 0; |
| 20 | 19 | height: auto; |
modified gui/tailwind.config.cjs +1 −1
| @@ -27,7 +27,7 @@ | ||
| 27 | 27 | "spin-slow": "spin 6s linear infinite", |
| 28 | 28 | }, |
| 29 | 29 | borderRadius: { |
| 30 | - default: "5px", | |
| 30 | + default: "0.5rem", | |
| 31 | 31 | }, |
| 32 | 32 | colors: { |
| 33 | 33 | background: varWithFallback("background"), |