sacrifice dead goats to make gemini-scrollbars work on firefox 42 and chrome 48 and later. the problem is that flexbox interacts badly with gemini-scrollbars, as gemini looks at the offsetWidth of the container in order to make the width of its enclosed scrollable view = width+scrollbarwidth. The problem is that flexbox then sees that the scrollable view has expanded, and unhelpfully flexes the container to fit it. This fixes the problem by providing more explicit widths for the containers to stop them flexing. I'm not sure I want to know why we don't also see the same problem with heights.

This commit is contained in:
Matthew Hodgson 2015-11-13 00:46:50 +00:00
parent e0efb6862e
commit caa2fd97d1
2 changed files with 14 additions and 2 deletions

View File

@ -107,12 +107,14 @@ limitations under the License.
width: 100%; width: 100%;
/* specify width and margin in here rather than the wrapper otherwise gemini-scrollbars gets confused */
max-width: 960px;
margin: auto;
overflow-y: auto; overflow-y: auto;
} }
.mx_RoomView_messageListWrapper { .mx_RoomView_messageListWrapper {
max-width: 960px;
margin: auto;
} }
.mx_RoomView_MessageList { .mx_RoomView_MessageList {

View File

@ -71,8 +71,14 @@ limitations under the License.
background-color: #eaf5f0; background-color: #eaf5f0;
/*
We can't use flex here as gemini-scrollbars chokes on the width calculation (on FF 42 and Chrome 48)
and you end up with double-scrollbars and an ever-increasing width.
-webkit-flex: 0 0 210px; -webkit-flex: 0 0 210px;
flex: 0 0 210px; flex: 0 0 210px;
*/
width: 210px;
} }
.mx_MatrixChat .mx_LeftPanel.collapsed { .mx_MatrixChat .mx_LeftPanel.collapsed {
@ -117,8 +123,12 @@ limitations under the License.
-webkit-order: 3; -webkit-order: 3;
order: 3; order: 3;
/* Similarly, specify width explicitly otherwise gemini-scrollbars gets confused
-webkit-flex: 0 0 235px; -webkit-flex: 0 0 235px;
flex: 0 0 235px; flex: 0 0 235px;
*/
width: 235px;
} }
.mx_MatrixChat .mx_RightPanel.collapsed { .mx_MatrixChat .mx_RightPanel.collapsed {