Skip to content

Commit

Permalink
fixing the size of <li> elements (#4)
Browse files Browse the repository at this point in the history
* extend examples/README to test tables

* tentative fix for <li> elements that are too small
  • Loading branch information
parmentelat authored Jun 30, 2022
1 parent e774243 commit 03071d4
Show file tree
Hide file tree
Showing 2 changed files with 73 additions and 3 deletions.
75 changes: 72 additions & 3 deletions examples/README.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,9 @@
}
},
"source": [
"You're in a browser, so remember that you can always use smaller / larger fonts with keyboard shortcuts like `Alt +` and `Alt -` or similar (it could be `Ctrl` instead of `Alt` depending on the platform you are on)."
"You're in a browser, so remember that you can always use smaller / larger fonts with keyboard shortcuts like `Alt +` and `Alt -` or similar (it could be `Ctrl` instead of `Alt` depending on the platform you are on).\n",
"\n",
"<div style=\"font-size: 50%\"> ideally, the following 2 cells are shown side-by-side, at least that was the case with the old-school classic notebook</div>"
]
},
{
Expand Down Expand Up @@ -422,6 +424,60 @@
" ...\n",
"```"
]
},
{
"cell_type": "markdown",
"metadata": {
"slideshow": {
"slide_type": "slide"
}
},
"source": [
"# tables"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Mostly for checking the rendering of tables, here's a few samples"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"# first using pandas\n",
"\n",
"import seaborn as sns\n",
"titanic = sns.load_dataset('titanic')\n",
"columns = \"survived\tpclass\tsex\tage\tembarked\tclass\twho\tadult_male\".split()\n",
"titanic[columns].head(8)"
]
},
{
"cell_type": "markdown",
"metadata": {
"slideshow": {
"slide_type": "slide"
}
},
"source": [
"and the same but inlined as markdown\n",
"\n",
"| | survived | pclass | sex | age | embarked | class | who | adult_male |\n",
"|---:|-----------:|---------:|:-------|------:|:-----------|:--------|:------|:-------------|\n",
"| 0 | 0 | 3 | male | 22 | S | Third | man | True |\n",
"| 1 | 1 | 1 | female | 38 | C | First | woman | False |\n",
"| 2 | 1 | 3 | female | 26 | S | Third | woman | False |\n",
"| 3 | 1 | 1 | female | 35 | S | First | woman | False |\n",
"| 4 | 0 | 3 | male | 35 | S | Third | man | True |\n",
"| 5 | 0 | 3 | male | nan | Q | Third | man | True |\n",
"| 6 | 0 | 1 | male | 54 | S | First | man | True |\n",
"| 7 | 0 | 3 | male | 2 | S | Third | child | False |\n"
]
}
],
"metadata": {
Expand All @@ -430,7 +486,7 @@
"formats": "ipynb"
},
"kernelspec": {
"display_name": "Python 3",
"display_name": "Python 3 (ipykernel)",
"language": "python",
"name": "python3"
},
Expand All @@ -444,11 +500,24 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.7.3"
"version": "3.9.7"
},
"rise": {
"autolaunch": true,
"enable_chalkboard": true
},
"toc": {
"base_numbering": 1,
"nav_menu": {},
"number_sections": true,
"sideBar": true,
"skip_h1_title": false,
"title_cell": "Table of Contents",
"title_sidebar": "Contents",
"toc_cell": false,
"toc_position": {},
"toc_section_display": true,
"toc_window_display": false
}
},
"nbformat": 4,
Expand Down
1 change: 1 addition & 0 deletions packages/application/style/base.css
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,7 @@
}

.rise-enabled .jp-RenderedHTMLCommon p,
.rise-enabled .jp-RenderedHTMLCommon li,
.rise-enabled i {
font-size: 2.25rem;
}
Expand Down

0 comments on commit 03071d4

Please sign in to comment.