Skip to content

Commit aff76cf

Browse files
authored
Less vertical whitespace in HTML reprs (#10795)
* Less vertical whitespace in HTML reprs * ensure consistent line-height in google colab
1 parent cbe04e6 commit aff76cf

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

xarray/static/css/style.css

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
1-
/* CSS stylesheet for displaying xarray objects in jupyterlab.
2-
*
3-
*/
1+
/* CSS stylesheet for displaying xarray objects in notebooks */
42

53
:root {
64
--xr-font-color0: var(
@@ -79,6 +77,7 @@ body.vscode-dark {
7977
display: block !important;
8078
min-width: 300px;
8179
max-width: 700px;
80+
line-height: 1.6;
8281
}
8382

8483
.xr-text-repr-fallback {
@@ -121,6 +120,8 @@ body.vscode-dark {
121120
padding-left: 0 !important;
122121
display: grid;
123122
grid-template-columns: 150px auto auto 1fr 0 20px 0 20px;
123+
margin-block-start: 0;
124+
margin-block-end: 0;
124125
}
125126

126127
.xr-section-item {
@@ -131,6 +132,7 @@ body.vscode-dark {
131132
display: inline-block;
132133
opacity: 0;
133134
height: 0;
135+
margin: 0;
134136
}
135137

136138
.xr-section-item input + label {
@@ -189,7 +191,6 @@ body.vscode-dark {
189191
.xr-section-summary,
190192
.xr-section-inline-details {
191193
padding-top: 4px;
192-
padding-bottom: 4px;
193194
}
194195

195196
.xr-section-inline-details {
@@ -199,6 +200,7 @@ body.vscode-dark {
199200
.xr-section-details {
200201
display: none;
201202
grid-column: 1 / -1;
203+
margin-top: 4px;
202204
margin-bottom: 5px;
203205
}
204206

0 commit comments

Comments
 (0)