]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blame - client/src/app/header/search-typeahead.component.scss
Fix query string parsing
[github/Chocobozzz/PeerTube.git] / client / src / app / header / search-typeahead.component.scss
CommitLineData
f409f0c3 1@import '_mixins';
9677fca7
RK
2@import '_variables';
3@import '_bootstrap-variables';
4@import '~bootstrap/scss/mixins/_breakpoints';
f409f0c3 5
9b8a7aa8
RK
6#search-video {
7 @include peertube-input-text($search-input-width);
8 padding-left: 10px;
9 padding-right: 40px; // For the search icon
10 font-size: 14px;
11
12 &::placeholder {
e66883b3 13 color: pvar(--inputPlaceholderColor);
9b8a7aa8
RK
14 }
15}
16
17.icon.icon-search {
18 @include icon(25px);
19 height: 21px;
20
e66883b3 21 background-color: pvar(--mainForegroundColor);
9b8a7aa8
RK
22 mask: url('../../assets/images/header/search.svg') no-repeat 50% 50%;
23
24 // yolo
25 position: absolute;
26 margin-left: -35px;
27 margin-top: 5px;
28}
29
f409f0c3
RK
30.jump-to-suggestions {
31 top: 100%;
32 left: 0;
555fdc8c 33 z-index: z(typeahead);
f409f0c3
RK
34 width: 100%;
35}
36
6af662a5 37#typeahead-help,
f409f0c3 38#typeahead-instructions,
5fb2e288 39li.suggestion {
e66883b3 40 border: 1px solid pvar(--mainBackgroundColor);
e66883b3 41 background: pvar(--mainBackgroundColor);
f409f0c3
RK
42 transition: .3s ease;
43 transition-property: box-shadow;
71489890 44 cursor: pointer;
6567e5a7
RK
45
46 // soft border-radius for the last suggestion and the link inside
47 &:last-of-type {
48 &, & ::ng-deep a {
49 border-bottom-right-radius: 3px;
50 border-bottom-left-radius: 3px;
51 }
52 }
f409f0c3
RK
53}
54
6af662a5 55#typeahead-help,
f409f0c3
RK
56#typeahead-instructions {
57 margin-top: 10px;
58 width: 100%;
59 padding: .5rem 1rem;
6af662a5 60 white-space: normal;
f409f0c3
RK
61
62 ul {
63 list-style: none;
64 padding: 0;
65 margin-bottom: .5rem;
66
67 em {
68 font-weight: 600;
69 margin-right: 0.2rem;
70 font-style: normal;
71 }
72 }
73}
74
75#typeahead-container {
9b8a7aa8 76 input {
e66883b3 77 border: 1px solid pvar(--mainBackgroundColor) !important;
f409f0c3
RK
78 box-shadow: rgba(0, 0, 0, 0.1) 0px 1px 20px 0px;
79 flex-grow: 1;
80 transition: box-shadow .3s ease, width .2s ease;
81 }
82
9677fca7 83 @media screen and (min-width: $mobile-view) {
52cc0d54
RK
84 margin-left: 10px;
85 }
86
9677fca7 87 @media screen and (max-width: $small-view) {
52cc0d54
RK
88 flex: 1;
89
9b8a7aa8 90 input {
52cc0d54
RK
91 width: unset;
92 }
93 }
94
9b8a7aa8 95 span {
f409f0c3
RK
96 right: 10px;
97 }
98
99 & > div:last-child {
5fb2e288 100 // we have to switch the display and not the opacity,
f409f0c3
RK
101 // to avoid clashing with the rest of the interface.
102 display: none;
103 }
104
105 &:focus,
106 ::ng-deep &:focus-within {
107 & > div:last-child {
9677fca7 108 @media screen and (min-width: $mobile-view) {
52cc0d54
RK
109 display: initial !important;
110 }
5fb2e288 111
6af662a5 112 #typeahead-help,
f409f0c3 113 #typeahead-instructions,
5fb2e288 114 li.suggestion {
f409f0c3
RK
115 box-shadow: rgba(0, 0, 0, 0.2) 0px 10px 20px -5px;
116 }
117 }
118
119 ::ng-deep input {
120 box-shadow: rgba(0, 0, 0, 0.2) 0px 1px 20px 0px;
121 border-end-start-radius: 0;
122 border-end-end-radius: 0;
123
9677fca7 124 @include media-breakpoint-up(lg) {
f409f0c3
RK
125 width: 500px;
126 }
127 }
128 }
129}
130
f409f0c3
RK
131.glyphicon {
132 top: 3px;
133}
134
135.advanced-search-status {
6af662a5
RK
136 height: max-content;
137 cursor: default;
138
139 &.c-help {
140 cursor: help;
141 }
f409f0c3
RK
142}
143
144.small-title {
145 @include in-content-small-title;
146
147 margin-bottom: .5rem;
148}
149
6af662a5
RK
150::ng-deep my-suggestion {
151 width: 100%;
f409f0c3 152}