signal-desktop/stylesheets/components/SearchInput.scss

85 lines
1.7 KiB
SCSS
Raw Normal View History

2023-01-03 19:55:46 +00:00
// Copyright 2021 Signal Messenger, LLC
2021-05-11 00:50:43 +00:00
// SPDX-License-Identifier: AGPL-3.0-only
.module-SearchInput {
&__container {
2023-04-20 17:03:43 +00:00
margin-inline: 16px;
margin-bottom: 8px;
2022-02-14 17:57:11 +00:00
position: relative;
2021-05-11 00:50:43 +00:00
}
&__icon {
height: 16px;
2023-04-20 17:03:43 +00:00
inset-inline-start: 8px;
2022-02-14 17:57:11 +00:00
pointer-events: none;
2021-05-11 00:50:43 +00:00
position: absolute;
top: 6px;
width: 16px;
2022-02-14 17:57:11 +00:00
@include light-theme {
2023-05-04 18:04:22 +00:00
@include color-svg(
'../images/icons/v3/search/search-compact-light.svg',
$color-gray-45
);
2022-02-14 17:57:11 +00:00
}
@include dark-theme {
2023-05-04 18:04:22 +00:00
@include color-svg(
'../images/icons/v3/search/search-compact-light.svg',
$color-gray-25
);
2022-02-14 17:57:11 +00:00
}
2021-05-11 00:50:43 +00:00
}
2022-02-14 17:57:11 +00:00
&__input {
@include font-body-2;
border: solid 1px transparent;
border-radius: 8px;
height: 28px;
2023-04-20 17:03:43 +00:00
padding-inline: 30px 5px;
2022-02-14 17:57:11 +00:00
width: 100%;
@include light-theme {
background-color: $color-black-alpha-06;
2022-02-14 17:57:11 +00:00
color: $color-gray-90;
&:placeholder {
color: $color-gray-45;
}
}
@include dark-theme {
background-color: $color-white-alpha-12;
color: $color-gray-05;
&:placeholder {
color: $color-gray-25;
}
}
&:focus {
2022-06-15 17:53:08 +00:00
@include keyboard-mode {
border: solid 1px $color-ultramarine;
}
2022-02-14 17:57:11 +00:00
outline: none;
}
&--with-text {
2023-04-20 17:03:43 +00:00
padding-inline-end: 30px;
2022-02-14 17:57:11 +00:00
}
}
&__cancel {
2023-05-04 18:04:22 +00:00
height: 16px;
2022-02-14 17:57:11 +00:00
position: absolute;
2023-04-20 17:03:43 +00:00
inset-inline-end: 8px;
2023-05-04 18:04:22 +00:00
top: 6px;
width: 16px;
2022-02-14 17:57:11 +00:00
@include light-theme {
2023-05-04 18:04:22 +00:00
@include color-svg('../images/icons/v3/x/x-compact.svg', $color-gray-60);
2022-02-14 17:57:11 +00:00
}
@include dark-theme {
2023-05-04 18:04:22 +00:00
@include color-svg('../images/icons/v3/x/x-compact.svg', $color-gray-25);
2022-02-14 17:57:11 +00:00
}
}
2021-05-11 00:50:43 +00:00
}