Commit ef4fb63e authored by Dave Pisek's avatar Dave Pisek

Swap main with article-tag in sec dashboard app

This commit replaces the currently used `<main>` with an
`<article>` to ensure component re-usability.

(Using a main tag within a vue-component introduces the possibility
of having two or more main tags on a page, this causes accessbility
issues)
parent 563d3d00
...@@ -129,12 +129,12 @@ export default { ...@@ -129,12 +129,12 @@ export default {
<vulnerability-count-list v-if="isLockedToProject" class="mb-0" /> <vulnerability-count-list v-if="isLockedToProject" class="mb-0" />
<div class="row mt-4"> <div class="row mt-4">
<main role="main" class="col" :class="{ 'col-xl-7': !isLockedToProject }"> <article class="col" :class="{ 'col-xl-7': !isLockedToProject }">
<security-dashboard-table <security-dashboard-table
:dashboard-documentation="dashboardDocumentation" :dashboard-documentation="dashboardDocumentation"
:empty-state-svg-path="emptyStateSvgPath" :empty-state-svg-path="emptyStateSvgPath"
/> />
</main> </article>
<aside v-if="!isLockedToProject" class="col-xl-5"> <aside v-if="!isLockedToProject" class="col-xl-5">
<vulnerability-chart /> <vulnerability-chart />
......
...@@ -40,9 +40,7 @@ describe 'Group overview', :js do ...@@ -40,9 +40,7 @@ describe 'Group overview', :js do
it 'displays the Security Dashboard view' do it 'displays the Security Dashboard view' do
visit group_path(group) visit group_path(group)
page.within(find('main')) do expect(page).to have_selector('.js-security-dashboard-table')
expect(page).to have_selector('.js-security-dashboard-table')
end
page.within(find('aside')) do page.within(find('aside')) do
expect(page).to have_content 'Vulnerabilities over time' expect(page).to have_content 'Vulnerabilities over time'
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment