philomena/assets/js/staffhider.js

18 lines
307 B
JavaScript
Raw Permalink Normal View History

2019-10-05 02:09:52 +02:00
/**
* StaffHider
*
* Hide staff elements if enabled in the settings.
*/
import { $$ } from './utils/dom';
function hideStaffTools() {
if (window.booru.hideStaffTools === 'true') {
2019-10-05 02:09:52 +02:00
$$('.js-staff-action').forEach(el => {
el.classList.add('hidden');
});
}
}
export { hideStaffTools };