From a021a279554416123233d7a3cf769180ade04a51 Mon Sep 17 00:00:00 2001 From: Sergiotarxz Date: Wed, 23 Aug 2023 16:34:12 +0200 Subject: [PATCH] Modifying the Burguillos.info logo. --- lib/BurguillosInfo/Ad.pm | 6 +-- lib/BurguillosInfo/Ads/Anunciate.pm | 19 +++++++- lib/BurguillosInfo/Ads/YoTeLoGuiso.pm | 12 +++-- public/css/styles.css | 29 +++++++----- public/css/styles.scss | 22 ++++++--- public/img/burguillos-new-logo.svg | 67 ++++++++++++++++----------- 6 files changed, 101 insertions(+), 54 deletions(-) diff --git a/lib/BurguillosInfo/Ad.pm b/lib/BurguillosInfo/Ad.pm index 0bdeb1c..6003cb0 100644 --- a/lib/BurguillosInfo/Ad.pm +++ b/lib/BurguillosInfo/Ad.pm @@ -13,12 +13,8 @@ has alternative => ( is => 'rw' ); -sub max_alternative { - return 0; -} - sub regenerate_alternative($self) { - $self->alternative(int(rand() * ($self->max_alternative+1))); + $self->alternative(rand()); } sub weight { diff --git a/lib/BurguillosInfo/Ads/Anunciate.pm b/lib/BurguillosInfo/Ads/Anunciate.pm index 09a7588..834e8e2 100644 --- a/lib/BurguillosInfo/Ads/Anunciate.pm +++ b/lib/BurguillosInfo/Ads/Anunciate.pm @@ -12,6 +12,15 @@ use Moo; use parent 'BurguillosInfo::Ad'; + +sub max_alternative { + return 1; +} + +sub default_alternative($self) { + return int($self->alternative * ($self->max_alternative + 1)); +} + sub weight { return 10; } @@ -24,7 +33,10 @@ sub is_active ($self) { return 1; } -sub seconds { +sub seconds($self) { + if ($self->default_alternative == 1) { + return 5; + } return 8; } @@ -36,7 +48,10 @@ sub href { return 'mailto:contact@owlcode.tech?subject=Quiero%20anunciarme%20en%20Burguillos.info'; } -sub text { +sub text($self) { + if ($self->default_alternative == 1) { + return '¡Anunciate en Burguillos.info! Precios a partir de 18.15€, pulsa aquí y escribenos.'; + } return 'Pulsando este anuncio puedes enviarnos un correo para anunciarte en este sitio. ¡Si me ves funciona!'; } diff --git a/lib/BurguillosInfo/Ads/YoTeLoGuiso.pm b/lib/BurguillosInfo/Ads/YoTeLoGuiso.pm index ae5d34a..1c60817 100644 --- a/lib/BurguillosInfo/Ads/YoTeLoGuiso.pm +++ b/lib/BurguillosInfo/Ads/YoTeLoGuiso.pm @@ -24,25 +24,29 @@ sub max_alternative { return 3; } +sub default_alternative($self) { + return int($self->alternative * ($self->max_alternative + 1)); +} + sub is_active ($self) { return 1; } sub img ($self) { - if ( $self->alternative == 2 ) { + if ( $self->default_alternative == 2 ) { return '/img/anuncio-yo-te-lo-guiso-3.webp'; } - if ( $self->alternative == 1 ) { + if ( $self->default_alternative == 1 ) { return '/img/anuncio-yo-te-lo-guiso-2.webp'; } return '/img/anuncio-yo-te-lo-guiso-1.webp'; } sub text($self) { - if ( $self->alternative == 2 ) { + if ( $self->default_alternative == 2 ) { return '¡Comida distinta cada día! Ven a YoTeLoGuiso.'; } - if ( $self->alternative == 1 ) { + if ( $self->default_alternative == 1 ) { return 'Una comida como esta no la ves todos los días, disponible en Burguillos, entra y descubrelo.'; } diff --git a/public/css/styles.css b/public/css/styles.css index c79ee40..75a5f34 100644 --- a/public/css/styles.css +++ b/public/css/styles.css @@ -163,15 +163,17 @@ body { body div.page-contents div.description a.suscribe-category-rss img { width: 40px; height: 40px; } + body div.page-contents nav.mobile-shortcuts > a { + display: flex; + align-items: center; + justify-content: center; } body div.page-contents nav > a.menu-expand > img { width: 30px; - height: 30px; - padding-top: 15px; } + height: 30px; } body div.page-contents nav > a > img.index-image-menu { vertical-align: middle; - width: 50px; - height: 50px; - padding-bottom: 10px; } + width: 40px; + height: 40px; } body div.page-contents nav.desktop { display: none; } body div.page-contents nav.desktop a { @@ -182,8 +184,6 @@ body { display: block; font-size: 25px; margin: 0px; } - body div.page-contents nav a.go-to-index img { - margin-top: 5%; } body div.page-contents nav a { padding-left: 10px; padding-right: 10px; @@ -214,7 +214,11 @@ body { top: 0%; } body div.page-contents nav.mobile-shortcuts a { height: 100%; - width: 16.6666666667%; } + width: 16.6666666667%; + padding-left: 0; + padding-top: 0; + padding-right: 0; + padding-bottom: 0; } body div.page-contents nav.mobile-shortcuts div { width: 66.6666666667%; } body div.page-contents nav.mobile-foldable { @@ -259,11 +263,14 @@ body { margin-right: 10%; } body div.page-contents nav.desktop { display: block; - height: auto; } + height: auto; + height: 60px; } body div.page-contents nav.desktop a { - display: table-cell; } + display: table-cell; + height: 60px; } body div.page-contents nav.desktop a img.index-image-menu { - padding-top: 15px; } + height: 40px; + width: 40px; } body div.page-contents nav.mobile-shortcuts { display: none; } body div.page-contents.no-carousel { diff --git a/public/css/styles.scss b/public/css/styles.scss index 770c3ff..5d8c7f3 100644 --- a/public/css/styles.scss +++ b/public/css/styles.scss @@ -240,17 +240,21 @@ body { } } + nav.mobile-shortcuts > a { + display:flex; + align-items: center; + justify-content: center; + } + nav > a.menu-expand > img { width: 30px; height: 30px; - padding-top: 15px; } nav > a > img.index-image-menu { vertical-align: middle; - width: 50px; - height: 50px; - padding-bottom: 10px; + width: 40px; + height: 40px; } nav.desktop { @@ -269,7 +273,6 @@ body { margin: 0px; a.go-to-index img { - margin-top: 5%; } a { @@ -321,6 +324,10 @@ body { a { height: 100%; width: (100% / 6); + padding-left: 0; + padding-top: 0; + padding-right: 0; + padding-bottom: 0; } div { @@ -410,12 +417,15 @@ body { nav.desktop { display: block; height: auto; + height: 60px; a { display: table-cell; + height: 60px; img.index-image-menu { - padding-top: 15px; + height: 40px; + width: 40px; } } } diff --git a/public/img/burguillos-new-logo.svg b/public/img/burguillos-new-logo.svg index c8c2053..7b0404a 100644 --- a/public/img/burguillos-new-logo.svg +++ b/public/img/burguillos-new-logo.svg @@ -24,9 +24,9 @@ inkscape:deskcolor="#d1d1d1" inkscape:document-units="mm" showgrid="false" - inkscape:zoom="1.3932941" - inkscape:cx="424.53349" - inkscape:cy="274.1704" + inkscape:zoom="0.49260385" + inkscape:cx="508.52221" + inkscape:cy="261.87371" inkscape:window-width="1920" inkscape:window-height="1011" inkscape:window-x="0" @@ -34,6 +34,11 @@ inkscape:window-maximized="1" inkscape:current-layer="layer1" /> + style="fill:#8400b4;fill-opacity:1;stroke:#8400b4;stroke-width:2.70604;stroke-dasharray:none" + d="m 6.2765833,52.32988 16.9366957,-8.80056 7.764406,6.625174 C 21.126656,46.000841 12.943755,49.985234 6.2765833,52.32988 Z" + id="path2078" + sodipodi:nodetypes="cccc" />