mirror of
https://github.com/mastodon/mastodon.git
synced 2024-11-30 08:16:17 +01:00
Fix hide and show media button on admin page (#6347)
This commit is contained in:
parent
3d881eed27
commit
8cd2828e91
@ -28,13 +28,13 @@ delegate(document, batchCheckboxClassName, 'change', () => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
delegate(document, '.media-spoiler-show-button', 'click', () => {
|
delegate(document, '.media-spoiler-show-button', 'click', () => {
|
||||||
[].forEach.call(document.querySelectorAll('.activity-stream .media-spoiler-wrapper'), (content) => {
|
[].forEach.call(document.querySelectorAll('button.media-spoiler'), (element) => {
|
||||||
content.classList.add('media-spoiler-wrapper__visible');
|
element.click();
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
delegate(document, '.media-spoiler-hide-button', 'click', () => {
|
delegate(document, '.media-spoiler-hide-button', 'click', () => {
|
||||||
[].forEach.call(document.querySelectorAll('.activity-stream .media-spoiler-wrapper'), (content) => {
|
[].forEach.call(document.querySelectorAll('.spoiler-button.spoiler-button--visible button'), (element) => {
|
||||||
content.classList.remove('media-spoiler-wrapper__visible');
|
element.click();
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user