...
 
Commits (2)
...@@ -90,7 +90,6 @@ ...@@ -90,7 +90,6 @@
const getSelectedFiletype = n => n.options[n.selectedIndex].value; const getSelectedFiletype = n => n.options[n.selectedIndex].value;
const save = function(msg) { const save = function(msg) {
msg = typeof msg === "string" ? msg : "Configuration saved."; msg = typeof msg === "string" ? msg : "Configuration saved.";
const files = []; const files = [];
$$("li.file").forEach((item) => { $$("li.file").forEach((item) => {
...@@ -102,7 +101,7 @@ ...@@ -102,7 +101,7 @@
const fileDisabled = const fileDisabled =
item.querySelector(".checkbox-file-enabled") item.querySelector(".checkbox-file-enabled")
.checked === false; .checked === false;
$(".input-file-hostnames") item.querySelector(".input-file-hostnames")
.value.split(",") .value.split(",")
.forEach((hostname) => { .forEach((hostname) => {
hostnames.push(hostname.trim()); hostnames.push(hostname.trim());
...@@ -358,12 +357,15 @@ ...@@ -358,12 +357,15 @@
} else { } else {
listItem.classList.add("disabled"); listItem.classList.add("disabled");
} }
const dragIcon = create("div");
dragIcon.setAttribute("class", "drag-icon");
listItem.appendChild(input); listItem.appendChild(input);
listItem.appendChild(select); listItem.appendChild(select);
listItem.appendChild(inputHostnames); listItem.appendChild(inputHostnames);
listItem.appendChild(btnAdd); listItem.appendChild(btnAdd);
listItem.appendChild(btnRemove); listItem.appendChild(btnRemove);
listItem.appendChild(checkboxEnabled); listItem.appendChild(checkboxEnabled);
listItem.appendChild(dragIcon);
addEventsToListItem(listItem); addEventsToListItem(listItem);
if (refNode) { if (refNode) {
refNode.parentNode.insertBefore( refNode.parentNode.insertBefore(
......
...@@ -36,6 +36,18 @@ h1 span { ...@@ -36,6 +36,18 @@ h1 span {
color: #19cf85; color: #19cf85;
} }
div.drag-icon {
display: inline-block;
width: 64px;
height: 64px;
margin-bottom: -25px;
background: {
image: url("icons/hand-drawn-drag-icon.png");
size: cover;
position: center;
}
}
.hidden { .hidden {
display: none; display: none;
} }
......