commit
8537eea89d
|
@ -711,6 +711,18 @@ h6 {
|
|||
right: 0px;
|
||||
}
|
||||
|
||||
.right-7 {
|
||||
right: 1.75rem;
|
||||
}
|
||||
|
||||
.top-1\.5 {
|
||||
top: 0.375rem;
|
||||
}
|
||||
|
||||
.top-1 {
|
||||
top: 0.25rem;
|
||||
}
|
||||
|
||||
.left-3 {
|
||||
left: 0.75rem;
|
||||
}
|
||||
|
@ -795,6 +807,14 @@ h6 {
|
|||
z-index: -10;
|
||||
}
|
||||
|
||||
.z-0 {
|
||||
z-index: 0;
|
||||
}
|
||||
|
||||
.z-10 {
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
.z-990 {
|
||||
z-index: 990;
|
||||
}
|
||||
|
@ -807,18 +827,10 @@ h6 {
|
|||
z-index: 1020;
|
||||
}
|
||||
|
||||
.z-10 {
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
.z-50 {
|
||||
z-index: 50;
|
||||
}
|
||||
|
||||
.z-0 {
|
||||
z-index: 0;
|
||||
}
|
||||
|
||||
.order-2 {
|
||||
order: 2;
|
||||
}
|
||||
|
@ -990,6 +1002,10 @@ h6 {
|
|||
margin-top: 0.75rem;
|
||||
}
|
||||
|
||||
.ml-2 {
|
||||
margin-left: 0.5rem;
|
||||
}
|
||||
|
||||
.mt-8 {
|
||||
margin-top: 2rem;
|
||||
}
|
||||
|
@ -1014,14 +1030,18 @@ h6 {
|
|||
margin-left: 1.5rem;
|
||||
}
|
||||
|
||||
.ml-2 {
|
||||
margin-left: 0.5rem;
|
||||
}
|
||||
|
||||
.mb-8 {
|
||||
margin-bottom: 2rem;
|
||||
}
|
||||
|
||||
.mb-7 {
|
||||
margin-bottom: 1.75rem;
|
||||
}
|
||||
|
||||
.mt-1 {
|
||||
margin-top: 0.25rem;
|
||||
}
|
||||
|
||||
.mt-2 {
|
||||
margin-top: 0.5rem;
|
||||
}
|
||||
|
@ -1050,14 +1070,6 @@ h6 {
|
|||
margin-top: 1.5rem;
|
||||
}
|
||||
|
||||
.mb-7 {
|
||||
margin-bottom: 1.75rem;
|
||||
}
|
||||
|
||||
.mt-1 {
|
||||
margin-top: 0.25rem;
|
||||
}
|
||||
|
||||
.mr-6 {
|
||||
margin-right: 1.5rem;
|
||||
}
|
||||
|
@ -1122,6 +1134,10 @@ h6 {
|
|||
height: 3rem;
|
||||
}
|
||||
|
||||
.h-5 {
|
||||
height: 1.25rem;
|
||||
}
|
||||
|
||||
.h-4 {
|
||||
height: 1rem;
|
||||
}
|
||||
|
@ -1138,14 +1154,14 @@ h6 {
|
|||
height: 2.5rem;
|
||||
}
|
||||
|
||||
.h-5 {
|
||||
height: 1.25rem;
|
||||
}
|
||||
|
||||
.h-48 {
|
||||
height: 12rem;
|
||||
}
|
||||
|
||||
.h-3 {
|
||||
height: 0.75rem;
|
||||
}
|
||||
|
||||
.h-19 {
|
||||
height: 4.75rem;
|
||||
}
|
||||
|
@ -1166,10 +1182,6 @@ h6 {
|
|||
height: 7.5rem;
|
||||
}
|
||||
|
||||
.h-3 {
|
||||
height: 0.75rem;
|
||||
}
|
||||
|
||||
.h-\[90vh\] {
|
||||
height: 90vh;
|
||||
}
|
||||
|
@ -1262,6 +1274,10 @@ h6 {
|
|||
width: 10rem;
|
||||
}
|
||||
|
||||
.w-5 {
|
||||
width: 1.25rem;
|
||||
}
|
||||
|
||||
.w-4 {
|
||||
width: 1rem;
|
||||
}
|
||||
|
@ -1286,8 +1302,8 @@ h6 {
|
|||
width: 3rem;
|
||||
}
|
||||
|
||||
.w-5 {
|
||||
width: 1.25rem;
|
||||
.w-3 {
|
||||
width: 0.75rem;
|
||||
}
|
||||
|
||||
.w-28 {
|
||||
|
@ -1306,10 +1322,6 @@ h6 {
|
|||
width: 22.5rem;
|
||||
}
|
||||
|
||||
.w-3 {
|
||||
width: 0.75rem;
|
||||
}
|
||||
|
||||
.w-80 {
|
||||
width: 20rem;
|
||||
}
|
||||
|
@ -1322,6 +1334,14 @@ h6 {
|
|||
min-width: 900px;
|
||||
}
|
||||
|
||||
.min-w-\[400px\] {
|
||||
min-width: 400px;
|
||||
}
|
||||
|
||||
.min-w-\[500px\] {
|
||||
min-width: 500px;
|
||||
}
|
||||
|
||||
.max-w-\[300px\] {
|
||||
max-width: 300px;
|
||||
}
|
||||
|
@ -1334,10 +1354,6 @@ h6 {
|
|||
max-width: 10rem;
|
||||
}
|
||||
|
||||
.max-w-screen-sm {
|
||||
max-width: 576px;
|
||||
}
|
||||
|
||||
.max-w-\[400px\] {
|
||||
max-width: 400px;
|
||||
}
|
||||
|
@ -1354,10 +1370,18 @@ h6 {
|
|||
max-width: 100%;
|
||||
}
|
||||
|
||||
.max-w-screen-sm {
|
||||
max-width: 576px;
|
||||
}
|
||||
|
||||
.max-w-lg {
|
||||
max-width: 32rem;
|
||||
}
|
||||
|
||||
.max-w-\[350px\] {
|
||||
max-width: 350px;
|
||||
}
|
||||
|
||||
.flex-auto {
|
||||
flex: 1 1 auto;
|
||||
}
|
||||
|
@ -1424,6 +1448,11 @@ h6 {
|
|||
transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
|
||||
}
|
||||
|
||||
.translate-x-1 {
|
||||
--tw-translate-x: 0.25rem;
|
||||
transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
|
||||
}
|
||||
|
||||
.-translate-x-full {
|
||||
--tw-translate-x: -100%;
|
||||
transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
|
||||
|
@ -1439,11 +1468,6 @@ h6 {
|
|||
transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
|
||||
}
|
||||
|
||||
.translate-x-1 {
|
||||
--tw-translate-x: 0.25rem;
|
||||
transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
|
||||
}
|
||||
|
||||
.-translate-y-7 {
|
||||
--tw-translate-y: -1.75rem;
|
||||
transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
|
||||
|
@ -1527,6 +1551,10 @@ h6 {
|
|||
grid-template-columns: repeat(2, minmax(0, 1fr));
|
||||
}
|
||||
|
||||
.flex-row {
|
||||
flex-direction: row;
|
||||
}
|
||||
|
||||
.flex-col {
|
||||
flex-direction: column;
|
||||
}
|
||||
|
@ -1640,10 +1668,6 @@ h6 {
|
|||
border-radius: 50%;
|
||||
}
|
||||
|
||||
.rounded-10 {
|
||||
border-radius: 2.5rem;
|
||||
}
|
||||
|
||||
.rounded-1\.4 {
|
||||
border-radius: 0.35rem;
|
||||
}
|
||||
|
@ -1652,6 +1676,10 @@ h6 {
|
|||
border-radius: 0.25rem;
|
||||
}
|
||||
|
||||
.rounded-10 {
|
||||
border-radius: 2.5rem;
|
||||
}
|
||||
|
||||
.rounded-md {
|
||||
border-radius: 0.375rem;
|
||||
}
|
||||
|
@ -2789,6 +2817,10 @@ h6 {
|
|||
background-color: rgb(8 85 119 / 0.05);
|
||||
}
|
||||
|
||||
.hover\:bg-blue-500\/80:hover {
|
||||
background-color: rgb(94 114 228 / 0.8);
|
||||
}
|
||||
|
||||
.hover\:bg-gray-50:hover {
|
||||
--tw-bg-opacity: 1;
|
||||
background-color: rgb(248 249 250 / var(--tw-bg-opacity));
|
||||
|
@ -2981,14 +3013,14 @@ h6 {
|
|||
--tw-gradient-to: transparent;
|
||||
}
|
||||
|
||||
.dark .dark\:fill-gray-700 {
|
||||
fill: #495057;
|
||||
}
|
||||
|
||||
.dark .dark\:fill-gray-300 {
|
||||
fill: #d2d6da;
|
||||
}
|
||||
|
||||
.dark .dark\:fill-gray-700 {
|
||||
fill: #495057;
|
||||
}
|
||||
|
||||
.dark .dark\:fill-gray-500 {
|
||||
fill: #adb5bd;
|
||||
}
|
||||
|
@ -3018,6 +3050,10 @@ h6 {
|
|||
color: rgb(245 57 57 / var(--tw-text-opacity));
|
||||
}
|
||||
|
||||
.dark .dark\:opacity-80 {
|
||||
opacity: 0.8;
|
||||
}
|
||||
|
||||
.dark .dark\:opacity-50 {
|
||||
opacity: 0.5;
|
||||
}
|
||||
|
@ -3026,10 +3062,6 @@ h6 {
|
|||
opacity: 0.9;
|
||||
}
|
||||
|
||||
.dark .dark\:opacity-80 {
|
||||
opacity: 0.8;
|
||||
}
|
||||
|
||||
.dark .dark\:opacity-60 {
|
||||
opacity: 0.6;
|
||||
}
|
||||
|
@ -3366,10 +3398,6 @@ h6 {
|
|||
grid-column: span 8 / span 8;
|
||||
}
|
||||
|
||||
.lg\:col-span-3 {
|
||||
grid-column: span 3 / span 3;
|
||||
}
|
||||
|
||||
.lg\:mx-8 {
|
||||
margin-left: 2rem;
|
||||
margin-right: 2rem;
|
||||
|
|
|
@ -73,13 +73,16 @@ class darkMode {
|
|||
},
|
||||
body: JSON.stringify({ darkmode: isDark }),
|
||||
};
|
||||
const send = await fetch(`${location.href.split("/").slice(0, -1).join("/")}/darkmode`, data);
|
||||
const send = await fetch(
|
||||
`${location.href.split("/").slice(0, -1).join("/")}/darkmode`,
|
||||
data
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
class FlashMsg {
|
||||
constructor() {
|
||||
this.delayBeforeRemove = 5000;
|
||||
this.delayBeforeRemove = 8000;
|
||||
this.init();
|
||||
}
|
||||
|
||||
|
@ -95,6 +98,16 @@ class FlashMsg {
|
|||
}, this.delayBeforeRemove);
|
||||
} catch (err) {}
|
||||
});
|
||||
|
||||
window.addEventListener("click", (e) => {
|
||||
try {
|
||||
if (e.target.closest("button").hasAttribute("close-flash-message")) {
|
||||
const closeBtn = e.target.closest("button");
|
||||
const flashEl = closeBtn.closest("[flash-message]");
|
||||
flashEl.remove();
|
||||
}
|
||||
} catch (err) {}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -25,7 +25,6 @@ class FilterSettings {
|
|||
const settingCount = settings.length;
|
||||
let hiddenCount = 0;
|
||||
settings.forEach((setting) => {
|
||||
console.log(setting);
|
||||
try {
|
||||
const title = setting
|
||||
.querySelector("h5")
|
||||
|
@ -96,7 +95,6 @@ class Multiple {
|
|||
`[${this.prefix}-settings-multiple]`
|
||||
);
|
||||
multiples.forEach((container) => {
|
||||
console.log(container.querySelectorAll(`[setting-container]`));
|
||||
if (container.querySelectorAll(`[setting-container]`).length <= 0)
|
||||
container.parentElement
|
||||
.querySelector("[multiple-handler]")
|
||||
|
|
|
@ -148,7 +148,6 @@ class Dropdown {
|
|||
|
||||
//hide date filter on local
|
||||
hideFilterOnLocal(type) {
|
||||
console.log(type);
|
||||
if (type === "local") {
|
||||
this.hideInp(`input#from-date`);
|
||||
this.hideInp(`input#to-date`);
|
||||
|
@ -197,7 +196,6 @@ class Filter {
|
|||
const value = document
|
||||
.querySelector(`[${this.prefix}-setting-select-text="success"]`)
|
||||
.textContent.trim();
|
||||
console.log(value);
|
||||
|
||||
this.successValue = value;
|
||||
//run filter
|
||||
|
@ -219,7 +217,6 @@ class Filter {
|
|||
const value = document
|
||||
.querySelector(`[${this.prefix}-setting-select-text="reload"]`)
|
||||
.textContent.trim();
|
||||
console.log(value);
|
||||
|
||||
this.reloadValue = value;
|
||||
//run filter
|
||||
|
@ -330,9 +327,8 @@ class Download {
|
|||
if (response.status === 200) {
|
||||
const res = await response.json();
|
||||
//last update
|
||||
return console.log(res);
|
||||
return;
|
||||
} else {
|
||||
console.log(`Error: ${response.status}`);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
|
|
@ -149,7 +149,6 @@ class Dropdown {
|
|||
|
||||
//hide date filter on local
|
||||
hideFilterOnLocal(type) {
|
||||
console.log(type);
|
||||
if (type === "local") {
|
||||
this.hideInp(`input#from-date`);
|
||||
this.hideInp(`input#to-date`);
|
||||
|
@ -266,7 +265,6 @@ class FetchLogs {
|
|||
}
|
||||
|
||||
async getLogsFromToDate() {
|
||||
console.log(this.fromDate, this.toDate);
|
||||
let response;
|
||||
if (this.toDate) {
|
||||
response = await fetch(
|
||||
|
|
|
@ -147,7 +147,6 @@ class Dropdown {
|
|||
|
||||
//hide date filter on local
|
||||
hideFilterOnLocal(type) {
|
||||
console.log(type);
|
||||
if (type === "local") {
|
||||
this.hideInp(`input#from-date`);
|
||||
this.hideInp(`input#to-date`);
|
||||
|
@ -193,7 +192,6 @@ class Filter {
|
|||
const btnValue = btn.getAttribute("value");
|
||||
|
||||
this.lastType = btnValue;
|
||||
console.log(this.lastType);
|
||||
//run filter
|
||||
this.filter();
|
||||
}
|
||||
|
@ -402,6 +400,62 @@ class Upload {
|
|||
}
|
||||
}
|
||||
|
||||
class Modal {
|
||||
constructor(prefix = "plugins") {
|
||||
this.prefix = prefix;
|
||||
this.container = document.querySelector(`[${this.prefix}-list]`);
|
||||
this.modal = document.querySelector(`[${this.prefix}-modal]`);
|
||||
this.modalNameInp = this.modal.querySelector("input#name");
|
||||
this.modalTitle = this.modal.querySelector(`[${this.prefix}-modal-title]`);
|
||||
this.modalTxt = this.modal.querySelector(`[${this.prefix}-modal-text]`);
|
||||
this.init();
|
||||
}
|
||||
|
||||
init() {
|
||||
this.container.addEventListener("click", (e) => {
|
||||
//DELETE HANDLER
|
||||
try {
|
||||
if (
|
||||
e.target.closest("button").getAttribute(`${this.prefix}`) === "delete"
|
||||
) {
|
||||
const btnEl = e.target.closest("button");
|
||||
const name = btnEl.getAttribute("name");
|
||||
this.setModal(name);
|
||||
this.showModal();
|
||||
}
|
||||
} catch (err) {}
|
||||
});
|
||||
|
||||
this.modal.addEventListener("click", (e) => {
|
||||
//CLOSE MODAL HANDLER
|
||||
try {
|
||||
if (
|
||||
e.target.closest("button").hasAttribute(`${this.prefix}-modal-close`)
|
||||
) {
|
||||
this.hideModal();
|
||||
}
|
||||
} catch (err) {}
|
||||
});
|
||||
}
|
||||
|
||||
setModal(name) {
|
||||
this.modalNameInp.value = name;
|
||||
this.modalTitle.textContent = `DELETE ${name}`;
|
||||
this.modalTxt.textContent = `Are you sure you want to delete ${name}`;
|
||||
}
|
||||
|
||||
showModal() {
|
||||
this.modal.classList.add("flex");
|
||||
this.modal.classList.remove("hidden");
|
||||
}
|
||||
|
||||
hideModal() {
|
||||
this.modal.classList.add("hidden");
|
||||
this.modal.classList.remove("flex");
|
||||
}
|
||||
}
|
||||
|
||||
const setDropdown = new Dropdown("plugins");
|
||||
const setFilter = new Filter("plugins");
|
||||
const setUpload = new Upload();
|
||||
const setModal = new Modal("plugins");
|
||||
|
|
|
@ -7,16 +7,20 @@ class ServiceModal {
|
|||
this.modal = document.querySelector("[services-modal]");
|
||||
this.modalTitle = this.modal.querySelector("[services-modal-title]");
|
||||
this.modalTabs = this.modal.querySelector(["[services-tabs]"]);
|
||||
this.modalTabsHeader = this.modal.querySelector(["[services-tabs-header]"]);
|
||||
|
||||
this.modalCard = this.modal.querySelector("[services-modal-card]");
|
||||
//modal forms
|
||||
this.formNewEdit = this.modal.querySelector("[services-modal-form]");
|
||||
this.formDelete = this.modal.querySelector("[services-modal-form-delete]");
|
||||
this.formRename = this.modal.querySelector("[services-modal-form-rename]");
|
||||
//container
|
||||
this.container = document.querySelector("main");
|
||||
//general inputs
|
||||
this.inputs = this.modal.querySelectorAll("input[default-value]");
|
||||
this.selects = this.modal.querySelectorAll("select[default-value]");
|
||||
this.lastGroup = "";
|
||||
this.lastAction = "";
|
||||
|
||||
this.init();
|
||||
}
|
||||
|
@ -35,57 +39,59 @@ class ServiceModal {
|
|||
});
|
||||
|
||||
this.container.addEventListener("click", (e) => {
|
||||
//delete button
|
||||
//actions
|
||||
try {
|
||||
if (
|
||||
e.target.closest("button").getAttribute("services-action") ===
|
||||
"delete"
|
||||
) {
|
||||
this.setDeleteForm(
|
||||
"delete",
|
||||
e.target.closest("button").getAttribute("services-name")
|
||||
);
|
||||
this.openModal();
|
||||
}
|
||||
} catch (err) {}
|
||||
//new button
|
||||
try {
|
||||
if (
|
||||
e.target.closest("button").getAttribute("services-action") === "new"
|
||||
) {
|
||||
this.setNewEditForm("new", "service");
|
||||
this.setDefaultValue();
|
||||
this.openModal();
|
||||
}
|
||||
} catch (err) {}
|
||||
//edit button
|
||||
try {
|
||||
if (
|
||||
e.target.closest("button").getAttribute("services-action") === "edit"
|
||||
) {
|
||||
//no reupdate if same service
|
||||
if (e.target.closest("button").hasAttribute("services-action")) {
|
||||
//do nothing if same btn and service as before
|
||||
const isLastSame = this.isLastServAndAct(e.target);
|
||||
if (isLastSame) return;
|
||||
//else set the good form
|
||||
const action = e.target
|
||||
.closest("button")
|
||||
.getAttribute("services-action");
|
||||
const serviceName = e.target
|
||||
.closest("button")
|
||||
.getAttribute("services-name");
|
||||
|
||||
if (this.lastGroup === serviceName) return this.openModal();
|
||||
//else
|
||||
this.lastGroup = serviceName;
|
||||
this.setNewEditForm("edit", serviceName);
|
||||
//change this to hidden config on service card later
|
||||
const servicesSettings = e.target
|
||||
.closest("[services-service]")
|
||||
.querySelector("[services-settings]")
|
||||
.getAttribute("value");
|
||||
this.setDefaultValue();
|
||||
const obj = JSON.parse(servicesSettings);
|
||||
this.updateModalData(obj);
|
||||
let form;
|
||||
if (action === "edit" || action === "new") form = this.formNewEdit;
|
||||
if (action === "delete") form = this.formDelete;
|
||||
if (action === "rename") form = this.formRename;
|
||||
this.setForm(action, serviceName, form);
|
||||
//reset settings value
|
||||
if (action === "edit" || action === "new") this.setDefaultValue();
|
||||
//get custom settings of service and apply it to modal settings
|
||||
if (action === "edit") {
|
||||
const servicesSettings = e.target
|
||||
.closest("[services-service]")
|
||||
.querySelector("[services-settings]")
|
||||
.getAttribute("value");
|
||||
const obj = JSON.parse(servicesSettings);
|
||||
this.updateModalData(obj);
|
||||
}
|
||||
//open modal when all done
|
||||
this.openModal();
|
||||
}
|
||||
} catch (err) {}
|
||||
});
|
||||
}
|
||||
|
||||
isLastServAndAct(target) {
|
||||
const serviceName = target.closest("button").getAttribute("services-name");
|
||||
const serviceAction = target
|
||||
.closest("button")
|
||||
.getAttribute("services-action");
|
||||
|
||||
if (this.lastGroup === serviceName && this.lastAction === serviceAction) {
|
||||
this.openModal();
|
||||
return true;
|
||||
} else {
|
||||
this.lastGroup = serviceName;
|
||||
this.lastAction = serviceAction;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
setDefaultValue() {
|
||||
this.inputs.forEach((inpt) => {
|
||||
const defaultVal = inpt.getAttribute("default-value");
|
||||
|
@ -140,50 +146,93 @@ class ServiceModal {
|
|||
}
|
||||
}
|
||||
|
||||
setNewEditForm(action, serviceName) {
|
||||
this.showNewEditForm();
|
||||
setForm(action, serviceName, formEl) {
|
||||
this.modalTitle.textContent = `${action} ${serviceName}`;
|
||||
this.formNewEdit.setAttribute("id", `form-${action}-${serviceName}`);
|
||||
this.formNewEdit
|
||||
formEl.setAttribute("id", `form-${action}-${serviceName}`);
|
||||
formEl
|
||||
.querySelector(`input[name="operation"]`)
|
||||
.setAttribute("value", action);
|
||||
this.formNewEdit
|
||||
.querySelector(`input[name="OLD_SERVER_NAME"]`)
|
||||
.setAttribute("value", serviceName);
|
||||
}
|
||||
|
||||
setDeleteForm(action, serviceName) {
|
||||
this.showDeleteForm();
|
||||
this.modalTitle.textContent = `${action} ${serviceName}`;
|
||||
this.formDelete.setAttribute("id", `form-${action}-${serviceName}`);
|
||||
this.formDelete
|
||||
.querySelector(`input[name="SERVER_NAME"]`)
|
||||
.setAttribute("value", serviceName);
|
||||
this.formDelete.querySelector(
|
||||
`[services-modal-text]`
|
||||
).textContent = `Are you sure you want to delete ${serviceName} ?`;
|
||||
if (action === "edit" || action === "new") {
|
||||
this.showNewEditForm();
|
||||
formEl
|
||||
.querySelector(`input[name="OLD_SERVER_NAME"]`)
|
||||
.setAttribute("value", serviceName);
|
||||
}
|
||||
|
||||
if (action === "rename") {
|
||||
this.showRenameForm();
|
||||
formEl
|
||||
.querySelector(`input[name="OLD_SERVER_NAME"]`)
|
||||
.setAttribute("value", serviceName);
|
||||
formEl
|
||||
.querySelector(`input[name="SERVER_NAME"]`)
|
||||
.setAttribute("value", serviceName);
|
||||
}
|
||||
|
||||
if (action === "delete") {
|
||||
this.showDeleteForm();
|
||||
formEl.setAttribute("id", `form-${action}-${serviceName}`);
|
||||
formEl
|
||||
.querySelector(`input[name="SERVER_NAME"]`)
|
||||
.setAttribute("value", serviceName);
|
||||
formEl.querySelector(
|
||||
`[services-modal-text]`
|
||||
).textContent = `Are you sure you want to delete ${serviceName} ?`;
|
||||
}
|
||||
}
|
||||
|
||||
showNewEditForm() {
|
||||
this.modalCard.classList.add("h-[90vh]");
|
||||
this.modalCard.classList.add("w-full");
|
||||
|
||||
this.modalTabs.classList.add("grid");
|
||||
this.modalTabs.classList.remove("hidden");
|
||||
|
||||
this.cardViewport();
|
||||
this.showTabs();
|
||||
this.hideForms();
|
||||
this.formNewEdit.classList.remove("hidden");
|
||||
this.formDelete.classList.add("hidden");
|
||||
}
|
||||
|
||||
showDeleteForm() {
|
||||
this.cardNoViewport();
|
||||
this.hideTabs();
|
||||
this.hideForms();
|
||||
|
||||
this.formDelete.classList.remove("hidden");
|
||||
}
|
||||
|
||||
showRenameForm() {
|
||||
this.cardNoViewport();
|
||||
this.hideTabs();
|
||||
this.hideForms();
|
||||
this.formRename.classList.remove("hidden");
|
||||
}
|
||||
|
||||
cardViewport() {
|
||||
this.modalCard.classList.add("h-[90vh]");
|
||||
this.modalCard.classList.add("w-full");
|
||||
}
|
||||
|
||||
cardNoViewport() {
|
||||
this.modalCard.classList.remove("h-[90vh]");
|
||||
this.modalCard.classList.remove("w-full");
|
||||
}
|
||||
|
||||
hideForms() {
|
||||
this.formNewEdit.classList.add("hidden");
|
||||
this.formDelete.classList.add("hidden");
|
||||
this.formRename.classList.add("hidden");
|
||||
}
|
||||
|
||||
hideTabs() {
|
||||
this.modalTabs.classList.remove("grid");
|
||||
this.modalTabs.classList.add("hidden");
|
||||
|
||||
this.formNewEdit.classList.add("hidden");
|
||||
this.formDelete.classList.remove("hidden");
|
||||
this.modalTabsHeader.classList.remove("flex");
|
||||
this.modalTabsHeader.classList.add("hidden");
|
||||
}
|
||||
|
||||
showTabs() {
|
||||
this.modalTabs.classList.add("grid");
|
||||
this.modalTabs.classList.remove("hidden");
|
||||
this.modalTabsHeader.classList.add("flex");
|
||||
this.modalTabsHeader.classList.remove("hidden");
|
||||
}
|
||||
|
||||
updateModalData(settings) {
|
||||
|
@ -319,7 +368,6 @@ class Multiple {
|
|||
);
|
||||
//clone it and change name by total - 1 (schema is hidden)
|
||||
const clone = schema.cloneNode(true);
|
||||
console.log(clone.getAttribute("services-settings-multiple"));
|
||||
const name = clone
|
||||
.getAttribute("services-settings-multiple")
|
||||
.replace(`SCHEMA`, `${count + 1}`);
|
||||
|
@ -519,7 +567,6 @@ class Multiple {
|
|||
`[${this.prefix}-settings-multiple]`
|
||||
);
|
||||
multiples.forEach((container) => {
|
||||
console.log(container.querySelectorAll(`[setting-container]`));
|
||||
if (container.querySelectorAll(`[setting-container]`).length <= 0)
|
||||
container.parentElement
|
||||
.querySelector("[multiple-handler]")
|
||||
|
@ -583,7 +630,6 @@ class FilterSettings {
|
|||
const settingCount = settings.length;
|
||||
let hiddenCount = 0;
|
||||
settings.forEach((setting) => {
|
||||
console.log(setting);
|
||||
try {
|
||||
const title = setting
|
||||
.querySelector("h5")
|
||||
|
|
|
@ -325,13 +325,27 @@ class FolderModal {
|
|||
//add folder
|
||||
try {
|
||||
if (e.target.closest("li").hasAttribute(`${this.prefix}-add-folder`)) {
|
||||
this.setModal("new", this.getPathFromBread(), "folder", "");
|
||||
this.setModal(
|
||||
"new",
|
||||
this.getPathFromBread(),
|
||||
"folder",
|
||||
"",
|
||||
"",
|
||||
this.getLevelFromBread()
|
||||
);
|
||||
}
|
||||
} catch (err) {}
|
||||
//add file
|
||||
try {
|
||||
if (e.target.closest("li").hasAttribute(`${this.prefix}-add-file`)) {
|
||||
this.setModal("new", this.getPathFromBread(), "file", "");
|
||||
this.setModal(
|
||||
"new",
|
||||
this.getPathFromBread(),
|
||||
"file",
|
||||
"",
|
||||
"",
|
||||
this.getLevelFromBread()
|
||||
);
|
||||
}
|
||||
} catch (err) {}
|
||||
});
|
||||
|
@ -444,6 +458,10 @@ class FolderModal {
|
|||
return `${path}/`;
|
||||
}
|
||||
|
||||
getLevelFromBread() {
|
||||
const level = this.breadContainer.lastElementChild.getAttribute("level");
|
||||
return level;
|
||||
}
|
||||
//set all needed data from btn action and folder info
|
||||
setModal(action, path, type, content, name, level) {
|
||||
//title
|
||||
|
|
|
@ -34,6 +34,22 @@
|
|||
flash-message
|
||||
class="p-4 mb-1 md:mb-3 md:mr-3 z-[1001] flex flex-col fixed bottom-0 right-0 w-full md:w-1/2 max-w-[300px] min-h-20 bg-white rounded-lg dark:brightness-110 hover:scale-102 transition shadow-md break-words dark:bg-slate-850 dark:shadow-dark-xl bg-clip-border"
|
||||
>
|
||||
<button
|
||||
close-flash-message
|
||||
role="close alert message"
|
||||
type="button"
|
||||
class="absolute right-7 top-1.5"
|
||||
>
|
||||
<svg
|
||||
class="cursor-pointer fill-gray-600 dark:fill-gray-300 dark:opacity-80 absolute h-5 w-5"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
viewBox="0 0 320 512"
|
||||
>
|
||||
<path
|
||||
d="M310.6 150.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L160 210.7 54.6 105.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L114.7 256 9.4 361.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L160 301.3 265.4 406.6c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L205.3 256 310.6 150.6z"
|
||||
></path>
|
||||
</svg>
|
||||
</button>
|
||||
{% if category == 'error' %}
|
||||
<h5 class="text-lg mb-0 text-red-500">Error</h5>
|
||||
<p class="text-gray-700 dark:text-gray-300 mb-0 text-sm">
|
||||
|
@ -50,6 +66,7 @@
|
|||
<!-- end flash message-->
|
||||
{% endif %} {% endwith %}
|
||||
</div>
|
||||
|
||||
<!-- info -->
|
||||
<main
|
||||
class="absolute xl:pl-75 w-full px-2 sm:px-6 pb-0 pt-20 sm:pt-6 min-h-[91vh] flex flex-col justify-between"
|
||||
|
|
|
@ -348,7 +348,7 @@ url_for(request.endpoint)[1:].split("/")[-1].strip().replace('_', '-') %}
|
|||
{{current_endpoint}}-modal-path-suffix
|
||||
class="mb-0 dark:text-white dark:opacity-50 text-gray-700 opacity-50 text-sm"
|
||||
>
|
||||
dzqd
|
||||
suffix
|
||||
</p>
|
||||
</div>
|
||||
<input type="hidden" name="csrf_token" value="{{ csrf_token() }}" />
|
||||
|
|
|
@ -3,7 +3,7 @@ config["CONFIG"].get_config() %}
|
|||
|
||||
<div class="p-4 col-span-12 relative flex flex-col min-w-0 break-words bg-white shadow-xl dark:bg-slate-850 dark:shadow-dark-xl rounded-2xl bg-clip-border"
|
||||
>
|
||||
<div class="flex justify-start items-center gap-x-4 gap-y-2 mb-2">
|
||||
<div {{current_endpoint}}-tabs-header class="flex justify-start items-center gap-x-4 gap-y-2 my-3">
|
||||
<h5 class="transition duration-300 ease-in-out dark:opacity-90 ml-2 font-bold text-md uppercase dark:text-white mb-0">CONFIGS</h5>
|
||||
<!-- search inpt-->
|
||||
<div class="flex relative col-span-12 sm:col-span-6 lg:col-span-4 3xl:col-span-3">
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
>
|
||||
<!-- case remote and no match-->
|
||||
{% elif remote_version and not check_version %}
|
||||
<span class="font-bold leading-normal text-sm text-yellow-50-500 mx-0.5"
|
||||
<span class="font-bold leading-normal text-sm text-yellow-500 mx-0.5"
|
||||
>Update to</span
|
||||
>{{ remote_version }} {% endif %}
|
||||
</p>
|
||||
|
|
|
@ -16,25 +16,45 @@
|
|||
<link rel="stylesheet" href="css/dashboard.css" />
|
||||
</head>
|
||||
<body>
|
||||
{% if error %} {% with messages = get_flashed_messages(with_categories=true)
|
||||
%} {% if messages %}
|
||||
{% with messages = get_flashed_messages(with_categories=true) %} {% if
|
||||
messages %}
|
||||
<!-- flash message-->
|
||||
{% for category, message in messages %}
|
||||
<div
|
||||
flash-message
|
||||
class="p-4 mb-1 md:mb-3 md:mr-3 z-[1001] flex flex-col fixed bottom-0 right-0 w-full md:w-1/2 max-w-screen-sm min-h-20 bg-white rounded-lg dark:brightness-110 hover:scale-102 transition shadow-md break-words dark:bg-slate-850 dark:shadow-dark-xl bg-clip-border"
|
||||
class="p-4 mb-1 md:mb-3 md:mr-3 z-[1001] flex flex-col fixed bottom-0 right-0 w-full md:w-1/2 max-w-[300px] min-h-20 bg-white rounded-lg dark:brightness-110 hover:scale-102 transition shadow-md break-words dark:bg-slate-850 dark:shadow-dark-xl bg-clip-border"
|
||||
>
|
||||
<button
|
||||
close-flash-message
|
||||
role="close alert message"
|
||||
type="button"
|
||||
class="absolute right-7 top-1.5"
|
||||
>
|
||||
<svg
|
||||
class="cursor-pointer fill-gray-600 dark:fill-gray-300 dark:opacity-80 absolute h-5 w-5"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
viewBox="0 0 320 512"
|
||||
>
|
||||
<path
|
||||
d="M310.6 150.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L160 210.7 54.6 105.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L114.7 256 9.4 361.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L160 301.3 265.4 406.6c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L205.3 256 310.6 150.6z"
|
||||
></path>
|
||||
</svg>
|
||||
</button>
|
||||
{% if category == 'error' %}
|
||||
<h5 class="text-lg mb-0 text-red-500">Error</h5>
|
||||
<p class="text-red-500 mb-0 text-sm">{{ message|safe }}</p>
|
||||
<p class="text-gray-700 dark:text-gray-300 mb-0 text-sm">
|
||||
{{ message|safe }}
|
||||
</p>
|
||||
{% else %}
|
||||
<h5 class="text-lg mb-0 text-green-500">Success</h5>
|
||||
<p class="text-green-500 mb-0 text-sm">{{ message|safe }}</p>
|
||||
<p class="text-gray-700 dark:text-gray-300 mb-0 text-sm">
|
||||
{{ message|safe }}
|
||||
</p>
|
||||
{% endif %}
|
||||
</div>
|
||||
{% endfor %}
|
||||
<!-- end flash message-->
|
||||
{% endif %} {% endwith %} {%endif %}
|
||||
{% endif %} {% endwith %}
|
||||
<!-- end flash message-->
|
||||
<!--content -->
|
||||
<main class="grid grid-cols-2 align-middle items-center min-h-screen">
|
||||
|
|
|
@ -316,7 +316,7 @@
|
|||
<a
|
||||
target="_blank"
|
||||
class="{% if current_endpoint == 'logs' %}font-semibold text-slate-700 dark:bg-primary/50 rounded-lg dark:hover:bg-primary/60 bg-primary/20 hover:bg-primary/30{% else %}dark:hover:bg-primary/20 hover:bg-primary/5 {% endif %} hover:rounded-lg dark:text-white dark:opacity-80 py-1 text-sm ease-nav-brand my-0 mx-2 flex items-center whitespace-nowrap px-4 transition"
|
||||
href="/plugins?{{plugin['id']}}"
|
||||
href="{{request.url_root}}/plugins?{{plugin['id']}}"
|
||||
>
|
||||
<div
|
||||
class="mr-2 flex items-center justify-center rounded-lg bg-center stroke-0 text-center p-1 xl:p-1.5"
|
||||
|
@ -404,7 +404,7 @@
|
|||
/></svg
|
||||
></a>
|
||||
</li>
|
||||
<li class="mx-2.5 w-6">
|
||||
<li class="mx-2.5 w-6 -translate-y-1">
|
||||
<a href="https://discord.gg/fTf46FmtyD" target="_blank"
|
||||
><svg
|
||||
class="translate-y-1 hover:opacity-80"
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
<!-- modal -->
|
||||
<div
|
||||
plugins-modal
|
||||
class="dark:brightness-110 hidden w-screen h-screen fixed bg-gray-600/50 z-[1001] top-0 left-0 justify-center items-center"
|
||||
class="dark:brightness-110 w-screen h-screen fixed bg-gray-600/50 z-[1001] top-0 left-0 flex justify-center items-center"
|
||||
>
|
||||
<div
|
||||
plugins-modal-card
|
||||
class="overflow-y-auto mx-3 ml-2 mr-6 sm:mx-6 lg:mx-8 my-3 px-4 pt-4 pb-8 w-full h-[90vh] flex flex-col break-words bg-white shadow-xl dark:bg-slate-850 dark:shadow-dark-xl rounded-2xl bg-clip-border"
|
||||
class="min-w-[500px ]overflow-y-auto mx-3 ml-2 mr-6 sm:mx-6 lg:mx-8 my-3 px-4 pt-4 pb-8 w-full max-w-[400px] flex flex-col break-words bg-white shadow-xl dark:bg-slate-850 dark:shadow-dark-xl rounded-2xl bg-clip-border"
|
||||
>
|
||||
<div class="w-full flex justify-between mb-2">
|
||||
<p
|
||||
|
@ -30,12 +30,12 @@
|
|||
<form
|
||||
plugins-modal-form-delete
|
||||
class="w-full h-full flex flex-col justify-between"
|
||||
id="form-delete-server_name"
|
||||
id="form-delete-plugin"
|
||||
method="POST"
|
||||
>
|
||||
<input type="hidden" name="csrf_token" value="{{ csrf_token() }}" />
|
||||
<input type="hidden" value="server_name" name="SERVER_NAME" />
|
||||
<input type="hidden" value="delete" name="operation" />
|
||||
<input type="hidden" value="name" name="name" id="name" />
|
||||
<input type="hidden" value="delete" name="operation" id="operation" />
|
||||
<div>
|
||||
<p
|
||||
plugins-modal-text
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
{% extends "base.html" %} {% block content %}{% set current_endpoint =
|
||||
url_for(request.endpoint)[1:].split("/")[-1].strip().replace('_', '-') %}
|
||||
url_for(request.endpoint)[1:].split("/")[-1].strip().replace('_', '-') %} {%
|
||||
include "plugins-modal.html" %}
|
||||
|
||||
<!-- info -->
|
||||
<div
|
||||
class="p-4 col-span-12 md:col-span-5 2xl:col-span-4 relative min-w-0 break-words bg-white shadow-xl dark:bg-slate-850 dark:shadow-dark-xl rounded-2xl bg-clip-border"
|
||||
|
@ -117,7 +119,7 @@ url_for(request.endpoint)[1:].split("/")[-1].strip().replace('_', '-') %}
|
|||
<!-- filter -->
|
||||
<div
|
||||
{{current_endpoint}}-filter
|
||||
class="p-4 col-span-12 2xl:col-span-4 relative min-w-0 break-words bg-white shadow-xl dark:bg-slate-850 dark:shadow-dark-xl rounded-2xl bg-clip-border"
|
||||
class="p-4 col-span-12 md:col-span-6 2xl:col-span-4 relative min-w-0 break-words bg-white shadow-xl dark:bg-slate-850 dark:shadow-dark-xl rounded-2xl bg-clip-border"
|
||||
>
|
||||
<h5 class="mb-2 font-bold dark:text-white">FILTER</h5>
|
||||
<div class="grid grid-cols-12 gap-x-4 gap-y-2">
|
||||
|
@ -213,7 +215,7 @@ url_for(request.endpoint)[1:].split("/")[-1].strip().replace('_', '-') %}
|
|||
<h5 class="col-mb-2 font-bold dark:text-white">LIST</h5>
|
||||
|
||||
<div {{current_endpoint}}-list class="grid grid-cols-12 gap-3">
|
||||
{% for plugin in plugins %} {% if plugin['page'] %}
|
||||
{% for plugin in plugins %} {% if plugin['external'] %}
|
||||
<div
|
||||
{{current_endpoint}}-external="{% if plugin['external'] %} external {%else%} internal {%endif%}"
|
||||
class="py-3 min-h-12 relative col-span-12 sm:col-span-6 2xl:col-span-4 3xl:col-span-3 p-1 flex justify-between items-center transition rounded bg-gray-100 hover:bg-gray-300 dark:bg-slate-700 dark:hover:bg-slate-800"
|
||||
|
@ -225,7 +227,11 @@ url_for(request.endpoint)[1:].split("/")[-1].strip().replace('_', '-') %}
|
|||
{{plugin['name']}}
|
||||
</p>
|
||||
<div class="flex items-center">
|
||||
<a class="hover:-translate-y-px" href="/plugins?{{plugin['id']}}">
|
||||
{% if plugin['page']%}
|
||||
<a
|
||||
class="hover:-translate-y-px"
|
||||
href="{{request.url_root}}/plugins?{{plugin['id']}}"
|
||||
>
|
||||
<svg
|
||||
class="h-6 w-6 fill-sky-500 dark dark:brightness-90"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
|
@ -236,6 +242,7 @@ url_for(request.endpoint)[1:].split("/")[-1].strip().replace('_', '-') %}
|
|||
></path>
|
||||
</svg>
|
||||
</a>
|
||||
{%endif%}
|
||||
<button
|
||||
{{current_endpoint}}-action="delete"
|
||||
name="{{plugin['id']}}"
|
||||
|
@ -255,7 +262,6 @@ url_for(request.endpoint)[1:].split("/")[-1].strip().replace('_', '-') %}
|
|||
</div>
|
||||
</div>
|
||||
{% else %}
|
||||
|
||||
<div
|
||||
{{current_endpoint}}-external="{% if plugin['external'] %} external {%else%} internal {%endif%}"
|
||||
class="py-3 min-h-12 relative col-span-12 sm:col-span-6 2xl:col-span-4 3xl:col-span-3 p-1 flex justify-between items-center transition rounded bg-gray-100 hover:bg-gray-300 dark:bg-slate-700 dark:hover:bg-slate-800"
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
>
|
||||
<div
|
||||
services-modal-card
|
||||
class="overflow-y-auto mx-3 ml-2 mr-6 sm:mx-6 lg:mx-8 my-3 px-4 pt-4 pb-8 w-full h-[90vh] flex flex-col break-words bg-white shadow-xl dark:bg-slate-850 dark:shadow-dark-xl rounded-2xl bg-clip-border"
|
||||
class="overflow-y-auto mx-3 ml-2 mr-6 sm:mx-6 lg:mx-8 my-3 px-4 pt-4 pb-8 w-full min-w-[500px] h-[90vh] flex flex-col break-words bg-white shadow-xl dark:bg-slate-850 dark:shadow-dark-xl rounded-2xl bg-clip-border"
|
||||
>
|
||||
<div class="w-full flex justify-between mb-2">
|
||||
<p
|
||||
|
@ -26,7 +26,10 @@
|
|||
</svg>
|
||||
</button>
|
||||
</div>
|
||||
<div class="flex justify-start items-center gap-x-4 gap-y-2 mb-2">
|
||||
<div
|
||||
services-tabs-header
|
||||
class="flex justify-start items-center gap-x-4 gap-y-2 my-3"
|
||||
>
|
||||
<h5
|
||||
class="transition duration-300 ease-in-out dark:opacity-90 ml-2 font-bold text-md uppercase dark:text-white mb-0"
|
||||
>
|
||||
|
@ -116,6 +119,48 @@
|
|||
<!-- end action button-->
|
||||
</form>
|
||||
<!-- end delete form-->
|
||||
<!-- rename form-->
|
||||
<form
|
||||
services-modal-form-rename
|
||||
class="w-full h-full flex flex-col justify-between"
|
||||
id="form-rename-server_name"
|
||||
method="POST"
|
||||
>
|
||||
<input type="hidden" name="csrf_token" value="{{ csrf_token() }}" />
|
||||
<input type="hidden" value="OLD_SERVER_NAME" name="OLD_SERVER_NAME" />
|
||||
<input type="hidden" value="rename" name="operation" />
|
||||
<div
|
||||
class="my-2 flex flex-row justify-center align-middle items-center"
|
||||
{{current_endpoint}}-modal-path
|
||||
>
|
||||
<input
|
||||
type="text"
|
||||
name="SERVER_NAME"
|
||||
id="SERVER_NAME"
|
||||
class="dark:border-slate-600 dark:bg-slate-700 dark:text-gray-300 sm:ml-1 max-w-[350px] disabled:opacity-75 focus:valid:border-green-500 focus:file:invalid:border-red-500 outline-none focus:border-primary text-sm leading-5.6 ease block w-full appearance-none rounded-lg border border-solid border-gray-300 bg-white bg-clip-padding px-1.5 py-1 font-normal text-gray-700 transition-all placeholder:text-gray-500"
|
||||
placeholder="path"
|
||||
required
|
||||
/>
|
||||
</div>
|
||||
<!-- action button -->
|
||||
<div class="w-full justify-center flex mt-10">
|
||||
<button
|
||||
services-modal-close
|
||||
type="button"
|
||||
class="dark:brightness-90 mr-3 inline-block px-6 py-3 font-bold text-center text-white uppercase align-middle transition-all rounded-lg cursor-pointer bg-red-500 hover:bg-red-500/80 focus:bg-red-500/80 leading-normal text-md ease-in tracking-tight-rem shadow-xs bg-150 bg-x-25 hover:-translate-y-px active:opacity-85 hover:shadow-md"
|
||||
>
|
||||
Close
|
||||
</button>
|
||||
<button
|
||||
type="submit"
|
||||
class="dark:brightness-90 inline-block px-6 py-3 font-bold text-center text-white uppercase align-middle transition-all rounded-lg cursor-pointer bg-sky-500 hover:bg-sky-500/80 focus:bg-sky-500/80 leading-normal text-md ease-in tracking-tight-rem shadow-xs bg-150 bg-x-25 hover:-translate-y-px active:opacity-85 hover:shadow-md"
|
||||
>
|
||||
Rename
|
||||
</button>
|
||||
</div>
|
||||
<!-- end action button-->
|
||||
</form>
|
||||
<!-- end rename form-->
|
||||
</div>
|
||||
</div>
|
||||
<!-- end modal -->
|
||||
|
|
|
@ -334,7 +334,7 @@
|
|||
</a>
|
||||
|
||||
<button
|
||||
services-action="edit"
|
||||
services-action="rename"
|
||||
type="button"
|
||||
services-name="{{service["SERVER_NAME"]['value']}}"
|
||||
|
||||
|
@ -350,6 +350,20 @@
|
|||
/>
|
||||
</svg>
|
||||
</button>
|
||||
<button
|
||||
services-action="edit"
|
||||
type="button"
|
||||
services-name="{{service["SERVER_NAME"]['value']}}"
|
||||
|
||||
class="dark:brightness-90 z-20 mx-1 bg-blue-500 hover:bg-blue-500/80 focus:bg-yellow-500/80 inline-block p-3 font-bold text-center text-white uppercase align-middle transition-all rounded-lg cursor-pointer leading-normal text-xs ease-in tracking-tight-rem shadow-xs bg-150 bg-x-25 hover:-translate-y-px active:opacity-85 hover:shadow-md"
|
||||
>
|
||||
<svg class="h-6 w-6 fill-white"
|
||||
xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512">
|
||||
<path d="M495.9 166.6c3.2 8.7 .5 18.4-6.4 24.6l-43.3 39.4c1.1 8.3 1.7 16.8 1.7 25.4s-.6 17.1-1.7 25.4l43.3 39.4c6.9 6.2 9.6 15.9 6.4 24.6c-4.4 11.9-9.7 23.3-15.8 34.3l-4.7 8.1c-6.6 11-14 21.4-22.1 31.2c-5.9 7.2-15.7 9.6-24.5 6.8l-55.7-17.7c-13.4 10.3-28.2 18.9-44 25.4l-12.5 57.1c-2 9.1-9 16.3-18.2 17.8c-13.8 2.3-28 3.5-42.5 3.5s-28.7-1.2-42.5-3.5c-9.2-1.5-16.2-8.7-18.2-17.8l-12.5-57.1c-15.8-6.5-30.6-15.1-44-25.4L83.1 425.9c-8.8 2.8-18.6 .3-24.5-6.8c-8.1-9.8-15.5-20.2-22.1-31.2l-4.7-8.1c-6.1-11-11.4-22.4-15.8-34.3c-3.2-8.7-.5-18.4 6.4-24.6l43.3-39.4C64.6 273.1 64 264.6 64 256s.6-17.1 1.7-25.4L22.4 191.2c-6.9-6.2-9.6-15.9-6.4-24.6c4.4-11.9 9.7-23.3 15.8-34.3l4.7-8.1c6.6-11 14-21.4 22.1-31.2c5.9-7.2 15.7-9.6 24.5-6.8l55.7 17.7c13.4-10.3 28.2-18.9 44-25.4l12.5-57.1c2-9.1 9-16.3 18.2-17.8C227.3 1.2 241.5 0 256 0s28.7 1.2 42.5 3.5c9.2 1.5 16.2 8.7 18.2 17.8l12.5 57.1c15.8 6.5 30.6 15.1 44 25.4l55.7-17.7c8.8-2.8 18.6-.3 24.5 6.8c8.1 9.8 15.5 20.2 22.1 31.2l4.7 8.1c6.1 11 11.4 22.4 15.8 34.3zM256 336c44.2 0 80-35.8 80-80s-35.8-80-80-80s-80 35.8-80 80s35.8 80 80 80z"/></svg>
|
||||
|
||||
</button>
|
||||
|
||||
|
||||
{% if service["SERVER_NAME"]['method'] != "scheduler" %}
|
||||
<button
|
||||
services-action="delete"
|
||||
|
|
Loading…
Reference in New Issue