From a1311ee2509f45277dfeb1382b9a0e434ff71b15 Mon Sep 17 00:00:00 2001 From: Aldarien Date: Fri, 10 Apr 2020 14:39:18 -0400 Subject: [PATCH] Afinaciones --- bootstrap/web/config.php | 3 +- common/Controller/Web/Home.php | 12 ++-- public/assets/styles/header.css | 9 --- public/assets/styles/home.css | 6 +- public/assets/styles/main.css | 12 +++- resources/views/home/clientes.blade.php | 66 ++++++++++--------- resources/views/home/contacto.blade.php | 4 +- resources/views/home/eventos.blade.php | 60 +++++++++++++++-- resources/views/home/testimonios.blade.php | 13 ++-- resources/views/layout/footer.blade.php | 6 +- .../views/layout/footer/contacto.blade.php | 2 +- resources/views/layout/footer/redes.blade.php | 17 +++++ .../views/layout/footer/ubicacion.blade.php | 4 +- resources/views/layout/menu.blade.php | 15 ++--- 14 files changed, 150 insertions(+), 79 deletions(-) delete mode 100644 public/assets/styles/header.css diff --git a/bootstrap/web/config.php b/bootstrap/web/config.php index 18424c4..bee7612 100644 --- a/bootstrap/web/config.php +++ b/bootstrap/web/config.php @@ -61,7 +61,8 @@ return [ 'https://cdnjs.cloudflare.com/ajax/libs/fomantic-ui/2.8.4/themes/default/assets/fonts/icons.woff2', 'https://cdnjs.cloudflare.com/ajax/libs/fomantic-ui/2.8.4/themes/default/assets/fonts/outline-icons.woff', 'https://cdnjs.cloudflare.com/ajax/libs/fomantic-ui/2.8.4/themes/default/assets/fonts/outline-icons.woff2', - 'https://fonts.googleapis.com/css2?family=Roboto:wght@300;400;900&display=swap' + 'https://fonts.googleapis.com/css2?family=Roboto:wght@300;400;900&display=swap', + 'https://fonts.googleapis.com/css2?family=Raleway:wght@800&display=swap' ] ] ] diff --git a/common/Controller/Web/Home.php b/common/Controller/Web/Home.php index 767bcf5..8b054e6 100644 --- a/common/Controller/Web/Home.php +++ b/common/Controller/Web/Home.php @@ -20,7 +20,7 @@ class Home { ]; $clientes = []; for ($i = 0; $i < 20; $i ++) { - $clientes[$i] = '
' . $i . '
'; + $clientes[$i] = '
' . $i . '
'; } $testimonios = $this->loadData($container, 'testimonios'); @@ -29,13 +29,11 @@ class Home { if (!isset($evento->image)) { $evento->image = '
'; } + if (!isset($evento->servicio)) { + $evento->servicio = mt_rand(0, count($servicios) - 1); + } } - /*$eventos = [ - (object) [ - 'titulo' => '2da Corrida Famliar Inclusiva DIMERC', - 'image' => '
' - ] - ];*/ + return $view->render($response, 'home', compact('banner', 'servicios', 'frase', 'clientes', 'testimonios', 'eventos')); } diff --git a/public/assets/styles/header.css b/public/assets/styles/header.css deleted file mode 100644 index 16c8451..0000000 --- a/public/assets/styles/header.css +++ /dev/null @@ -1,9 +0,0 @@ -#page_logo { - font-family: Raleway, sans-serif; - font-weight: 800; - font-size: 2.2rem; - color: #404041; -} -#page_logo .orange { - color: #F26721; -} diff --git a/public/assets/styles/home.css b/public/assets/styles/home.css index 17bad2c..abfb4a8 100644 --- a/public/assets/styles/home.css +++ b/public/assets/styles/home.css @@ -41,9 +41,9 @@ #clientes .header:first-child { padding-bottom: 1rem; } -#clientes .ci { - display: flex; - align-items: center +#clientes #img_clientes .row { + padding-top: 0; + padding-bottom: 0; } #testimonios { diff --git a/public/assets/styles/main.css b/public/assets/styles/main.css index 11b773b..8fc42f5 100644 --- a/public/assets/styles/main.css +++ b/public/assets/styles/main.css @@ -2,6 +2,16 @@ body, .ui { font-family: Roboto, sans-serif !important; } +#page_logo { + font-family: Raleway, sans-serif; + font-weight: 800; + font-size: 2.2rem; + color: #404041; +} +#page_logo .orange { + color: #F26721; +} + footer { flex: none; color: white; @@ -9,7 +19,7 @@ footer { font-family: Roboto; } footer .dark-grey { - background-color: grey; + background-color: #404041; } footer .grid { margin: 0 !important; diff --git a/resources/views/home/clientes.blade.php b/resources/views/home/clientes.blade.php index f359b54..14e3f91 100644 --- a/resources/views/home/clientes.blade.php +++ b/resources/views/home/clientes.blade.php @@ -3,29 +3,33 @@ CLIENTES
-
- -
-
-
-
- @for ($i = 0; $i < min(10, count($clientes)); $i += 2) -
- {!!$clientes[$i]!!} -
- @endfor -
-
- @for ($i = 1; $i < min(10, count($clientes)); $i += 2) -
- {!!$clientes[$i]!!} -
- @endfor -
+
+
+ +
+
+
-
- +
+
+
+
+ @for ($i = 0; $i < min(12, count($clientes)); $i += 2) +
+ {!!$clientes[$i]!!} +
+ @endfor +
+
+ @for ($i = 1; $i < min(12, count($clientes)); $i += 2) +
+ {!!$clientes[$i]!!} +
+ @endfor +
+
+
@@ -38,34 +42,36 @@ @endforeach ] var current = 0 + var rows = 2 + var cols = 6 function decreaseClientes() { $('#img_clientes').find('.row').find('.column:last-child').remove() - current -= 2 - if (current < -8) { - current = clientes.length - 10 + current -= rows + if (current < - cols * rows) { + current = clientes.length - (cols - 1) * rows } n = current if (n < 0) { n = clientes.length + n } $('#img_clientes').find('.row:first-child').prepend( - $('
').attr('class', 'three wide column').append(clientes[n]) + $('
').attr('class', 'five wide tablet two wide computer column').append(clientes[n]) ) $('#img_clientes').find('.row:last-child').prepend( - $('
').attr('class', 'three wide column').append(clientes[n + 1]) + $('
').attr('class', 'five wide tablet two wide computer column').append(clientes[n + 1]) ) } function increaseClientes() { $('#img_clientes').find('.row').find('.column:first-child').remove() current += 2 - if (current > clientes.length - 10) { - current = -8 + if (current > clientes.length - cols * rows) { + current = - (cols - 1) * rows } $('#img_clientes').find('.row:first-child').append( - $('
').attr('class', 'three wide column').append(clientes[current + 8]) + $('
').attr('class', 'five wide tablet two wide computer column').append(clientes[current + (cols - 1) * rows]) ) $('#img_clientes').find('.row:last-child').append( - $('
').attr('class', 'three wide column').append(clientes[current + 9]) + $('
').attr('class', 'five wide tablet two wide computer column').append(clientes[current + cols * rows - 1]) ) } $(document).ready(function() { diff --git a/resources/views/home/contacto.blade.php b/resources/views/home/contacto.blade.php index ea4a895..0d5ac5e 100644 --- a/resources/views/home/contacto.blade.php +++ b/resources/views/home/contacto.blade.php @@ -8,7 +8,7 @@
-
+
@@ -35,7 +35,7 @@ @push('scripts') +@endpush diff --git a/resources/views/home/testimonios.blade.php b/resources/views/home/testimonios.blade.php index 2ecf216..a38b26e 100644 --- a/resources/views/home/testimonios.blade.php +++ b/resources/views/home/testimonios.blade.php @@ -32,9 +32,9 @@ }, @endforeach ] - var current = 0 + var current_testimonio = 0 function cambiar(id) { - if (id == current) { + if (id == current_testimonio) { return } $('#testimonio').html('').append( @@ -42,15 +42,18 @@ ).append( $('
').attr('class', 'ui header').html(testimonios[id].emisor) ) - $('#marcador').find(".icon[data-id='" + current + "']").addClass('outline') + $('#marcador').find(".icon[data-id='" + current_testimonio + "']").addClass('outline') $('#marcador').find(".icon[data-id='" + id + "']").removeClass('outline') - current = id + $('#marcador').find('.icon.outline').css('cursor', 'pointer') + $('#marcador').find('.icon:not(.outline)').css('cursor', 'default') + current_testimonio = id } $(document).ready(function() { - $('#marcador').find('.icon').css('cursor', 'pointer').click(function() { + $('#marcador').find('.icon').click(function() { var id = $(this).attr('data-id') cambiar(id) }) + $('#marcador').find('.icon.outline').css('cursor', 'pointer') }) @endpush diff --git a/resources/views/layout/footer.blade.php b/resources/views/layout/footer.blade.php index e2bc714..c976ed1 100644 --- a/resources/views/layout/footer.blade.php +++ b/resources/views/layout/footer.blade.php @@ -3,13 +3,13 @@