File tree Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -131,8 +131,20 @@ class Sidebar {
131
131
} )
132
132
} else if ( breakpoint ) {
133
133
this . _addClassName ( this . _getBreakpointClassName ( breakpoint ) )
134
+
135
+ if ( this . _isOverlaid ( ) ) {
136
+ EventHandler . one ( this . _element , TRANSITION_END , ( ) => {
137
+ this . _addClickOutListener ( )
138
+ } )
139
+ }
134
140
} else {
135
141
this . _addClassName ( this . _firstBreakpointClassName ( ) )
142
+
143
+ if ( this . _isOverlaid ( ) ) {
144
+ EventHandler . one ( this . _element , TRANSITION_END , ( ) => {
145
+ this . _addClickOutListener ( )
146
+ } )
147
+ }
136
148
}
137
149
138
150
const complete = ( ) => {
@@ -154,8 +166,14 @@ class Sidebar {
154
166
this . _removeClickOutListener ( )
155
167
} else if ( breakpoint ) {
156
168
this . _element . classList . remove ( this . _getBreakpointClassName ( breakpoint ) )
169
+ if ( this . _isOverlaid ( ) ) {
170
+ this . _removeClickOutListener ( )
171
+ }
157
172
} else {
158
173
this . _element . classList . remove ( this . _firstBreakpointClassName ( ) )
174
+ if ( this . _isOverlaid ( ) ) {
175
+ this . _removeClickOutListener ( )
176
+ }
159
177
}
160
178
161
179
const complete = ( ) => {
You can’t perform that action at this time.
0 commit comments