essai de fix du pb de clic sur les liens statics
This commit is contained in:
parent
9f8f9f3a62
commit
f9c98d6941
|
@ -99,11 +99,13 @@ import router from './router/router';
|
|||
|
||||
function processStaticLinks(store, map) {
|
||||
let general_link_fields = document.querySelectorAll('#menu > ul > li > a');
|
||||
for (let field of general_link_fields) {
|
||||
let general_link_href = field.getAttribute('href');
|
||||
for (let i =1; i < general_link_fields.length; i ++) {
|
||||
let general_link_href = general_link_fields[i].getAttribute('href');
|
||||
const nid = general_link_href.charAt(general_link_href.length-1);
|
||||
field.setAttribute('data-node-nid', parseInt(nid));
|
||||
field.addEventListener('click', (e) => onClickContentLink(e, store, map, 'static'));
|
||||
if (!isNaN(nid)) {
|
||||
general_link_fields[i].setAttribute('data-node-nid', parseInt(nid));
|
||||
general_link_fields[i].addEventListener('click', (e) => onClickContentLink(e, store, map, 'static'));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -138,14 +138,7 @@ const handleMapMovement = () => {
|
|||
watch(
|
||||
() => href.value,
|
||||
() => {
|
||||
console.log("NEW HREF");
|
||||
console.log(href.value);
|
||||
|
||||
isModaleEtape = !isObjectEmpty(etape.value);
|
||||
|
||||
console.log("CAS 1", !wasModaleEtape && isModaleEtape);
|
||||
console.log("CAS 2", wasModaleEtape && isModaleEtape);
|
||||
console.log("CAS 3", wasModaleEtape && !isModaleEtape);
|
||||
|
||||
if (!wasModaleEtape && isModaleEtape) {
|
||||
document.documentElement.style.setProperty('--modale-enter-delay', `${duration.value}s`);
|
||||
|
|
Loading…
Reference in New Issue