114 lines
2.9 KiB
Text
114 lines
2.9 KiB
Text
/*
|
|
Copyright 2022 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.
|
|
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_FormattingButtons {
|
|
display: flex;
|
|
justify-content: start;
|
|
|
|
.mx_FormattingButtons_Button {
|
|
--size: 26px;
|
|
position: relative;
|
|
cursor: pointer;
|
|
height: var(--size);
|
|
line-height: var(--size);
|
|
width: auto;
|
|
padding-left: var(--size);
|
|
margin-right: 6px;
|
|
background-color: transparent;
|
|
border: none;
|
|
|
|
&:last-child {
|
|
margin-right: auto;
|
|
}
|
|
|
|
&::before {
|
|
content: '';
|
|
position: absolute;
|
|
top: 7px;
|
|
left: 7px;
|
|
height: 12px;
|
|
width: 12px;
|
|
background-color: $icon-button-color;
|
|
mask-repeat: no-repeat;
|
|
mask-size: contain;
|
|
mask-position: center;
|
|
}
|
|
|
|
&::after {
|
|
content: '';
|
|
position: absolute;
|
|
left: 0;
|
|
top: 0;
|
|
z-index: 0;
|
|
width: var(--size);
|
|
height: var(--size);
|
|
border-radius: 5px;
|
|
}
|
|
|
|
&:hover {
|
|
&::after {
|
|
background: rgba($secondary-content, 0.1);
|
|
}
|
|
|
|
&::before {
|
|
background-color: $secondary-content;
|
|
}
|
|
}
|
|
}
|
|
|
|
.mx_FormattingButtons_active {
|
|
&::after {
|
|
background: rgba($accent, 0.1);
|
|
}
|
|
|
|
&::before {
|
|
background-color: $accent;
|
|
}
|
|
}
|
|
|
|
.mx_FormattingButtons_Button_bold::before {
|
|
mask-image: url('$(res)/img/element-icons/room/composer/bold.svg');
|
|
}
|
|
|
|
.mx_FormattingButtons_Button_italic::before {
|
|
mask-image: url('$(res)/img/element-icons/room/composer/italic.svg');
|
|
}
|
|
|
|
.mx_FormattingButtons_Button_underline::before {
|
|
mask-image: url('$(res)/img/element-icons/room/composer/underline.svg');
|
|
}
|
|
|
|
.mx_FormattingButtons_Button_strike-through::before {
|
|
mask-image: url('$(res)/img/element-icons/room/composer/strike_through.svg');
|
|
}
|
|
}
|
|
|
|
.mx_FormattingButtons_Tooltip {
|
|
padding: 0 2px 0 2px;
|
|
|
|
.mx_FormattingButtons_Tooltip_KeyboardShortcut {
|
|
color: $tertiary-content;
|
|
|
|
kbd {
|
|
margin-top: 2px;
|
|
text-align: center;
|
|
display: inline-block;
|
|
text-transform: capitalize;
|
|
font-size: 12px;
|
|
font-family: Inter, sans-serif;
|
|
}
|
|
}
|
|
}
|