SUPPORT-9601: fix
This commit is contained in:
parent
16c09f721f
commit
e4aad2bc6f
3 changed files with 24 additions and 7 deletions
|
|
@ -33,7 +33,9 @@
|
|||
<div class="container-inside">
|
||||
<div class="list-group lk-what">
|
||||
<div>
|
||||
<div class="title short-text"><a href="<!--#echo var='ulUrl'-->">Личный кабинет</a> для ведения воинского учета в организациях</div>
|
||||
<div class="title short-text">
|
||||
<a href="<!--#echo var='ulUrl'-->"
|
||||
id="login-link">Личный кабинет</a> для ведения воинского учета в организациях</div>
|
||||
<div class="paragraph">
|
||||
<div class="paragraph-left">
|
||||
<div class="text icon-checklist">Кому доступен личный кабинет?</div>
|
||||
|
|
|
|||
|
|
@ -127,6 +127,13 @@ a.btn.disabled {
|
|||
opacity: 0.5;
|
||||
cursor: not-allowed;
|
||||
}
|
||||
|
||||
.disabled-link {
|
||||
pointer-events: none;
|
||||
opacity: 0.5;
|
||||
cursor: not-allowed;
|
||||
}
|
||||
|
||||
button:is(:hover, :focus, :active),
|
||||
a.btn:is(:hover, :focus, :active) {
|
||||
background: var(--color-link-hover);
|
||||
|
|
@ -143,6 +150,8 @@ a.btn:is(:hover, :focus, :active) {
|
|||
background: transparent;
|
||||
}
|
||||
|
||||
|
||||
|
||||
.header {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
|
|
|
|||
|
|
@ -63,6 +63,16 @@ function checkCsp(cspTimeout) {
|
|||
window.addEventListener('DOMContentLoaded', () => {
|
||||
const browserCheckInfo = document.getElementById('browser-check-info');
|
||||
const loginButton = document.getElementById('login-button');
|
||||
const loginLink = document.getElementById('login-link');
|
||||
|
||||
const disableLogin = () => {
|
||||
if (loginButton && loginLink) {
|
||||
loginButton.href = '';
|
||||
loginLink.href = '';
|
||||
loginButton.classList.add('disabled');
|
||||
loginLink.classList.add('disabled-link');
|
||||
}
|
||||
};
|
||||
|
||||
const browserPassed = checkBrowser();
|
||||
|
||||
|
|
@ -74,15 +84,11 @@ window.addEventListener('DOMContentLoaded', () => {
|
|||
}
|
||||
} else {
|
||||
if (loginButton) {
|
||||
loginButton.classList.add('disabled');
|
||||
loginButton.addEventListener('click', (e) => e.preventDefault());
|
||||
disableLogin();
|
||||
}
|
||||
}
|
||||
});
|
||||
} else {
|
||||
if (loginButton) {
|
||||
loginButton.classList.add('disabled');
|
||||
loginButton.addEventListener('click', (e) => e.preventDefault());
|
||||
}
|
||||
disableLogin();
|
||||
}
|
||||
});
|
||||
Loading…
Add table
Add a link
Reference in a new issue