@sanity/ui 3.0.0-static.13 → 3.0.0-static.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_chunks-cjs/_visual-editing.js +101 -106
- package/dist/_chunks-cjs/_visual-editing.js.map +1 -1
- package/dist/_chunks-es/_visual-editing.mjs +101 -106
- package/dist/_chunks-es/_visual-editing.mjs.map +1 -1
- package/dist/cli.js +1 -1
- package/dist/css.js.map +1 -1
- package/dist/css.mjs.map +1 -1
- package/package.json +1 -1
- package/src/css/aspects/margin/margin.style.ts +0 -3
- package/src/ui/primitives/popover/popover.tsx +7 -6
- package/src/ui/primitives/popover/{popoverCard.tsx → popoverLayer.tsx} +14 -28
- package/src/ui/primitives/tooltip/tooltip.tsx +21 -24
- package/src/ui/primitives/tooltip/{tooltipCard.tsx → tooltipLayer.tsx} +14 -27
- package/src/css/aspects/height/rules.ts +0 -7
- package/src/css/aspects/width/rules.ts +0 -8
- package/src/css/components/menu/rules.ts +0 -15
- package/src/css/primitives/avatar/rules.ts +0 -176
- package/src/css/primitives/button/rules.ts +0 -302
- package/src/css/primitives/checkbox/rules.ts +0 -152
- package/src/css/primitives/code/rules.ts +0 -96
- package/src/css/primitives/container/rules.ts +0 -8
- package/src/css/primitives/heading/rules.ts +0 -155
- package/src/css/primitives/kbd/rules.ts +0 -20
- package/src/css/primitives/label/rules.ts +0 -137
- package/src/css/primitives/radio/rules.ts +0 -121
- package/src/css/primitives/select/rules.ts +0 -22
- package/src/css/primitives/switch/rules.ts +0 -340
- package/src/css/primitives/text/rules.ts +0 -164
- package/src/css/primitives/textArea/rules.ts +0 -7
- package/src/css/primitives/textInput/rules.ts +0 -224
- package/src/css/primitives/tooltip/rules.ts +0 -19
|
@@ -1,155 +0,0 @@
|
|
|
1
|
-
import {responsiveRules} from '../../responsiveRules'
|
|
2
|
-
import {Rules} from '../../types'
|
|
3
|
-
|
|
4
|
-
export const headingRules: Rules = {
|
|
5
|
-
'heading': {
|
|
6
|
-
'--font-weight-regular': `var(--font-heading-weight-regular)`,
|
|
7
|
-
'--font-weight-medium': `var(--font-heading-weight-medium)`,
|
|
8
|
-
'--font-weight-semibold': `var(--font-heading-weight-semibold)`,
|
|
9
|
-
'--font-weight-bold': `var(--font-heading-weight-bold)`,
|
|
10
|
-
|
|
11
|
-
'--font-family': `var(--font-heading-family)`,
|
|
12
|
-
'--font-feature-settings': `var(--font-heading-feature-settings)`,
|
|
13
|
-
|
|
14
|
-
'color': 'var(--color-fg)',
|
|
15
|
-
|
|
16
|
-
'@nest': {
|
|
17
|
-
'& a': {
|
|
18
|
-
color: 'var(--color-link-fg)',
|
|
19
|
-
textDecoration: 'none',
|
|
20
|
-
},
|
|
21
|
-
},
|
|
22
|
-
},
|
|
23
|
-
|
|
24
|
-
// 'heading-accent': {
|
|
25
|
-
// '--color-fg': 'var(--color-accent-fg)',
|
|
26
|
-
// },
|
|
27
|
-
|
|
28
|
-
'heading-muted': {
|
|
29
|
-
'--color-fg': 'var(--color-tinted-default-fg-4)',
|
|
30
|
-
},
|
|
31
|
-
|
|
32
|
-
...responsiveRules('heading-0', {
|
|
33
|
-
'--font-size': 'var(--font-heading-0-size)',
|
|
34
|
-
'--font-line-height': 'var(--font-heading-0-line-height)',
|
|
35
|
-
'--font-letter-spacing': 'var(--font-heading-0-letter-spacing)',
|
|
36
|
-
'--font-icon-size': 'var(--font-heading-0-icon-size)',
|
|
37
|
-
'--font-ascender-height': 'var(--font-heading-0-ascender-height)',
|
|
38
|
-
'--font-descender-height': 'var(--font-heading-0-descender-height)',
|
|
39
|
-
// '--font-cap-height': 'var(--font-heading-0-cap-height)',
|
|
40
|
-
}),
|
|
41
|
-
|
|
42
|
-
...responsiveRules('heading-1', {
|
|
43
|
-
'--font-size': 'var(--font-heading-1-size)',
|
|
44
|
-
'--font-line-height': 'var(--font-heading-1-line-height)',
|
|
45
|
-
'--font-letter-spacing': 'var(--font-heading-1-letter-spacing)',
|
|
46
|
-
'--font-icon-size': 'var(--font-heading-1-icon-size)',
|
|
47
|
-
'--font-ascender-height': 'var(--font-heading-1-ascender-height)',
|
|
48
|
-
'--font-descender-height': 'var(--font-heading-1-descender-height)',
|
|
49
|
-
// '--font-cap-height': 'var(--font-heading-1-cap-height)',
|
|
50
|
-
}),
|
|
51
|
-
|
|
52
|
-
...responsiveRules('heading-2', {
|
|
53
|
-
'--font-size': 'var(--font-heading-2-size)',
|
|
54
|
-
'--font-line-height': 'var(--font-heading-2-line-height)',
|
|
55
|
-
'--font-letter-spacing': 'var(--font-heading-2-letter-spacing)',
|
|
56
|
-
'--font-icon-size': 'var(--font-heading-2-icon-size)',
|
|
57
|
-
'--font-ascender-height': 'var(--font-heading-2-ascender-height)',
|
|
58
|
-
'--font-descender-height': 'var(--font-heading-2-descender-height)',
|
|
59
|
-
// '--font-cap-height': 'var(--font-heading-2-cap-height)',
|
|
60
|
-
}),
|
|
61
|
-
|
|
62
|
-
...responsiveRules('heading-3', {
|
|
63
|
-
'--font-size': 'var(--font-heading-3-size)',
|
|
64
|
-
'--font-line-height': 'var(--font-heading-3-line-height)',
|
|
65
|
-
'--font-letter-spacing': 'var(--font-heading-3-letter-spacing)',
|
|
66
|
-
'--font-icon-size': 'var(--font-heading-3-icon-size)',
|
|
67
|
-
'--font-ascender-height': 'var(--font-heading-3-ascender-height)',
|
|
68
|
-
'--font-descender-height': 'var(--font-heading-3-descender-height)',
|
|
69
|
-
// '--font-cap-height': 'var(--font-heading-3-cap-height)',
|
|
70
|
-
}),
|
|
71
|
-
|
|
72
|
-
...responsiveRules('heading-4', {
|
|
73
|
-
'--font-size': 'var(--font-heading-4-size)',
|
|
74
|
-
'--font-line-height': 'var(--font-heading-4-line-height)',
|
|
75
|
-
'--font-letter-spacing': 'var(--font-heading-4-letter-spacing)',
|
|
76
|
-
'--font-icon-size': 'var(--font-heading-4-icon-size)',
|
|
77
|
-
'--font-ascender-height': 'var(--font-heading-4-ascender-height)',
|
|
78
|
-
'--font-descender-height': 'var(--font-heading-4-descender-height)',
|
|
79
|
-
// '--font-cap-height': 'var(--font-heading-4-cap-height)',
|
|
80
|
-
}),
|
|
81
|
-
|
|
82
|
-
...responsiveRules('heading-5', {
|
|
83
|
-
'--font-size': 'var(--font-heading-5-size)',
|
|
84
|
-
'--font-line-height': 'var(--font-heading-5-line-height)',
|
|
85
|
-
'--font-letter-spacing': 'var(--font-heading-5-letter-spacing)',
|
|
86
|
-
'--font-icon-size': 'var(--font-heading-5-icon-size)',
|
|
87
|
-
'--font-ascender-height': 'var(--font-heading-5-ascender-height)',
|
|
88
|
-
'--font-descender-height': 'var(--font-heading-5-descender-height)',
|
|
89
|
-
// '--font-cap-height': 'var(--font-heading-5-cap-height)',
|
|
90
|
-
}),
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
// import {getTheme_v2} from '@sanity/ui/theme'
|
|
94
|
-
// import {ThemeProps} from '../../_compat'
|
|
95
|
-
// import {css} from '../../lib/styled'
|
|
96
|
-
// import {HeadingStyleProps} from './types'
|
|
97
|
-
|
|
98
|
-
// export function headingBaseStyle(props: HeadingStyleProps & ThemeProps): ReturnType<typeof css> {
|
|
99
|
-
// const {$accent, $muted} = props
|
|
100
|
-
// const {font} = getTheme_v2(props.theme)
|
|
101
|
-
|
|
102
|
-
// return css`
|
|
103
|
-
// ${$accent &&
|
|
104
|
-
// css`
|
|
105
|
-
// color: var(--card-accent-fg-color);
|
|
106
|
-
// `}
|
|
107
|
-
|
|
108
|
-
// ${$muted &&
|
|
109
|
-
// css`
|
|
110
|
-
// color: var(--card-muted-fg-color);
|
|
111
|
-
// `}
|
|
112
|
-
|
|
113
|
-
// & code {
|
|
114
|
-
// font-family: ${font.code.family};
|
|
115
|
-
// border-radius: 1px;
|
|
116
|
-
// }
|
|
117
|
-
|
|
118
|
-
// & a {
|
|
119
|
-
// text-decoration: none;
|
|
120
|
-
// border-radius: 1px;
|
|
121
|
-
// color: var(--card-link-color);
|
|
122
|
-
// outline: none;
|
|
123
|
-
|
|
124
|
-
// @media (hover: hover) {
|
|
125
|
-
// &:hover {
|
|
126
|
-
// text-decoration: underline;
|
|
127
|
-
// }
|
|
128
|
-
// }
|
|
129
|
-
|
|
130
|
-
// &:focus {
|
|
131
|
-
// box-shadow:
|
|
132
|
-
// 0 0 0 1px var(--card-bg-color),
|
|
133
|
-
// 0 0 0 3px var(--card-focus-ring-color);
|
|
134
|
-
// }
|
|
135
|
-
|
|
136
|
-
// &:focus:not(:focus-visible) {
|
|
137
|
-
// box-shadow: none;
|
|
138
|
-
// }
|
|
139
|
-
// }
|
|
140
|
-
|
|
141
|
-
// & strong {
|
|
142
|
-
// font-weight: ${font.heading.weights.bold};
|
|
143
|
-
// }
|
|
144
|
-
|
|
145
|
-
// & svg {
|
|
146
|
-
// /* Certain popular CSS libraries changes the defaults for SVG display */
|
|
147
|
-
// /* Make sure SVGs are rendered as inline elements */
|
|
148
|
-
// display: inline;
|
|
149
|
-
// }
|
|
150
|
-
|
|
151
|
-
// & [data-sanity-icon] {
|
|
152
|
-
// vertical-align: baseline;
|
|
153
|
-
// }
|
|
154
|
-
// `
|
|
155
|
-
// }
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import {Rules} from '../../types'
|
|
2
|
-
|
|
3
|
-
export const kbdRules: Rules = {
|
|
4
|
-
kbd: {
|
|
5
|
-
// '--color-bg': 'var(--color-tinted-default-bg-1)',
|
|
6
|
-
// '--color-border': 'var(--color-tinted-default-border-2)',
|
|
7
|
-
// '--color-fg': 'var(--color-tinted-default-fg-3)',
|
|
8
|
-
|
|
9
|
-
'boxShadow': 'inset 0 0 0 0.5px var(--color-border)',
|
|
10
|
-
'background': 'var(--color-muted-bg)',
|
|
11
|
-
'font': 'inherit',
|
|
12
|
-
'verticalAlign': 'top',
|
|
13
|
-
|
|
14
|
-
'@nest': {
|
|
15
|
-
'&:not([hidden])': {
|
|
16
|
-
display: 'inline-block',
|
|
17
|
-
},
|
|
18
|
-
},
|
|
19
|
-
},
|
|
20
|
-
}
|
|
@@ -1,137 +0,0 @@
|
|
|
1
|
-
import {responsiveRules} from '../../responsiveRules'
|
|
2
|
-
import {Rules} from '../../types'
|
|
3
|
-
|
|
4
|
-
export const labelRules: Rules = {
|
|
5
|
-
'label': {
|
|
6
|
-
'--font-weight-regular': `var(--font-label-weight-regular)`,
|
|
7
|
-
'--font-weight-medium': `var(--font-label-weight-medium)`,
|
|
8
|
-
'--font-weight-semibold': `var(--font-label-weight-semibold)`,
|
|
9
|
-
'--font-weight-bold': `var(--font-label-weight-bold)`,
|
|
10
|
-
|
|
11
|
-
'--font-family': `var(--font-label-family)`,
|
|
12
|
-
'--font-feature-settings': `var(--font-label-feature-settings)`,
|
|
13
|
-
|
|
14
|
-
'color': 'var(--color-fg)',
|
|
15
|
-
'textTransform': 'uppercase',
|
|
16
|
-
|
|
17
|
-
'@nest': {
|
|
18
|
-
'& a': {
|
|
19
|
-
color: 'var(--color-link-fg)',
|
|
20
|
-
textDecoration: 'none',
|
|
21
|
-
},
|
|
22
|
-
},
|
|
23
|
-
},
|
|
24
|
-
|
|
25
|
-
'label-accent': {
|
|
26
|
-
'--color-fg': 'var(--color-accent-fg)',
|
|
27
|
-
},
|
|
28
|
-
|
|
29
|
-
'label-muted': {
|
|
30
|
-
'--color-fg': 'var(--color-muted-fg)',
|
|
31
|
-
},
|
|
32
|
-
|
|
33
|
-
...responsiveRules('label-0', {
|
|
34
|
-
'--font-size': 'var(--font-label-0-size)',
|
|
35
|
-
'--font-line-height': 'var(--font-label-0-line-height)',
|
|
36
|
-
'--font-letter-spacing': 'var(--font-label-0-letter-spacing)',
|
|
37
|
-
'--font-icon-size': 'var(--font-label-0-icon-size)',
|
|
38
|
-
'--font-ascender-height': 'var(--font-label-0-ascender-height)',
|
|
39
|
-
'--font-descender-height': 'var(--font-label-0-descender-height)',
|
|
40
|
-
// '--font-cap-height': 'var(--font-label-0-cap-height)',
|
|
41
|
-
}),
|
|
42
|
-
|
|
43
|
-
...responsiveRules('label-1', {
|
|
44
|
-
'--font-size': 'var(--font-label-1-size)',
|
|
45
|
-
'--font-line-height': 'var(--font-label-1-line-height)',
|
|
46
|
-
'--font-letter-spacing': 'var(--font-label-1-letter-spacing)',
|
|
47
|
-
'--font-icon-size': 'var(--font-label-1-icon-size)',
|
|
48
|
-
'--font-ascender-height': 'var(--font-label-1-ascender-height)',
|
|
49
|
-
'--font-descender-height': 'var(--font-label-1-descender-height)',
|
|
50
|
-
// '--font-cap-height': 'var(--font-label-1-cap-height)',
|
|
51
|
-
}),
|
|
52
|
-
|
|
53
|
-
...responsiveRules('label-2', {
|
|
54
|
-
'--font-size': 'var(--font-label-2-size)',
|
|
55
|
-
'--font-line-height': 'var(--font-label-2-line-height)',
|
|
56
|
-
'--font-letter-spacing': 'var(--font-label-2-letter-spacing)',
|
|
57
|
-
'--font-icon-size': 'var(--font-label-2-icon-size)',
|
|
58
|
-
'--font-ascender-height': 'var(--font-label-2-ascender-height)',
|
|
59
|
-
'--font-descender-height': 'var(--font-label-2-descender-height)',
|
|
60
|
-
// '--font-cap-height': 'var(--font-label-2-cap-height)',
|
|
61
|
-
}),
|
|
62
|
-
|
|
63
|
-
...responsiveRules('label-3', {
|
|
64
|
-
'--font-size': 'var(--font-label-3-size)',
|
|
65
|
-
'--font-line-height': 'var(--font-label-3-line-height)',
|
|
66
|
-
'--font-letter-spacing': 'var(--font-label-3-letter-spacing)',
|
|
67
|
-
'--font-icon-size': 'var(--font-label-3-icon-size)',
|
|
68
|
-
'--font-ascender-height': 'var(--font-label-3-ascender-height)',
|
|
69
|
-
'--font-descender-height': 'var(--font-label-3-descender-height)',
|
|
70
|
-
// '--font-cap-height': 'var(--font-label-3-cap-height)',
|
|
71
|
-
}),
|
|
72
|
-
|
|
73
|
-
...responsiveRules('label-4', {
|
|
74
|
-
'--font-size': 'var(--font-label-4-size)',
|
|
75
|
-
'--font-line-height': 'var(--font-label-4-line-height)',
|
|
76
|
-
'--font-letter-spacing': 'var(--font-label-4-letter-spacing)',
|
|
77
|
-
'--font-icon-size': 'var(--font-label-4-icon-size)',
|
|
78
|
-
'--font-ascender-height': 'var(--font-label-4-ascender-height)',
|
|
79
|
-
'--font-descender-height': 'var(--font-label-4-descender-height)',
|
|
80
|
-
// '--font-cap-height': 'var(--font-label-4-cap-height)',
|
|
81
|
-
}),
|
|
82
|
-
|
|
83
|
-
...responsiveRules('label-5', {
|
|
84
|
-
'--font-size': 'var(--font-label-5-size)',
|
|
85
|
-
'--font-line-height': 'var(--font-label-5-line-height)',
|
|
86
|
-
'--font-letter-spacing': 'var(--font-label-5-letter-spacing)',
|
|
87
|
-
'--font-icon-size': 'var(--font-label-5-icon-size)',
|
|
88
|
-
'--font-ascender-height': 'var(--font-label-5-ascender-height)',
|
|
89
|
-
'--font-descender-height': 'var(--font-label-5-descender-height)',
|
|
90
|
-
// '--font-cap-height': 'var(--font-label-5-cap-height)',
|
|
91
|
-
}),
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
// import {getTheme_v2} from '@sanity/ui/theme'
|
|
95
|
-
// import {ThemeProps} from '../../_compat'
|
|
96
|
-
// import {css} from '../../lib/styled'
|
|
97
|
-
|
|
98
|
-
// export function labelBaseStyle(
|
|
99
|
-
// props: {$accent?: boolean; $muted: boolean} & ThemeProps,
|
|
100
|
-
// ): ReturnType<typeof css> {
|
|
101
|
-
// const {$accent, $muted} = props
|
|
102
|
-
// const {font} = getTheme_v2(props.theme)
|
|
103
|
-
|
|
104
|
-
// return css`
|
|
105
|
-
// text-transform: uppercase;
|
|
106
|
-
|
|
107
|
-
// ${$accent &&
|
|
108
|
-
// css`
|
|
109
|
-
// color: var(--card-accent-fg-color);
|
|
110
|
-
// `}
|
|
111
|
-
|
|
112
|
-
// ${$muted &&
|
|
113
|
-
// css`
|
|
114
|
-
// color: var(--card-muted-fg-color);
|
|
115
|
-
// `}
|
|
116
|
-
|
|
117
|
-
// & code {
|
|
118
|
-
// font-family: ${font.code.family};
|
|
119
|
-
// border-radius: 1px;
|
|
120
|
-
// }
|
|
121
|
-
|
|
122
|
-
// & a {
|
|
123
|
-
// text-decoration: none;
|
|
124
|
-
// border-radius: 1px;
|
|
125
|
-
// }
|
|
126
|
-
|
|
127
|
-
// & svg {
|
|
128
|
-
// /* Certain popular CSS libraries changes the defaults for SVG display */
|
|
129
|
-
// /* Make sure SVGs are rendered as inline elements */
|
|
130
|
-
// display: inline;
|
|
131
|
-
// }
|
|
132
|
-
|
|
133
|
-
// & [data-sanity-icon] {
|
|
134
|
-
// vertical-align: baseline;
|
|
135
|
-
// }
|
|
136
|
-
// `
|
|
137
|
-
// }
|
|
@@ -1,121 +0,0 @@
|
|
|
1
|
-
import {Rules} from '../../types'
|
|
2
|
-
|
|
3
|
-
export const radioRules: Rules = {
|
|
4
|
-
radio: {
|
|
5
|
-
'position': 'relative',
|
|
6
|
-
|
|
7
|
-
'@nest': {
|
|
8
|
-
'&:not([hidden])': {
|
|
9
|
-
display: 'inline-block',
|
|
10
|
-
},
|
|
11
|
-
|
|
12
|
-
'& input': {
|
|
13
|
-
appearance: 'none',
|
|
14
|
-
position: 'absolute',
|
|
15
|
-
top: '0',
|
|
16
|
-
left: '0',
|
|
17
|
-
opacity: '0',
|
|
18
|
-
height: '100%',
|
|
19
|
-
width: '100%',
|
|
20
|
-
outline: 'none',
|
|
21
|
-
zIndex: '1',
|
|
22
|
-
padding: '0',
|
|
23
|
-
margin: '0',
|
|
24
|
-
borderRadius: '9999px',
|
|
25
|
-
border: 'none',
|
|
26
|
-
},
|
|
27
|
-
|
|
28
|
-
/* enabled */
|
|
29
|
-
'& > input + span': {
|
|
30
|
-
'display': 'block',
|
|
31
|
-
'position': 'relative',
|
|
32
|
-
'width': 'var(--input-radio-size)',
|
|
33
|
-
'height': 'var(--input-radio-size)',
|
|
34
|
-
'borderRadius': '9999px',
|
|
35
|
-
'backgroundColor': 'var(--color-input-bg)',
|
|
36
|
-
'boxShadow': 'inset 0 0 0 1px var(--color-input-border)',
|
|
37
|
-
// border-radius: ${rem(input.radio.size / 2)};
|
|
38
|
-
// background: ${color.input.default.enabled.bg};
|
|
39
|
-
// box-shadow: ${focusRingBorderStyle({
|
|
40
|
-
// color: color.input.default.enabled.border,
|
|
41
|
-
// width: input.border.width,
|
|
42
|
-
// })};
|
|
43
|
-
|
|
44
|
-
'--color-input-fg': 'var(--color-tinted-default-fg-0)',
|
|
45
|
-
'--color-input-bg': 'var(--color-tinted-default-bg-0)',
|
|
46
|
-
'--color-input-border': 'var(--color-tinted-default-border-1)',
|
|
47
|
-
},
|
|
48
|
-
|
|
49
|
-
'& > input + span::after': {
|
|
50
|
-
content: '""',
|
|
51
|
-
position: 'absolute',
|
|
52
|
-
top: `calc((var(--input-radio-size) - var(--input-radio-mark-size)) / 2)`,
|
|
53
|
-
left: `calc((var(--input-radio-size) - var(--input-radio-mark-size)) / 2)`,
|
|
54
|
-
width: 'var(--input-radio-mark-size)',
|
|
55
|
-
height: 'var(--input-radio-mark-size)',
|
|
56
|
-
backgroundColor: 'var(--color-input-fg)',
|
|
57
|
-
borderRadius: '9999px',
|
|
58
|
-
opacity: 0,
|
|
59
|
-
},
|
|
60
|
-
|
|
61
|
-
/* hovered */
|
|
62
|
-
'& > input:not(:disabled):hover + span': {
|
|
63
|
-
'--color-input-bg': 'var(--color-tinted-default-bg-1)',
|
|
64
|
-
'--color-input-border': 'var(--color-tinted-default-border-2)',
|
|
65
|
-
},
|
|
66
|
-
|
|
67
|
-
/* focused */
|
|
68
|
-
'& > input:not(:disabled):focus + span': {
|
|
69
|
-
'--color-input-border': 'var(--color-tinted-default-border-2)',
|
|
70
|
-
// box-shadow: ${focusRingStyle({
|
|
71
|
-
// border: {width: input.border.width, color: color.input.default.enabled.border},
|
|
72
|
-
// focusRing: input.radio.focusRing,
|
|
73
|
-
// })};
|
|
74
|
-
},
|
|
75
|
-
|
|
76
|
-
'& > input:not(:disabled):focus:not(:focus-visible) + span': {
|
|
77
|
-
// box-shadow: ${focusRingBorderStyle({
|
|
78
|
-
// color: color.input.default.enabled.border,
|
|
79
|
-
// width: input.border.width,
|
|
80
|
-
// })};
|
|
81
|
-
},
|
|
82
|
-
|
|
83
|
-
'& > input:checked + span::after': {
|
|
84
|
-
opacity: 1,
|
|
85
|
-
},
|
|
86
|
-
|
|
87
|
-
// /* customValidity */
|
|
88
|
-
// &[data-error] + span {
|
|
89
|
-
// background-color: ${color.input.invalid.enabled.border};
|
|
90
|
-
// box-shadow: ${focusRingBorderStyle({
|
|
91
|
-
// width: input.border.width,
|
|
92
|
-
// color: color.input.invalid.enabled.muted.bg,
|
|
93
|
-
// })};
|
|
94
|
-
// &::after {
|
|
95
|
-
// background: ${color.input.invalid.enabled.muted.bg};
|
|
96
|
-
// }
|
|
97
|
-
// }
|
|
98
|
-
|
|
99
|
-
// /* read only */
|
|
100
|
-
// &[data-read-only] + span {
|
|
101
|
-
// box-shadow: 0 0 0 1px ${color.input.default.readOnly.border};
|
|
102
|
-
// background: ${color.input.default.readOnly.bg};
|
|
103
|
-
|
|
104
|
-
// &::after {
|
|
105
|
-
// background: ${color.input.default.readOnly.border};
|
|
106
|
-
// }
|
|
107
|
-
// }
|
|
108
|
-
|
|
109
|
-
// /* disabled */
|
|
110
|
-
// &:not([data-read-only]):disabled + span {
|
|
111
|
-
// box-shadow: 0 0 0 1px ${color.input.default.disabled.border};
|
|
112
|
-
// background: ${color.input.default.disabled.bg};
|
|
113
|
-
|
|
114
|
-
// &::after {
|
|
115
|
-
// background: ${color.input.default.disabled.border};
|
|
116
|
-
// }
|
|
117
|
-
// }
|
|
118
|
-
// `
|
|
119
|
-
},
|
|
120
|
-
},
|
|
121
|
-
}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import {Rules} from '../../types'
|
|
2
|
-
|
|
3
|
-
export const selectRules: Rules = {
|
|
4
|
-
'select': {
|
|
5
|
-
'@nest': {
|
|
6
|
-
'& > select:disabled': {
|
|
7
|
-
opacity: 1,
|
|
8
|
-
},
|
|
9
|
-
},
|
|
10
|
-
},
|
|
11
|
-
|
|
12
|
-
'select-presentation': {
|
|
13
|
-
'@nest': {
|
|
14
|
-
'& > span': {
|
|
15
|
-
// place icon to the right
|
|
16
|
-
position: 'absolute',
|
|
17
|
-
top: 0,
|
|
18
|
-
right: 0,
|
|
19
|
-
},
|
|
20
|
-
},
|
|
21
|
-
},
|
|
22
|
-
}
|