Skip to content
Merged
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
2 changes: 2 additions & 0 deletions app/views/accounts/connected_accounts/show.html.erb
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
<% title t('account.navigation.connected_accounts') %>

<h1 class="mt0">
<%= t('headings.account.connected_accounts') %>
Comment on lines +1 to 4
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thinking out loud a bit: It's sensible that the page's title and the page's h1 are the same, which raises a question whether it's worth having duplicate strings for these. And if we do have duplicate strings (one for the navigation and one for the page title), whether the value we use in title should be the same as the page's h1, or the same as what's shown in the navigation.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, 100% agree

</h1>
Expand Down
2 changes: 2 additions & 0 deletions app/views/accounts/history/show.html.erb
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
<% title t('account.navigation.history') %>

<h1 class="mt0">
<%= t('account.navigation.history') %>
</h1>
Expand Down
2 changes: 2 additions & 0 deletions app/views/accounts/two_factor_authentication/show.html.erb
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
<% title t('account.navigation.two_factor_authentication') %>

<h1 class="mt0">
<%= t('headings.account.two_factor') %>
</h1>
Expand Down
5 changes: 4 additions & 1 deletion app/views/layouts/account_side_nav.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@
<%= render 'accounts/nav_auth', enable_mobile_nav: true, greeting: @view_model.header_personalization %>
<% end %>

<% content_for(:mobile_nav) do %>
<%= render 'accounts/mobile_nav' %>
<% end %>

<% content_for :content do %>
<div class="top-banner grid-row grid-gap mb3">
<div class="grid-offset-3 grid-col-3">
Expand Down Expand Up @@ -29,5 +33,4 @@
</div>
<% end %>

<%= render 'accounts/mobile_nav' %>
<%= render template: 'layouts/base', locals: { disable_card: true } %>
2 changes: 2 additions & 0 deletions app/views/layouts/base.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,8 @@
</head>

<body class="<%= Rails.env %>-env site <%= yield(:background_cls) %>">
<div class="usa-overlay"></div>
<%= yield(:mobile_nav) if content_for?(:mobile_nav) %>
<div class="site-wrap bg-light-blue">
<%= render 'shared/banner' %>
<div aria-label="main-navigation" role="navigation">
Expand Down
5 changes: 4 additions & 1 deletion spec/views/accounts/_nav_auth.html.erb_spec.rb
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
require 'rails_helper'

describe 'accounts/_nav_auth.html.erb' do
include Devise::Test::ControllerHelpers

before do
@user = build_stubbed(:user, :signed_up)
@user = build_stubbed(:user, :with_backup_code)
allow(view).to receive(:greeting).and_return(@user.email)
allow(view).to receive(:current_user).and_return(@user)
end

context 'user is signed in' do
Expand Down