diff --git a/package.json b/package.json
index 2316482f87..f1dec0195c 100644
--- a/package.json
+++ b/package.json
@@ -72,7 +72,6 @@
"flux": "2.1.1",
"focus-visible": "^5.0.2",
"fuse.js": "^2.2.0",
- "gemini-scrollbar": "github:matrix-org/gemini-scrollbar#91e1e566",
"gfm.css": "^1.1.1",
"glob-to-regexp": "^0.4.1",
"highlight.js": "^9.15.8",
@@ -93,7 +92,6 @@
"react-beautiful-dnd": "^4.0.1",
"react-dom": "^16.9.0",
"react-focus-lock": "^2.2.1",
- "react-gemini-scrollbar": "github:matrix-org/react-gemini-scrollbar#9cf17f63b7c0b0ec5f31df27da0f82f7238dc594",
"resize-observer-polyfill": "^1.5.0",
"sanitize-html": "^1.18.4",
"text-encoding-utf-8": "^1.0.1",
diff --git a/res/css/_common.scss b/res/css/_common.scss
index a4ef603242..ad64aced50 100644
--- a/res/css/_common.scss
+++ b/res/css/_common.scss
@@ -207,37 +207,6 @@ input[type=text]:focus, input[type=password]:focus, textarea:focus {
transition: opacity 0.2s ease-in-out;
}
-/* XXX: critical hack to GeminiScrollbar to allow them to work in FF 42 and Chrome 48.
- Stop the scrollbar view from pushing out the container's overall sizing, which causes
- flexbox to adapt to the new size and cause the view to keep growing.
- */
-.gm-scrollbar-container .gm-scroll-view {
- position: absolute;
-}
-
-/* Expand thumbs on hoverover */
-.gm-scrollbar {
- border-radius: 5px !important;
-}
-.gm-scrollbar.-vertical {
- width: 6px;
- transition: width 120ms ease-out !important;
-}
-.gm-scrollbar.-vertical:hover,
-.gm-scrollbar.-vertical:active {
- width: 8px;
- transition: width 120ms ease-out !important;
-}
-.gm-scrollbar.-horizontal {
- height: 6px;
- transition: height 120ms ease-out !important;
-}
-.gm-scrollbar.-horizontal:hover,
-.gm-scrollbar.-horizontal:active {
- height: 8px;
- transition: height 120ms ease-out !important;
-}
-
// These are magic constants which are excluded from tinting, to let themes
// (which only have CSS, unlike skins) tell the app what their non-tinted
// colourscheme is by inspecting the stylesheet DOM.
diff --git a/res/css/_components.scss b/res/css/_components.scss
index 8f05394a48..6890a1ffd1 100644
--- a/res/css/_components.scss
+++ b/res/css/_components.scss
@@ -178,7 +178,6 @@
@import "./views/rooms/_RoomTile.scss";
@import "./views/rooms/_RoomUpgradeWarningBar.scss";
@import "./views/rooms/_SearchBar.scss";
-@import "./views/rooms/_SearchableEntityList.scss";
@import "./views/rooms/_SendMessageComposer.scss";
@import "./views/rooms/_Stickers.scss";
@import "./views/rooms/_TopUnreadMessagesBar.scss";
diff --git a/res/css/structures/_GroupView.scss b/res/css/structures/_GroupView.scss
index 517b8b1922..2575169664 100644
--- a/res/css/structures/_GroupView.scss
+++ b/res/css/structures/_GroupView.scss
@@ -180,10 +180,6 @@ limitations under the License.
line-height: 2em;
}
-.mx_GroupView > .mx_MainSplit {
- flex: 1;
-}
-
.mx_GroupView_body {
flex-grow: 1;
}
@@ -341,8 +337,8 @@ limitations under the License.
display: none;
}
-.mx_GroupView_body .gm-scroll-view > * {
- margin: 11px 50px 0px 68px;
+.mx_GroupView_body .mx_AutoHideScrollbar_offset > * {
+ margin: 11px 50px 50px 68px;
}
.mx_GroupView_groupDesc textarea {
@@ -370,7 +366,7 @@ limitations under the License.
padding: 40px 20px;
}
-.mx_GroupView .mx_MemberInfo .gm-scroll-view > :not(.mx_MemberInfo_avatar) {
+.mx_GroupView .mx_MemberInfo .mx_AutoHideScrollbar_offset > :not(.mx_MemberInfo_avatar) {
padding-left: 16px;
padding-right: 16px;
}
diff --git a/res/css/structures/_MainSplit.scss b/res/css/structures/_MainSplit.scss
index 4d73953cd7..25e1153fce 100644
--- a/res/css/structures/_MainSplit.scss
+++ b/res/css/structures/_MainSplit.scss
@@ -18,6 +18,7 @@ limitations under the License.
display: flex;
flex-direction: row;
min-width: 0;
+ height: 100%;
}
// move hit area 5px to the right so it doesn't overlap with the timeline scrollbar
diff --git a/res/css/structures/_MatrixChat.scss b/res/css/structures/_MatrixChat.scss
index f2ce7e1d5c..c5a5d50068 100644
--- a/res/css/structures/_MatrixChat.scss
+++ b/res/css/structures/_MatrixChat.scss
@@ -76,13 +76,6 @@ limitations under the License.
flex: 1 1 0;
min-width: 0;
- /* Experimental fix for https://github.com/vector-im/vector-web/issues/947
- and https://github.com/vector-im/vector-web/issues/946.
- Empirically this stops the MessagePanel's width exploding outwards when
- gemini is in 'prevented' mode
- */
- overflow-x: auto;
-
/* To fix https://github.com/vector-im/riot-web/issues/3298 where Safari
needed height 100% all the way down to the HomePage. Height does not
have to be auto, empirically.
diff --git a/res/css/structures/_MyGroups.scss b/res/css/structures/_MyGroups.scss
index d25789ab94..36150c33a5 100644
--- a/res/css/structures/_MyGroups.scss
+++ b/res/css/structures/_MyGroups.scss
@@ -67,9 +67,6 @@ limitations under the License.
}
}
-
-
-
.mx_MyGroups_headerCard_header {
font-weight: bold;
margin-bottom: 10px;
@@ -98,6 +95,11 @@ limitations under the License.
display: flex;
flex-direction: column;
+ overflow-y: auto;
+}
+
+.mx_MyGroups_scrollable {
+ overflow-y: inherit;
}
.mx_MyGroups_placeholder {
diff --git a/res/css/structures/_RoomDirectory.scss b/res/css/structures/_RoomDirectory.scss
index 5ae8df7176..f3a7b0e243 100644
--- a/res/css/structures/_RoomDirectory.scss
+++ b/res/css/structures/_RoomDirectory.scss
@@ -1,5 +1,6 @@
/*
Copyright 2015, 2016 OpenMarket Ltd
+Copyright 2020 The Matrix.org Foundation C.I.C.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
@@ -45,9 +46,8 @@ limitations under the License.
}
.mx_RoomDirectory_listheader {
- display: flex;
- margin-top: 12px;
- margin-bottom: 12px;
+ display: block;
+ margin-top: 13px;
}
.mx_RoomDirectory_searchbox {
@@ -64,7 +64,7 @@ limitations under the License.
}
.mx_RoomDirectory_table {
- font-size: 14px;
+ font-size: 12px;
color: $primary-fg-color;
width: 100%;
text-align: left;
@@ -112,6 +112,7 @@ limitations under the License.
.mx_RoomDirectory_name {
display: inline-block;
+ font-size: 18px;
font-weight: 600;
}
@@ -148,8 +149,8 @@ limitations under the License.
padding: 0;
}
-.mx_RoomDirectory p {
- font-size: 14px;
+.mx_RoomDirectory > span {
+ font-size: 15px;
margin-top: 0;
.mx_AccessibleButton {
diff --git a/res/css/structures/_TagPanel.scss b/res/css/structures/_TagPanel.scss
index dddd2e324c..03f5ce230c 100644
--- a/res/css/structures/_TagPanel.scss
+++ b/res/css/structures/_TagPanel.scss
@@ -23,6 +23,7 @@ limitations under the License.
flex-direction: column;
align-items: center;
justify-content: space-between;
+ height: 100%;
}
.mx_TagPanel_items_selected {
@@ -57,6 +58,7 @@ limitations under the License.
.mx_TagPanel .mx_TagPanel_scroller {
flex-grow: 1;
+ width: 100%;
}
.mx_TagPanel .mx_TagPanel_tagTileContainer {
diff --git a/res/css/views/dialogs/_UnknownDeviceDialog.scss b/res/css/views/dialogs/_UnknownDeviceDialog.scss
index 02e0fb1fe5..2b0f8dceca 100644
--- a/res/css/views/dialogs/_UnknownDeviceDialog.scss
+++ b/res/css/views/dialogs/_UnknownDeviceDialog.scss
@@ -14,14 +14,6 @@ See the License for the specific language governing permissions and
limitations under the License.
*/
-// CSS voodoo to support a gemini-scrollbar for the contents of the dialog
-.mx_Dialog_unknownDevice .mx_Dialog {
- // ideally we'd shrink the height to fit when needed, but in practice this
- // is a pain in the ass. plus might as well make the dialog big given how
- // important it is.
- height: 100%;
-}
-
.mx_UnknownDeviceDialog {
height: 100%;
display: flex;
@@ -44,6 +36,7 @@ limitations under the License.
.mx_UnknownDeviceDialog .mx_Dialog_content {
margin-bottom: 24px;
+ overflow-y: scroll;
}
.mx_UnknownDeviceDialog_deviceList > li {
diff --git a/res/css/views/directory/_NetworkDropdown.scss b/res/css/views/directory/_NetworkDropdown.scss
index d402f6c48f..106392f880 100644
--- a/res/css/views/directory/_NetworkDropdown.scss
+++ b/res/css/views/directory/_NetworkDropdown.scss
@@ -1,5 +1,5 @@
/*
-Copyright 2015, 2016 OpenMarket Ltd
+Copyright 2020 The Matrix.org Foundation C.I.C.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
@@ -15,70 +15,149 @@ limitations under the License.
*/
.mx_NetworkDropdown {
+ height: 32px;
position: relative;
-}
+ width: max-content;
+ padding-right: 32px;
+ margin-left: auto;
+ margin-right: 9px;
+ margin-top: 12px;
-.mx_NetworkDropdown_input {
- position: relative;
- border-radius: 3px;
- border: 1px solid $strong-input-border-color;
- font-weight: 300;
- font-size: 13px;
- user-select: none;
-}
-
-.mx_NetworkDropdown_arrow {
- border-color: $primary-fg-color transparent transparent;
- border-style: solid;
- border-width: 5px 5px 0;
- display: block;
- height: 0;
- position: absolute;
- right: 10px;
- top: 16px;
- width: 0;
-}
-
-.mx_NetworkDropdown_networkoption {
- height: 37px;
- line-height: 37px;
- padding-left: 8px;
- padding-right: 8px;
- overflow: hidden;
- white-space: nowrap;
- text-overflow: ellipsis;
-}
-
-.mx_NetworkDropdown_networkoption img {
- margin: 5px;
- width: 25px;
- vertical-align: middle;
-}
-
-input.mx_NetworkDropdown_networkoption, input.mx_NetworkDropdown_networkoption:focus {
- border: 0;
- padding-top: 0;
- padding-bottom: 0;
+ .mx_AccessibleButton {
+ width: max-content;
+ }
}
.mx_NetworkDropdown_menu {
- position: absolute;
- left: -1px;
- right: -1px;
- top: 100%;
- z-index: 2;
+ min-width: 204px;
margin: 0;
- padding: 0px;
- border-radius: 3px;
- border: 1px solid $accent-color;
+ box-sizing: border-box;
+ border-radius: 4px;
+ border: 1px solid $dialog-close-fg-color;
background-color: $primary-bg-color;
}
-.mx_NetworkDropdown_menu .mx_NetworkDropdown_networkoption:hover {
- background-color: $focus-bg-color;
-}
-
.mx_NetworkDropdown_menu_network {
font-weight: bold;
}
+.mx_NetworkDropdown_server {
+ padding: 12px 0;
+ border-bottom: 1px solid $input-darker-fg-color;
+
+ .mx_NetworkDropdown_server_title {
+ padding: 0 10px;
+ font-size: 15px;
+ font-weight: 600;
+ line-height: 20px;
+ margin-bottom: 4px;
+
+ // remove server button
+ .mx_AccessibleButton {
+ position: absolute;
+ display: inline;
+ right: 12px;
+ height: 16px;
+ width: 16px;
+ margin-top: 4px;
+
+ &::after {
+ content: "";
+ position: absolute;
+ width: 16px;
+ height: 16px;
+ mask-repeat: no-repeat;
+ mask-position: center;
+ mask-size: contain;
+ mask-image: url('$(res)/img/feather-customised/x.svg');
+ background-color: $notice-primary-color;
+ }
+ }
+ }
+
+ .mx_NetworkDropdown_server_subtitle {
+ padding: 0 10px;
+ font-size: 10px;
+ line-height: 14px;
+ margin-top: -4px;
+ margin-bottom: 4px;
+ color: $muted-fg-color;
+ }
+
+ .mx_NetworkDropdown_server_network {
+ font-size: 12px;
+ line-height: 16px;
+ padding: 4px 10px;
+ cursor: pointer;
+ position: relative;
+
+ overflow: hidden;
+ white-space: nowrap;
+ text-overflow: ellipsis;
+
+ &[aria-checked=true]::after {
+ content: "";
+ position: absolute;
+ width: 16px;
+ height: 16px;
+ right: 10px;
+ mask-repeat: no-repeat;
+ mask-position: center;
+ mask-size: contain;
+ mask-image: url('$(res)/img/feather-customised/check.svg');
+ background-color: $input-valid-border-color;
+ }
+ }
+}
+
+.mx_NetworkDropdown_server_add,
+.mx_NetworkDropdown_server_network {
+ &:hover {
+ background-color: $header-panel-bg-color;
+ }
+}
+
+.mx_NetworkDropdown_server_add {
+ padding: 16px 10px 16px 32px;
+ position: relative;
+ border-radius: 0 0 4px 4px;
+
+ &::before {
+ content: "";
+ position: absolute;
+ width: 16px;
+ height: 16px;
+ left: 7px;
+ mask-repeat: no-repeat;
+ mask-position: center;
+ mask-size: contain;
+ mask-image: url('$(res)/img/feather-customised/plus.svg');
+ background-color: $muted-fg-color;
+ }
+}
+
+.mx_NetworkDropdown_handle {
+ position: relative;
+
+ &::after {
+ content: "";
+ position: absolute;
+ width: 24px;
+ height: 24px;
+ right: -28px; // - (24 + 4)
+ mask-repeat: no-repeat;
+ mask-position: center;
+ mask-size: contain;
+ mask-image: url('$(res)/img/feather-customised/chevron-down.svg');
+ background-color: $primary-fg-color;
+ }
+
+ .mx_NetworkDropdown_handle_server {
+ color: $muted-fg-color;
+ font-size: 12px;
+ }
+}
+
+.mx_NetworkDropdown_dialog .mx_Dialog {
+ width: 45vw;
+}
diff --git a/res/css/views/elements/_DirectorySearchBox.scss b/res/css/views/elements/_DirectorySearchBox.scss
index ef944f6fa0..75ef3fbabd 100644
--- a/res/css/views/elements/_DirectorySearchBox.scss
+++ b/res/css/views/elements/_DirectorySearchBox.scss
@@ -18,7 +18,6 @@ limitations under the License.
display: flex;
padding-left: 9px;
padding-right: 9px;
- margin: 0 5px 0 0 !important;
}
.mx_DirectorySearchBox_joinButton {
diff --git a/res/css/views/rooms/_SearchableEntityList.scss b/res/css/views/rooms/_SearchableEntityList.scss
deleted file mode 100644
index 37a663123d..0000000000
--- a/res/css/views/rooms/_SearchableEntityList.scss
+++ /dev/null
@@ -1,77 +0,0 @@
-/*
-Copyright 2016 OpenMarket Ltd
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-*/
-
-.mx_SearchableEntityList {
- display: flex;
-
- flex-direction: column;
-}
-
-.mx_SearchableEntityList_query {
- font-family: $font-family;
- border-radius: 3px;
- border: 1px solid $input-border-color;
- padding: 9px;
- color: $primary-fg-color;
- background-color: $primary-bg-color;
- margin-left: 3px;
- font-size: 15px;
- margin-bottom: 8px;
- width: 189px;
-}
-
-.mx_SearchableEntityList_query::-moz-placeholder {
- color: $primary-fg-color;
- opacity: 0.5;
- font-size: 12px;
-}
-
-.mx_SearchableEntityList_query::-webkit-input-placeholder {
- color: $primary-fg-color;
- opacity: 0.5;
- font-size: 12px;
-}
-
-.mx_SearchableEntityList_listWrapper {
- flex: 1;
-
- overflow-y: auto;
-}
-
-.mx_SearchableEntityList_list {
- display: table;
- table-layout: fixed;
- width: 100%;
-}
-
-.mx_SearchableEntityList_list .mx_EntityTile_chevron {
- display: none;
-}
-
-.mx_SearchableEntityList_hrWrapper {
- width: 100%;
- flex: 0 0 auto;
-}
-
-.mx_SearchableEntityList hr {
- height: 1px;
- border: 0px;
- color: $primary-fg-color;
- background-color: $primary-fg-color;
- margin-right: 15px;
- margin-top: 11px;
- margin-bottom: 11px;
-}
diff --git a/res/img/feather-customised/chevron-down.svg b/res/img/feather-customised/chevron-down.svg
new file mode 100644
index 0000000000..bcb185ede7
--- /dev/null
+++ b/res/img/feather-customised/chevron-down.svg
@@ -0,0 +1,3 @@
+
diff --git a/res/themes/dark/css/_dark.scss b/res/themes/dark/css/_dark.scss
index 77360c870a..bfa2272283 100644
--- a/res/themes/dark/css/_dark.scss
+++ b/res/themes/dark/css/_dark.scss
@@ -221,10 +221,6 @@ $user-tile-hover-bg-color: $header-panel-bg-color;
filter: invert(1);
}
-.gm-scrollbar .thumb {
- filter: invert(1);
-}
-
// markdown overrides:
.mx_EventTile_content .markdown-body pre:hover {
border-color: #808080 !important; // inverted due to rules below
diff --git a/src/components/structures/ContextMenu.js b/src/components/structures/ContextMenu.js
index 898991f4f2..b4647a6c30 100644
--- a/src/components/structures/ContextMenu.js
+++ b/src/components/structures/ContextMenu.js
@@ -350,7 +350,7 @@ export const ContextMenuButton = ({ label, isExpanded, children, ...props }) =>
};
ContextMenuButton.propTypes = {
...AccessibleButton.propTypes,
- label: PropTypes.string.isRequired,
+ label: PropTypes.string,
isExpanded: PropTypes.bool.isRequired, // whether or not the context menu is currently open
};
@@ -377,7 +377,6 @@ export const MenuGroup = ({children, label, ...props}) => {
;
};
MenuGroup.propTypes = {
- ...AccessibleButton.propTypes,
label: PropTypes.string.isRequired,
className: PropTypes.string, // optional
};
diff --git a/src/components/structures/EmbeddedPage.js b/src/components/structures/EmbeddedPage.js
index 6d734c3838..f854dc955f 100644
--- a/src/components/structures/EmbeddedPage.js
+++ b/src/components/structures/EmbeddedPage.js
@@ -23,11 +23,11 @@ import PropTypes from 'prop-types';
import request from 'browser-request';
import { _t } from '../../languageHandler';
import sanitizeHtml from 'sanitize-html';
-import * as sdk from '../../index';
import dis from '../../dispatcher';
import {MatrixClientPeg} from '../../MatrixClientPeg';
import classnames from 'classnames';
import MatrixClientContext from "../../contexts/MatrixClientContext";
+import AutoHideScrollbar from "./AutoHideScrollbar";
export default class EmbeddedPage extends React.PureComponent {
static propTypes = {
@@ -117,10 +117,9 @@ export default class EmbeddedPage extends React.PureComponent {
;
if (this.props.scrollbar) {
- const GeminiScrollbarWrapper = sdk.getComponent("elements.GeminiScrollbarWrapper");
- return
{ _t( @@ -93,7 +92,7 @@ export default createReactClass({
{explanation}
+ {explanation}