@@ -14,7 +14,10 @@ See the License for the specific language governing permissions and
1414limitations under the License.
1515*/
1616
17- . mx_RoomHeader {
17+ /* add 20px to the height of the header when editing */
18+ . mx_RoomHeader_editing {
19+ -webit-flex : 0 0 103px ! impor tant;
20+ flex : 0 0 103px ! impor tant;
1821}
1922
2023. mx_RoomHeader_wrapper {
@@ -33,6 +36,10 @@ limitations under the License.
3336 display : flex;
3437}
3538
39+ . mx_RoomHeader_editing . mx_RoomHeader_wrapper {
40+ border-bottom : 1px solid transparent;
41+ }
42+
3643. mx_RoomHeader_leftRow {
3744 margin-left : -2px ;
3845
@@ -47,12 +54,13 @@ limitations under the License.
4754}
4855
4956. mx_RoomHeader_textButton {
50- height : 48 px ;
57+ height : 36 px ;
5158 background-color : # 76cfa6;
52- border-radius : 48 px ;
59+ border-radius : 36 px ;
5360 margin-right : 8px ;
5461 color : # fff;
55- line-height : 48px ;
62+ line-height : 34px ;
63+ margin-top : -2px ;
5664 text-align : center;
5765
5866 -webkit-box-ordinal-group : 2 ;
@@ -69,7 +77,20 @@ limitations under the License.
6977*/
7078 padding-left : 12px ;
7179 padding-right : 12px ;
72- }
80+ }
81+
82+ . mx_RoomHeader_cancelButton {
83+ -webkit-box-ordinal-group : 2 ;
84+ -moz-box-ordinal-group : 2 ;
85+ -ms-flex-order : 2 ;
86+ -webkit-order : 2 ;
87+ order : 2 ;
88+
89+ cursor : pointer;
90+
91+ padding-left : 12px ;
92+ padding-right : 12px ;
93+ }
7394
7495. mx_RoomHeader_rightRow {
7596 margin-top : 4px ;
@@ -84,7 +105,7 @@ limitations under the License.
84105
85106. mx_RoomHeader_info {
86107 display : table-cell;
87- /* height: 48px; */
108+ width : 100 % ;
88109 vertical-align : middle;
89110}
90111
@@ -107,9 +128,9 @@ limitations under the License.
107128}
108129
109130. mx_RoomHeader_name {
110- cursor : pointer;
111131 vertical-align : middle;
112- height : 30px ;
132+ width : 100% ;
133+ height : 31px ;
113134 overflow : hidden;
114135 color : # 454545;
115136 font-weight : bold;
@@ -118,6 +139,7 @@ limitations under the License.
118139 padding-right : 16px ;
119140 /* why isn't text-overflow working? */
120141 text-overflow : ellipsis;
142+ border-bottom : 1px solid transparent;
121143}
122144
123145. mx_RoomHeader_nametext {
@@ -142,11 +164,18 @@ limitations under the License.
142164 pointer-events : none;
143165}
144166
145- . mx_RoomHeader_leftRow : hover . mx_RoomHeader_name {
167+ . mx_RoomHeader_name ,
168+ . mx_RoomHeader_avatar ,
169+ . mx_RoomHeader_avatarPicker ,
170+ . mx_RoomHeader_avatarPicker_edit {
171+ cursor : pointer;
172+ }
173+
174+ . mx_RoomHeader_name : hover div : not ( . mx_RoomHeader_editable ) {
146175 color : # 76cfa6;
147176}
148177
149- . mx_RoomHeader_leftRow : hover . mx_RoomHeader_settingsButton {
178+ . mx_RoomHeader_name : hover . mx_RoomHeader_settingsButton {
150179 visibility : visible;
151180}
152181
@@ -159,24 +188,20 @@ limitations under the License.
159188 visibility : visible;
160189}
161190
162-
163- . mx_RoomHeader_nameEditing {
164- padding-left : 8px ;
165- padding-right : 16px ;
166- margin-top : -5px ;
191+ . mx_RoomHeader_placeholder {
192+ color : # a2a2a2 ! impor tant;
167193}
168194
169- . mx_RoomHeader_name input , . mx_RoomHeader_nameInput {
170- border-radius : 3px ;
171- width : 260px ;
172- border : 1px solid # c7c7c7;
173- font-weight : 300 ;
174- font-size : 13px ;
175- padding : 9px ;
195+ . mx_RoomHeader_editable {
196+ border-bottom : 1px solid # c7c7c7 ! impor tant;
197+ min-width : 70px ;
198+ cursor : text;
176199}
177200
178- . mx_RoomHeader_nameInput {
179- margin-top : 6px ;
201+ . mx_RoomHeader_editable : focus {
202+ border-bottom : 1px solid # 76CFA6 ! impor tant;
203+ outline : none;
204+ box-shadow : none;
180205}
181206
182207. mx_RoomHeader_topic {
@@ -185,10 +210,11 @@ limitations under the License.
185210 max-height : 42px ;
186211 color : # 454545;
187212 font-weight : 300 ;
188- padding -left: 19px ;
189- padding -right: 16px ;
213+ margin -left: 19px ;
214+ margin -right: 16px ;
190215 overflow : hidden;
191216 text-overflow : ellipsis;
217+ border-bottom : 1px solid transparent;
192218}
193219
194220. mx_RoomHeader_avatar {
@@ -198,10 +224,24 @@ limitations under the License.
198224 vertical-align : middle;
199225}
200226
201- . mx_RoomHeader_avatar img {
227+ . mx_RoomHeader_avatar . mx_RoomAvatar {
202228 border-radius : 24px ;
203229}
204230
231+ . mx_RoomHeader_avatarPicker_edit {
232+ position : absolute;
233+ margin-left : 16px ;
234+ margin-top : 4px ;
235+ }
236+
237+ . mx_RoomHeader_avatarPicker_edit > label {
238+ cursor : pointer;
239+ }
240+
241+ . mx_RoomHeader_avatarPicker_edit > input {
242+ display : none;
243+ }
244+
205245. mx_RoomHeader_button {
206246 display : table-cell;
207247 vertical-align : top;
0 commit comments