From 953da1ae2ab2c086737398561675ca970a95ee2d Mon Sep 17 00:00:00 2001 From: Suguru Hirahara Date: Thu, 25 May 2023 04:03:19 +0000 Subject: [PATCH] Remove `_RoleButton.pcss` (#10958) * Remove obsolete style rules These have been obsolete since 3c5c2bef6dbac51ce6e1864056523815ca4c38d9. * Remove _RoleButton.pcss mx_RoleButton_tooltip style rules are used only on NotificationBadge.tsx. * Rename the class --- res/css/_components.pcss | 1 - res/css/views/elements/_RoleButton.pcss | 33 ------------------- res/css/views/rooms/_NotificationBadge.pcss | 7 ++++ .../views/rooms/NotificationBadge.tsx | 2 +- 4 files changed, 8 insertions(+), 35 deletions(-) delete mode 100644 res/css/views/elements/_RoleButton.pcss diff --git a/res/css/_components.pcss b/res/css/_components.pcss index 559b9e51a8..4765904241 100644 --- a/res/css/_components.pcss +++ b/res/css/_components.pcss @@ -196,7 +196,6 @@ @import "./views/elements/_ReplyChain.pcss"; @import "./views/elements/_ResizeHandle.pcss"; @import "./views/elements/_RichText.pcss"; -@import "./views/elements/_RoleButton.pcss"; @import "./views/elements/_RoomAliasField.pcss"; @import "./views/elements/_SSOButtons.pcss"; @import "./views/elements/_SearchWarning.pcss"; diff --git a/res/css/views/elements/_RoleButton.pcss b/res/css/views/elements/_RoleButton.pcss deleted file mode 100644 index 41cd11d7c1..0000000000 --- a/res/css/views/elements/_RoleButton.pcss +++ /dev/null @@ -1,33 +0,0 @@ -/* -Copyright 2017 Vector Creations 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_RoleButton { - margin-left: 4px; - margin-right: 4px; - cursor: pointer; - display: inline-block; -} - -.mx_RoleButton object { - pointer-events: none; -} - -.mx_RoleButton_tooltip { - display: inline-block; - position: relative; - top: -25px; - left: 6px; -} diff --git a/res/css/views/rooms/_NotificationBadge.pcss b/res/css/views/rooms/_NotificationBadge.pcss index 4afa320dd9..6facab61f7 100644 --- a/res/css/views/rooms/_NotificationBadge.pcss +++ b/res/css/views/rooms/_NotificationBadge.pcss @@ -69,3 +69,10 @@ limitations under the License. } } } + +.mx_NotificationBadge_tooltip { + display: inline-block; + position: relative; + top: -25px; + left: 6px; +} diff --git a/src/components/views/rooms/NotificationBadge.tsx b/src/components/views/rooms/NotificationBadge.tsx index d5692b6b39..a9b08ebd7a 100644 --- a/src/components/views/rooms/NotificationBadge.tsx +++ b/src/components/views/rooms/NotificationBadge.tsx @@ -123,7 +123,7 @@ export default class NotificationBadge extends React.PureComponent; + tooltip = ; } return (