summaryrefslogtreecommitdiffhomepage
path: root/theme-test.tsx
diff options
context:
space:
mode:
authorDax Raad <[email protected]>2025-11-08 20:21:02 -0500
committerDax Raad <[email protected]>2025-11-08 20:21:02 -0500
commit4d20e1c3c6207cf6731ad8db9f92caf4ef31cb99 (patch)
tree1c0b14810b8919e0d9dba022384da876717f8e2e /theme-test.tsx
parent4bb7ea91271e85621a1394c70867ddc26be45631 (diff)
parent969af4d54122b727d7251b2977f617424d08e4cb (diff)
downloadopencode-4d20e1c3c6207cf6731ad8db9f92caf4ef31cb99.tar.gz
opencode-4d20e1c3c6207cf6731ad8db9f92caf4ef31cb99.zip
Merge remote-tracking branch 'origin/dev' into dev
Diffstat (limited to 'theme-test.tsx')
-rw-r--r--theme-test.tsx10
1 files changed, 2 insertions, 8 deletions
diff --git a/theme-test.tsx b/theme-test.tsx
index 61837473e..810ff4fc1 100644
--- a/theme-test.tsx
+++ b/theme-test.tsx
@@ -135,10 +135,7 @@ const htmlTemplate = `
`
// Arrow functions
-const debounce = <T extends (...args: any[]) => any>(
- func: T,
- wait: number,
-): ((...args: Parameters<T>) => void) => {
+const debounce = <T extends (...args: any[]) => any>(func: T, wait: number): ((...args: Parameters<T>) => void) => {
let timeout: NodeJS.Timeout
return (...args: Parameters<T>) => {
clearTimeout(timeout)
@@ -161,10 +158,7 @@ async function fetchUserData(userId: number): Promise<User> {
}
// React component with various patterns
-const ThemeProvider: FC<{ children: ReactNode; theme?: Theme }> = ({
- children,
- theme = "auto",
-}) => {
+const ThemeProvider: FC<{ children: ReactNode; theme?: Theme }> = ({ children, theme = "auto" }) => {
const [currentTheme, setCurrentTheme] = useState<Theme>(theme)
const [status, setStatus] = useState<Status>("pending")