Diferencia entre revisiones de «MediaWiki:Gadget-show-quality-on-cats.js»

m
tweak
m (tweak)
m (tweak)
const page = response.query.pages[id];
all[page.title] = page.categories.map(function(o){ return o.title.replace('Category:','') });
})
 
document.querySelectorAll('#mw-pages a').forEach(function (el) {
Object.keys(icons).forEach(function (cat) {
const title = el.getAttribute('title')
const data = all[title]
if (!data.categories.includes(cat)) { return }
console.log(title, 'is a', cat)
})
})
 
40 275

ediciones