app/views/accounts/_piv_cac.html.erb
<h2 class="margin-top-0 margin-bottom-1">
<%= t('headings.account.federal_employee_id') %>
</h2>
<div role="list">
<% MfaContext.new(current_user).piv_cac_configurations.each do |configuration| %>
<%= render ManageableAuthenticatorComponent.new(
configuration:,
user_session:,
manage_url: edit_piv_cac_path(id: configuration.id),
manage_api_url: api_internal_two_factor_authentication_piv_cac_path(id: configuration.id),
custom_strings: {
deleted: t('two_factor_authentication.piv_cac.deleted'),
renamed: t('two_factor_authentication.piv_cac.renamed'),
manage_accessible_label: t('two_factor_authentication.piv_cac.manage_accessible_label'),
},
role: 'listitem',
) %>
<% end %>
</div>
<% if current_user.piv_cac_configurations.count < IdentityConfig.store.max_piv_cac_per_account %>
<%= render ButtonComponent.new(
url: setup_piv_cac_url,
icon: :add,
outline: true,
class: 'margin-top-2',
).with_content(t('account.index.piv_cac_add')) %>
<% end %>