Denis Mamaev
2 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with
2 additions and
1 deletions
-
src/Fancybox/Fancybox.js
-
src/Fancybox/scss/base.scss
|
|
@ -825,7 +825,7 @@ class Fancybox extends Base { |
|
|
|
|
|
|
|
$style.id = id; |
|
|
|
$style.type = "text/css"; |
|
|
|
$style.innerHTML = `.compensate-for-scrollbar {padding-right: ${scrollbarWidth}px;}`; |
|
|
|
$style.innerHTML = `.compensate-for-scrollbar {--fancybox-scrollbar-compensate: ${scrollbarWidth}px;}`; |
|
|
|
|
|
|
|
document.getElementsByTagName("head")[0].appendChild($style); |
|
|
|
|
|
|
|
|
|
@ -5,6 +5,7 @@ html.with-fancybox { |
|
|
|
body.compensate-for-scrollbar { |
|
|
|
overflow: hidden !important; |
|
|
|
touch-action: none; |
|
|
|
padding-right: var(--fancybox-scrollbar-compensate, 0); |
|
|
|
} |
|
|
|
|
|
|
|
.fancybox__container { |
|
|
|