Skip to content

Commit ec50455

Browse files
glemaitreogrisel
andcommitted
FIX break inheritance in CSS style to show diagram (scikit-learn#21797)
Co-authored-by: Olivier Grisel <[email protected]>
1 parent cddbc6a commit ec50455

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

sklearn/utils/_estimator_html_repr.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -307,7 +307,12 @@ def _write_estimator_html(
307307
text-align: center;
308308
}
309309
#$id div.sk-container {
310-
display: inline-block;
310+
/* jupyter's `normalize.less` sets `[hidden] { display: none; }`
311+
but bootstrap.min.css set `[hidden] { display: none !important; }`
312+
so we also need the `!important` here to be able to override the
313+
default hidden behavior on the sphinx rendered scikit-learn.org.
314+
See: https://github.com/scikit-learn/scikit-learn/issues/21755 */
315+
display: inline-block !important;
311316
position: relative;
312317
}
313318
#$id div.sk-text-repr-fallback {

0 commit comments

Comments
 (0)