mirror of
https://codeberg.org/leana8959/.files.git
synced 2025-12-06 14:49:14 +00:00
vanadium/firefox: inline some bindings
This commit is contained in:
parent
8fade47f8c
commit
76059ce726
1 changed files with 5 additions and 9 deletions
|
|
@ -13,10 +13,7 @@ in {
|
|||
SearchEngines = {
|
||||
Default = "Google en@en";
|
||||
Remove = ["Google"];
|
||||
Add = let
|
||||
lrValues = ["lang_fr" "lang_en" "lang_zh-TW"];
|
||||
hlValues = ["fr" "en" "zh-TW"];
|
||||
in
|
||||
Add =
|
||||
# Google specialized for each language x display language
|
||||
# reference: https://developers.google.com/custom-search/docs/xml_results?hl=zh-tw#advanced-search-query-parameters
|
||||
lib.mapCartesianProduct (
|
||||
|
|
@ -29,7 +26,7 @@ in {
|
|||
in {
|
||||
Name = "Google ${lr'}@${hl'}";
|
||||
Alias =
|
||||
if (lib.removePrefix "lang_" lr == hl)
|
||||
if lib.removePrefix "lang_" lr == hl
|
||||
then "@G" + lr'
|
||||
else "@G" + lr' + hl';
|
||||
Description = "Your data yum yum (but ${lr'} in ${hl'})";
|
||||
|
|
@ -37,10 +34,9 @@ in {
|
|||
SuggestURLTemplate = "https://suggestqueries.google.com/complete/search?q={searchTerms}&lr=${lr}&hl=${hl}";
|
||||
URLTemplate = "https://google.com/search?q=-ai+{searchTerms}&lr=${lr}&hl=${hl}";
|
||||
}
|
||||
)
|
||||
{
|
||||
lr = lrValues;
|
||||
hl = hlValues;
|
||||
) {
|
||||
lr = ["lang_fr" "lang_en" "lang_zh-TW"];
|
||||
hl = ["fr" "en" "zh-TW"];
|
||||
}
|
||||
++ [
|
||||
# Forges
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue