File tree Expand file tree Collapse file tree 1 file changed +11
-14
lines changed
Expand file tree Collapse file tree 1 file changed +11
-14
lines changed Original file line number Diff line number Diff line change @@ -153,33 +153,31 @@ body {
153153 width : 3rem ;
154154 margin-left : auto;
155155 padding : 0 ;
156+ display : flex;
157+ flex-direction : column;
158+ align-items : center;
159+ justify-content : center;
156160}
157161
158162.navbar-burger span {
159163 background : var (--navbar-font-color );
160- display : block;
161- height : 1px ;
162- left : 50% ;
163- margin-left : -7px ;
164- position : absolute;
165- top : 50% ;
164+ height : 1.5px ;
166165 width : 1rem ;
167166}
168167
169- .navbar-burger span : nth-child ( 1 ) {
170- margin-top : -6 px ;
168+ .navbar-burger : not (. is-active ) span {
169+ transition : transform ease-out 0.25 s , opacity 0 s 0.25 s , margin-top ease-out 0.25 s 0.25 s ;
171170}
172171
173- .navbar-burger span : nth-child ( 2 ) {
174- margin-top : -1 px ;
172+ .navbar-burger span + span {
173+ margin-top : 0.25 rem ;
175174}
176175
177- .navbar-burger span : nth-child ( 3 ) {
178- margin-top : 4 px ;
176+ .navbar-burger . is-active span + span {
177+ margin-top : -1.5 px ;
179178}
180179
181180.navbar-burger .is-active span : nth-child (1 ) {
182- margin-left : -5px ;
183181 transform : rotate (45deg );
184182}
185183
@@ -188,7 +186,6 @@ body {
188186}
189187
190188.navbar-burger .is-active span : nth-child (3 ) {
191- margin-left : -5px ;
192189 transform : rotate (-45deg );
193190}
194191
You can’t perform that action at this time.
0 commit comments