19 Zeilen
746 B
TypeScript
19 Zeilen
746 B
TypeScript
const he = document.getElementsByClassName("headers-end")[0];
|
|
const header = document.createElement("span");
|
|
header.classList.add("heading");
|
|
header.classList.add("more-actions");
|
|
he.appendChild(header);
|
|
const library_list = document.getElementsByClassName("library-items")[0];
|
|
for (let c = 0; c < library_list.childElementCount; c++) {
|
|
const child = library_list.children[c];
|
|
const item_bar = child.getElementsByClassName("item-bar")[0];
|
|
if (!child.classList.contains("pre-order")) {
|
|
const button = child.getElementsByClassName("remove-from-library")[0];
|
|
const parent = button.parentNode!;
|
|
parent.removeChild(button);
|
|
item_bar.appendChild(button);
|
|
} else {
|
|
item_bar.appendChild(document.createElement("span"));
|
|
}
|
|
}
|