Commit 174c6052 authored by Karl Hasselbring's avatar Karl Hasselbring

Verbessertes Kartendesign, jetzt auch für Quicktips

parent 9cb547ba
...@@ -22,13 +22,12 @@ class Result ...@@ -22,13 +22,12 @@ class Result
public $engineBoost = 1; # Der Boost für den Provider des Suchergebnisses public $engineBoost = 1; # Der Boost für den Provider des Suchergebnisses
public $valid = true; # Ob das Ergebnis noch gültig ist (bool) public $valid = true; # Ob das Ergebnis noch gültig ist (bool)
public $host; # Der aus dem Link gelesene Host des Suchergebnisses public $host; # Der aus dem Link gelesene Host des Suchergebnisses
public $strippedHost; # Der Host in Form "foo.bar.de" public $strippedHost; # Der Host in Form "foo.bar.de"
public $strippedDomain; # Die Domain in Form "bar.de" public $strippedDomain; # Die Domain in Form "bar.de"
public $strippedLink; # Der Link in Form "foo.bar.de/test" public $strippedLink; # Der Link in Form "foo.bar.de/test"
public $rank; # Das Ranking für das Ergebnis public $rank; # Das Ranking für das Ergebnis
# Erstellt ein neues Ergebnis # Erstellt ein neues Ergebnis
#public function __construct($provider, $titel, $link, $anzeigeLink, $descr, $gefVon, $sourceRank, $partnershop = false, $image = "", $price = 0, $additionalInformation = [])
public function __construct($provider, $titel, $link, $anzeigeLink, $descr, $gefVon, $sourceRank, $additionalInformation = []) public function __construct($provider, $titel, $link, $anzeigeLink, $descr, $gefVon, $sourceRank, $additionalInformation = [])
{ {
$provider = simplexml_load_string($provider); $provider = simplexml_load_string($provider);
......
...@@ -71,7 +71,7 @@ abstract class Searchengine ...@@ -71,7 +71,7 @@ abstract class Searchengine
$this->useragent = "Mozilla/5.0 (Windows NT 6.1; WOW64; rv:40.0) Gecko/20100101 Firefox/40.1"; $this->useragent = "Mozilla/5.0 (Windows NT 6.1; WOW64; rv:40.0) Gecko/20100101 Firefox/40.1";
$this->ip = $metager->getIp(); $this->ip = $metager->getIp();
$this->gefVon = "<a href=\"" . $this->homepage . "\" target=\"_blank\" rel=\"noopener\">" . $this->displayName . "</a>"; $this->gefVon = $this->displayName;
$this->startTime = microtime(); $this->startTime = microtime();
# Suchstring generieren # Suchstring generieren
......
/* Quicktips */ /* Quicktips */
/*
* <div id="quicktips">
* <div class="quicktip" type="TYPE">
* <details>
* <summary>
* <h1><a href="URL">TITLE
* <p>SUMMARY
* <div class="quicktip-detail">
* <h1><a href="DETAILURL">DETAILTITLE
* <p>DETAILSUMMARY
* <span>GEFVON
* </...>
*/
#quicktips { #quicktips {
display: flex; display: flex;
flex-direction: column; flex-direction: column;
...@@ -25,7 +10,12 @@ ...@@ -25,7 +10,12 @@
.quicktip { .quicktip {
margin: 10px 0px; margin: 10px 0px;
padding: 10px 0px 10px 10px; padding: 10px 0px 10px 10px;
width: 100%;
border: 1px solid #ccc;
border-left: 3px solid #fb0; border-left: 3px solid #fb0;
@media(max-width: @screen-xs-max) {
box-shadow: 0px 1px 1.5px 0px rgba(0, 0, 0, 0.12), 1px 0px 1px 0px rgba(0, 0, 0, 0.24);
}
details:not([open=""]) { details:not([open=""]) {
.quicktip-summary p { .quicktip-summary p {
white-space: nowrap; white-space: nowrap;
...@@ -81,7 +71,7 @@ ...@@ -81,7 +71,7 @@
} }
} }
&[type=spendenaufruf] { &[type=spendenaufruf] {
border-left: #ddd; border: none;
color: #ff8000; color: #ff8000;
.quicktip-summary { .quicktip-summary {
display: flex; display: flex;
......
...@@ -11,40 +11,35 @@ ...@@ -11,40 +11,35 @@
@media(max-width: @screen-xs-max) { @media(max-width: @screen-xs-max) {
box-shadow: 0px 1px 1.5px 0px rgba(0, 0, 0, 0.12), 1px 0px 1px 0px rgba(0, 0, 0, 0.24); box-shadow: 0px 1px 1.5px 0px rgba(0, 0, 0, 0.12), 1px 0px 1px 0px rgba(0, 0, 0, 0.24);
} }
.result-title {
margin: 0px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
a,
a:active,
a:hover,
a:focus,
a:visited {
color: black;
font-size: @result-font-large;
font-weight: bold;
text-decoration: none;
}
}
.result-header { .result-header {
display: flex; .result-title {
>*:not(:first-child) { margin: 0px;
margin-left: 15px; overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
font-size: @result-font-large;
a {
&,
&:active,
&:hover,
&:focus,
&:visited {
color: black;
text-decoration: none;
}
}
} }
.result-link { .result-link {
overflow: auto; overflow: hidden;
a, text-overflow: ellipsis;
a:active, white-space: nowrap;
a:hover, font-size: @result-font-small;
a:focus, &,
a:visited { &:active,
white-space: nowrap; &:hover,
overflow: hidden; &:focus,
text-overflow: ellipsis; &:visited {
display: block;
color: #333; color: #333;
font-size: @result-font-small;
text-decoration: none; text-decoration: none;
} }
} }
...@@ -85,13 +80,19 @@ ...@@ -85,13 +80,19 @@
margin-top: 25px; margin-top: 25px;
display: flex; display: flex;
flex-wrap: wrap; flex-wrap: wrap;
&>* { &>*:not(:first-child) {
margin: 10px; margin-left: 20px;
} }
.result-open a { .result-open {
color: #ff8000; &,
&:active,
&:hover,
&:focus,
&:visited {
color: #ff8000;
}
} }
.result-open-newtab a { .result-open-newtab {
&, &,
&:active, &:active,
&:hover, &:hover,
...@@ -102,8 +103,7 @@ ...@@ -102,8 +103,7 @@
text-decoration: none; text-decoration: none;
} }
} }
.result-open-proxy, .result-open-proxy {
.result-open-proxy a {
&, &,
&:active, &:active,
&:hover, &:hover,
...@@ -144,6 +144,7 @@ ...@@ -144,6 +144,7 @@
background-color: #e0e0e0; background-color: #e0e0e0;
} }
a, a,
a:active,
a:hover, a:hover,
a:focus, a:focus,
a:visited { a:visited {
...@@ -154,19 +155,14 @@ ...@@ -154,19 +155,14 @@
} }
} }
&.ad .ad-label { &.ad .ad-label {
border: green solid 1px; &,
padding: 1px; & a,
color: green; & a:active,
border-radius: 4px; & a:hover,
} & a:focus,
.result-information { & a:visited {
border-radius: 5px; font-size: @result-font-small;
padding-left: 0px; color: #555;
&>.save {
position: absolute;
top: 0;
right: 10px;
cursor: pointer;
} }
} }
&>.remover { &>.remover {
......
@if(isset($ad) && !$apiAuthorized) @if(isset($ad) && !$apiAuthorized)
<div class="result ad"> <div class="result ad">
<h2 class="result-title"> <a class="ad-label" href="{!! $ad->link !!}" target="_blank" rel="noopener">Werbung von {!! $ad->gefVon !!}</a>
<a class="title" href="{{ $ad->link }}" target="{{ $metager->getNewtab() }}" data-hoster="{{ $ad->gefVon }}" data-count="0"> </span>
{{ $ad->titel }}
</a>
</h2>
<div class="result-header"> <div class="result-header">
<div class="result-link"> <h2 class="result-title">
<a href="{{ $ad->link }}" target="{{ $metager->getNewtab() }}" data-hoster="{{ $ad->gefVon }}" data-count="0"> <a href="{{ $ad->link }}" target="{{ $metager->getNewtab() }}">
{{ $ad->anzeigeLink }} {{ $ad->titel }}
</a> </a>
</div> </h2>
<span class="result-hoster"> <a class="result-link" href="{{ $ad->link }}" target="{{ $metager->getNewtab() }}">
<span class="ad-label">{!! trans('ad.werbung') !!}</span> {!! trans('ad.von') !!} {!! $ad->gefVon !!} {{ $ad->anzeigeLink }}
</span> </a>
</div> </div>
<div class="result-description"> <div class="result-body">
{{ $ad->descr }} <div class="result-description">
{{ $ad->descr }}
</div>
</div> </div>
</div> </div>
@endif @endif
<div class="result" data-count="{{ $result->number }}"> <div class="result">
<h2 class="result-title">
<a href="{{ $result->link }}" target="{{ $metager->getNewtab() }}" data-hoster="{{ strip_tags($result->gefVon) }}" data-count="{{ $result->number }}" rel="noopener">
{!! $result->titel !!}
</a>
</h2>
<div class="result-header"> <div class="result-header">
<div class="result-link"> <h2 class="result-title">
<a href="{{ $result->link }}" target="{{ $metager->getNewtab() }}" data-hoster="{{ strip_tags($result->gefVon) }}" data-count="{{ $result->number }}" rel="noopener"> <a href="{{ $result->link }}" target="{{ $metager->getNewtab() }}" rel="noopener">
{{ $result->anzeigeLink }} {!! $result->titel !!}
</a> </a>
</div> </h2>
<a class="result-link" href="{{ $result->link }}" target="{{ $metager->getNewtab() }}" rel="noopener">
{{ $result->anzeigeLink }}
</a>
@if( isset($result->partnershop) && $result->partnershop === TRUE ) @if( isset($result->partnershop) && $result->partnershop === TRUE )
<span class="partnershop-info"> <span class="partnershop-info">
<img src="/img/boosticon.png" height="13" alt=""> <img src="/img/boosticon.png" height="13" alt="">
...@@ -20,14 +18,14 @@ ...@@ -20,14 +18,14 @@
<div class="result-body"> <div class="result-body">
@if( isset($result->logo) ) @if( isset($result->logo) )
<div class="result-logo"> <div class="result-logo">
<a href="{{ $result->link }}" target="{{ $metager->getNewtab() }}" data-hoster="{{ strip_tags($result->gefVon) }}" data-count="{{ $result->number }}"> <a href="{{ $result->link }}" target="{{ $metager->getNewtab() }}" rel="noopener">
<img src="{{ $metager->getImageProxyLink($result->logo) }}" alt="" /> <img src="{{ $metager->getImageProxyLink($result->logo) }}" alt="" />
</a> </a>
</div> </div>
@endif @endif
@if( $result->image !== "" ) @if( $result->image !== "" )
<div class="result-image result-description"> <div class="result-image result-description">
<a href="{{ $result->link }}" target="{{ $metager->getNewtab() }}" data-hoster="{{ strip_tags($result->gefVon) }}" data-count="{{ $result->number }}" rel="noopener"> <a href="{{ $result->link }}" target="{{ $metager->getNewtab() }}" rel="noopener">
<img src="{{ $metager->getImageProxyLink($result->image) }}" align="left" width="120px" height="60px" alt="" /> <img src="{{ $metager->getImageProxyLink($result->image) }}" align="left" width="120px" height="60px" alt="" />
</a> </a>
{!! $result->descr !!} {!! $result->descr !!}
...@@ -45,22 +43,16 @@ ...@@ -45,22 +43,16 @@
@endif @endif
</div> </div>
<div class="result-footer"> <div class="result-footer">
<div class="result-open"> <a class="result-open" href="{{ $result->link }}" target="_self" rel="noopener">
<a href="{{ $result->link }}" target="_self" data-hoster="{{ strip_tags($result->gefVon) }}" rel="noopener"> ÖFFNEN
<span>ÖFFNEN</span> </a>
</a> <a class="result-open-newtab" href="{{ $result->link }}" target="_blank" rel="noopener">
</div> IN NEUEM TAB
<div class="result-open-newtab"> </a>
<a href="{{ $result->link }}" target="_blank" data-hoster="{{ strip_tags($result->gefVon) }}" rel="noopener"> <a class="result-open-proxy" onmouseover="$(this).popover('show');" onmouseout="$(this).popover('hide');" data-toggle="popover" data-placement="auto right" data-container="body" data-content="@lang('result.proxytext')" href="{{ $result->proxyLink }}" target="{{ $metager->getNewtab() }}" rel="noopener">
<span>IN NEUEM TAB</span> <img src="/img/proxyicon.png" alt="" />
</a> ANONYM ÖFFNEN
</div> </a>
<div class="result-open-proxy">
<a onmouseover="$(this).popover('show');" onmouseout="$(this).popover('hide');" data-toggle="popover" data-placement="auto right" data-container="body" data-content="@lang('result.proxytext')" href="{{ $result->proxyLink }}" target="{{ $metager->getNewtab() }}" rel="noopener">
<img src="/img/proxyicon.png" alt="" />
<span>ANONYM ÖFFNEN</span>
</a>
</div>
<div class="result-options"> <div class="result-options">
<a class="dropdown-opener" href="javascript:void(0);"> <a class="dropdown-opener" href="javascript:void(0);">
<i class="fa fa-chevron-down option-opener-icon" aria-hidden="true"></i> <i class="fa fa-chevron-down option-opener-icon" aria-hidden="true"></i>
...@@ -72,7 +64,7 @@ ...@@ -72,7 +64,7 @@
</li> </li>
<hr> <hr>
<li class="js-only"> <li class="js-only">
<a href="javascript:resultSaver({{ $result->number }});" class="saver" data-counter="{{ $result->number }}"> <a href="javascript:resultSaver({{ $result->number }});" class="saver">
<i class="fa fa-floppy-o"></i> {!! trans('result.options.savetab') !!} <i class="fa fa-floppy-o"></i> {!! trans('result.options.savetab') !!}
</a> </a>
</li> </li>
......
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