1
0
mirror of https://github.com/BookStackApp/BookStack.git synced 2025-07-30 04:23:11 +03:00

Converted image-manager to be component/HTML based

Instead of vue based.
This commit is contained in:
Dan Brown
2020-07-25 00:20:58 +01:00
parent b6aa232205
commit 02dc3154e3
23 changed files with 483 additions and 392 deletions

View File

@ -106,4 +106,15 @@ export function findText(selector, text) {
*/
export function showLoading(element) {
element.innerHTML = `<div class="loading-container"><div></div><div></div><div></div></div>`;
}
/**
* Remove any loading indicators within the given element.
* @param {Element} element
*/
export function removeLoading(element) {
const loadingEls = element.querySelectorAll('.loading-container');
for (const el of loadingEls) {
el.remove();
}
}