MediaWiki:MarcEditorDynamicLinks.js: mudanças entre as edições

Conteúdo deletado Conteúdo adicionado
Sem resumo de edição
Sem resumo de edição
 
(3 revisões intermediárias pelo mesmo usuário não estão sendo mostradas)
Linha 1:
/* jshint esversion: 810 */
function main() {
// calling main functions
makeMarcFieldHelpLink();
authorityLinks();
setIndicators();
rmCarriageReturn();
rmHtmlTags();
Linha 20 ⟶ 21:
if (newNodes.length !== 0) {
// if there are new nodes added
console.log('observer before:', newNodes.length);
makeMarcFieldHelpLink();
authorityLinks();
console.logsetIndicators('observer after');
}
});
Linha 52:
}
 
// document.addEventListener('DOMContentLoaded', () => main());
// if (document.readyState === 'complete' || document.readyState !== 'loading') {
// main();
// console.log(document.readyState);
// } else {
// document.addEventListener('DOMContentLoaded', main);
// console.log('DOMContentLoaded');
// }
 
document.addEventListener("DOMContentLoaded", function(event) {
makeMarcFieldHelpLink();
authorityLinks();
main();
});
 
// for no obvious reason to me, the first call to the "main" function is not
// occurring, so wait 3 seconds and call it anyway.
// setTimeout(main, 3000);