Open History to see the last commit
1import '../styles/index.css'
2import { ThemeContextProvider } from '@tanstack/devtools-ui'
3import { TooltipProvider } from './ui/tooltip'
4import { Shell } from './Shell'
5import type { TanStackDevtoolsPluginProps } from '@tanstack/devtools'
6import type { FormDevtoolsInit } from '../core'
7import type { JSX } from 'solid-js'
8import { FormDevtoolsStoreProvider } from '@/stores/formDevtoolsStore'
9β
10const wrapperStyle: JSX.CSSProperties = {
11 height: '100%',
12 width: '100%',
13 'overflow-y': 'hidden',
14 'overflow-x': 'hidden',
15 position: 'relative',
16}
17β
18type DevtoolsProps = TanStackDevtoolsPluginProps & FormDevtoolsInit
19β
20function FormDevtoolsContent(props: DevtoolsProps) {
21 return (
22 <ThemeContextProvider theme={props.theme}>
23 <TooltipProvider openDelay={0} interactive>
24 <div
25 class="tanstack-form-devtools"
26 data-theme={props.theme}
27 style={wrapperStyle}
28 >
29 <Shell adapterName={props.adapterName} theme={props.theme} />
30 </div>
31 </TooltipProvider>
32 </ThemeContextProvider>
33 )
34}
35β
36export default function App(props: DevtoolsProps) {
37 return (
38 <FormDevtoolsStoreProvider>
39 <FormDevtoolsContent {...props} />
40 </FormDevtoolsStoreProvider>
41 )
42}