Skip to content

Commit d4089bf

Browse files
authored
Merge pull request #189 from hkawase/fix/hide-unwrapped-line-scrollbars
fix: hide per-line scrollbars of unwrapped code blocks in editing mode
2 parents 6945766 + ccbce24 commit d4089bf

2 files changed

Lines changed: 5 additions & 0 deletions

File tree

‎src/css/code-block.scss‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,9 @@
165165
overflow-wrap: normal !important;
166166
overflow-x: auto;
167167
overscroll-behavior-x: contain;
168+
169+
/* ::-webkit-scrollbar is ignored when scrollbar-color/width is set (Obsidian sets it on body) */
170+
scrollbar-width: none;
168171
white-space: pre !important;
169172
word-wrap: normal;
170173

‎styles.css‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1481,6 +1481,8 @@ pre.codeblock-customizer-pre.codeblock-customizer-codeblock-semi-collapsed .code
14811481
overflow-wrap: normal !important;
14821482
overflow-x: auto;
14831483
overscroll-behavior-x: contain;
1484+
/* ::-webkit-scrollbar is ignored when scrollbar-color/width is set (Obsidian sets it on body) */
1485+
scrollbar-width: none;
14841486
white-space: pre !important;
14851487
word-wrap: normal;
14861488
}

0 commit comments

Comments
 (0)