const content = UiDialog.getDialog(this)!.content;
content.querySelector("h1")!.textContent = Language.get("wcf.acp.dataImport.completed");
const spinner = content.querySelector("fa-icon")!;
- spinner.setIcon("check", true);
+ spinner.setIcon("check");
const formSubmit = document.createElement("div");
formSubmit.className = "formSubmit";
});
const spinner = content.querySelector("fa-icon")!;
- spinner.setIcon("check", true);
+ spinner.setIcon("check");
spinner.parentElement!.dataset.status = "success";
const formSubmit = document.createElement("div");
const dialog = UiDialog.getDialog(this);
if (dialog !== undefined) {
const spinner = dialog.content.querySelector("fa-icon")!;
- spinner.setIcon("xmark", true);
+ spinner.setIcon("xmark");
spinner.parentElement!.dataset.status = "error";
}
const icon = document.createElement("fa-icon");
icon.size = 48;
- icon.setIcon("spinner", true);
+ icon.setIcon("spinner");
this._overlay.appendChild(icon);
const title = document.createElement("span");
const title = toggleButton.dataset.titleExpand!;
const icon = toggleButton.querySelector("fa-icon");
if (icon) {
- icon.setIcon("up-right-and-down-left-from-center", true);
+ icon.setIcon("up-right-and-down-left-from-center");
toggleButton.title = title;
} else {
toggleButton.textContent = title;
const title = toggleButton.dataset.titleCollapse!;
const icon = toggleButton.querySelector("fa-icon");
if (icon) {
- icon.setIcon("down-left-and-up-right-to-center", true);
+ icon.setIcon("down-left-and-up-right-to-center");
toggleButton.title = title;
} else {
toggleButton.textContent = title;
const icon = button.querySelector(".jsIconNotificationSettingsEmailType fa-icon") as FaIcon;
switch (value) {
case "daily":
- icon.setIcon("clock", false);
+ icon.setIcon("clock");
break;
case "instant":
- icon.setIcon("bolt", true);
+ icon.setIcon("bolt");
break;
case "none":
- icon.setIcon("xmark", true);
+ icon.setIcon("xmark");
break;
}
});
const fileIcon = file.querySelector("fa-icon")!;
- fileIcon.setIcon("xmark", true);
+ fileIcon.setIcon("xmark");
fileIcon.insertAdjacentElement("beforebegin", deleteButton);
deleteButton.append(fileIcon);
}
const fileIcon = DomTraverse.childByTag(DomTraverse.childByClass(file, "mediaThumbnail")!, "FA-ICON")!;
- fileIcon.setIcon("xmark", true);
+ fileIcon.setIcon("xmark");
file.classList.add("uploadFailed", "pointer", "jsTooltip");
file.title = Language.get("wcf.global.button.delete");
const icon = document.createElement("fa-icon");
icon.size = 64;
- icon.setIcon("spinner", false);
+ icon.setIcon("spinner");
const fileName = element.textContent;
element.textContent = "";
small.innerHTML = "";
const icon = fileElement.querySelector("fa-icon")!;
- icon.setIcon("ban", true);
+ icon.setIcon("ban");
const innerError = document.createElement("span");
innerError.className = "innerError";
small.innerHTML = "";
const icon = fileElement.querySelector("fa-icon")!;
- icon.setIcon("ban", true);
+ icon.setIcon("ban");
let innerError = fileElement.querySelector(".innerError") as HTMLElement;
if (innerError === null) {
const icon = button.querySelector("fa-icon")!;
if (type === "showAll") {
- icon.setIcon("eye", false);
+ icon.setIcon("eye");
} else {
- icon.setIcon("eye-slash", false);
+ icon.setIcon("eye-slash");
}
}
}
actionElement.nodeName === "FA-ICON" ? (actionElement as FaIcon) : actionElement.querySelector("fa-icon");
if (icon) {
if (icon.name === "square") {
- icon.setIcon("square-check", false);
+ icon.setIcon("square-check");
const newTitle = actionElement.dataset.disableTitle || Language.get("wcf.global.button.disable");
actionElement.title = newTitle;
} else {
- icon.setIcon("square", false);
+ icon.setIcon("square");
const newTitle = actionElement.dataset.enableTitle || Language.get("wcf.global.button.enable");
actionElement.title = newTitle;
const icon = document.createElement("fa-icon");
icon.size = 16;
- icon.setIcon("eye", false);
+ icon.setIcon("eye");
button.appendChild(icon);
button.addEventListener("click", () => {
function toggle(input: HTMLInputElement, button: HTMLElement, icon: FaIcon): void {
if (input.type === "password") {
- icon.setIcon("eye-slash", false);
+ icon.setIcon("eye-slash");
button.dataset.tooltip = Language.get("wcf.global.form.password.button.hide");
input.type = "text";
} else {
- icon.setIcon("eye-slash", true);
+ icon.setIcon("eye-slash");
button.dataset.tooltip = Language.get("wcf.global.form.password.button.show");
input.type = "password";
}
const content = Dialog_1.default.getDialog(this).content;
content.querySelector("h1").textContent = Language.get("wcf.acp.dataImport.completed");
const spinner = content.querySelector("fa-icon");
- spinner.setIcon("check", true);
+ spinner.setIcon("check");
const formSubmit = document.createElement("div");
formSubmit.className = "formSubmit";
formSubmit.innerHTML = `<button class="button buttonPrimary">${Language.get("wcf.global.button.next")}</button>`;
Dialog_1.default.setCallback(this, "onClose", () => this.onClose());
});
const spinner = content.querySelector("fa-icon");
- spinner.setIcon("check", true);
+ spinner.setIcon("check");
spinner.parentElement.dataset.status = "success";
const formSubmit = document.createElement("div");
formSubmit.className = "formSubmit";
const dialog = Dialog_1.default.getDialog(this);
if (dialog !== undefined) {
const spinner = dialog.content.querySelector("fa-icon");
- spinner.setIcon("xmark", true);
+ spinner.setIcon("xmark");
spinner.parentElement.dataset.status = "error";
}
return true;
this._overlay.setAttribute("role", "status");
const icon = document.createElement("fa-icon");
icon.size = 48;
- icon.setIcon("spinner", true);
+ icon.setIcon("spinner");
this._overlay.appendChild(icon);
const title = document.createElement("span");
title.textContent = Language.get("wcf.global.loading");
const title = toggleButton.dataset.titleExpand;
const icon = toggleButton.querySelector("fa-icon");
if (icon) {
- icon.setIcon("up-right-and-down-left-from-center", true);
+ icon.setIcon("up-right-and-down-left-from-center");
toggleButton.title = title;
}
else {
const title = toggleButton.dataset.titleCollapse;
const icon = toggleButton.querySelector("fa-icon");
if (icon) {
- icon.setIcon("down-left-and-up-right-to-center", true);
+ icon.setIcon("down-left-and-up-right-to-center");
toggleButton.title = title;
}
else {
const icon = button.querySelector(".jsIconNotificationSettingsEmailType fa-icon");
switch (value) {
case "daily":
- icon.setIcon("clock", false);
+ icon.setIcon("clock");
break;
case "instant":
- icon.setIcon("bolt", true);
+ icon.setIcon("bolt");
break;
case "none":
- icon.setIcon("xmark", true);
+ icon.setIcon("xmark");
break;
}
_objectId = 0;
EventHandler.fire("com.woltlab.wcf.media.upload", "removedErroneousUploadRow");
});
const fileIcon = file.querySelector("fa-icon");
- fileIcon.setIcon("xmark", true);
+ fileIcon.setIcon("xmark");
fileIcon.insertAdjacentElement("beforebegin", deleteButton);
deleteButton.append(fileIcon);
file.classList.add("uploadFailed");
};
}
const fileIcon = DomTraverse.childByTag(DomTraverse.childByClass(file, "mediaThumbnail"), "FA-ICON");
- fileIcon.setIcon("xmark", true);
+ fileIcon.setIcon("xmark");
file.classList.add("uploadFailed", "pointer", "jsTooltip");
file.title = Language.get("wcf.global.button.delete");
file.addEventListener("click", () => file.remove());
const progress = element.querySelector("progress");
const icon = document.createElement("fa-icon");
icon.size = 64;
- icon.setIcon("spinner", false);
+ icon.setIcon("spinner");
const fileName = element.textContent;
element.textContent = "";
element.append(icon);
const small = fileElement.querySelector("small");
small.innerHTML = "";
const icon = fileElement.querySelector("fa-icon");
- icon.setIcon("ban", true);
+ icon.setIcon("ban");
const innerError = document.createElement("span");
innerError.className = "innerError";
innerError.textContent = Language.get("wcf.upload.error.uploadFailed");
const small = fileElement.querySelector("small");
small.innerHTML = "";
const icon = fileElement.querySelector("fa-icon");
- icon.setIcon("ban", true);
+ icon.setIcon("ban");
let innerError = fileElement.querySelector(".innerError");
if (innerError === null) {
innerError = document.createElement("span");
}
const icon = button.querySelector("fa-icon");
if (type === "showAll") {
- icon.setIcon("eye", false);
+ icon.setIcon("eye");
}
else {
- icon.setIcon("eye-slash", false);
+ icon.setIcon("eye-slash");
}
}
}
const icon = actionElement.nodeName === "FA-ICON" ? actionElement : actionElement.querySelector("fa-icon");
if (icon) {
if (icon.name === "square") {
- icon.setIcon("square-check", false);
+ icon.setIcon("square-check");
const newTitle = actionElement.dataset.disableTitle || Language.get("wcf.global.button.disable");
actionElement.title = newTitle;
}
else {
- icon.setIcon("square", false);
+ icon.setIcon("square");
const newTitle = actionElement.dataset.enableTitle || Language.get("wcf.global.button.enable");
actionElement.title = newTitle;
}
inputAddon.appendChild(button);
const icon = document.createElement("fa-icon");
icon.size = 16;
- icon.setIcon("eye", false);
+ icon.setIcon("eye");
button.appendChild(icon);
button.addEventListener("click", () => {
toggle(input, button, icon);
}
function toggle(input, button, icon) {
if (input.type === "password") {
- icon.setIcon("eye-slash", false);
+ icon.setIcon("eye-slash");
button.dataset.tooltip = Language.get("wcf.global.form.password.button.hide");
input.type = "text";
}
else {
- icon.setIcon("eye-slash", true);
+ icon.setIcon("eye-slash");
button.dataset.tooltip = Language.get("wcf.global.form.password.button.show");
input.type = "password";
}