forked from Ponysearch/Ponysearch
New Theme, Pix-art.
First commit
This commit is contained in:
parent
3ff269c84c
commit
d740e7384a
22 changed files with 1182 additions and 0 deletions
1
Makefile
1
Makefile
|
@ -51,6 +51,7 @@ styles:
|
||||||
@lessc -x searx/static/themes/courgette/less/style-rtl.less > searx/static/themes/courgette/css/style-rtl.css
|
@lessc -x searx/static/themes/courgette/less/style-rtl.less > searx/static/themes/courgette/css/style-rtl.css
|
||||||
@lessc -x searx/static/less/bootstrap/bootstrap.less > searx/static/css/bootstrap.min.css
|
@lessc -x searx/static/less/bootstrap/bootstrap.less > searx/static/css/bootstrap.min.css
|
||||||
@lessc -x searx/static/themes/oscar/less/oscar/oscar.less > searx/static/themes/oscar/css/oscar.min.css
|
@lessc -x searx/static/themes/oscar/less/oscar/oscar.less > searx/static/themes/oscar/css/oscar.min.css
|
||||||
|
@lessc -x searx/static/themes/pix-art/less/style.less > searx/static/themes/pix-art/css/style.css
|
||||||
|
|
||||||
grunt:
|
grunt:
|
||||||
@grunt --gruntfile searx/static/themes/oscar/gruntfile.js
|
@grunt --gruntfile searx/static/themes/oscar/gruntfile.js
|
||||||
|
|
1
searx/static/themes/pix-art/css/style.css
Normal file
1
searx/static/themes/pix-art/css/style.css
Normal file
File diff suppressed because one or more lines are too long
BIN
searx/static/themes/pix-art/img/favicon.png
Normal file
BIN
searx/static/themes/pix-art/img/favicon.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3 KiB |
BIN
searx/static/themes/pix-art/img/preference-icon-pixel.png
Normal file
BIN
searx/static/themes/pix-art/img/preference-icon-pixel.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 242 B |
BIN
searx/static/themes/pix-art/img/search-icon-pixel.png
Normal file
BIN
searx/static/themes/pix-art/img/search-icon-pixel.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 204 B |
BIN
searx/static/themes/pix-art/img/searx-pixel.png
Normal file
BIN
searx/static/themes/pix-art/img/searx-pixel.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 439 B |
203
searx/static/themes/pix-art/img/searx_logo.svg
Normal file
203
searx/static/themes/pix-art/img/searx_logo.svg
Normal file
|
@ -0,0 +1,203 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||||
|
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
||||||
|
|
||||||
|
<svg
|
||||||
|
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
||||||
|
xmlns:cc="http://creativecommons.org/ns#"
|
||||||
|
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||||
|
xmlns:svg="http://www.w3.org/2000/svg"
|
||||||
|
xmlns="http://www.w3.org/2000/svg"
|
||||||
|
xmlns:xlink="http://www.w3.org/1999/xlink"
|
||||||
|
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||||
|
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||||
|
width="744.09448819"
|
||||||
|
height="1052.3622047"
|
||||||
|
id="svg2"
|
||||||
|
version="1.1"
|
||||||
|
inkscape:version="0.48.4 r9939"
|
||||||
|
sodipodi:docname="searx_logo.svg"
|
||||||
|
inkscape:export-filename="/home/a/magnif.png"
|
||||||
|
inkscape:export-xdpi="203.1774"
|
||||||
|
inkscape:export-ydpi="203.1774">
|
||||||
|
<defs
|
||||||
|
id="defs4">
|
||||||
|
<linearGradient
|
||||||
|
inkscape:collect="always"
|
||||||
|
id="linearGradient3857">
|
||||||
|
<stop
|
||||||
|
style="stop-color:#ffffff;stop-opacity:1;"
|
||||||
|
offset="0"
|
||||||
|
id="stop3859" />
|
||||||
|
<stop
|
||||||
|
style="stop-color:#ffffff;stop-opacity:0;"
|
||||||
|
offset="1"
|
||||||
|
id="stop3861" />
|
||||||
|
</linearGradient>
|
||||||
|
<linearGradient
|
||||||
|
id="linearGradient3790">
|
||||||
|
<stop
|
||||||
|
style="stop-color:#a9a9a9;stop-opacity:1;"
|
||||||
|
offset="0"
|
||||||
|
id="stop3792" />
|
||||||
|
<stop
|
||||||
|
style="stop-color:#000000;stop-opacity:1;"
|
||||||
|
offset="1"
|
||||||
|
id="stop3794" />
|
||||||
|
</linearGradient>
|
||||||
|
<radialGradient
|
||||||
|
inkscape:collect="always"
|
||||||
|
xlink:href="#linearGradient3790"
|
||||||
|
id="radialGradient3798"
|
||||||
|
cx="294.45947"
|
||||||
|
cy="208.37973"
|
||||||
|
fx="294.45947"
|
||||||
|
fy="208.37973"
|
||||||
|
r="107.58125"
|
||||||
|
gradientUnits="userSpaceOnUse" />
|
||||||
|
<linearGradient
|
||||||
|
inkscape:collect="always"
|
||||||
|
xlink:href="#linearGradient3857"
|
||||||
|
id="linearGradient3865"
|
||||||
|
x1="120.68947"
|
||||||
|
y1="239.61774"
|
||||||
|
x2="120.68947"
|
||||||
|
y2="602.17517"
|
||||||
|
gradientUnits="userSpaceOnUse" />
|
||||||
|
<linearGradient
|
||||||
|
inkscape:collect="always"
|
||||||
|
xlink:href="#linearGradient3790"
|
||||||
|
id="linearGradient3912"
|
||||||
|
x1="186.74416"
|
||||||
|
y1="354.42426"
|
||||||
|
x2="255.84358"
|
||||||
|
y2="254.35953"
|
||||||
|
gradientUnits="userSpaceOnUse"
|
||||||
|
gradientTransform="matrix(1.2227304,0,0,0.89945099,-289.31433,113.40259)" />
|
||||||
|
<filter
|
||||||
|
inkscape:collect="always"
|
||||||
|
id="filter4024"
|
||||||
|
x="-0.12996517"
|
||||||
|
width="1.2599303"
|
||||||
|
y="-0.14709377"
|
||||||
|
height="1.2941875">
|
||||||
|
<feGaussianBlur
|
||||||
|
inkscape:collect="always"
|
||||||
|
stdDeviation="6.4759344"
|
||||||
|
id="feGaussianBlur4026" />
|
||||||
|
</filter>
|
||||||
|
<filter
|
||||||
|
inkscape:collect="always"
|
||||||
|
id="filter3983"
|
||||||
|
x="-1.0608404"
|
||||||
|
width="3.1216809"
|
||||||
|
y="-0.31017202"
|
||||||
|
height="1.620344">
|
||||||
|
<feGaussianBlur
|
||||||
|
inkscape:collect="always"
|
||||||
|
stdDeviation="9.392858"
|
||||||
|
id="feGaussianBlur3985" />
|
||||||
|
</filter>
|
||||||
|
</defs>
|
||||||
|
<sodipodi:namedview
|
||||||
|
id="base"
|
||||||
|
pagecolor="#ffffff"
|
||||||
|
bordercolor="#666666"
|
||||||
|
borderopacity="1.0"
|
||||||
|
inkscape:pageopacity="0.0"
|
||||||
|
inkscape:pageshadow="2"
|
||||||
|
inkscape:zoom="1.979899"
|
||||||
|
inkscape:cx="30.708726"
|
||||||
|
inkscape:cy="948.08556"
|
||||||
|
inkscape:document-units="px"
|
||||||
|
inkscape:current-layer="layer1"
|
||||||
|
showgrid="false"
|
||||||
|
inkscape:window-width="1364"
|
||||||
|
inkscape:window-height="663"
|
||||||
|
inkscape:window-x="0"
|
||||||
|
inkscape:window-y="30"
|
||||||
|
inkscape:window-maximized="0"
|
||||||
|
showguides="true"
|
||||||
|
inkscape:guide-bbox="true" />
|
||||||
|
<metadata
|
||||||
|
id="metadata7">
|
||||||
|
<rdf:RDF>
|
||||||
|
<cc:Work
|
||||||
|
rdf:about="">
|
||||||
|
<dc:format>image/svg+xml</dc:format>
|
||||||
|
<dc:type
|
||||||
|
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||||
|
<dc:title />
|
||||||
|
</cc:Work>
|
||||||
|
</rdf:RDF>
|
||||||
|
</metadata>
|
||||||
|
<g
|
||||||
|
inkscape:label="Layer 1"
|
||||||
|
inkscape:groupmode="layer"
|
||||||
|
id="layer1">
|
||||||
|
<path
|
||||||
|
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
|
||||||
|
d="m 70.523181,34.870671 c -7.11959,15.242893 -10.17798,31.779192 -8.22563,48.814566 5.01677,43.774133 41.675309,79.324503 91.536109,95.162893 -6.62576,-22.40752 -5.34093,-44.9362 2.6395,-65.84431 C 108.73618,98.821131 74.828141,70.195435 70.523181,34.870671 z"
|
||||||
|
id="path3814-0-7"
|
||||||
|
inkscape:connector-curvature="0" />
|
||||||
|
<path
|
||||||
|
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
|
||||||
|
d="m 303.77876,36.21406 c 7.11959,15.242893 10.17798,31.779192 8.22563,48.814566 -5.01677,43.774134 -41.67531,79.324504 -91.53611,95.162894 6.62576,-22.40752 5.34093,-44.9362 -2.6395,-65.84431 47.73698,-14.18269 81.64502,-42.808386 85.94998,-78.13315 z"
|
||||||
|
id="path3814-0"
|
||||||
|
inkscape:connector-curvature="0" />
|
||||||
|
<path
|
||||||
|
transform="matrix(0.6556593,-0.75505688,0.75505688,0.6556593,0,0)"
|
||||||
|
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
|
||||||
|
d="m -5.0905523,259.06055 18.4167573,0 c 6.220455,0 11.228257,16.68196 11.228257,37.40349 l 0,172.83701 c 0,20.72153 -5.007802,37.40349 -11.228257,37.40349 l -18.4167573,0 c -6.2204547,0 -11.2282577,-16.68196 -11.2282577,-37.40349 l 0,-172.83701 c 0,-20.72153 5.007803,-37.40349 11.2282577,-37.40349 z"
|
||||||
|
id="rect3804" />
|
||||||
|
<path
|
||||||
|
sodipodi:type="arc"
|
||||||
|
style="fill:url(#radialGradient3798);fill-opacity:1;fill-rule:nonzero;stroke:none"
|
||||||
|
id="path2987"
|
||||||
|
sodipodi:cx="294.45947"
|
||||||
|
sodipodi:cy="208.37973"
|
||||||
|
sodipodi:rx="107.58125"
|
||||||
|
sodipodi:ry="107.58125"
|
||||||
|
d="m 402.04073,208.37973 a 107.58125,107.58125 0 1 1 -215.16251,0 107.58125,107.58125 0 1 1 215.16251,0 z"
|
||||||
|
transform="translate(-107.07617,-60.609153)" />
|
||||||
|
<path
|
||||||
|
sodipodi:type="arc"
|
||||||
|
style="fill:url(#linearGradient3865);fill-opacity:1;fill-rule:nonzero;stroke:none"
|
||||||
|
id="path3757"
|
||||||
|
sodipodi:cx="131.82491"
|
||||||
|
sodipodi:cy="299.29346"
|
||||||
|
sodipodi:rx="101.52033"
|
||||||
|
sodipodi:ry="101.52033"
|
||||||
|
d="m 233.34524,299.29346 a 101.52033,101.52033 0 1 1 -203.040667,0 101.52033,101.52033 0 1 1 203.040667,0 z"
|
||||||
|
transform="matrix(0.76865672,0,0,0.76865672,85.80266,-82.535889)" />
|
||||||
|
<path
|
||||||
|
sodipodi:type="arc"
|
||||||
|
style="fill:#1a1a1a;fill-opacity:1;fill-rule:nonzero;stroke:none"
|
||||||
|
id="path3800"
|
||||||
|
sodipodi:cx="183.34268"
|
||||||
|
sodipodi:cy="156.35687"
|
||||||
|
sodipodi:rx="27.274118"
|
||||||
|
sodipodi:ry="27.274118"
|
||||||
|
d="m 210.6168,156.35687 a 27.274118,27.274118 0 1 1 -54.54824,0 27.274118,27.274118 0 1 1 54.54824,0 z"
|
||||||
|
transform="translate(5,-7.1428572)" />
|
||||||
|
<path
|
||||||
|
sodipodi:type="arc"
|
||||||
|
style="fill:#ffffff;fill-opacity:1;fill-rule:nonzero;stroke:none"
|
||||||
|
id="path3802"
|
||||||
|
sodipodi:cx="197.9899"
|
||||||
|
sodipodi:cy="203.32896"
|
||||||
|
sodipodi:rx="5.5558391"
|
||||||
|
sodipodi:ry="5.5558391"
|
||||||
|
d="m 203.54574,203.32896 a 5.5558391,5.5558391 0 1 1 -11.11168,0 5.5558391,5.5558391 0 1 1 11.11168,0 z"
|
||||||
|
transform="translate(1.4847712,-63.564549)" />
|
||||||
|
<rect
|
||||||
|
style="fill:#ffffff;fill-opacity:0.82211531000000004;fill-rule:nonzero;stroke:none;filter:url(#filter4024)"
|
||||||
|
id="rect3916"
|
||||||
|
width="2.2392972"
|
||||||
|
height="159.43797"
|
||||||
|
x="19.525793"
|
||||||
|
y="337.8396"
|
||||||
|
rx="2.8666623"
|
||||||
|
ry="9.0007057"
|
||||||
|
transform="matrix(0.74466525,-0.84318084,0.84318084,0.74466525,-35.543204,-26.349917)" />
|
||||||
|
</g>
|
||||||
|
</svg>
|
After Width: | Height: | Size: 7.1 KiB |
49
searx/static/themes/pix-art/js/searx.js
Normal file
49
searx/static/themes/pix-art/js/searx.js
Normal file
|
@ -0,0 +1,49 @@
|
||||||
|
if(searx.autocompleter) {
|
||||||
|
window.addEvent('domready', function() {
|
||||||
|
new Autocompleter.Request.JSON('q', '/autocompleter', {
|
||||||
|
postVar:'q',
|
||||||
|
postData:{
|
||||||
|
'format': 'json'
|
||||||
|
},
|
||||||
|
ajaxOptions:{
|
||||||
|
timeout: 5 // Correct option?
|
||||||
|
},
|
||||||
|
'minLength': 4,
|
||||||
|
'selectMode': false,
|
||||||
|
cache: true,
|
||||||
|
delay: 300
|
||||||
|
});
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
(function (w, d) {
|
||||||
|
'use strict';
|
||||||
|
function addListener(el, type, fn) {
|
||||||
|
if (el.addEventListener) {
|
||||||
|
el.addEventListener(type, fn, false);
|
||||||
|
} else {
|
||||||
|
el.attachEvent('on' + type, fn);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function placeCursorAtEnd() {
|
||||||
|
if (this.setSelectionRange) {
|
||||||
|
var len = this.value.length * 2;
|
||||||
|
this.setSelectionRange(len, len);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
addListener(w, 'load', function () {
|
||||||
|
var qinput = d.getElementById('q');
|
||||||
|
if (qinput !== null && qinput.value === "") {
|
||||||
|
addListener(qinput, 'focus', placeCursorAtEnd);
|
||||||
|
qinput.focus();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
if (!!('ontouchstart' in window)) {
|
||||||
|
document.getElementsByTagName("html")[0].className += " touch";
|
||||||
|
}
|
||||||
|
|
||||||
|
})(window, document);
|
||||||
|
|
119
searx/static/themes/pix-art/less/definitions.less
Normal file
119
searx/static/themes/pix-art/less/definitions.less
Normal file
|
@ -0,0 +1,119 @@
|
||||||
|
/*
|
||||||
|
* searx, A privacy-respecting, hackable metasearch engine
|
||||||
|
*
|
||||||
|
* To change the colors of the site, simple edit this variables
|
||||||
|
*/
|
||||||
|
|
||||||
|
/// Basic Colors
|
||||||
|
|
||||||
|
@color-base: #3498DB;
|
||||||
|
@color-base-dark: #2980B9;
|
||||||
|
@color-base-light: #ECF0F1;
|
||||||
|
@color-highlight: #094089;
|
||||||
|
@color-black: #000000;
|
||||||
|
|
||||||
|
/// General
|
||||||
|
|
||||||
|
@color-font: #444;
|
||||||
|
@color-font-light: #888;
|
||||||
|
|
||||||
|
@color-red: #C0392B;
|
||||||
|
|
||||||
|
@color-url-font: #1a11be;
|
||||||
|
@color-url-visited-font: #8E44AD;
|
||||||
|
@results-width: 50em;
|
||||||
|
|
||||||
|
|
||||||
|
/// Start-Screen
|
||||||
|
|
||||||
|
// hmarg
|
||||||
|
@color-hmarg-border: @color-base;
|
||||||
|
@color-hmarg-font: @color-base;
|
||||||
|
@color-hmarg-font-hover: @color-base;
|
||||||
|
|
||||||
|
|
||||||
|
/// Search-Input
|
||||||
|
|
||||||
|
@color-search-border: @color-base;
|
||||||
|
@color-search-background: #FFF;
|
||||||
|
@color-search-font: #222;
|
||||||
|
|
||||||
|
/// Autocompleter
|
||||||
|
|
||||||
|
@color-autocompleter-choices-background: #FFF;
|
||||||
|
@color-autocompleter-choices-border: @color-base;
|
||||||
|
@color-autocompleter-choices-border-left-right: @color-base;
|
||||||
|
@color-autocompleter-choices-border-bottom: @color-base;
|
||||||
|
|
||||||
|
@color-autocompleter-choices-font: #444;
|
||||||
|
|
||||||
|
/// Answers
|
||||||
|
@color-answers-border: @color-base-dark;
|
||||||
|
|
||||||
|
// Selected
|
||||||
|
@color-autocompleter-selected-background: #444;
|
||||||
|
@color-autocompleter-selected-font: #FFF;
|
||||||
|
@color-autocompleter-selected-queried-font: #9FCFFF;
|
||||||
|
|
||||||
|
/// Categories
|
||||||
|
|
||||||
|
@color-categories-item-selected: @color-base;
|
||||||
|
@color-categories-item-selected-font: #FFF;
|
||||||
|
|
||||||
|
@color-categories-item-border-selected: @color-base-dark;
|
||||||
|
@color-categories-item-border-unselected: #E8E7E6;
|
||||||
|
@color-categories-item-border-unselected-hover: @color-base;
|
||||||
|
|
||||||
|
|
||||||
|
/// Results
|
||||||
|
|
||||||
|
@color-suggestions-button-background: @color-base;
|
||||||
|
@color-suggestions-button-font: #FFF;
|
||||||
|
|
||||||
|
@color-download-button-background: @color-base;
|
||||||
|
@color-download-button-font: #FFF;
|
||||||
|
|
||||||
|
@color-result-search-background: @color-base-light;
|
||||||
|
|
||||||
|
@color-result-definition-border: gray;
|
||||||
|
@color-result-torrent-border: lightgray;
|
||||||
|
@color-result-top-border: #E8E7E6;
|
||||||
|
|
||||||
|
// Link to result
|
||||||
|
@color-result-link-font: @color-base-dark;
|
||||||
|
@color-result-link-visited-font: @color-url-visited-font;
|
||||||
|
|
||||||
|
// Url to result
|
||||||
|
@color-result-url-font: @color-red;
|
||||||
|
|
||||||
|
// Publish Date
|
||||||
|
@color-result-publishdate-font: @color-font-light;
|
||||||
|
|
||||||
|
// Images
|
||||||
|
@color-result-image-span-background-hover: rgba(0, 0, 0, 0.6);
|
||||||
|
@color-result-image-span-font: #FFF;
|
||||||
|
|
||||||
|
// Search-URL
|
||||||
|
@color-result-search-url-border: #888;
|
||||||
|
@color-result-search-url-font: #444;
|
||||||
|
|
||||||
|
|
||||||
|
/// Settings
|
||||||
|
|
||||||
|
@color-settings-fieldset: @color-base;
|
||||||
|
@color-settings-tr-hover: #DDD;
|
||||||
|
|
||||||
|
// Labels
|
||||||
|
@color-settings-label-allowed-background: #E74C3C;
|
||||||
|
@color-settings-label-allowed-font: #FFF;
|
||||||
|
|
||||||
|
@color-settings-label-deny-background: #2ECC71;
|
||||||
|
@color-settings-label-deny-font: @color-font;
|
||||||
|
|
||||||
|
@color-settings-return-background: @color-base;
|
||||||
|
@color-settings-return-font: #FFF;
|
||||||
|
|
||||||
|
/// Other
|
||||||
|
|
||||||
|
@color-engines-font: @color-font-light;
|
||||||
|
@color-percentage-div-background: #444;
|
27
searx/static/themes/pix-art/less/mixins.less
Normal file
27
searx/static/themes/pix-art/less/mixins.less
Normal file
|
@ -0,0 +1,27 @@
|
||||||
|
/*
|
||||||
|
* searx, A privacy-respecting, hackable metasearch engine
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Mixins
|
||||||
|
|
||||||
|
.text-size-adjust (@property: 100%) {
|
||||||
|
-webkit-text-size-adjust: @property;
|
||||||
|
-ms-text-size-adjust: @property;
|
||||||
|
-moz-text-size-adjust: @property;
|
||||||
|
text-size-adjust: @property;
|
||||||
|
}
|
||||||
|
|
||||||
|
.rounded-corners (@radius: 4px) {
|
||||||
|
-webkit-border-radius: @radius;
|
||||||
|
-moz-border-radius: @radius;
|
||||||
|
border-radius: @radius;
|
||||||
|
}
|
||||||
|
|
||||||
|
.user-select () {
|
||||||
|
-webkit-touch-callout: none;
|
||||||
|
-webkit-user-select: none;
|
||||||
|
-khtml-user-select: none;
|
||||||
|
-moz-user-select: none;
|
||||||
|
-ms-user-select: none;
|
||||||
|
user-select: none;
|
||||||
|
}
|
56
searx/static/themes/pix-art/less/search.less
Normal file
56
searx/static/themes/pix-art/less/search.less
Normal file
|
@ -0,0 +1,56 @@
|
||||||
|
/*
|
||||||
|
* searx, A privacy-respecting, hackable metasearch engine
|
||||||
|
*/
|
||||||
|
|
||||||
|
.search {
|
||||||
|
padding: 0;
|
||||||
|
margin: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
#search_wrapper {
|
||||||
|
position: relative;
|
||||||
|
width: @results-width;
|
||||||
|
padding: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.center #search_wrapper {
|
||||||
|
margin-left: auto;
|
||||||
|
margin-right: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.q {
|
||||||
|
background: none repeat scroll 0 0 @color-search-background;
|
||||||
|
border: 1px solid @color-search-border;
|
||||||
|
color: @color-search-font;
|
||||||
|
font-size: 16px;
|
||||||
|
height: 28px;
|
||||||
|
margin: 0;
|
||||||
|
outline: medium none;
|
||||||
|
padding: 2px;
|
||||||
|
padding-left: 8px;
|
||||||
|
padding-right: 0px !important;
|
||||||
|
width: 100%;
|
||||||
|
z-index: 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
#search_submit {
|
||||||
|
position: absolute;
|
||||||
|
top: 13px;
|
||||||
|
right: 1px;
|
||||||
|
padding: 0;
|
||||||
|
border: 0;
|
||||||
|
background: url('../img/search-icon-pixel.png') no-repeat;
|
||||||
|
background-size: 24px 24px;
|
||||||
|
opacity: 0.8;
|
||||||
|
width: 24px;
|
||||||
|
height: 30px;
|
||||||
|
font-size: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
@media screen and (max-width: @results-width) {
|
||||||
|
#search_wrapper {
|
||||||
|
width: 90%;
|
||||||
|
clear:both;
|
||||||
|
overflow: hidden
|
||||||
|
}
|
||||||
|
}
|
438
searx/static/themes/pix-art/less/style.less
Normal file
438
searx/static/themes/pix-art/less/style.less
Normal file
|
@ -0,0 +1,438 @@
|
||||||
|
/*
|
||||||
|
* searx, A privacy-respecting, hackable metasearch engine
|
||||||
|
*
|
||||||
|
* To convert "style.less" to "style.css" run: $make styles
|
||||||
|
*/
|
||||||
|
|
||||||
|
@import "definitions.less";
|
||||||
|
|
||||||
|
@import "mixins.less";
|
||||||
|
|
||||||
|
|
||||||
|
// Main LESS-Code
|
||||||
|
|
||||||
|
html {
|
||||||
|
font-family: sans-serif;
|
||||||
|
font-size: 0.9em;
|
||||||
|
.text-size-adjust;
|
||||||
|
color: @color-font;
|
||||||
|
padding: 0;
|
||||||
|
margin: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
body, #container {
|
||||||
|
padding: 0;
|
||||||
|
margin: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
canvas {
|
||||||
|
image-rendering: optimizeSpeed;
|
||||||
|
image-rendering: -moz-crisp-edges;
|
||||||
|
image-rendering: -webkit-optimize-contrast;
|
||||||
|
image-rendering: optimize-contrast;
|
||||||
|
image-rendering: pixelated;
|
||||||
|
-ms-interpolation-mode: nearest-neighbor;
|
||||||
|
width:32px;
|
||||||
|
height:32px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#container {
|
||||||
|
width: 100%;
|
||||||
|
position: absolute;
|
||||||
|
top: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Search-Field
|
||||||
|
|
||||||
|
@import "search.less";
|
||||||
|
|
||||||
|
// Autocompleter
|
||||||
|
|
||||||
|
|
||||||
|
.row {
|
||||||
|
max-width: 800px;
|
||||||
|
margin: 20px auto;
|
||||||
|
text-align: justify;
|
||||||
|
|
||||||
|
h1 {
|
||||||
|
font-size: 3em;
|
||||||
|
margin-top: 50px;
|
||||||
|
}
|
||||||
|
|
||||||
|
p {
|
||||||
|
padding: 0 10px;
|
||||||
|
max-width: 700px;
|
||||||
|
}
|
||||||
|
|
||||||
|
h3,ul {
|
||||||
|
margin: 4px 8px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.hmarg {
|
||||||
|
margin: 0 20px;
|
||||||
|
border: 1px solid @color-hmarg-border;
|
||||||
|
padding: 4px 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
a {
|
||||||
|
&:link.hmarg {
|
||||||
|
color: @color-hmarg-font;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:visited.hmarg {
|
||||||
|
color: @color-hmarg-font;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:active.hmarg {
|
||||||
|
color: @color-hmarg-font-hover;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:hover.hmarg {
|
||||||
|
color: @color-hmarg-font-hover;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.top_margin {
|
||||||
|
margin-top: 60px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.center {
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
h1 {
|
||||||
|
font-size: 5em;
|
||||||
|
}
|
||||||
|
|
||||||
|
div.title {
|
||||||
|
background: url('../img/searx-pixel.png') no-repeat;
|
||||||
|
width: 100%;
|
||||||
|
min-height: 80px;
|
||||||
|
background-position: center;
|
||||||
|
|
||||||
|
h1 {
|
||||||
|
visibility: hidden;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
input[type="submit"] {
|
||||||
|
padding: 2px 6px;
|
||||||
|
margin: 2px 4px;
|
||||||
|
display: inline-block;
|
||||||
|
background: @color-download-button-background;
|
||||||
|
color: @color-download-button-font;
|
||||||
|
.rounded-corners;
|
||||||
|
border: 0;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
input[type="checkbox"] {
|
||||||
|
visibility: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
|
fieldset {
|
||||||
|
margin: 8px;
|
||||||
|
border: 1px solid @color-settings-fieldset;
|
||||||
|
}
|
||||||
|
|
||||||
|
#categories {
|
||||||
|
margin: 0 10px;
|
||||||
|
.user-select;
|
||||||
|
}
|
||||||
|
|
||||||
|
.checkbox_container {
|
||||||
|
display: inline-block;
|
||||||
|
position: relative;
|
||||||
|
margin: 0 3px;
|
||||||
|
padding: 0px;
|
||||||
|
|
||||||
|
input {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.checkbox_container label, .engine_checkbox label {
|
||||||
|
cursor: pointer;
|
||||||
|
padding: 4px 10px;
|
||||||
|
margin: 0;
|
||||||
|
display: block;
|
||||||
|
text-transform: capitalize;
|
||||||
|
.user-select;
|
||||||
|
}
|
||||||
|
|
||||||
|
.checkbox_container input[type="checkbox"]:checked + label {
|
||||||
|
background: @color-categories-item-selected;
|
||||||
|
color: @color-categories-item-selected-font;
|
||||||
|
}
|
||||||
|
|
||||||
|
.engine_checkbox {
|
||||||
|
padding: 4px;
|
||||||
|
}
|
||||||
|
|
||||||
|
label {
|
||||||
|
&.allow {
|
||||||
|
background: @color-settings-label-allowed-background;
|
||||||
|
padding: 4px 8px;
|
||||||
|
color: @color-settings-label-allowed-font;
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.deny {
|
||||||
|
background: @color-settings-label-deny-background;
|
||||||
|
padding: 4px 8px;
|
||||||
|
color: @color-settings-label-deny-font;
|
||||||
|
display: inline;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.engine_checkbox input[type="checkbox"]:checked + label {
|
||||||
|
&:nth-child(2) + label {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.allow {
|
||||||
|
display: inline;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
a {
|
||||||
|
text-decoration: none;
|
||||||
|
color: @color-url-font;
|
||||||
|
|
||||||
|
&:visited {
|
||||||
|
color: @color-url-visited-font;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.engines {
|
||||||
|
color: @color-engines-font;
|
||||||
|
}
|
||||||
|
|
||||||
|
.small_font {
|
||||||
|
font-size: 0.8em;
|
||||||
|
}
|
||||||
|
|
||||||
|
.small p {
|
||||||
|
margin: 2px 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.right {
|
||||||
|
float: right;
|
||||||
|
}
|
||||||
|
|
||||||
|
.invisible {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.left {
|
||||||
|
float: left;
|
||||||
|
}
|
||||||
|
|
||||||
|
.highlight {
|
||||||
|
color: @color-highlight;
|
||||||
|
}
|
||||||
|
|
||||||
|
.content .highlight {
|
||||||
|
color: @color-black;
|
||||||
|
}
|
||||||
|
|
||||||
|
.percentage {
|
||||||
|
position: relative;
|
||||||
|
width: 300px;
|
||||||
|
|
||||||
|
div {
|
||||||
|
background: @color-percentage-div-background;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
table {
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
td {
|
||||||
|
padding: 0 4px;
|
||||||
|
}
|
||||||
|
|
||||||
|
tr {
|
||||||
|
&:hover {
|
||||||
|
background: @color-settings-tr-hover;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#results {
|
||||||
|
margin: auto;
|
||||||
|
padding: 0;
|
||||||
|
width: @results-width;
|
||||||
|
margin-bottom: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#search_url {
|
||||||
|
margin-top: 8px;
|
||||||
|
|
||||||
|
input {
|
||||||
|
border: 1px solid @color-result-search-url-border;
|
||||||
|
padding: 4px;
|
||||||
|
color: @color-result-search-url-font;
|
||||||
|
width: 14em;
|
||||||
|
display: block;
|
||||||
|
margin: 4px;
|
||||||
|
font-size: 0.8em;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#preferences {
|
||||||
|
top: 10px;
|
||||||
|
padding: 0;
|
||||||
|
border: 0;
|
||||||
|
background: url('../img/preference-icon-pixel.png') no-repeat;
|
||||||
|
background-size: 28px 28px;
|
||||||
|
opacity: 0.8;
|
||||||
|
width: 28px;
|
||||||
|
height: 30px;
|
||||||
|
display: block;
|
||||||
|
|
||||||
|
* {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#pagination {
|
||||||
|
clear: both;
|
||||||
|
|
||||||
|
br {
|
||||||
|
clear: both;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#apis {
|
||||||
|
margin-top: 8px;
|
||||||
|
clear: both;
|
||||||
|
}
|
||||||
|
|
||||||
|
#categories_container {
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
@media screen and (max-width: @results-width) {
|
||||||
|
|
||||||
|
#results {
|
||||||
|
margin: auto;
|
||||||
|
padding: 0;
|
||||||
|
width: 90%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.checkbox_container {
|
||||||
|
display: block;
|
||||||
|
width: 90%;
|
||||||
|
//float: left;
|
||||||
|
|
||||||
|
label {
|
||||||
|
border-bottom: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.preferences_container {
|
||||||
|
display: none;
|
||||||
|
postion: fixed !important;
|
||||||
|
top: 100px;
|
||||||
|
right: 0px;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@media screen and (max-width: 75em) {
|
||||||
|
|
||||||
|
div.title {
|
||||||
|
|
||||||
|
h1 {
|
||||||
|
font-size: 1em;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
html.touch #categories {
|
||||||
|
width: 95%;
|
||||||
|
height: 30px;
|
||||||
|
text-align: left;
|
||||||
|
overflow-x: scroll;
|
||||||
|
overflow-y: hidden;
|
||||||
|
-webkit-overflow-scrolling: touch;
|
||||||
|
|
||||||
|
#categories_container {
|
||||||
|
width: 1000px;
|
||||||
|
width: -moz-max-content;
|
||||||
|
width: -webkit-max-content;
|
||||||
|
width: max-content;
|
||||||
|
|
||||||
|
.checkbox_container {
|
||||||
|
display: inline-block;
|
||||||
|
width: auto;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#categories {
|
||||||
|
font-size: 90%;
|
||||||
|
clear: both;
|
||||||
|
|
||||||
|
.checkbox_container {
|
||||||
|
margin-top: 2px;
|
||||||
|
margin: auto;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#categories {
|
||||||
|
font-size: 90%;
|
||||||
|
clear: both;
|
||||||
|
|
||||||
|
.checkbox_container {
|
||||||
|
margin-top: 2px;
|
||||||
|
margin: auto;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#apis {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
#search_url {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.favicon {
|
||||||
|
float: left;
|
||||||
|
margin-right: 4px;
|
||||||
|
margin-top: 2px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.preferences_back {
|
||||||
|
background: none repeat scroll 0 0 @color-settings-return-background;
|
||||||
|
border: 0 none;
|
||||||
|
.rounded-corners;
|
||||||
|
cursor: pointer;
|
||||||
|
display: inline-block;
|
||||||
|
margin: 2px 4px;
|
||||||
|
padding: 4px 6px;
|
||||||
|
|
||||||
|
a {
|
||||||
|
color: @color-settings-return-font;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.hidden {
|
||||||
|
opacity: 0;
|
||||||
|
overflow: hidden;
|
||||||
|
font-size: 0.8em;
|
||||||
|
position: absolute;
|
||||||
|
bottom: -20px;
|
||||||
|
width: 100%;
|
||||||
|
text-position: center;
|
||||||
|
background: white;
|
||||||
|
transition: opacity 1s ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
#categories_container:hover .hidden {
|
||||||
|
transition: opacity 1s ease;
|
||||||
|
opacity: 0.8;
|
||||||
|
}
|
65
searx/templates/pix-art/about.html
Normal file
65
searx/templates/pix-art/about.html
Normal file
|
@ -0,0 +1,65 @@
|
||||||
|
{% extends 'pix-art/base.html' %}
|
||||||
|
{% block content %}
|
||||||
|
<div class="row"{% if rtl %} dir="ltr"{% endif %}>
|
||||||
|
<h1>About <a href="{{ url_for('index') }}">searx</a></h1>
|
||||||
|
|
||||||
|
<p>Searx is a <a href="https://en.wikipedia.org/wiki/Metasearch_engine">metasearch engine</a>, aggregating the results of other <a href="{{ url_for('preferences') }}">search engines</a> while not storing information about its users.
|
||||||
|
</p>
|
||||||
|
<h2>Why use Searx?</h2>
|
||||||
|
<ul>
|
||||||
|
<li>Searx may not offer you as personalised results as Google, but it doesn't generate a profile about you</li>
|
||||||
|
<li>Searx doesn't care about what you search for, never shares anything with a third party, and it can't be used to compromise you</li>
|
||||||
|
<li>Searx is free software, the code is 100% open and you can help to make it better. See more on <a href="https://github.com/asciimoo/searx">github</a></li>
|
||||||
|
</ul>
|
||||||
|
<p>If you do care about privacy, want to be a conscious user, or otherwise believe
|
||||||
|
in digital freedom, make Searx your default search engine or run it on your own server</p>
|
||||||
|
|
||||||
|
<h2>Technical details - How does it work?</h2>
|
||||||
|
|
||||||
|
<p>Searx is a <a href="https://en.wikipedia.org/wiki/Metasearch_engine">metasearch engine</a>,
|
||||||
|
inspired by the <a href="http://seeks-project.info/">seeks project</a>.<br />
|
||||||
|
It provides basic privacy by mixing your queries with searches on other platforms without storing search data. Queries are made using a POST request on every browser (except chrome*). Therefore they show up in neither our logs, nor your url history. In case of Chrome* users there is an exception, if Searx used from the search bar it performs GET requests.<br />
|
||||||
|
Searx can be added to your browser's search bar; moreover, it can be set as the default search engine.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<h2>How can I make it my own?</h2>
|
||||||
|
|
||||||
|
<p>Searx appreciates your concern regarding logs, so take the <a href="https://github.com/asciimoo/searx">code</a> and run it yourself! <br />Add your Searx to this <a href="https://github.com/asciimoo/searx/wiki/Searx-instances">list</a> to help other people reclaim their privacy and make the Internet freer!
|
||||||
|
<br />The more decentralized Internet is the more freedom we have!</p>
|
||||||
|
|
||||||
|
|
||||||
|
<h2>More about searx</h2>
|
||||||
|
|
||||||
|
<ul>
|
||||||
|
<li><a href="https://github.com/asciimoo/searx">github</a></li>
|
||||||
|
<li><a href="https://www.ohloh.net/p/searx/">ohloh</a></li>
|
||||||
|
<li><a href="https://twitter.com/Searx_engine">twitter</a></li>
|
||||||
|
<li>IRC: #searx @ freenode (<a href="https://kiwiirc.com/client/irc.freenode.com/searx">webclient</a>)</li>
|
||||||
|
<li><a href="https://www.transifex.com/projects/p/searx/">transifex</a></li>
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
|
||||||
|
<hr />
|
||||||
|
|
||||||
|
<h2 id="faq">FAQ</h2>
|
||||||
|
|
||||||
|
<h3>How to add to firefox?</h3>
|
||||||
|
<p><a href="#" onclick="window.external.AddSearchProvider(window.location.protocol + '//' + window.location.host + '{{ url_for('opensearch') }}');">Install</a> searx as a search engine on any version of Firefox! (javascript required)</p>
|
||||||
|
|
||||||
|
<h2 id="dev_faq">Developer FAQ</h2>
|
||||||
|
|
||||||
|
<h3>New engines?</h3>
|
||||||
|
<ul>
|
||||||
|
<li>Edit your <a href="https://raw.github.com/asciimoo/searx/master/searx/settings.yml">settings.yml</a></li>
|
||||||
|
<li>Create your custom engine module, check the <a href="https://github.com/asciimoo/searx/blob/master/examples/basic_engine.py">example engine</a></li>
|
||||||
|
</ul>
|
||||||
|
<p>Don't forget to restart searx after config edit!</p>
|
||||||
|
|
||||||
|
<h3>Installation/WSGI support?</h3>
|
||||||
|
<p>See the <a href="https://github.com/asciimoo/searx/wiki/Installation">installation and setup</a> wiki page</p>
|
||||||
|
|
||||||
|
<h3>How to debug engines?</h3>
|
||||||
|
<p><a href="{{ url_for('stats') }}">Stats page</a> contains some useful data about the engines used.</p>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
{% endblock %}
|
28
searx/templates/pix-art/base.html
Normal file
28
searx/templates/pix-art/base.html
Normal file
|
@ -0,0 +1,28 @@
|
||||||
|
<!DOCTYPE html>
|
||||||
|
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8" />
|
||||||
|
<meta name="description" content="Searx - a privacy-respecting, hackable metasearch engine" />
|
||||||
|
<meta name="keywords" content="searx, search, search engine, metasearch, meta search" />
|
||||||
|
<meta name="generator" content="searx/{{ searx_version }}">
|
||||||
|
<meta name="viewport" content="width=device-width, maximum-scale=1.0, user-scalable=1" />
|
||||||
|
<title>{% block title %}{% endblock %}searx</title>
|
||||||
|
<link rel="stylesheet" href="{{ url_for('static', filename='css/style.css') }}" type="text/css" media="screen" />
|
||||||
|
<link rel="shortcut icon" href="{{ url_for('static', filename='img/favicon.png') }}?v=2" />
|
||||||
|
{% block styles %}
|
||||||
|
{% endblock %}
|
||||||
|
{% block meta %}{% endblock %}
|
||||||
|
{% block head %}
|
||||||
|
{% endblock %}
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<div id="container">
|
||||||
|
{% block content %}
|
||||||
|
{% endblock %}
|
||||||
|
<script type="text/javascript">
|
||||||
|
searx = {};
|
||||||
|
</script>
|
||||||
|
<script src="{{ url_for('static', filename='js/searx.js') }}" ></script>
|
||||||
|
</div>
|
||||||
|
</body>
|
||||||
|
</html>
|
12
searx/templates/pix-art/index.html
Normal file
12
searx/templates/pix-art/index.html
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
{% extends "pix-art/base.html" %}
|
||||||
|
{% block content %}
|
||||||
|
<div class="center">
|
||||||
|
<div class="title"><h1><img src="{{ url_for('static', filename='img/searx-pixel.png') }}" alt="Searx Logo"/></h1></div>
|
||||||
|
{% include 'pix-art/search.html' %}
|
||||||
|
<p class="top_margin">
|
||||||
|
<a href="{{ url_for('about') }}" class="hmarg">{{ _('about') }}</a>
|
||||||
|
<a href="{{ url_for('preferences') }}" class="hmarg">{{ _('preferences') }}</a>
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
|
{% endblock %}
|
||||||
|
|
82
searx/templates/pix-art/preferences.html
Normal file
82
searx/templates/pix-art/preferences.html
Normal file
|
@ -0,0 +1,82 @@
|
||||||
|
{% extends "default/base.html" %}
|
||||||
|
{% block head %} {% endblock %}
|
||||||
|
{% block content %}
|
||||||
|
<div class="row">
|
||||||
|
<h2>{{ _('Preferences') }}</h2>
|
||||||
|
|
||||||
|
<form method="post" action="{{ url_for('preferences') }}" id="search_form">
|
||||||
|
<fieldset>
|
||||||
|
<legend>{{ _('Search language') }}</legend>
|
||||||
|
<p>
|
||||||
|
<select name='language'>
|
||||||
|
<option value="all" {% if current_language == 'all' %}selected="selected"{% endif %}>{{ _('Automatic') }}</option>
|
||||||
|
{% for lang_id,lang_name,country_name in language_codes | sort(attribute=1) %}
|
||||||
|
<option value="{{ lang_id }}" {% if lang_id == current_language %}selected="selected"{% endif %}>{{ lang_name }} ({{ country_name }}) - {{ lang_id }}</option>
|
||||||
|
{% endfor %}
|
||||||
|
</select>
|
||||||
|
</p>
|
||||||
|
</fieldset>
|
||||||
|
<fieldset>
|
||||||
|
<legend>{{ _('Interface language') }}</legend>
|
||||||
|
<p>
|
||||||
|
<select name='locale'>
|
||||||
|
{% for locale_id,locale_name in locales.items() | sort %}
|
||||||
|
<option value="{{ locale_id }}" {% if locale_id == current_locale %}selected="selected"{% endif %}>{{ locale_name }}</option>
|
||||||
|
{% endfor %}
|
||||||
|
</select>
|
||||||
|
</p>
|
||||||
|
</fieldset>
|
||||||
|
<fieldset>
|
||||||
|
<legend>{{ _('Method') }}</legend>
|
||||||
|
<p>
|
||||||
|
<select name='method'>
|
||||||
|
<option value="POST" {% if method == 'POST' %}selected="selected"{% endif %}>POST</option>
|
||||||
|
<option value="GET" {% if method == 'GET' %}selected="selected"{% endif %}>GET</option>
|
||||||
|
</select>
|
||||||
|
</p>
|
||||||
|
</fieldset>
|
||||||
|
<fieldset>
|
||||||
|
<legend>{{ _('Themes') }}</legend>
|
||||||
|
<p>
|
||||||
|
<select name="theme">
|
||||||
|
{% for name in themes %}
|
||||||
|
<option value="{{ name }}" {% if name == theme %}selected="selected"{% endif %}>{{ name }}</option>
|
||||||
|
{% endfor %}
|
||||||
|
</select>
|
||||||
|
</p>
|
||||||
|
</fieldset>
|
||||||
|
<fieldset>
|
||||||
|
<legend>{{ _('Currently used search engines') }}</legend>
|
||||||
|
|
||||||
|
<table>
|
||||||
|
<tr>
|
||||||
|
<th>{{ _('Engine name') }}</th>
|
||||||
|
<th>{{ _('Allow') }} / {{ _('Block') }}</th>
|
||||||
|
</tr>
|
||||||
|
{% for (categ,search_engines) in categs %}
|
||||||
|
{% for search_engine in search_engines %}
|
||||||
|
|
||||||
|
{% if not search_engine.private %}
|
||||||
|
<tr>
|
||||||
|
<td>{{ search_engine.name }} ({{ shortcuts[search_engine.name] }})‎</td>
|
||||||
|
<td class="engine_checkbox">
|
||||||
|
<input type="checkbox" id="engine_{{ categ|replace(' ', '_') }}_{{ search_engine.name|replace(' ', '_') }}" name="engine_{{ search_engine.name }}__{{ categ }}"{% if (search_engine.name, categ) in blocked_engines %} checked="checked"{% endif %} />
|
||||||
|
<label class="allow" for="engine_{{ categ|replace(' ', '_') }}_{{ search_engine.name|replace(' ', '_') }}">{{ _('Allow') }}</label>
|
||||||
|
<label class="deny" for="engine_{{ categ|replace(' ', '_') }}_{{ search_engine.name|replace(' ', '_') }}">{{ _('Block') }}</label>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
{% endif %}
|
||||||
|
{% endfor %}
|
||||||
|
{% endfor %}
|
||||||
|
</table>
|
||||||
|
</fieldset>
|
||||||
|
<p class="small_font">{{ _('These settings are stored in your cookies, this allows us not to store this data about you.') }}
|
||||||
|
<br />
|
||||||
|
{{ _("These cookies serve your sole convenience, we don't use these cookies to track you.") }}
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<input type="submit" value="{{ _('save') }}" />
|
||||||
|
<div class="{% if rtl %}left{% else %}right{% endif %} preferences_back"><a href="{{ url_for('index') }}">{{ _('back') }}</a></div>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
{% endblock %}
|
13
searx/templates/pix-art/result_templates/default.html
Normal file
13
searx/templates/pix-art/result_templates/default.html
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
<a href="{{ result.url }}" title="{{ result.title | striptags }}">
|
||||||
|
<canvas id="canvas-{{ pageno }}-{{ index }}" class="icon" width="16" height="16"></canvas>
|
||||||
|
</a>
|
||||||
|
<script type="text/javascript">
|
||||||
|
var img{{ pageno }}_{{ index }} = new Image();
|
||||||
|
img{{ pageno }}_{{ index }}.src = 'http://{{ result.url | extract_domain }}/favicon.ico';
|
||||||
|
|
||||||
|
img{{ pageno }}_{{ index }}.onload = function () {
|
||||||
|
var can{{ pageno }}_{{ index }} = document.getElementById('canvas-{{ pageno }}-{{ index }}');
|
||||||
|
var ctx = can{{ pageno }}_{{ index }}.getContext("2d");
|
||||||
|
ctx.drawImage(img{{ pageno }}_{{ index }}, 0, 0, 16, 16);
|
||||||
|
};
|
||||||
|
</script>
|
6
searx/templates/pix-art/result_templates/images.html
Normal file
6
searx/templates/pix-art/result_templates/images.html
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
<div class="image_result">
|
||||||
|
<p>
|
||||||
|
<a href="{{ result.img_src }}"><img src="{% if result.thumbnail_src %}{{ image_proxify(result.thumbnail_src) }}{% else %}{{ image_proxify(result.img_src) }}{% endif %}" title="{{ result.title|striptags }}" alt="{{ result.title|striptags }}" /></a>
|
||||||
|
<span class="url"><a href="{{ result.url }}" class="small_font">{{ _('original context') }}</a></span>
|
||||||
|
</p>
|
||||||
|
</div>
|
44
searx/templates/pix-art/results.html
Normal file
44
searx/templates/pix-art/results.html
Normal file
|
@ -0,0 +1,44 @@
|
||||||
|
{% extends "pix-art/base.html" %}
|
||||||
|
{% block title %}{{ q }} - {% endblock %}
|
||||||
|
{% block meta %}{% endblock %}
|
||||||
|
{% block content %}
|
||||||
|
<div class="preferences_container right"><a href="{{ url_for('preferences') }}" id="preferences"><span>preferences</span></a></div>
|
||||||
|
<div class="small search center">
|
||||||
|
{% include 'pix-art/search.html' %}
|
||||||
|
</div>
|
||||||
|
<div id="results">
|
||||||
|
{% for result in results %}
|
||||||
|
{% set index = loop.index %}
|
||||||
|
{% include 'pix-art/result_templates/default.html' %}
|
||||||
|
{% endfor %}
|
||||||
|
|
||||||
|
{% if paging %}
|
||||||
|
<div id="pagination">
|
||||||
|
{% if pageno > 1 %}
|
||||||
|
<form method="{{ method or 'POST' }}" action="{{ url_for('index') }}">
|
||||||
|
<div class="{% if rtl %}right{% else %}left{% endif %}">
|
||||||
|
<input type="hidden" name="q" value="{{ q }}" />
|
||||||
|
{% for category in selected_categories %}
|
||||||
|
<input type="hidden" name="category_{{ category }}" value="1"/>
|
||||||
|
{% endfor %}
|
||||||
|
<input type="hidden" name="pageno" value="{{ pageno-1 }}" />
|
||||||
|
<input type="submit" value="<< {{ _('previous page') }}" />
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
{% endif %}
|
||||||
|
<form method="{{ method or 'POST' }}" action="{{ url_for('index') }}">
|
||||||
|
<div class="{% if rtl %}left{% else %}right{% endif %}">
|
||||||
|
{% for category in selected_categories %}
|
||||||
|
<input type="hidden" name="category_{{ category }}" value="1"/>
|
||||||
|
{% endfor %}
|
||||||
|
<input type="hidden" name="q" value="{{ q }}" />
|
||||||
|
<input type="hidden" name="pageno" value="{{ pageno+1 }}" />
|
||||||
|
<input type="submit" value="{{ _('next page') }} >>" />
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
|
||||||
|
<br />
|
||||||
|
</div>
|
||||||
|
{% endif %}
|
||||||
|
</div>
|
||||||
|
{% endblock %}
|
9
searx/templates/pix-art/search.html
Normal file
9
searx/templates/pix-art/search.html
Normal file
|
@ -0,0 +1,9 @@
|
||||||
|
<form method="{{ method or 'POST' }}" action="{{ url_for('index') }}" id="search_form">
|
||||||
|
<div id="search_wrapper">
|
||||||
|
<input type="text" placeholder="{{ _('Search for...') }}" id="q" class="q" name="q" tabindex="1" size="100" {% if q %}value="{{ q }}"{% endif %}/>
|
||||||
|
<input type="submit" value="search" id="search_submit" />
|
||||||
|
{% for category in categories %}
|
||||||
|
<input type="hidden" name="category_{{ category }}" value="1"/>
|
||||||
|
{% endfor %}
|
||||||
|
</div>
|
||||||
|
</form>
|
22
searx/templates/pix-art/stats.html
Normal file
22
searx/templates/pix-art/stats.html
Normal file
|
@ -0,0 +1,22 @@
|
||||||
|
{% extends "default/base.html" %}
|
||||||
|
{% block head %} {% endblock %}
|
||||||
|
{% block content %}
|
||||||
|
<h2>{{ _('Engine stats') }}</h2>
|
||||||
|
|
||||||
|
{% for stat_name,stat_category in stats %}
|
||||||
|
<div class="left">
|
||||||
|
<table>
|
||||||
|
<tr colspan="3">
|
||||||
|
<th>{{ stat_name }}</th>
|
||||||
|
</tr>
|
||||||
|
{% for engine in stat_category %}
|
||||||
|
<tr>
|
||||||
|
<td>{{ engine.name }}</td>
|
||||||
|
<td>{{ '%.02f'|format(engine.avg) }}</td>
|
||||||
|
<td class="percentage"><div style="width: {{ engine.percentage }}%"> </div></td>
|
||||||
|
</tr>
|
||||||
|
{% endfor %}
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
{% endfor %}
|
||||||
|
{% endblock %}
|
|
@ -29,6 +29,7 @@ import hashlib
|
||||||
|
|
||||||
from datetime import datetime, timedelta
|
from datetime import datetime, timedelta
|
||||||
from urllib import urlencode
|
from urllib import urlencode
|
||||||
|
from urlparse import urlparse
|
||||||
from werkzeug.contrib.fixers import ProxyFix
|
from werkzeug.contrib.fixers import ProxyFix
|
||||||
from flask import (
|
from flask import (
|
||||||
Flask, request, render_template, url_for, Response, make_response,
|
Flask, request, render_template, url_for, Response, make_response,
|
||||||
|
@ -178,6 +179,12 @@ def code_highlighter(codelines, language=None):
|
||||||
return html_code
|
return html_code
|
||||||
|
|
||||||
|
|
||||||
|
# Extract domain from url
|
||||||
|
@app.template_filter('extract_domain')
|
||||||
|
def extract_domain(url):
|
||||||
|
return urlparse(url)[1]
|
||||||
|
|
||||||
|
|
||||||
def get_base_url():
|
def get_base_url():
|
||||||
if settings['server']['base_url']:
|
if settings['server']['base_url']:
|
||||||
hostname = settings['server']['base_url']
|
hostname = settings['server']['base_url']
|
||||||
|
|
Loading…
Reference in a new issue