Skip to content

Commit

Permalink
fix link on top in rtl
Browse files Browse the repository at this point in the history
  • Loading branch information
Gnkalk committed May 22, 2024
1 parent fd4ff9a commit 9a97750
Show file tree
Hide file tree
Showing 6 changed files with 22 additions and 6 deletions.
2 changes: 1 addition & 1 deletion searx/static/themes/simple/css/searxng-rtl.min.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion searx/static/themes/simple/css/searxng-rtl.min.css.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion searx/static/themes/simple/css/searxng.min.css.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion searx/static/themes/simple/src/less/search.less
Original file line number Diff line number Diff line change
Expand Up @@ -457,7 +457,7 @@ html.no-js #clear_search.hide_if_nojs {
}

#links_on_top {
translate: -2rem !important;
.ltr-translate(-2rem);
}

#search_logo {
Expand Down
4 changes: 4 additions & 0 deletions searx/static/themes/simple/src/less/style-ltr.less
Original file line number Diff line number Diff line change
Expand Up @@ -82,4 +82,8 @@
flex-direction: @offset
}

.ltr-translate(@offset){
translate: @offset !important;
}

@import "style.less";
16 changes: 14 additions & 2 deletions searx/static/themes/simple/src/less/style-rtl.less
Original file line number Diff line number Diff line change
Expand Up @@ -85,13 +85,17 @@

.ltr-flex-dir(@offset) {
& when (@offset = row) {
flex-direction: row-reverse
flex-direction: row-reverse;
}
& when (@offset = row-reverse) {
flex-direction: row
flex-direction: row;
}
}

.ltr-translate(@offset){
translate: calc(-1 * @offset) !important;
}

@import "style.less";

#q,
Expand Down Expand Up @@ -174,4 +178,12 @@

#main_results #links_on_top{
translate: 100%;
}

@media screen and (max-width: @phone) {
#main_index #links_on_top {
top: 1rem;
left: 2rem;
translate: 1rem !important;
}
}

0 comments on commit 9a97750

Please sign in to comment.