signal-desktop/stylesheets/components/CountryCodeSelect.scss

121 lines
2.4 KiB
SCSS
Raw Normal View History

// Copyright 2024 Signal Messenger, LLC
// SPDX-License-Identifier: AGPL-3.0-only
2024-11-15 23:09:31 +00:00
@use '../mixins';
@use '../variables';
.CountryCodeSelect {
2024-11-15 23:09:31 +00:00
@include mixins.button-reset();
& {
display: flex;
flex-direction: row;
gap: 12px;
align-items: center;
@include mixins.font-body-2;
border: solid 1px transparent;
border-radius: 8px;
height: 28px;
padding-inline: 12px;
width: 100%;
}
2024-11-15 23:09:31 +00:00
@include mixins.light-theme {
background-color: variables.$color-black-alpha-06;
color: variables.$color-gray-90;
}
@include mixins.dark-theme {
background-color: variables.$color-white-alpha-12;
color: variables.$color-gray-05;
}
&__text {
flex-grow: 1;
}
&__arrow {
flex-shrink: 0;
width: 16px;
height: 16px;
2024-11-15 23:09:31 +00:00
@include mixins.light-theme {
@include mixins.color-svg(
'../images/icons/v3/dropdown/dropdown-compact.svg',
2024-11-15 23:09:31 +00:00
variables.$color-black
);
}
2024-11-15 23:09:31 +00:00
@include mixins.dark-theme {
@include mixins.color-svg(
'../images/icons/v3/dropdown/dropdown-compact.svg',
2024-11-15 23:09:31 +00:00
variables.$color-gray-05
);
}
}
&__Modal__body {
2024-02-09 18:36:54 +00:00
padding-inline: 10px;
padding-block: 16px 0;
}
&__Modal__Search__container.module-SearchInput__container {
margin-block: 8px;
2024-02-09 18:36:54 +00:00
margin-inline: 10px;
}
&__table {
flex-grow: 1;
// 90px is the size of the modal title + search field, 89vh max modal height
min-height: calc(min(89vh - 90px, 344px));
max-height: 344px;
overflow-y: scroll;
scrollbar-width: none;
&::-webkit-scrollbar {
display: none;
}
}
&__CountryButton {
2024-11-15 23:09:31 +00:00
@include mixins.button-reset();
& {
@include mixins.font-body-1;
2024-11-15 23:09:31 +00:00
width: 100%;
2024-11-15 23:09:31 +00:00
display: flex;
flex-direction: row;
align-items: center;
2024-11-15 23:09:31 +00:00
height: 40px;
padding-inline: 14px;
border-radius: 8px;
}
2024-11-15 23:09:31 +00:00
@include mixins.mouse-mode {
2024-02-09 18:36:54 +00:00
&:hover {
2024-11-15 23:09:31 +00:00
@include mixins.light-theme {
background-color: variables.$color-black-alpha-06;
}
2024-11-15 23:09:31 +00:00
@include mixins.dark-theme {
background-color: variables.$color-white-alpha-12;
}
}
}
2024-02-09 18:36:54 +00:00
2024-11-15 23:09:31 +00:00
@include mixins.keyboard-mode {
2024-02-09 18:36:54 +00:00
&:focus {
2024-11-15 23:09:31 +00:00
box-shadow: inset 0px 0px 0px 2px variables.$color-ultramarine;
2024-02-09 18:36:54 +00:00
}
}
}
&__CountryButton__name {
flex-grow: 1;
}
&__CountryButton__code {
opacity: 0.5;
}
}