Add default properties to link buttons and remove redundant settings (#8151)

* 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 <luixxiul@users.noreply.github.com>

* Add line-height: inherit to link button

Remove redundant setting
- _GenericFeatureFeedbackDialog.scss
- _PinnedEventTile.scss
- _SpaceCreateMenu.scss

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Add font-weight: normal to link button

Remove redundant setting
- _SpotlightDialog.scss
- _UserMenu.scss

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Dedupe _link and _link_inline

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* 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 <luixxiul@users.noreply.github.com>
This commit is contained in:
Suguru Hirahara 2022-04-05 17:29:35 +00:00 committed by GitHub
parent 457fc542da
commit 35c49a8cd8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
15 changed files with 13 additions and 44 deletions

View file

@ -157,10 +157,6 @@ limitations under the License.
margin: 4px 0 11px 0; margin: 4px 0 11px 0;
font-size: $font-12px; font-size: $font-12px;
.mx_AccessibleButton_kind_link {
font-size: inherit;
}
a { a {
text-decoration: none; text-decoration: none;
} }

View file

@ -147,11 +147,6 @@ limitations under the License.
margin-top: 8px; margin-top: 8px;
} }
} }
.mx_AccessibleButton_kind_link {
font-weight: normal;
font-size: inherit;
}
} }
} }

View file

@ -88,13 +88,12 @@ limitations under the License.
div.mx_AccessibleButton_kind_link.mx_Login_forgot { div.mx_AccessibleButton_kind_link.mx_Login_forgot {
display: block; display: block;
margin: 0 auto; margin: 0 auto;
// style it as a link
font-size: inherit;
&.mx_AccessibleButton_disabled { &.mx_AccessibleButton_disabled {
cursor: not-allowed; cursor: not-allowed;
} }
} }
.mx_Login_spinner { .mx_Login_spinner {
display: flex; display: flex;
justify-content: center; justify-content: center;

View file

@ -58,10 +58,6 @@ limitations under the License.
line-height: $font-15px; line-height: $font-15px;
} }
.mx_AccessibleButton_kind_link {
font-size: inherit;
}
a, .mx_AccessibleButton_kind_link { a, .mx_AccessibleButton_kind_link {
color: $accent; color: $accent;
text-decoration: underline; text-decoration: underline;

View file

@ -21,9 +21,4 @@ limitations under the License.
line-height: $font-20px; line-height: $font-20px;
margin-bottom: 24px; margin-bottom: 24px;
} }
.mx_AccessibleButton_kind_link {
font-size: inherit;
line-height: inherit;
}
} }

View file

@ -77,6 +77,7 @@ limitations under the License.
.mx_AccessibleButton_hasKind { .mx_AccessibleButton_hasKind {
&.mx_AccessibleButton_kind_link { &.mx_AccessibleButton_kind_link {
font-size: $font-14px;
margin: 7px 18px; margin: 7px 18px;
&.mx_SettingsTab_showAdvanced { &.mx_SettingsTab_showAdvanced {

View file

@ -241,7 +241,6 @@ limitations under the License.
.mx_SpotlightDialog_recentSearches > h4 > .mx_AccessibleButton_kind_link { .mx_SpotlightDialog_recentSearches > h4 > .mx_AccessibleButton_kind_link {
padding: 0; padding: 0;
float: right; float: right;
font-weight: normal;
font-size: $font-12px; font-size: $font-12px;
line-height: $font-15px; line-height: $font-15px;
color: $secondary-content; color: $secondary-content;

View file

@ -130,14 +130,20 @@ limitations under the License.
} }
} }
&.mx_AccessibleButton_kind_link { &.mx_AccessibleButton_kind_link,
&.mx_AccessibleButton_kind_link_inline {
color: $accent; color: $accent;
font-size: inherit;
font-weight: normal;
line-height: inherit;
}
&.mx_AccessibleButton_kind_link {
padding: 0; padding: 0;
} }
&.mx_AccessibleButton_kind_link_inline { &.mx_AccessibleButton_kind_link_inline {
color: $accent; display: inline;
font-size: inherit;
padding: 0 2px; padding: 0 2px;
} }

View file

@ -23,10 +23,6 @@ limitations under the License.
} }
} }
.mx_AccessibleButton_kind_link {
font-size: inherit;
}
.mx_NewRoomIntro_buttons { .mx_NewRoomIntro_buttons {
margin-top: 28px; margin-top: 28px;
display: flex; display: flex;

View file

@ -92,8 +92,6 @@ limitations under the License.
.mx_AccessibleButton_kind_link { .mx_AccessibleButton_kind_link {
margin-left: 12px; margin-left: 12px;
font-size: inherit;
line-height: inherit;
} }
} }

View file

@ -61,6 +61,7 @@ limitations under the License.
margin-bottom: 28px; margin-bottom: 28px;
> .mx_AccessibleButton_kind_link { > .mx_AccessibleButton_kind_link {
font-size: $font-14px;
margin-right: 10px; margin-right: 10px;
} }
} }

View file

@ -50,10 +50,6 @@ limitations under the License.
font-size: $font-12px; font-size: $font-12px;
line-height: $font-15px; line-height: $font-15px;
margin-right: 32px; margin-right: 32px;
.mx_AccessibleButton_kind_link {
font-size: inherit;
}
} }
} }

View file

@ -32,9 +32,5 @@ limitations under the License.
margin-top: 20px; margin-top: 20px;
} }
} }
.mx_AccessibleButton_kind_link {
font-size: inherit;
}
} }
} }

View file

@ -65,6 +65,7 @@ limitations under the License.
display: inline-block; display: inline-block;
margin: auto 18px; margin: auto 18px;
color: #368bd6; color: #368bd6;
font-size: $font-14px; // See _SpaceSettingsDialog.scss
} }
> .mx_SpaceBasicSettings_avatar_remove { > .mx_SpaceBasicSettings_avatar_remove {

View file

@ -93,10 +93,6 @@ $spacePanelWidth: 68px;
width: min-content; width: min-content;
} }
.mx_AccessibleButton_kind_link {
font-size: inherit;
}
.mx_AccessibleButton_disabled { .mx_AccessibleButton_disabled {
cursor: not-allowed; cursor: not-allowed;
} }
@ -118,7 +114,5 @@ $spacePanelWidth: 68px;
.mx_AccessibleButton_kind_link { .mx_AccessibleButton_kind_link {
color: $accent; color: $accent;
position: relative; position: relative;
font-size: inherit;
line-height: inherit;
} }
} }