Skip to content

Commit

Permalink
[#2328] Processed tabpanel feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
jiromaykin authored and alextreme committed Apr 26, 2024
1 parent a8a59c6 commit a365067
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions src/open_inwoner/js/components/form/LoginForm.js
Original file line number Diff line number Diff line change
Expand Up @@ -50,13 +50,12 @@ export class LoginFormFocus {

activateTabFromHash() {
const hash = window.location.hash
const zakelijkTab = document.getElementById('zakelijk_tab')
const particulierTab = document.getElementById('particulier_tab')
const particulierPanel = document.getElementById('particulier_panel')
const zakelijkPanel = document.getElementById('zakelijk_panel')

if (hash.includes('zakelijk')) {
const zakelijkTab = document.getElementById('zakelijk_tab')
const particulierTab = document.getElementById('particulier_tab')

particulierTab.classList.remove('active')
particulierPanel.classList.remove('active')
particulierPanel.classList.add('hide')
Expand All @@ -65,16 +64,13 @@ export class LoginFormFocus {
zakelijkPanel.classList.add('active')
zakelijkTab.classList.add('active')
} else {
const zakelijkHeader = document.getElementById('zakelijk_tab')
const particulierHeader = document.getElementById('particulier_tab')

particulierPanel.classList.remove('hide')
particulierHeader.classList.add('active')
particulierTab.classList.add('active')
particulierPanel.classList.remove('active')

zakelijkPanel.classList.add('hide')
zakelijkPanel.classList.remove('active')
zakelijkHeader.classList.remove('active')
zakelijkTab.classList.remove('active')
}
}
}
Expand Down

0 comments on commit a365067

Please sign in to comment.