]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blame - client/src/app/+search/search.component.scss
Square channel avatar consistency
[github/Chocobozzz/PeerTube.git] / client / src / app / +search / search.component.scss
CommitLineData
57c36b27
C
1@import '_variables';
2@import '_mixins';
3
57c36b27 4.search-result {
b34a444e 5 padding: 40px;
57c36b27 6
0b18f4aa
C
7 .results-header {
8 font-size: 16px;
57c36b27
C
9 padding-bottom: 20px;
10 margin-bottom: 30px;
11 border-bottom: 1px solid #DADADA;
12
0b18f4aa
C
13 .first-line {
14 display: flex;
15 flex-direction: row;
16
17 .results-counter {
18 flex-grow: 1;
19
20 .search-value {
21 font-weight: $font-semibold;
22 }
23 }
24
25 .results-filter-button {
b1ee8526 26 cursor: pointer;
0b18f4aa
C
27
28 .icon.icon-filter {
29 @include icon(20px);
30
31 position: relative;
32 top: -1px;
33 margin-right: 5px;
c41c0e28 34 background-image: url('../../assets/images/feather/filter.svg');
0b18f4aa
C
35 }
36 }
37 }
57c36b27
C
38 }
39
40 .entry {
41 display: flex;
42 min-height: 130px;
43 padding-bottom: 20px;
44 margin-bottom: 20px;
45
f37dc0dd 46 &.video-channel {
f37dc0dd 47 img {
e2409062
C
48 $image-size: 130px;
49 $margin-size: ($video-thumbnail-width - $image-size) / 2; // So we have the same width than the video miniature
50
deb8b9cd 51 @include channel-avatar($image-size);
f37dc0dd 52
e2409062 53 margin: 0 ($margin-size + 10) 0 $margin-size;
f37dc0dd
C
54 }
55
56 .video-channel-info {
f37dc0dd
C
57 flex-grow: 1;
58 width: fit-content;
59
60 .video-channel-names {
61 @include disable-default-a-behaviour;
62
63 display: flex;
64 align-items: baseline;
e66883b3 65 color: pvar(--mainForegroundColor);
f37dc0dd
C
66 width: fit-content;
67
68 .video-channel-display-name {
69 font-weight: $font-semibold;
70 font-size: 18px;
71 }
72
73 .video-channel-name {
74 font-size: 14px;
75 color: $grey-actor-name;
76 margin-left: 5px;
77 }
78 }
79 }
80 }
57c36b27
C
81 }
82}
83
8a3183e5
K
84@media screen and (min-width: $small-view) and (max-width: breakpoint(xl)) {
85 .video-channel-info .video-channel-names {
86 flex-direction: column !important;
87
88 .video-channel-name {
89 @include ellipsis; // Ellipsis and max-width on channel-name to not break screen
90
91 max-width: 250px;
92 margin-left: 0 !important;
93 }
94 }
95
96 :host-context(.main-col:not(.expanded)) {
97 // Override the min-width: 500px to not break screen
98 ::ng-deep .video-miniature-information {
99 min-width: 300px !important;
100 }
101 }
102}
103
104@media screen and (min-width: $small-view) and (max-width: breakpoint(lg)) {
105 :host-context(.main-col:not(.expanded)) {
106 .video-channel-info .video-channel-names {
107 .video-channel-name {
108 max-width: 160px;
109 }
110 }
111
112 // Override the min-width: 500px to not break screen
113 ::ng-deep .video-miniature-information {
e66883b3 114 min-width: $video-thumbnail-width !important;
8a3183e5
K
115 }
116 }
117
118 :host-context(.expanded) {
119 // Override the min-width: 500px to not break screen
120 ::ng-deep .video-miniature-information {
121 min-width: 300px !important;
122 }
123 }
124}
125
c182527a 126@media screen and (max-width: $small-view) {
4682468d
K
127 .search-result {
128 .entry.video-channel,
129 .entry.video {
130 flex-direction: column;
131 height: auto;
132 justify-content: center;
133 align-items: center;
134 text-align: center;
8a3183e5 135
4682468d
K
136 img {
137 margin: 0;
138 }
139
140 img {
141 margin: 0;
142 }
0933bb4a 143
4682468d
K
144 .video-channel-info .video-channel-names {
145 align-items: center;
146 flex-direction: column !important;
147
148 .video-channel-name {
149 margin-left: 0 !important;
150 }
151 }
152
153 my-subscribe-button {
154 margin-top: 5px;
155 }
c182527a 156 }
6e930af9 157 }
c182527a 158}
6e930af9 159
c182527a
C
160@media screen and (max-width: $mobile-view) {
161 .search-result {
162 padding: 20px 10px;
57c36b27 163
c182527a
C
164 .results-header {
165 font-size: 15px !important;
166 }
57c36b27 167
c182527a 168 .entry {
c182527a
C
169 &.video {
170 .video-info-name,
171 .video-info-account {
172 margin: auto;
173 }
0933bb4a 174
c182527a
C
175 my-video-thumbnail {
176 margin-right: 0 !important;
0933bb4a 177
03652b31 178 ::ng-deep .video-thumbnail {
0933bb4a
C
179 width: 100%;
180 height: auto;
c182527a
C
181
182 img {
183 width: 100%;
184 height: auto;
185 }
0933bb4a
C
186 }
187 }
57c36b27
C
188 }
189 }
190 }
191}