FileCR Search Fix

A simple script to re-add the original Search feature, instead of Google Search.

Stan na 29-01-2023. Zobacz najnowsza wersja.

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Greasemonkey lub Violentmonkey.

You will need to install an extension such as Tampermonkey to install this script.

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Violentmonkey.

Aby zainstalować ten skrypt, wymagana będzie instalacja rozszerzenia Tampermonkey lub Userscripts.

You will need to install an extension such as Tampermonkey to install this script.

Aby zainstalować ten skrypt, musisz zainstalować rozszerzenie menedżera skryptów użytkownika.

(Mam już menedżera skryptów użytkownika, pozwól mi to zainstalować!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Musisz zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

(Mam już menedżera stylów użytkownika, pozwól mi to zainstalować!)

// ==UserScript==
// @name        FileCR Search Fix
// @namespace   lemons
// @license     Unlicense
// @match       *://filecr.com/*
// @icon        https://filecr.com/wp-content/uploads/2018/11/favico.png
// @grant       none
// @version     1.2
// @author      lemons
// @description A simple script to re-add the original Search feature, instead of Google Search.
// ==/UserScript==

// readd search
document.querySelector(".nav-bar > .header-logo").outerHTML += `<div class="search-container">
<form class="header--search" method="get" action="https://filecr.com/">
<input type="text" class="header--search-input" id="search-input" value="${new URLSearchParams(location.search).get("s") ?? ""}" placeholder="Search software here..." autocomplete="off" name="s" data-ddg-inputtype="unknown">
<button type="submit" aria-label="search button" class="header--search-submit">
<div class="icon">
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20" fill="currentColor" class="w-5 h-5">
  <path fill-rule="evenodd" d="M9 3.5a5.5 5.5 0 100 11 5.5 5.5 0 000-11zM2 9a7 7 0 1112.452 4.391l3.328 3.329a.75.75 0 11-1.06 1.06l-3.329-3.328A7 7 0 012 9z" clip-rule="evenodd"></path>
</svg>
</div>
</button>
</form>
</div>`;

// remove google sidebar
document.querySelector("#wgs_widget-2").style.display = "none";