Commit 6d49c8f0 authored by Daniel J. Ramirez's avatar Daniel J. Ramirez

Improved result templates.

parent 5389bc28
......@@ -657,13 +657,34 @@ nav #eelo_links > * {
margin-top: 8px;
margin-bottom: 6px;
}
.result .result-content p {
.result .result-content p,
.result .result-content pre {
margin-top: 8px;
margin-bottom: 8px;
}
.result.result-torrent .extra-info > :not(:last-child) {
margin-right: 16px;
}
.result.result-videos {
position: relative;
}
.result.result-videos .result-content {
display: flex;
margin: 0px;
}
.result.result-videos .result-content .result_header {
margin-top: 0;
}
.result.result-videos .result-content > .thumbnail {
flex: 1;
}
.result.result-videos .result-content > :not(.thumbnail) {
flex: 3;
padding-left: 16px;
}
.result.result-videos .result-content .thumbnail > img {
width: 100%;
}
.result .external-link {
font-size: 14px;
color: #39a441;
......@@ -671,8 +692,18 @@ nav #eelo_links > * {
.result .extra-info {
color: rgba(0, 0, 0, 0.4);
}
.result .code-block {
background-color: rgba(0, 0, 0, 0.03);
padding: 0 16px;
border-radius: 8px;
border: 1px solid rgba(0, 0, 0, 0.2);
}
.result .code-block pre {
white-space: pre-wrap;
}
.result.result-default,
.result.result-torrent {
.result.result-torrent,
.result.result-videos {
margin-bottom: 32px;
}
.result.result-images {
......@@ -751,6 +782,18 @@ nav #eelo_links > * {
width: 100%;
margin-top: 16px;
}
.infobox table tr {
vertical-align: baseline;
}
.infobox table tr td {
padding: 0;
padding-bottom: 8px;
}
.infobox table tr > .label {
text-align: right;
color: rgba(0, 0, 0, 0.4);
padding-right: 16px;
}
#image_result_mini_gallery_header {
display: flex;
align-items: center;
......@@ -845,3 +888,9 @@ nav #eelo_links > * {
margin-bottom: 8px;
}
}
.highlight .lineno,
.highlighttable .lineno {
margin-right: 16px;
color: rgba(0, 0, 0, 0.4);
display: none;
}
.container-padding,nav{padding-left:16px;padding-right:16px}.color-transition,a{transition:color .2s ease-in-out}.border-color-transition,#search_form #search_input_container{transition:border-color .2s ease-in-out}.fill-transition,.checkmark .icon{transition:fill .2s ease-in-out}.disabled,[disabled],#preferences #engines .engine input:checked~.data{opacity:.4}#pagination{display:flex;justify-content:space-between}.container{max-width:1100px;padding-left:16px;padding-right:16px;display:flex;justify-content:space-between;margin:auto}.container>:first-child{max-width:600px;width:600px}.container>:last-child:not(:first-child){max-width:400px;width:400px}.container.full{max-width:100%}.container.full>:first-child{max-width:100%;width:100%}.container.full>:last-child:not(:first-child){display:none}.container.full #pagination{max-width:400px;width:400px;margin:auto;justify-content:space-around}#search_bar_area{border-bottom:1px solid rgba(0,0,0,.1)}#search_bar_area #search_form{max-width:600px;margin:auto}.inline{display:flex;flex-direction:row}@media screen and (max-width:1100px){.container{flex-direction:column-reverse}.container>*{margin:auto}#preferences.container{flex-direction:column;margin-top:16px}}@media screen and (max-width:600px){.container{max-width:100%;padding-left:16px;padding-right:16px}.container>:first-child,.container>:last-child:not(:first-child){max-width:100%;width:100%}main{margin-top:16px}#search_input_container{margin-left:16px;margin-right:16px}.container.full #pagination{max-width:100%;width:100%}}#index{max-width:600px;margin:auto}#index img{width:300px;display:block;margin:auto;margin-top:64px;margin-bottom:64px}#index img#logo_inline{display:none}@media screen and (max-width:600px){#index img{width:50vmin;margin-bottom:24px}}@media screen and (max-height:600px) and (orientation:landscape){#index img{width:70vmin;margin-top:32px;display:none}#index img#logo_inline{display:block}}.block,.btn.btn-block{display:block;width:100%;box-sizing:border-box}.text-muted{color:rgba(0,0,0,.4)}.danger,.btn.danger{color:#e06572}.widget,.btn,.custom-select:not(.flat){border:2px solid rgba(0,0,0,.2);padding:4px 12px;background-color:transparent;transition:border-color .2s ease-in-out,color .2s ease-in-out}.btn{padding:8px 16px;text-transform:uppercase;background-color:transparent;border-radius:8px;text-align:center;font-size:16px;font-weight:700;color:#5c6469}.btn.primary,input.btn[type=submit]{color:#5068dd}.btn:hover{border-color:#5068dd}.btn.danger:hover{border-color:#e06572}.btn.btn-flat{border:none;border-radius:0;background-color:transparent}.btn.btn-flat:hover{color:#5068dd}.btn.plain-white{border-color:rgba(255,255,255,.4);color:rgba(255,255,255,.8);background-color:rgba(0,0,0,.5)}.checkmark .icon{fill:#60686f}.checkmark .icon.checked{fill:#5068dd}.checkmark_input{display:none}.checkmark_input.inverted:checked+.checkmark .checked{display:none}.checkmark_input.inverted:checked+.checkmark .unchecked{display:initial}.checkmark_input.inverted:not(:checked)+.checkmark .checked{display:initial}.checkmark_input.inverted:not(:checked)+.checkmark .unchecked{display:none}.custom-select{appearance:none;-webkit-appearance:none;-moz-appearance:none;font-weight:400;background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA8AAAAPCAQAAACR313BAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAAmJLR0QA/4ePzL8AAAAJcEhZcwAABFkAAARZAVnbJUkAAAAHdElNRQfgBxgLDwB20OFsAAAAbElEQVQY073OsQ3CMAAEwJMYwJGnsAehpoXJItltBkmcdZBYgIIiQoLglnz3ui+eP+bk5uneteTMZJa6OJuIqvYzSJoqwqBq8gdmTTW86/dghxAUq4xsVYT9laBYXCw93Aajh7GPEF23t4fkBYevGFTANkPRAAAAJXRFWHRkYXRlOmNyZWF0ZQAyMDE2LTA3LTI0VDExOjU1OjU4KzAyOjAwRFqFOQAAACV0RVh0ZGF0ZTptb2RpZnkAMjAxNi0wNy0yNFQxMToxNTowMCswMjowMP7RDgQAAAAZdEVYdFNvZnR3YXJlAHd3dy5pbmtzY2FwZS5vcmeb7jwaAAAAAElFTkSuQmCC) 96% no-repeat}.custom-select.flat{border:none}.custom-select:not(.flat){width:100%;border-radius:50px}html{position:relative;min-height:100%;color:#60686f}body{margin:0;padding:0;font-size:16px;margin-bottom:120px;background-color:#fff;font-family:Roboto,Cantarell,Helvetica,Arial,sans-serif}body.lock{overflow:hidden}body *{font-family:sans-serif,Cantarell,Roboto,Helvetica,Arial}input,select{box-shadow:none!important}a{color:#1f6ed7}a,select,a:focus,select:focus,a:active,select:active,a:hover,select:hover{outline:0;text-decoration:none}label{color:#5c6469}section{margin-bottom:32px}ul>li{margin-bottom:8px}fieldset{border:none;padding:0}footer{position:absolute;bottom:0;width:100%;height:auto;text-align:center;color:#c1c1c1;padding-bottom:8px}.hidden,#icons{display:none}#image_view_modal{position:absolute;top:0;width:100%;height:100vh;background-color:rgba(0,0,0,.9);z-index:100}#image_view_modal button{display:block;width:100%;text-align:right;background:0 0;border:none}#image_view_modal button .icon{fill:#fff}#image_view_modal .card-container{display:flex;height:100%}#image_view_modal #image_view_card{margin:auto;max-width:600px;max-height:80vh}@media screen and (max-width:600px){#image_view_modal #image_view_card{margin-left:16px;margin-right:16px;max-width:100%;width:100%}}#image_view_modal #image_view_image{display:block;max-width:100%;max-height:70vh;background-color:#fff;margin:auto}#image_view_modal .options{margin-top:8px}#image_view_modal .btn{border-color:rgba(255,255,255,.4);color:rgba(255,255,255,.8);background-color:rgba(0,0,0,.5);display:inline-block;margin-right:8px}nav{height:48px;display:flex;align-items:center;justify-content:space-between;text-transform:capitalize;margin-bottom:24px}nav a{color:#868686}nav a:hover{color:#5068dd}nav #eelo_links>*{margin-right:32px}#nav_toggle_btn{display:none}@media screen and (max-width:600px){nav{position:fixed;right:0;top:0;flex-direction:column;height:100%;background-color:#fff;z-index:1000;width:280px;min-width:280px;max-width:280px;align-items:unset;box-shadow:0 0 0 rgba(0,0,0,.2);transition:transform .2s ease-in-out,box-shadow .2s ease-in-out;padding:0}nav>:first-child{margin-top:8px}nav>:last-child{margin-bottom:8px}nav a{display:block;padding:8px 16px}#nav_toggle_btn{display:block;position:absolute;top:24px;right:8px;z-index:1001}#nav_toggle:checked~#nav_toggle_btn>.menu-open{display:none}#nav_toggle:checked~#nav_toggle_btn>.menu-close{display:initial}#nav_toggle:checked~nav{box-shadow:0 0 30px rgba(0,0,0,.2);transform:translateX(0)}#nav_toggle:checked~#nav_toggle_btn{position:fixed}#nav_toggle:not(:checked)~#nav_toggle_btn>.menu-open{display:initial}#nav_toggle:not(:checked)~#nav_toggle_btn>.menu-close{display:none}#nav_toggle:not(:checked)~nav{transform:translateX(100%)}}#search_form #search_input_container{position:relative;display:flex;align-items:center;border:2px solid rgba(0,0,0,.24);border-radius:50px;height:38px}#search_form #search_input_container:hover,#search_form #search_input_container:active{border-color:#5068dd}#search_form #search_input_container #q{font-size:16px;border:none;height:100%;width:100%;min-width:0;padding-left:16px;background-color:transparent}#search_form #search_input_container #q:focus{outline:0}#search_form #search_input_container button[type=submit]{position:relative;height:100%;width:38px;min-width:38px;border:none;background:0 0;padding:0;display:flex;cursor:pointer}#search_form #search_input_container button[type=submit] .icon{transition:fill .2s ease-in-out,transform .1s ease-in-out}#search_form #search_input_container button[type=submit]:hover .icon{fill:#5068dd;transform:scale(1.2)}#search_form #logo,#search_form #logo_link{height:32px}#search_form #logo_link{padding-left:4px}#search_form #search_input_container.rtl #q{margin-left:0;padding-right:16px}#search_form #search_input_container.rtl #logo_link{padding-left:0;padding-right:4px}#search_form .twitter-typeahead{position:unset!important;background-color:transparent;width:100%;height:100%}#search_form input.tt-hint{display:none}#search_form .tt-dropdown-menu{position:absolute;left:0;right:0!important;top:calc(116%)!important;border-radius:8px;border:2px solid rgba(0,0,0,.2);width:100%!important;box-sizing:border-box!important;background-color:#eee;padding-left:16px;padding-right:16px}#search_form.inline-search .tt-dropdown-menu{padding-left:52px}#search_form #search_params{display:flex;justify-content:space-between;font-size:14px;padding-bottom:16px;padding-top:16px;padding-left:24px;padding-right:24px}#search_form #search_params select,#search_form #search_params label{font-size:14px}#search_form #search_params select{color:rgba(0,0,0,.5);text-align:right;padding-right:32px}#search_form #search_params #time_and_lang{text-align:right}#search_form #search_params #time_and_lang>*{width:160px}#search_form .search_categories,#search_form #categories{text-transform:capitalize;display:flex;flex-wrap:wrap;align-items:center;position:relative;flex:100%}#search_form .search_categories label,#search_form #categories label{flex-basis:auto;font-size:14px;font-weight:400;margin-right:16px}#search_form .search_categories input[type=radio]:checked+label,#search_form #categories input[type=radio]:checked+label{color:#5068dd;font-weight:700}#search_form #more_categories{position:absolute;top:24px;display:flex;flex-direction:column;border-radius:8px;border:2px solid rgba(0,0,0,.2);background-color:#eee;padding-bottom:16px;left:0;z-index:998}#search_form #more_categories>label{padding:16px;padding-bottom:0;white-space:nowrap}#more_categories_container{border-left:1px solid rgba(0,0,0,.24);padding-left:16px;display:flex;align-items:center;position:relative}#more_categories_toggle:checked~#more_categories,#more_categories_toggle_[checked]~#more_categories{display:flex}#more_categories_toggle:checked~#show_more_categories,#more_categories_toggle_[checked]~#show_more_categories{display:none}#more_categories_toggle:checked~#show_less_categories,#more_categories_toggle_[checked]~#show_less_categories{display:initial}#more_categories_toggle:not(:checked)~#more_categories,#more_categories_toggle_:not([checked])~#more_categories{display:none}#more_categories_toggle:not(:checked)~#show_more_categories,#more_categories_toggle_:not([checked])~#show_more_categories{display:initial}#more_categories_toggle:not(:checked)~#show_less_categories,#more_categories_toggle_:not([checked])~#show_less_categories{display:none}@media screen and (max-width:600px){#search_form #search_params{overflow-x:scroll}#search_form #search_params #time_and_lang{display:flex}#search_form #search_params #time_and_lang>*{width:auto}#search_form #search_params,#search_form #categories{flex-wrap:nowrap}#search_form #more_categories{position:relative;flex-direction:row;align-items:center;top:0;border:none;border-radius:0;padding-bottom:0;background-color:transparent;margin-left:16px}#search_form #more_categories>label{padding:0}#search_input_container{margin-right:40px}.tt-dropdown-menu{padding-left:16px}}#results{margin-top:32px;margin-bottom:32px}.result .result-template{font-weight:700;text-transform:uppercase;color:rgba(0,0,0,.4)}.result .result-template+.result_header{margin-top:0}.result .result_header{margin-bottom:6px}.result .result_header .favicon{width:16px;height:16px}.result .subheader>:not(:last-child),.result .subheader>*>:not(:last-child){margin-right:16px}.result .result-content{margin-top:8px;margin-bottom:6px}.result .result-content p{margin-top:8px;margin-bottom:8px}.result.result-torrent .extra-info>:not(:last-child){margin-right:16px}.result .external-link{font-size:14px;color:#39a441}.result .extra-info{color:rgba(0,0,0,.4)}.result.result-default,.result.result-torrent{margin-bottom:32px}.result.result-images{display:inline}.result.result-images .img-thumbnail{width:100%;border:none;margin-bottom:8px}#results.image-gallery{display:flex;flex-wrap:wrap}#results.image-gallery .result.result-images{display:block;flex:20%;height:200px;max-height:200px;overflow:hidden}@supports (display:grid){#results.image-gallery{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));grid-gap:8px}#results.image-gallery .result.result-images{display:block;text-align:center;overflow:hidden}#results.image-gallery .result.result-images .img-thumbnail{height:100%;width:auto}}#default_images_container{column-count:5;column-gap:8px}#default_images_container .img-thumb-link{display:block;max-height:120px;overflow:hidden}#suggestions form,#corrections form{display:inline-block}#suggestions form .btn,#corrections form .btn{text-transform:none}.infobox{margin-top:32px}.infobox .head .title{font-size:22px;margin-top:0;margin-bottom:0}.infobox .head small{color:rgba(0,0,0,.4)}.infobox .body .image-container{max-height:250px;overflow:hidden;text-align:center}.infobox .body .content{flex:3}.infobox .body img{max-width:100%;width:100%;margin-top:16px}#image_result_mini_gallery_header{display:flex;align-items:center;justify-content:space-between}@media screen and (max-width:1100px){#results.image-gallery{grid-template-columns:repeat(auto-fit,minmax(100px,1fr))}#results.image-gallery .result.result-images{height:140px;max-height:140px}}#preferences h1,#preferences .nav-tabs,#preferences #notice{margin-bottom:24px}#preferences .options{margin-top:24px}#preferences .tab-content{margin-bottom:48px;display:none}#preferences input.tab-radio[type=radio]{display:none}#preferences input.tab-radio[type=radio]:checked+.tab-content{display:block}#preferences .preference{margin-bottom:16px}#preferences .preference.inline{justify-content:space-between}#preferences .preference.inline>:first-child{flex:2}#preferences .preference.inline>:last-child{flex:1}#preferences #tabs{margin-bottom:32px}#preferences #tabs>*{margin-right:32px}#preferences #controls{display:flex;flex-direction:column-reverse;justify-content:flex-end}#preferences #cookies_list .cookie-value{word-wrap:break-word}#preferences #action_buttons{margin-top:48px}#preferences #action_buttons>div{margin-bottom:24px}#preferences #action_buttons>div>*{margin-bottom:8px}#preferences #engines h3{text-transform:capitalize;margin-top:0}#preferences #engines .engine{display:flex;margin-bottom:8px}#preferences #engines .engine .data{width:100%;margin-left:16px;margin-right:16px}#preferences #engines .engine input:checked~.data .danger{display:inline}#preferences #engines .engine input:not(:checked)~.data i.danger{display:none}@media screen and (max-width:600px){.preference.inline{flex-direction:column}.preference.inline>:first-child{margin-bottom:8px}}
\ No newline at end of file
.container-padding,nav{padding-left:16px;padding-right:16px}.color-transition,a{transition:color .2s ease-in-out}.border-color-transition,#search_form #search_input_container{transition:border-color .2s ease-in-out}.fill-transition,.checkmark .icon{transition:fill .2s ease-in-out}.disabled,[disabled],#preferences #engines .engine input:checked~.data{opacity:.4}#pagination{display:flex;justify-content:space-between}.container{max-width:1100px;padding-left:16px;padding-right:16px;display:flex;justify-content:space-between;margin:auto}.container>:first-child{max-width:600px;width:600px}.container>:last-child:not(:first-child){max-width:400px;width:400px}.container.full{max-width:100%}.container.full>:first-child{max-width:100%;width:100%}.container.full>:last-child:not(:first-child){display:none}.container.full #pagination{max-width:400px;width:400px;margin:auto;justify-content:space-around}#search_bar_area{border-bottom:1px solid rgba(0,0,0,.1)}#search_bar_area #search_form{max-width:600px;margin:auto}.inline{display:flex;flex-direction:row}@media screen and (max-width:1100px){.container{flex-direction:column-reverse}.container>*{margin:auto}#preferences.container{flex-direction:column;margin-top:16px}}@media screen and (max-width:600px){.container{max-width:100%;padding-left:16px;padding-right:16px}.container>:first-child,.container>:last-child:not(:first-child){max-width:100%;width:100%}main{margin-top:16px}#search_input_container{margin-left:16px;margin-right:16px}.container.full #pagination{max-width:100%;width:100%}}#index{max-width:600px;margin:auto}#index img{width:300px;display:block;margin:auto;margin-top:64px;margin-bottom:64px}#index img#logo_inline{display:none}@media screen and (max-width:600px){#index img{width:50vmin;margin-bottom:24px}}@media screen and (max-height:600px) and (orientation:landscape){#index img{width:70vmin;margin-top:32px;display:none}#index img#logo_inline{display:block}}.block,.btn.btn-block{display:block;width:100%;box-sizing:border-box}.text-muted{color:rgba(0,0,0,.4)}.danger,.btn.danger{color:#e06572}.widget,.btn,.custom-select:not(.flat){border:2px solid rgba(0,0,0,.2);padding:4px 12px;background-color:transparent;transition:border-color .2s ease-in-out,color .2s ease-in-out}.btn{padding:8px 16px;text-transform:uppercase;background-color:transparent;border-radius:8px;text-align:center;font-size:16px;font-weight:700;color:#5c6469}.btn.primary,input.btn[type=submit]{color:#5068dd}.btn:hover{border-color:#5068dd}.btn.danger:hover{border-color:#e06572}.btn.btn-flat{border:none;border-radius:0;background-color:transparent}.btn.btn-flat:hover{color:#5068dd}.btn.plain-white{border-color:rgba(255,255,255,.4);color:rgba(255,255,255,.8);background-color:rgba(0,0,0,.5)}.checkmark .icon{fill:#60686f}.checkmark .icon.checked{fill:#5068dd}.checkmark_input{display:none}.checkmark_input.inverted:checked+.checkmark .checked{display:none}.checkmark_input.inverted:checked+.checkmark .unchecked{display:initial}.checkmark_input.inverted:not(:checked)+.checkmark .checked{display:initial}.checkmark_input.inverted:not(:checked)+.checkmark .unchecked{display:none}.custom-select{appearance:none;-webkit-appearance:none;-moz-appearance:none;font-weight:400;background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA8AAAAPCAQAAACR313BAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAAmJLR0QA/4ePzL8AAAAJcEhZcwAABFkAAARZAVnbJUkAAAAHdElNRQfgBxgLDwB20OFsAAAAbElEQVQY073OsQ3CMAAEwJMYwJGnsAehpoXJItltBkmcdZBYgIIiQoLglnz3ui+eP+bk5uneteTMZJa6OJuIqvYzSJoqwqBq8gdmTTW86/dghxAUq4xsVYT9laBYXCw93Aajh7GPEF23t4fkBYevGFTANkPRAAAAJXRFWHRkYXRlOmNyZWF0ZQAyMDE2LTA3LTI0VDExOjU1OjU4KzAyOjAwRFqFOQAAACV0RVh0ZGF0ZTptb2RpZnkAMjAxNi0wNy0yNFQxMToxNTowMCswMjowMP7RDgQAAAAZdEVYdFNvZnR3YXJlAHd3dy5pbmtzY2FwZS5vcmeb7jwaAAAAAElFTkSuQmCC) 96% no-repeat}.custom-select.flat{border:none}.custom-select:not(.flat){width:100%;border-radius:50px}html{position:relative;min-height:100%;color:#60686f}body{margin:0;padding:0;font-size:16px;margin-bottom:120px;background-color:#fff;font-family:Roboto,Cantarell,Helvetica,Arial,sans-serif}body.lock{overflow:hidden}body *{font-family:sans-serif,Cantarell,Roboto,Helvetica,Arial}input,select{box-shadow:none!important}a{color:#1f6ed7}a,select,a:focus,select:focus,a:active,select:active,a:hover,select:hover{outline:0;text-decoration:none}label{color:#5c6469}section{margin-bottom:32px}ul>li{margin-bottom:8px}fieldset{border:none;padding:0}footer{position:absolute;bottom:0;width:100%;height:auto;text-align:center;color:#c1c1c1;padding-bottom:8px}.hidden,#icons{display:none}#image_view_modal{position:absolute;top:0;width:100%;height:100vh;background-color:rgba(0,0,0,.9);z-index:100}#image_view_modal button{display:block;width:100%;text-align:right;background:0 0;border:none}#image_view_modal button .icon{fill:#fff}#image_view_modal .card-container{display:flex;height:100%}#image_view_modal #image_view_card{margin:auto;max-width:600px;max-height:80vh}@media screen and (max-width:600px){#image_view_modal #image_view_card{margin-left:16px;margin-right:16px;max-width:100%;width:100%}}#image_view_modal #image_view_image{display:block;max-width:100%;max-height:70vh;background-color:#fff;margin:auto}#image_view_modal .options{margin-top:8px}#image_view_modal .btn{border-color:rgba(255,255,255,.4);color:rgba(255,255,255,.8);background-color:rgba(0,0,0,.5);display:inline-block;margin-right:8px}nav{height:48px;display:flex;align-items:center;justify-content:space-between;text-transform:capitalize;margin-bottom:24px}nav a{color:#868686}nav a:hover{color:#5068dd}nav #eelo_links>*{margin-right:32px}#nav_toggle_btn{display:none}@media screen and (max-width:600px){nav{position:fixed;right:0;top:0;flex-direction:column;height:100%;background-color:#fff;z-index:1000;width:280px;min-width:280px;max-width:280px;align-items:unset;box-shadow:0 0 0 rgba(0,0,0,.2);transition:transform .2s ease-in-out,box-shadow .2s ease-in-out;padding:0}nav>:first-child{margin-top:8px}nav>:last-child{margin-bottom:8px}nav a{display:block;padding:8px 16px}#nav_toggle_btn{display:block;position:absolute;top:24px;right:8px;z-index:1001}#nav_toggle:checked~#nav_toggle_btn>.menu-open{display:none}#nav_toggle:checked~#nav_toggle_btn>.menu-close{display:initial}#nav_toggle:checked~nav{box-shadow:0 0 30px rgba(0,0,0,.2);transform:translateX(0)}#nav_toggle:checked~#nav_toggle_btn{position:fixed}#nav_toggle:not(:checked)~#nav_toggle_btn>.menu-open{display:initial}#nav_toggle:not(:checked)~#nav_toggle_btn>.menu-close{display:none}#nav_toggle:not(:checked)~nav{transform:translateX(100%)}}#search_form #search_input_container{position:relative;display:flex;align-items:center;border:2px solid rgba(0,0,0,.24);border-radius:50px;height:38px}#search_form #search_input_container:hover,#search_form #search_input_container:active{border-color:#5068dd}#search_form #search_input_container #q{font-size:16px;border:none;height:100%;width:100%;min-width:0;padding-left:16px;background-color:transparent}#search_form #search_input_container #q:focus{outline:0}#search_form #search_input_container button[type=submit]{position:relative;height:100%;width:38px;min-width:38px;border:none;background:0 0;padding:0;display:flex;cursor:pointer}#search_form #search_input_container button[type=submit] .icon{transition:fill .2s ease-in-out,transform .1s ease-in-out}#search_form #search_input_container button[type=submit]:hover .icon{fill:#5068dd;transform:scale(1.2)}#search_form #logo,#search_form #logo_link{height:32px}#search_form #logo_link{padding-left:4px}#search_form #search_input_container.rtl #q{margin-left:0;padding-right:16px}#search_form #search_input_container.rtl #logo_link{padding-left:0;padding-right:4px}#search_form .twitter-typeahead{position:unset!important;background-color:transparent;width:100%;height:100%}#search_form input.tt-hint{display:none}#search_form .tt-dropdown-menu{position:absolute;left:0;right:0!important;top:calc(116%)!important;border-radius:8px;border:2px solid rgba(0,0,0,.2);width:100%!important;box-sizing:border-box!important;background-color:#eee;padding-left:16px;padding-right:16px}#search_form.inline-search .tt-dropdown-menu{padding-left:52px}#search_form #search_params{display:flex;justify-content:space-between;font-size:14px;padding-bottom:16px;padding-top:16px;padding-left:24px;padding-right:24px}#search_form #search_params select,#search_form #search_params label{font-size:14px}#search_form #search_params select{color:rgba(0,0,0,.5);text-align:right;padding-right:32px}#search_form #search_params #time_and_lang{text-align:right}#search_form #search_params #time_and_lang>*{width:160px}#search_form .search_categories,#search_form #categories{text-transform:capitalize;display:flex;flex-wrap:wrap;align-items:center;position:relative;flex:100%}#search_form .search_categories label,#search_form #categories label{flex-basis:auto;font-size:14px;font-weight:400;margin-right:16px}#search_form .search_categories input[type=radio]:checked+label,#search_form #categories input[type=radio]:checked+label{color:#5068dd;font-weight:700}#search_form #more_categories{position:absolute;top:24px;display:flex;flex-direction:column;border-radius:8px;border:2px solid rgba(0,0,0,.2);background-color:#eee;padding-bottom:16px;left:0;z-index:998}#search_form #more_categories>label{padding:16px;padding-bottom:0;white-space:nowrap}#more_categories_container{border-left:1px solid rgba(0,0,0,.24);padding-left:16px;display:flex;align-items:center;position:relative}#more_categories_toggle:checked~#more_categories,#more_categories_toggle_[checked]~#more_categories{display:flex}#more_categories_toggle:checked~#show_more_categories,#more_categories_toggle_[checked]~#show_more_categories{display:none}#more_categories_toggle:checked~#show_less_categories,#more_categories_toggle_[checked]~#show_less_categories{display:initial}#more_categories_toggle:not(:checked)~#more_categories,#more_categories_toggle_:not([checked])~#more_categories{display:none}#more_categories_toggle:not(:checked)~#show_more_categories,#more_categories_toggle_:not([checked])~#show_more_categories{display:initial}#more_categories_toggle:not(:checked)~#show_less_categories,#more_categories_toggle_:not([checked])~#show_less_categories{display:none}@media screen and (max-width:600px){#search_form #search_params{overflow-x:scroll}#search_form #search_params #time_and_lang{display:flex}#search_form #search_params #time_and_lang>*{width:auto}#search_form #search_params,#search_form #categories{flex-wrap:nowrap}#search_form #more_categories{position:relative;flex-direction:row;align-items:center;top:0;border:none;border-radius:0;padding-bottom:0;background-color:transparent;margin-left:16px}#search_form #more_categories>label{padding:0}#search_input_container{margin-right:40px}.tt-dropdown-menu{padding-left:16px}}#results{margin-top:32px;margin-bottom:32px}.result .result-template{font-weight:700;text-transform:uppercase;color:rgba(0,0,0,.4)}.result .result-template+.result_header{margin-top:0}.result .result_header{margin-bottom:6px}.result .result_header .favicon{width:16px;height:16px}.result .subheader>:not(:last-child),.result .subheader>*>:not(:last-child){margin-right:16px}.result .result-content{margin-top:8px;margin-bottom:6px}.result .result-content p,.result .result-content pre{margin-top:8px;margin-bottom:8px}.result.result-torrent .extra-info>:not(:last-child){margin-right:16px}.result.result-videos{position:relative}.result.result-videos .result-content{display:flex;margin:0}.result.result-videos .result-content .result_header{margin-top:0}.result.result-videos .result-content>.thumbnail{flex:1}.result.result-videos .result-content>:not(.thumbnail){flex:3;padding-left:16px}.result.result-videos .result-content .thumbnail>img{width:100%}.result .external-link{font-size:14px;color:#39a441}.result .extra-info{color:rgba(0,0,0,.4)}.result .code-block{background-color:rgba(0,0,0,.03);padding:0 16px;border-radius:8px;border:1px solid rgba(0,0,0,.2)}.result .code-block pre{white-space:pre-wrap}.result.result-default,.result.result-torrent,.result.result-videos{margin-bottom:32px}.result.result-images{display:inline}.result.result-images .img-thumbnail{width:100%;border:none;margin-bottom:8px}#results.image-gallery{display:flex;flex-wrap:wrap}#results.image-gallery .result.result-images{display:block;flex:20%;height:200px;max-height:200px;overflow:hidden}@supports (display:grid){#results.image-gallery{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));grid-gap:8px}#results.image-gallery .result.result-images{display:block;text-align:center;overflow:hidden}#results.image-gallery .result.result-images .img-thumbnail{height:100%;width:auto}}#default_images_container{column-count:5;column-gap:8px}#default_images_container .img-thumb-link{display:block;max-height:120px;overflow:hidden}#suggestions form,#corrections form{display:inline-block}#suggestions form .btn,#corrections form .btn{text-transform:none}.infobox{margin-top:32px}.infobox .head .title{font-size:22px;margin-top:0;margin-bottom:0}.infobox .head small{color:rgba(0,0,0,.4)}.infobox .body .image-container{max-height:250px;overflow:hidden;text-align:center}.infobox .body .content{flex:3}.infobox .body img{max-width:100%;width:100%;margin-top:16px}.infobox table tr{vertical-align:baseline}.infobox table tr td{padding:0;padding-bottom:8px}.infobox table tr>.label{text-align:right;color:rgba(0,0,0,.4);padding-right:16px}#image_result_mini_gallery_header{display:flex;align-items:center;justify-content:space-between}@media screen and (max-width:1100px){#results.image-gallery{grid-template-columns:repeat(auto-fit,minmax(100px,1fr))}#results.image-gallery .result.result-images{height:140px;max-height:140px}}#preferences h1,#preferences .nav-tabs,#preferences #notice{margin-bottom:24px}#preferences .options{margin-top:24px}#preferences .tab-content{margin-bottom:48px;display:none}#preferences input.tab-radio[type=radio]{display:none}#preferences input.tab-radio[type=radio]:checked+.tab-content{display:block}#preferences .preference{margin-bottom:16px}#preferences .preference.inline{justify-content:space-between}#preferences .preference.inline>:first-child{flex:2}#preferences .preference.inline>:last-child{flex:1}#preferences #tabs{margin-bottom:32px}#preferences #tabs>*{margin-right:32px}#preferences #controls{display:flex;flex-direction:column-reverse;justify-content:flex-end}#preferences #cookies_list .cookie-value{word-wrap:break-word}#preferences #action_buttons{margin-top:48px}#preferences #action_buttons>div{margin-bottom:24px}#preferences #action_buttons>div>*{margin-bottom:8px}#preferences #engines h3{text-transform:capitalize;margin-top:0}#preferences #engines .engine{display:flex;margin-bottom:8px}#preferences #engines .engine .data{width:100%;margin-left:16px;margin-right:16px}#preferences #engines .engine input:checked~.data .danger{display:inline}#preferences #engines .engine input:not(:checked)~.data i.danger{display:none}@media screen and (max-width:600px){.preference.inline{flex-direction:column}.preference.inline>:first-child{margin-bottom:8px}}.highlight .lineno,.highlighttable .lineno{margin-right:16px;color:rgba(0,0,0,.4);display:none}
\ No newline at end of file
.highlight, .highlighttable {
.lineno {
margin-right: @spacing_large;
color: @text-muted-color;
display: none;
}
.kd {}
.kt {}
.nf {}
.o {}
}
\ No newline at end of file
......@@ -13,6 +13,7 @@
@corner-radius: 8px;
@dim-color-superlighter: rgba(0, 0, 0, 0.03);
@dim-color-lighter: rgba(0, 0, 0, 0.1);
@dim-color-light: rgba(0, 0, 0, 0.2);
@dim-color-normal: rgba(0, 0, 0, 0.4);
......
......@@ -7,4 +7,5 @@
@import "search.less";
@import "results.less";
@import "preferences.less";
\ No newline at end of file
@import "preferences.less";
@import "code.less";
\ No newline at end of file
......@@ -26,7 +26,7 @@
margin-top: @spacing_medium;
margin-bottom: @spacing_small;
p {
p, pre {
margin-top: @spacing_medium;
margin-bottom: @spacing_medium;
}
......@@ -35,6 +35,22 @@
&.result-torrent {
.extra-info > :not(:last-child) { margin-right: @spacing_large; }
}
&.result-videos {
position: relative;
.result-content {
display: flex;
margin: 0px;
.result_header { margin-top: 0; }
& > .thumbnail { flex: 1; }
& > :not(.thumbnail) {
flex: 3;
padding-left: @spacing_large;
}
.thumbnail > img { width: 100%; }
}
}
.external-link {
font-size: @fontsize_small;
......@@ -44,9 +60,21 @@
.extra-info {
color: @text-muted-color;
}
.code-block {
background-color: @dim-color-superlighter;
padding: 0 @spacing_large;
border-radius: @corner-radius;
border: 1px solid @dim-color-light;
pre {
white-space: pre-wrap;
}
}
}
.result.result-default, .result.result-torrent {
.result.result-default, .result.result-torrent, .result.result-videos {
margin-bottom: @spacing_xx-large;
}
.result.result-images {
......@@ -142,6 +170,24 @@
.footer {
}
table tr {
vertical-align: baseline;
td {
padding: 0;
padding-bottom: @spacing_medium;
}
& > .label {
text-align: right;
color: @text-muted-color;
padding-right: @spacing_large;
}
& > .value {
}
}
}
#image_result_mini_gallery_header {
......
{% extends "eelo/base.html" %}
{% block title %}{{ _('about') }} - {% endblock %}
{% block content %}
{% include '__common__/about.html' %}
<div class="container">
{% include '__common__/about.html' %}
</div>
{% endblock %}
......@@ -18,7 +18,7 @@
<span id="show_less_categories_" class="hidden">{{_("Less")}}</span>
<div id="more_categories">
{% for category in categories %}
{% if not (category in ["general", "images"] or category in selected_categories) %}
{% if not (category in ["general", "images", "map"] or category in selected_categories) %}
{{ category_widget(category) }}
{% endif %}
{% endfor %}
......
......@@ -21,14 +21,14 @@
</div>
{% if infobox.attributes %}
<table class="table table-striped infobox_part">
<table>
{% for attribute in infobox.attributes %}
<tr>
<td><bdi>{{ attribute.label }}</bdi></td>
<td class="label"><bdi>{{ attribute.label }}</bdi></td>
{% if attribute.image %}
<td><img class="img-responsive" src="{{ image_proxify(attribute.image.src) }}" alt="{{ attribute.image.alt }}" /></td>
<td class="value"><img class="img-responsive" src="{{ image_proxify(attribute.image.src) }}" alt="{{ attribute.image.alt }}" /></td>
{% else %}
<td><bdi>{{ attribute.value }}</bdi></td>
<td class="value"><bdi>{{ attribute.value }}</bdi></td>
{% endif %}
</tr>
{% endfor %}
......
{% from 'eelo/macros.html' import result_header, result_sub_header, result_footer, result_footer_rtl, icon %}
{{ result_header(result, favicons) }}
{{ result_sub_header(result) }}
{% call result_sub_header(result) %}
{% if result.repository %}<a href="{{ result.repository }}" {% if results_on_new_tab %}target="_blank" rel="noopener noreferrer"{% else %}rel="noreferrer"{% endif %}>{{ result.repository }}</a>{% endif %}
{% endcall %}
{% if result.content %}<p class="result-content">{{ result.content|safe }}</p>{% endif %}
<div class="result-content">
{% if result.content %}{{ result.content|safe }}{% endif %}
{% if result.repository %}<p class="result-content">{{ icon('file') }} <a href="{{ result.repository }}" {% if results_on_new_tab %}target="_blank" rel="noopener noreferrer"{% else %}rel="noreferrer"{% endif %}>{{ result.repository }}</a></p>{% endif %}
<div dir="ltr">
{{ result.codelines|code_highlighter(result.code_language)|safe }}
<div dir="ltr" class="code-block">
{{ result.codelines|code_highlighter(result.code_language)|safe }}
</div>
</div>
{% if rtl %}
{{ result_footer_rtl(result) }}
{% else %}
{{ result_footer(result) }}
{% endif %}
{{ result_footer(result) }}
\ No newline at end of file
{% from 'eelo/macros.html' import result_header, result_sub_header, result_footer, result_footer_rtl, icon with context %}
{{ result_header(result, favicons) }}
{{ result_sub_header(result) }}
{% call result_sub_header(result) %}
{% endcall %}
{% if result.embedded %}
<small> &bull; <a class="text-info btn-collapse collapsed cursor-pointer media-loader disabled_if_nojs" data-toggle="collapse" data-target="#result-media-{{ index }}" data-btn-text-collapsed="{{ _('show media') }}" data-btn-text-not-collapsed="{{ _('hide media') }}">{{ icon('music') }} {{ _('show media') }}</a></small>
{% endif %}
{% if result.embedded %}
<div id="result-media-{{ index }}" class="collapse">
{{ result.embedded|safe }}
</div>
{% endif %}
{% if result.img_src %}
<div class="container-fluid">
<div class="row">
<img src="{{ image_proxify(result.img_src) }}" alt="{{ result.title|striptags }}" title="{{ result.title|striptags }}" style="width: auto; max-height: 60px; min-height: 60px;" class="col-xs-2 col-sm-4 col-md-4 result-content">
{% if result.content %}<p class="result-content col-xs-8 col-sm-8 col-md-8">{{ result.content|safe }}</p>{% endif %}
</div>
<div class="result-content">
<span>
{% if result.content %}{{ result.content|safe }}{% endif %}
</span>
</div>
{% else %}
{% if result.content %}<p class="result-content">{{ result.content|safe }}</p>{% endif %}
{% endif %}
{% if rtl %}
{{ result_footer_rtl(result) }}
{% else %}
{{ result_footer(result) }}
{% endif %}
......@@ -38,8 +38,5 @@
<p>{% if result.content %}{{ result.content|safe }}{% endif %}</p>
</div>
{% if rtl %}
{{ result_footer_rtl(result) }}
{% else %}
{{ result_footer(result) }}
{% endif %}
{% from 'eelo/macros.html' import result_header, result_sub_header, result_footer, result_footer_rtl, icon %}
{{ result_header(result, favicons) }}
{{ result_sub_header(result) }}
{% if result.embedded %}
<small> &bull; <a class="text-info btn-collapse collapsed cursor-pointer media-loader disabled_if_nojs" data-toggle="collapse" data-target="#result-video-{{ index }}" data-btn-text-collapsed="{{ _('show video') }}" data-btn-text-not-collapsed="{{ _('hide video') }}">{{ icon('film') }} {{ _('show video') }}</a></small>
{% endif %}
{% if result.embedded %}
<div id="result-video-{{ index }}" class="collapse">
{{ result.embedded|safe }}
</div>
{% endif %}
<div class="container-fluid">
<div class="row">
<a href="{{ result.url }}" {% if results_on_new_tab %}target="_blank" rel="noopener noreferrer"{% else %}rel="noreferrer"{% endif %}><img class="thumbnail col-xs-6 col-sm-4 col-md-4 result-content" src="{{ image_proxify(result.thumbnail) }}" alt="{{ result.title|striptags }} {{ result.engine }}" /></a>
{% if result.content %}<p class="col-xs-12 col-sm-8 col-md-8 result-content">{{ result.content|safe }}</p>{% endif %}
</div>
</div>
{% if rtl %}
{{ result_footer_rtl(result) }}
{% else %}
{{ result_footer(result) }}
{% endif %}
<div class="result-content">
<a class="thumbnail" href="{{ result.url }}" {% if results_on_new_tab %}target="_blank" rel="noopener noreferrer"{% else %}rel="noreferrer"{% endif %}>
<img src="{{ image_proxify(result.thumbnail) }}" alt="{{ result.title|striptags }} {{ result.engine }}" />
</a>
<span>
{{ result_header(result, favicons) }}
{% call result_sub_header(result) -%}
{{result.engine}}
{%- endcall %}
</span>
</div>
\ No newline at end of file
......@@ -40,9 +40,11 @@
{% else %}
{% macro put_results(results_slice) -%}
{% macro put_results(results_slice, no_image=False) -%}
{%- for result in results_slice %}
{% set template = result.template|replace('.html', '') if result['template'] else None %}
{% if no_image and template == "images" and not image_gallery %}
{% else %}
<div class="result {% if template %}result-{{ template }}{% else %} result-default {% endif %}">
{% if template in ["torrent"] %}
<small class="result-template">{{template}}</small>
......@@ -55,12 +57,13 @@
{% include 'eelo/result_templates/default.html' %}
{% endif %}
</div>
{% endif %}
{%- endfor %}
{%- endmacro %}
<div id="results" {% if image_gallery %} class="image-gallery" {% endif %}>
{{ put_results(results[:3]) }}
{{ put_results(results[:3], True) }}
{% if image_results %}
<div id="image_result_mini_gallery_header">
......@@ -72,7 +75,7 @@
</div>
{% endif %}
{{ put_results(results[4:]) }}
{{ put_results(results[4:], True) }}
</div>
......
{% extends "eelo/base.html" %}
{% block title %}{{ _('stats') }} - {% endblock %}
{% block content %}
<div class="container-fluid">
<div class="container">
<h1>{{ _('Engine stats') }}</h1>
<div class="row">
{% for stat_name,stat_category in stats %}
......
......@@ -480,7 +480,18 @@ def index():
# search
searchData = None
try:
# we dont want users to select multiple categories, this simplifies the experience.
if request.form.get("categories"):
request.form["categories"] = "general"
if request.form.get("category"):
for k, v in request.form.items():
if k.startswith("category_"):
request.form.pop(k, None)
request.form["category_images"] = u"off"
request.form["category_" + request.form['category']] = u"On"
searchData = search(request)
except Exception as e:
# log exception
logger.exception('search error')
......@@ -491,7 +502,7 @@ def index():
else:
return index_error(), 500
# serarch 5 images and 5 videos
# serrch 5 images and 5 videos
images = []
videos = []
if searchData.categories == ['general'] and searchData.pageno == 1:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment