jupyter / jupyter/notebook

HTML output conflict with jupyter styling

Open
#4,546 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Jupyter Notebook
Stars
13.3k
Forks
5.8k
Avg merge
6d 11h
Merged PRs (30d)
7

Description

**Bug Description**
When outputting HTML using IPython library, the css affects the styling of Jupyter Notebook IDE itself.

**Code to Reproduce**
```
from IPython.core.display import display, HTML
testHTML = """

div {
border: 2px solid black;
}

"""
display(HTML(testHTML))
```
**Screenshot**
[https://imgur.com/naSsmJE](https://imgur.com/naSsmJE)

**Version Information**
[https://imgur.com/HcE0GSO](https://imgur.com/HcE0GSO)

Contributor guide

Open the contributing guide

Research direction

Start by running the provided display(HTML(testHTML)) reproduction in Jupyter Notebook and inspect how the embedded style reaches the notebook UI. Done means CSS from displayed HTML no longer changes the notebook IDE styling while the displayed HTML keeps its intended styling.

Written by the indexing model from the issue text.

Assessment

Tech stack
html, jupyter-notebook
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.