Skip to content

Commit 265b355

Browse files
feat(devtools): extract theme to devtool components (#173)
* feat: extract theme to devtool components * chore: changeset * fix: pr comments and test --------- Co-authored-by: Kevin Van Cott <kevinvandy656@gmail.com>
1 parent 97c878a commit 265b355

File tree

3 files changed

+10
-5
lines changed

3 files changed

+10
-5
lines changed

.changeset/long-corners-repair.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@tanstack/pacer-devtools': patch
3+
---
4+
5+
Moves devtools theme to the component to avoid theme mismatch.

packages/pacer-devtools/src/PacerDevtools.tsx renamed to packages/pacer-devtools/src/components/index.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
import { ThemeContextProvider } from '@tanstack/devtools-ui'
2-
import { PacerContextProvider } from './PacerContextProvider'
3-
import { Shell } from './components/Shell'
2+
import { PacerContextProvider } from '../PacerContextProvider'
3+
import { Shell } from './Shell'
44

55
import type { TanStackDevtoolsTheme } from '@tanstack/devtools-ui'
66

7-
interface PacerDevtools {
7+
interface DevtoolsProps {
88
theme: TanStackDevtoolsTheme
99
}
1010

11-
export default function PacerDevtools(props: PacerDevtools) {
11+
export default function PacerDevtools(props: DevtoolsProps) {
1212
return (
1313
<ThemeContextProvider theme={props.theme}>
1414
<PacerContextProvider>

packages/pacer-devtools/src/core.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { constructCoreClass } from '@tanstack/devtools-utils/solid'
33
export interface PacerDevtoolsInit {}
44

55
const [PacerDevtoolsCore, PacerDevtoolsCoreNoOp] = constructCoreClass(
6-
() => import('./PacerDevtools'),
6+
() => import('./components'),
77
)
88

99
export { PacerDevtoolsCore, PacerDevtoolsCoreNoOp }

0 commit comments

Comments
 (0)