File tree Expand file tree Collapse file tree 2 files changed +7
-3
lines changed Expand file tree Collapse file tree 2 files changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -114,12 +114,13 @@ export const PropertyBullet = styled.span`
114
114
` ;
115
115
116
116
export const InnerPropertiesWrap = styled . div `
117
- padding: 1em ;
117
+ padding: ${ ( { theme } ) => theme . schemaView . nestingSpacing } ;
118
118
` ;
119
119
120
120
export const PropertiesTable = styled . table `
121
121
border-collapse: collapse;
122
122
border-radius: 3px;
123
+ font-size: ${ props => props . theme . baseFont . size } ;
123
124
124
125
border-spacing: 0;
125
126
width: 100%;
@@ -140,7 +141,8 @@ export const PropertiesTable = styled.table`
140
141
${ InnerPropertiesWrap }
141
142
${ InnerPropertiesWrap }
142
143
${ InnerPropertiesWrap } {
143
- margin: 1em 0 1em 1em;
144
+ margin: ${ ( { theme } ) => theme . schemaView . nestingSpacing } ;
145
+ margin-right: 0;
144
146
background: #f0f0f0;
145
147
}
146
148
Original file line number Diff line number Diff line change @@ -32,6 +32,7 @@ const defaultTheme: ThemeInterface = {
32
32
typeNameColor : theme => transparentize ( 0.2 , theme . colors . text ) ,
33
33
typeTitleColor : theme => theme . schemaView . typeNameColor ,
34
34
requireLabelColor : theme => theme . colors . error ,
35
+ nestingSpacing : '1em' ,
35
36
} ,
36
37
baseFont : {
37
38
size : '14px' ,
@@ -135,6 +136,7 @@ export interface ResolvedThemeInterface {
135
136
typeNameColor : string ;
136
137
typeTitleColor : string ;
137
138
requireLabelColor : string ;
139
+ nestingSpacing : string ;
138
140
} ;
139
141
baseFont : {
140
142
size : string ;
@@ -174,5 +176,5 @@ export type primitive = string | number | boolean | undefined | null;
174
176
export type AdvancedThemeDeep < T > = T extends primitive
175
177
? T | ( ( theme : ResolvedThemeInterface ) => T )
176
178
: AdvancedThemeObject < T > ;
177
- export type AdvancedThemeObject < T > = { [ P in keyof T ] : AdvancedThemeDeep < T [ P ] > } ;
179
+ export type AdvancedThemeObject < T > = { [ P in keyof T ] ? : AdvancedThemeDeep < T [ P ] > } ;
178
180
export type ThemeInterface = AdvancedThemeObject < ResolvedThemeInterface > ;
You can’t perform that action at this time.
0 commit comments