Extravi / araa-search

A privacy-respecting, ad-free, self-hosted Google metasearch engine with strong security that offers full API support and utilizes Qwant for images, and DuckDuckGo for auto-complete.
https://araa.extravi.dev
GNU Affero General Public License v3.0
241 stars 22 forks source link

image search does not work with post request #112

Closed Extravi closed 9 months ago

Extravi commented 9 months ago

image

amogusussy commented 9 months ago

Could change it to:

if (document.querySelectorAll(".search-active")[1].innerText === "Images") {
    // Do image search stuff
}

This checks which of the search buttons is selected. If it's images, then do whatever it says.

Extravi commented 9 months ago

alright ill test that and add it in the update with ui fixes

Extravi commented 9 months ago

thanks

Extravi commented 9 months ago

image

Extravi commented 9 months ago

works thank you

amogusussy commented 9 months ago

Can you check that it works with other languages? Im not at my computer right now, so i cant.

It should probably be changed to use .value instead of .innerText, because .value stays the same across all ux languages.

amogusussy commented 9 months ago

Also,remove the 'All' and the index from the queryselector function to improve efficiency.

Extravi commented 9 months ago

Can you check that it works with other languages? Im not at my computer right now, so i cant.

It should probably be changed to use .value instead of .innerText, because .value stays the same across all ux languages.

I already added it to the code but I'll go back and make that change

Extravi commented 9 months ago

it dose not work without querySelectorAll but this version works


if (document.querySelectorAll(".search-active")[1].getAttribute("value") === "image") {
Extravi commented 9 months ago

image

Extravi commented 9 months ago

https://github.com/Extravi/araa-search/commit/f3ef65e2a26c8424a7ee6860c315ee9004c809eb