Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
Element
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
CI / CD Analytics
Repository Analytics
Value Stream Analytics
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
林焕东
Element
Commits
7753bd89
Commit
7753bd89
authored
Aug 12, 2017
by
Leopoldthecoder
Committed by
杨奕
Aug 18, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Popup: fix missing padding-right when overflow-y is scroll
parent
018931a7
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
1 deletion
+3
-1
src/utils/popup/index.js
src/utils/popup/index.js
+3
-1
No files found.
src/utils/popup/index.js
View file @
7753bd89
...
...
@@ -2,6 +2,7 @@ import Vue from 'vue';
import
merge
from
'
element-ui/src/utils/merge
'
;
import
PopupManager
from
'
element-ui/src/utils/popup/popup-manager
'
;
import
getScrollBarWidth
from
'
../scrollbar-width
'
;
import
{
getStyle
}
from
'
../dom
'
;
let
idSeed
=
1
;
const
transitions
=
[];
...
...
@@ -198,7 +199,8 @@ export default {
}
scrollBarWidth
=
getScrollBarWidth
();
let
bodyHasOverflow
=
document
.
documentElement
.
clientHeight
<
document
.
body
.
scrollHeight
;
if
(
scrollBarWidth
>
0
&&
bodyHasOverflow
)
{
let
bodyOverflowY
=
getStyle
(
document
.
body
,
'
overflowY
'
);
if
(
scrollBarWidth
>
0
&&
(
bodyHasOverflow
||
bodyOverflowY
===
'
scroll
'
))
{
document
.
body
.
style
.
paddingRight
=
scrollBarWidth
+
'
px
'
;
}
document
.
body
.
style
.
overflow
=
'
hidden
'
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment