Skip to content

Commit ed6b5d8

Browse files
committed
improve mobile image zooming
1 parent a633fd6 commit ed6b5d8

File tree

4 files changed

+15
-6
lines changed

4 files changed

+15
-6
lines changed

searx/static/themes/smart/css/ltr-style.css

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1104,6 +1104,7 @@ body.nord {
11041104

11051105
.image-details-container .image-details .image img {
11061106
object-fit: contain;
1107+
touch-action: pinch-zoom;
11071108
width: 100%;
11081109
height: 100%;
11091110
position: absolute;
@@ -1985,8 +1986,10 @@ body .body-container {
19851986
display: flex;
19861987
}
19871988

1988-
#index:has(#suggestion button) > main {
1989-
justify-content: flex-start;
1989+
@media (width <= 56rem) {
1990+
#index:has(#suggestion button) > main {
1991+
justify-content: flex-start;
1992+
}
19901993
}
19911994

19921995
main:has(.not-found) {

searx/static/themes/smart/css/rtl-style.css

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1050,6 +1050,7 @@ body.nord {
10501050

10511051
.image-details-container .image-details .image img {
10521052
object-fit: contain;
1053+
touch-action: pinch-zoom;
10531054
width: 100%;
10541055
height: 100%;
10551056
position: absolute;
@@ -1931,8 +1932,10 @@ body .body-container {
19311932
display: flex;
19321933
}
19331934

1934-
#index:has(#suggestion button) > main {
1935-
justify-content: flex-start;
1935+
@media (width <= 56rem) {
1936+
#index:has(#suggestion button) > main {
1937+
justify-content: flex-start;
1938+
}
19361939
}
19371940

19381941
main:has(.not-found) {

searx/static/themes/smart/src/scss/results/images.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,7 @@
124124
position: absolute;
125125
top: 0;
126126
left: 0;
127+
touch-action: pinch-zoom;
127128

128129
&#preview-img {
129130
filter: blur(10px);

searx/static/themes/smart/src/scss/style.scss

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -149,8 +149,10 @@ body {
149149
}
150150
}
151151

152-
#index:has(#suggestion button)>main {
153-
justify-content: flex-start;
152+
@include mixin.max-screens($screen-md) {
153+
#index:has(#suggestion button)>main {
154+
justify-content: flex-start;
155+
}
154156
}
155157

156158
// 404 page

0 commit comments

Comments
 (0)