Skip to content

Commit

Permalink
Merge pull request #23 from brichet/fix_style
Browse files Browse the repository at this point in the history
Fix CSS for Jupyterlab>4.1 and Notebook
  • Loading branch information
jtpio authored Jan 14, 2025
2 parents f14b9e5 + 0f71508 commit 5976c33
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 5 deletions.
12 changes: 10 additions & 2 deletions js/jupyterlab-slideshow/style/notebook.css
Original file line number Diff line number Diff line change
Expand Up @@ -57,21 +57,29 @@
background: transparent;
}

.jp-Deck .jp-Notebook.jp-WindowedPanel-outer,
.jp-Deck .jp-Notebook .jp-WindowedPanel-outer,
.jp-Deck .jp-Notebook .jp-WindowedPanel-inner,
body[data-notebook='notebooks'] .jp-Deck .jp-WindowedPanel-window,
body[data-notebook='notebooks'] .jp-Deck .jp-Notebook-cell {
background: transparent;
}

/* Remove shadow around notebook widget for Notebook application */
body[data-jp-deck-mode='presenting'] .jp-Deck .jp-Notebook .jp-WindowedPanel-viewport {
box-shadow: unset;
}

body[data-notebook='notebooks']
.jp-Deck
.jp-Notebook.jp-mod-commandMode
.jp-Cell.jp-mod-active.jp-mod-selected:not(.jp-mod-multiSelected) {
background: transparent !important;
}

.jp-Deck .jp-Notebook.jp-mod-scrollPastEnd::after {
/* Both are required for compatibility with Jupyterlab before and after 4.1.0, after
https://github.com/jupyterlab/jupyterlab/commit/6a86d8f163fe11cf7b1964b1ed54999ee2234c8c#diff-ccf3f53605be6603fd5fd949742f25ea8919c48dcc75322c483ebf9988404 */
.jp-Deck .jp-Notebook.jp-mod-scrollPastEnd::after,
.jp-Deck .jp-Notebook.jp-mod-scrollPastEnd > .jp-WindowedPanel-outer::after {
display: none;
}

Expand Down
6 changes: 3 additions & 3 deletions js/jupyterlab-slideshow/style/shell.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
body[data-jp-deck-mode='presenting'],
body[data-jp-deck-mode='presenting'] .jp-ThemedContainer:has(.jp-Deck),
body[data-jp-deck-mode='presenting'][data-notebook='notebooks'] .jp-WindowedPanel-outer {
background: var(--jp-layout-color0);
body[data-jp-deck-mode='presenting'] .jp-ThemedContainer:has(.jp-Deck) {
/* 'important' is required for Notebook application which add again this rule */
background: var(--jp-layout-color0) !important;
}

body[data-jp-deck-mode='presenting'] #jp-main-content-panel {
Expand Down

0 comments on commit 5976c33

Please sign in to comment.