File tree Expand file tree Collapse file tree 2 files changed +26
-2
lines changed Expand file tree Collapse file tree 2 files changed +26
-2
lines changed Original file line number Diff line number Diff line change 43
43
['label ' => 'Login ' , 'url ' => ['/site/login ' ]]
44
44
) : (
45
45
'<li> '
46
- . Html::beginForm (['/site/logout ' ], 'post ' , [ ' class ' => ' navbar-form ' ] )
46
+ . Html::beginForm (['/site/logout ' ], 'post ' )
47
47
. Html::submitButton (
48
48
'Logout ( ' . Yii::$ app ->user ->identity ->username . ') ' ,
49
- ['class ' => 'btn btn-link ' ]
49
+ ['class ' => 'btn btn-link logout ' ]
50
50
)
51
51
. Html::endForm ()
52
52
. '</li> '
Original file line number Diff line number Diff line change @@ -89,3 +89,27 @@ a.desc:after {
89
89
padding : 10px 20px ;
90
90
margin : 0 0 15px 0 ;
91
91
}
92
+
93
+ /* align the logout "link" (button in form) of the navbar */
94
+ .nav li > form > button .logout {
95
+ padding : 15px ;
96
+ border : none;
97
+ }
98
+
99
+ @media (max-width : 767px ) {
100
+ .nav li > form > button .logout {
101
+ display : block;
102
+ text-align : left;
103
+ width : 100% ;
104
+ padding : 10px 15px ;
105
+ }
106
+ }
107
+
108
+ .nav > li > form > button .logout : focus ,
109
+ .nav > li > form > button .logout : hover {
110
+ text-decoration : none;
111
+ }
112
+
113
+ .nav > li > form > button .logout : focus {
114
+ outline : none;
115
+ }
You can’t perform that action at this time.
0 commit comments