jupyter / jupyter/notebook

Unexpected line height when using inline code formatting and indented bulleted lists

Open
#3,069 4 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

I'm seeing some strange behavior when attempting to render inline code (like `this`) in an indented bulleted list. Essentially, I'm getting some extra space between two bullets when (1) bullet *n* has inline code and (2) when bullet *n+1* is indented from bullet *n*.

**Input**:
![code-indented-edit](https://user-images.githubusercontent.com/9792532/33105485-2a2e6ce6-cee2-11e7-9f9a-33244c3547e0.png)
**Rendered**:
![code-indented-rendered](https://user-images.githubusercontent.com/9792532/33105486-2a46c296-cee2-11e7-88aa-41f9fbf0ccd9.png)

I don't see this when:
- bullet *n* has inline code but bullet *n+1* is not indented;
- **Input**:
- ![code-nonindented-edit](https://user-images.githubusercontent.com/9792532/33105487-2a75e1de-cee2-11e7-8ef3-99658d699516.png)
- **Rendered**:
- ![code-nonindented-rendered](https://user-images.githubusercontent.com/9792532/33105491-2aa84872-cee2-11e7-9a22-5e17c9781199.png)
- bullet *n* has no inline code but bullet *n+1* is indented; or
- **Input**:
- ![text-indented-edit](https://user-images.githubusercontent.com/9792532/33105493-2cd041f4-cee2-11e7-93ac-9c2ddc4d3890.png)
- **Rendered**:
- ![text-indented-rendered](https://user-images.githubusercontent.com/9792532/33105494-2ced704e-cee2-11e7-90c5-50100255ddff.png)
- bullet *n* has no inline code and bullet *n+1* not indented.
- **Input**:
- ![text-nonindented-edit](https://user-images.githubusercontent.com/9792532/33105495-2d05a204-cee2-11e7-8860-beda7fbccda5.png)
- **Rendered**:
- ![text-nonindented-rendered](https://user-images.githubusercontent.com/9792532/33105496-2d2bff62-cee2-11e7-828b-55524748d82a.png)

Any recommendations on how to handle this would be greatly appreciated!

**Update**: I'm seeing this behavior in lists with a range of other formatting to bullet *n* when bullet *n+1* is indented (e.g., adding links, italicized font).

Contributor guide

Open the contributing guide

Research direction

No source file or test is named. Reproduce the four list cases in a Jupyter Notebook Markdown cell, comparing inline formatting with indented and non-indented bullets; done means the extra vertical space is absent and the affected formatting combinations render consistently.

Written by the indexing model from the issue text.

Assessment

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

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.