From 2bdecc9ac740c7e7e1acfc28b46d0a762da2e320 Mon Sep 17 00:00:00 2001 From: Suguru Hirahara Date: Wed, 23 Mar 2022 22:00:22 +0000 Subject: [PATCH 1/5] Add font-size: inherit to link button Remove redundant font-size settings _FeedbackDialog.scss _GenericFeatureFeedbackDialog.scss _Login.scss _NewRoomIntro.scss _NotificationSettingsTab.scss _PinnedEventTile.scss _PreferencesUserSettingsTab.scss _SpaceCreateMenu.scss _ToastContainer.scss _UserMenu.scss Specify font-size - _ProfileSettings.scss - _SpaceBasicSettings.scss - _SpaceSettingsDialog.scss Signed-off-by: Suguru Hirahara --- res/css/structures/_ToastContainer.scss | 4 ---- res/css/structures/_UserMenu.scss | 1 - res/css/structures/auth/_Login.scss | 3 +-- res/css/views/dialogs/_FeedbackDialog.scss | 4 ---- res/css/views/dialogs/_GenericFeatureFeedbackDialog.scss | 1 - res/css/views/dialogs/_SpaceSettingsDialog.scss | 1 + res/css/views/elements/_AccessibleButton.scss | 1 + res/css/views/rooms/_NewRoomIntro.scss | 4 ---- res/css/views/rooms/_PinnedEventTile.scss | 1 - res/css/views/settings/_ProfileSettings.scss | 1 + .../views/settings/tabs/room/_NotificationSettingsTab.scss | 4 ---- .../settings/tabs/user/_PreferencesUserSettingsTab.scss | 4 ---- res/css/views/spaces/_SpaceBasicSettings.scss | 1 + res/css/views/spaces/_SpaceCreateMenu.scss | 5 ----- 14 files changed, 5 insertions(+), 30 deletions(-) diff --git a/res/css/structures/_ToastContainer.scss b/res/css/structures/_ToastContainer.scss index 5137aed95a5..2609ddff7fb 100644 --- a/res/css/structures/_ToastContainer.scss +++ b/res/css/structures/_ToastContainer.scss @@ -157,10 +157,6 @@ limitations under the License. margin: 4px 0 11px 0; font-size: $font-12px; - .mx_AccessibleButton_kind_link { - font-size: inherit; - } - a { text-decoration: none; } diff --git a/res/css/structures/_UserMenu.scss b/res/css/structures/_UserMenu.scss index 90b825c886e..44941afa901 100644 --- a/res/css/structures/_UserMenu.scss +++ b/res/css/structures/_UserMenu.scss @@ -150,7 +150,6 @@ limitations under the License. .mx_AccessibleButton_kind_link { font-weight: normal; - font-size: inherit; } } } diff --git a/res/css/structures/auth/_Login.scss b/res/css/structures/auth/_Login.scss index 0e6912e4352..638917f1c28 100644 --- a/res/css/structures/auth/_Login.scss +++ b/res/css/structures/auth/_Login.scss @@ -88,13 +88,12 @@ limitations under the License. div.mx_AccessibleButton_kind_link.mx_Login_forgot { display: block; margin: 0 auto; - // style it as a link - font-size: inherit; &.mx_AccessibleButton_disabled { cursor: not-allowed; } } + .mx_Login_spinner { display: flex; justify-content: center; diff --git a/res/css/views/dialogs/_FeedbackDialog.scss b/res/css/views/dialogs/_FeedbackDialog.scss index 588f65eb65c..8d11b83fe11 100644 --- a/res/css/views/dialogs/_FeedbackDialog.scss +++ b/res/css/views/dialogs/_FeedbackDialog.scss @@ -58,10 +58,6 @@ limitations under the License. line-height: $font-15px; } - .mx_AccessibleButton_kind_link { - font-size: inherit; - } - a, .mx_AccessibleButton_kind_link { color: $accent; text-decoration: underline; diff --git a/res/css/views/dialogs/_GenericFeatureFeedbackDialog.scss b/res/css/views/dialogs/_GenericFeatureFeedbackDialog.scss index 3898e097567..be932858445 100644 --- a/res/css/views/dialogs/_GenericFeatureFeedbackDialog.scss +++ b/res/css/views/dialogs/_GenericFeatureFeedbackDialog.scss @@ -23,7 +23,6 @@ limitations under the License. } .mx_AccessibleButton_kind_link { - font-size: inherit; line-height: inherit; } } diff --git a/res/css/views/dialogs/_SpaceSettingsDialog.scss b/res/css/views/dialogs/_SpaceSettingsDialog.scss index 31a544d166f..ead082dba68 100644 --- a/res/css/views/dialogs/_SpaceSettingsDialog.scss +++ b/res/css/views/dialogs/_SpaceSettingsDialog.scss @@ -77,6 +77,7 @@ limitations under the License. .mx_AccessibleButton_hasKind { &.mx_AccessibleButton_kind_link { + font-size: $font-14px; margin: 7px 18px; &.mx_SettingsTab_showAdvanced { diff --git a/res/css/views/elements/_AccessibleButton.scss b/res/css/views/elements/_AccessibleButton.scss index a87aab7af85..cccb352a2cc 100644 --- a/res/css/views/elements/_AccessibleButton.scss +++ b/res/css/views/elements/_AccessibleButton.scss @@ -132,6 +132,7 @@ limitations under the License. &.mx_AccessibleButton_kind_link { color: $accent; + font-size: inherit; padding: 0; } diff --git a/res/css/views/rooms/_NewRoomIntro.scss b/res/css/views/rooms/_NewRoomIntro.scss index e2a792e670b..1b7e298ef6b 100644 --- a/res/css/views/rooms/_NewRoomIntro.scss +++ b/res/css/views/rooms/_NewRoomIntro.scss @@ -23,10 +23,6 @@ limitations under the License. } } - .mx_AccessibleButton_kind_link { - font-size: inherit; - } - .mx_NewRoomIntro_buttons { margin-top: 28px; display: flex; diff --git a/res/css/views/rooms/_PinnedEventTile.scss b/res/css/views/rooms/_PinnedEventTile.scss index 3673ae42e9a..6af3697bfdd 100644 --- a/res/css/views/rooms/_PinnedEventTile.scss +++ b/res/css/views/rooms/_PinnedEventTile.scss @@ -92,7 +92,6 @@ limitations under the License. .mx_AccessibleButton_kind_link { margin-left: 12px; - font-size: inherit; line-height: inherit; } } diff --git a/res/css/views/settings/_ProfileSettings.scss b/res/css/views/settings/_ProfileSettings.scss index f62b45d1e5b..ae77a432e0a 100644 --- a/res/css/views/settings/_ProfileSettings.scss +++ b/res/css/views/settings/_ProfileSettings.scss @@ -61,6 +61,7 @@ limitations under the License. margin-bottom: 28px; > .mx_AccessibleButton_kind_link { + font-size: $font-14px; margin-right: 10px; } } diff --git a/res/css/views/settings/tabs/room/_NotificationSettingsTab.scss b/res/css/views/settings/tabs/room/_NotificationSettingsTab.scss index 3dcd4566a50..036a3a5389f 100644 --- a/res/css/views/settings/tabs/room/_NotificationSettingsTab.scss +++ b/res/css/views/settings/tabs/room/_NotificationSettingsTab.scss @@ -50,10 +50,6 @@ limitations under the License. font-size: $font-12px; line-height: $font-15px; margin-right: 32px; - - .mx_AccessibleButton_kind_link { - font-size: inherit; - } } } diff --git a/res/css/views/settings/tabs/user/_PreferencesUserSettingsTab.scss b/res/css/views/settings/tabs/user/_PreferencesUserSettingsTab.scss index 00691679eee..ea979ac074c 100644 --- a/res/css/views/settings/tabs/user/_PreferencesUserSettingsTab.scss +++ b/res/css/views/settings/tabs/user/_PreferencesUserSettingsTab.scss @@ -32,9 +32,5 @@ limitations under the License. margin-top: 20px; } } - - .mx_AccessibleButton_kind_link { - font-size: inherit; - } } } diff --git a/res/css/views/spaces/_SpaceBasicSettings.scss b/res/css/views/spaces/_SpaceBasicSettings.scss index 976960f90d3..5ed772fa85f 100644 --- a/res/css/views/spaces/_SpaceBasicSettings.scss +++ b/res/css/views/spaces/_SpaceBasicSettings.scss @@ -65,6 +65,7 @@ limitations under the License. display: inline-block; margin: auto 18px; color: #368bd6; + font-size: $font-14px; // See _SpaceSettingsDialog.scss } > .mx_SpaceBasicSettings_avatar_remove { diff --git a/res/css/views/spaces/_SpaceCreateMenu.scss b/res/css/views/spaces/_SpaceCreateMenu.scss index 3151b35c851..c0e4a218399 100644 --- a/res/css/views/spaces/_SpaceCreateMenu.scss +++ b/res/css/views/spaces/_SpaceCreateMenu.scss @@ -93,10 +93,6 @@ $spacePanelWidth: 68px; width: min-content; } - .mx_AccessibleButton_kind_link { - font-size: inherit; - } - .mx_AccessibleButton_disabled { cursor: not-allowed; } @@ -118,7 +114,6 @@ $spacePanelWidth: 68px; .mx_AccessibleButton_kind_link { color: $accent; position: relative; - font-size: inherit; line-height: inherit; } } From 45a6510c482dd7cc4c4c4c25464a36e585d0e97b Mon Sep 17 00:00:00 2001 From: Suguru Hirahara Date: Thu, 24 Mar 2022 12:10:57 +0000 Subject: [PATCH 2/5] Add line-height: inherit to link button Remove redundant setting - _GenericFeatureFeedbackDialog.scss - _PinnedEventTile.scss - _SpaceCreateMenu.scss Signed-off-by: Suguru Hirahara --- res/css/views/dialogs/_GenericFeatureFeedbackDialog.scss | 4 ---- res/css/views/elements/_AccessibleButton.scss | 1 + res/css/views/rooms/_PinnedEventTile.scss | 1 - res/css/views/spaces/_SpaceCreateMenu.scss | 1 - 4 files changed, 1 insertion(+), 6 deletions(-) diff --git a/res/css/views/dialogs/_GenericFeatureFeedbackDialog.scss b/res/css/views/dialogs/_GenericFeatureFeedbackDialog.scss index be932858445..83f93495143 100644 --- a/res/css/views/dialogs/_GenericFeatureFeedbackDialog.scss +++ b/res/css/views/dialogs/_GenericFeatureFeedbackDialog.scss @@ -21,8 +21,4 @@ limitations under the License. line-height: $font-20px; margin-bottom: 24px; } - - .mx_AccessibleButton_kind_link { - line-height: inherit; - } } diff --git a/res/css/views/elements/_AccessibleButton.scss b/res/css/views/elements/_AccessibleButton.scss index cccb352a2cc..ad832008fb3 100644 --- a/res/css/views/elements/_AccessibleButton.scss +++ b/res/css/views/elements/_AccessibleButton.scss @@ -133,6 +133,7 @@ limitations under the License. &.mx_AccessibleButton_kind_link { color: $accent; font-size: inherit; + line-height: inherit; padding: 0; } diff --git a/res/css/views/rooms/_PinnedEventTile.scss b/res/css/views/rooms/_PinnedEventTile.scss index 6af3697bfdd..d31b1cbcda4 100644 --- a/res/css/views/rooms/_PinnedEventTile.scss +++ b/res/css/views/rooms/_PinnedEventTile.scss @@ -92,7 +92,6 @@ limitations under the License. .mx_AccessibleButton_kind_link { margin-left: 12px; - line-height: inherit; } } diff --git a/res/css/views/spaces/_SpaceCreateMenu.scss b/res/css/views/spaces/_SpaceCreateMenu.scss index c0e4a218399..2b24b9a2dcf 100644 --- a/res/css/views/spaces/_SpaceCreateMenu.scss +++ b/res/css/views/spaces/_SpaceCreateMenu.scss @@ -114,6 +114,5 @@ $spacePanelWidth: 68px; .mx_AccessibleButton_kind_link { color: $accent; position: relative; - line-height: inherit; } } From aee226fc7ea0e9bd59f4892040d36af05a247892 Mon Sep 17 00:00:00 2001 From: Suguru Hirahara Date: Fri, 25 Mar 2022 08:53:56 +0000 Subject: [PATCH 3/5] Add font-weight: normal to link button Remove redundant setting - _SpotlightDialog.scss - _UserMenu.scss Signed-off-by: Suguru Hirahara --- res/css/structures/_UserMenu.scss | 4 ---- res/css/views/dialogs/_SpotlightDialog.scss | 1 - res/css/views/elements/_AccessibleButton.scss | 1 + 3 files changed, 1 insertion(+), 5 deletions(-) diff --git a/res/css/structures/_UserMenu.scss b/res/css/structures/_UserMenu.scss index 44941afa901..a88e9eddb90 100644 --- a/res/css/structures/_UserMenu.scss +++ b/res/css/structures/_UserMenu.scss @@ -147,10 +147,6 @@ limitations under the License. margin-top: 8px; } } - - .mx_AccessibleButton_kind_link { - font-weight: normal; - } } } diff --git a/res/css/views/dialogs/_SpotlightDialog.scss b/res/css/views/dialogs/_SpotlightDialog.scss index 3041c860424..9f78d905b52 100644 --- a/res/css/views/dialogs/_SpotlightDialog.scss +++ b/res/css/views/dialogs/_SpotlightDialog.scss @@ -241,7 +241,6 @@ limitations under the License. .mx_SpotlightDialog_recentSearches > h4 > .mx_AccessibleButton_kind_link { padding: 0; float: right; - font-weight: normal; font-size: $font-12px; line-height: $font-15px; color: $secondary-content; diff --git a/res/css/views/elements/_AccessibleButton.scss b/res/css/views/elements/_AccessibleButton.scss index ad832008fb3..a63818c296a 100644 --- a/res/css/views/elements/_AccessibleButton.scss +++ b/res/css/views/elements/_AccessibleButton.scss @@ -133,6 +133,7 @@ limitations under the License. &.mx_AccessibleButton_kind_link { color: $accent; font-size: inherit; + font-weight: normal; line-height: inherit; padding: 0; } From 1742f01f58d8e5208d3662c905a45f41efd85dc8 Mon Sep 17 00:00:00 2001 From: Suguru Hirahara Date: Fri, 25 Mar 2022 09:07:28 +0000 Subject: [PATCH 4/5] Dedupe _link and _link_inline Signed-off-by: Suguru Hirahara --- res/css/views/elements/_AccessibleButton.scss | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/res/css/views/elements/_AccessibleButton.scss b/res/css/views/elements/_AccessibleButton.scss index a63818c296a..0372fb8d869 100644 --- a/res/css/views/elements/_AccessibleButton.scss +++ b/res/css/views/elements/_AccessibleButton.scss @@ -130,17 +130,19 @@ limitations under the License. } } - &.mx_AccessibleButton_kind_link { + &.mx_AccessibleButton_kind_link, + &.mx_AccessibleButton_kind_link_inline { color: $accent; font-size: inherit; font-weight: normal; line-height: inherit; + } + + &.mx_AccessibleButton_kind_link { padding: 0; } &.mx_AccessibleButton_kind_link_inline { - color: $accent; - font-size: inherit; padding: 0 2px; } From 3352084df490f4dd262c4d9b5eb5e5f92f035662 Mon Sep 17 00:00:00 2001 From: Suguru Hirahara Date: Fri, 25 Mar 2022 09:11:28 +0000 Subject: [PATCH 5/5] Set inline to "link_inline" Treat the button as its name indicates. For elements that should not be inlined, "link" should be used. Signed-off-by: Suguru Hirahara --- res/css/views/elements/_AccessibleButton.scss | 1 + 1 file changed, 1 insertion(+) diff --git a/res/css/views/elements/_AccessibleButton.scss b/res/css/views/elements/_AccessibleButton.scss index 0372fb8d869..b2a585decad 100644 --- a/res/css/views/elements/_AccessibleButton.scss +++ b/res/css/views/elements/_AccessibleButton.scss @@ -143,6 +143,7 @@ limitations under the License. } &.mx_AccessibleButton_kind_link_inline { + display: inline; padding: 0 2px; }