Open History to see the last commit
1import { styled } from './utils'
2β
3export const Panel = styled(
4 'div',
5 (_props, theme) => ({
6 fontSize: 'clamp(12px, 1.5vw, 14px)',
7 fontFamily: `sans-serif`,
8 display: 'flex',
9 backgroundColor: theme.background,
10 color: theme.foreground,
11 }),
12 {
13 '(max-width: 700px)': {
14 flexDirection: 'column',
15 },
16 '(max-width: 600px)': {
17 fontSize: '.9em',
18 // flexDirection: 'column',
19 },
20 },
21)
22β
23Panel.displayName = 'Panel'
24β
25export const ActiveQueryPanel = styled(
26 'div',
27 () => ({
28 flex: '1 1 500px',
29 display: 'flex',
30 flexDirection: 'column',
31 overflow: 'auto',
32 height: '100%',
33 }),
34 {
35 '(max-width: 700px)': (_props, theme) => ({
36 borderTop: `2px solid ${theme.gray}`,
37 }),
38 },
39)
40β
41ActiveQueryPanel.displayName = 'ActiveQueryPanel'
42β
43export const Button = styled('button', (props, theme) => ({
44 appearance: 'none',
45 fontSize: '.9em',
46 fontWeight: 'bold',
47 background: theme.gray,
48 border: '0',
49 borderRadius: '.3em',
50 color: 'white',
51 padding: '.5em',
52 opacity: props.disabled ? '.5' : undefined,
53 cursor: 'pointer',
54}))
55β
56Button.displayName = 'Button'
57β
58export const QueryKeys = styled('span', {
59 display: 'flex',
60 flexWrap: 'wrap',
61 gap: '0.5em',
62 fontSize: '0.9em',
63})
64β
65QueryKeys.displayName = 'QueryKeys'
66β
67export const QueryKey = styled('span', {
68 display: 'inline-flex',
69 alignItems: 'center',
70 padding: '.2em .4em',
71 fontWeight: 'bold',
72 textShadow: '0 0 10px black',
73 borderRadius: '.2em',
74})
75β
76QueryKey.displayName = 'QueryKey'
77β
78export const Code = styled('code', {
79 fontSize: '.9em',
80 color: 'inherit',
81 background: 'inherit',
82})
83β
84Code.displayName = 'Code'
85β
86export const Input = styled('input', (_props, theme) => ({
87 backgroundColor: theme.inputBackgroundColor,
88 border: 0,
89 borderRadius: '.2em',
90 color: theme.inputTextColor,
91 fontSize: '.9em',
92 lineHeight: `1.3`,
93 padding: '.3em .4em',
94}))
95β
96Input.displayName = 'Input'
97β
98export const Select = styled(
99 'select',
100 (_props, theme) => ({
101 display: `inline-block`,
102 fontSize: `.9em`,
103 fontFamily: `sans-serif`,
104 fontWeight: 'normal',
105 lineHeight: `1.3`,
106 padding: `.3em 1.5em .3em .5em`,
107 height: 'auto',
108 border: 0,
109 borderRadius: `.2em`,
110 appearance: `none`,
111 WebkitAppearance: 'none',
112 backgroundColor: theme.inputBackgroundColor,
113 backgroundImage: `url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='100' height='100' fill='%23444444'><polygon points='0,25 100,25 50,75'/></svg>")`,
114 backgroundRepeat: `no-repeat`,
115 backgroundPosition: `right .55em center`,
116 backgroundSize: `.65em auto, 100%`,
117 color: theme.inputTextColor,
118 }),
119 {
120 '(max-width: 500px)': {
121 display: 'none',
122 },
123 },
124)
125β
126Select.displayName = 'Select'