codeforamerica/ohana-web-search

View on GitHub
app/views/shared/_header.html.haml

Summary

Maintainability
Test Coverage
%header#content-header
  %h1#logo
    %a{ href: '/', target: '_self' }
      %img{ src: asset_path(SETTINGS[:site_logo]), alt: "#{SETTINGS[:site_title]} Logo" }
  %h2= t('branding.header', location: t('branding.location'))
  %nav
    %ul
      %li
        %a.popup-trigger.popup-default#about-btn{ href: '/about#about-box' }
          About
      %li
        %a.popup-trigger.popup-feedback#feedback-btn{ href: '/about#feedback-box', target: '_self' }
          Feedback
  .clearfix

-# Hide popups on /about because they are redundant to the content on that page.
- if controller_name != 'about'
  %aside#popups
    .popup-container.hide
      .arrow
        %span
      = render 'component/about/about'
    .popup-container.hide
      .arrow
        %span
      = render 'component/about/feedback', user_agent: user_agent