Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

981:rendered meetthedev on homepage #154

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 14 additions & 8 deletions web/modules/custom/posse_dc/posse_dc.module
Original file line number Diff line number Diff line change
Expand Up @@ -10,28 +10,34 @@ function posse_dc_preprocess(&$variables, $hook) {
$testimonial_block = views_embed_view('testimonial', 'block_1');
$testimonial['testimonial_block'] = $testimonial_block;

$meetthedevblock_block = views_embed_view('meetthedevblock', 'block_1');
$meetthedevblock['meetthedevblock_block'] = $meetthedevblock_block;

$services_block = \Drupal\block\Entity\Block::load('services');
$services_block_content = \Drupal::entityManager()
->getViewBuilder('block')
->view($services_block);

$variables['services_block'] = $services_block_content;

$posse_config = \Drupal::config('posse_dc.possesettings');

$variables['blog_display'] = (bool) $posse_config->get('blog_display');

$variables['portfolio_display'] = (bool) $posse_config->get('portfolio_display');

$variables['services_display'] = (bool) $posse_config->get('services_display');

$variables['meetthedevblock_display'] = (bool) $posse_config->get('meetthedevblock_display');

$variables['testimonial_display'] = (bool) $posse_config->get('testimonial_display');

$variables['service_1_title'] = $posse_config->get('service_1_title');
$variables['service_1_title'] = $posse_config->get('service_1_title');
$variables['service_1_body'] = $posse_config->get('service_1_body');
$variables['service_2_title'] = $posse_config->get('service_2_title');
$variables['service_2_body'] = $posse_config->get('service_2_body');
$variables['service_3_title'] = $posse_config->get('service_3_title');
$variables['service_3_body'] = $posse_config->get('service_3_body');
$variables['service_2_title'] = $posse_config->get('service_2_title');
$variables['service_2_body'] = $posse_config->get('service_2_body');
$variables['service_3_title'] = $posse_config->get('service_3_title');
$variables['service_3_body'] = $posse_config->get('service_3_body');
$variables['posse_color'] = $posse_config->get('posse_color');

}
Original file line number Diff line number Diff line change
Expand Up @@ -52,16 +52,15 @@
<div class="container-flex meetdev-photos">
<img src="{{ base_path ~ directory }}/images/coffee-cup.jpg" alt="coffee"><img src="{{ base_path ~ directory }}/images/the-dev.jpg" alt="photo of Reed Richards"><img src="{{ base_path ~ directory }}/images/boston-pup.jpg" alt="dog"><img src="{{ base_path ~ directory }}/images/imac.jpg" alt="computer"><img src="{{ base_path ~ directory }}/images/camera.jpg" alt="camera"></div>
<div class="meetthedev-titles">
<h2>Meet the Dev</h2>
<h2>{{ content }}</h2>
<h3>Reed Richards</h3>
</div>
<div class="meetthedev-icons">
<img src="{{ base_path ~ directory }}/images/angular.png" alt="Angular logo">
<img src="{{ base_path ~ directory }}/images/drupal7.png" alt="Drupal 7 logo">
<img src="{{ base_path ~ directory }}/images/wordpress.png" alt="Wordpress logo">
</div>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>
<div class="meetthedev-social">
<p>{{ meetthedevblock_display }}</p>
<ul>
<li><a href="http://www.facebook.com">Facebook</a></li>
<li><a href="http://www.twitter.com">Twitter</a></li>
Expand Down
15 changes: 14 additions & 1 deletion web/themes/custom/posse_theme/templates/page--front.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,19 @@
</div>
</div>
{% endif %}
{% if meetthedevblock_display %}
<div class="meetthedevblock-wrapper">
<div class="{{ container }}">
<div class="row">
<div class="col-xs-12">
<h2 id="meetthedev-tittles">Meet the Dev</h2>
<h3 id="meetthedev">Reed Richards</h3>
{{ meetthedevblock_block }}
</div>
</div>
</div>
</div>
{% endif %}
{% if testimonial_display %}
<div class="testimonial-wrapper">
<div class="{{ container }}">
Expand Down Expand Up @@ -154,7 +167,7 @@
{% endblock %}
{% endif %}
</div>
</div>
</div>

{% if blog_display %}
<div class="blog-wrapper">
Expand Down