Add toggles to i2psnark in preparation for CSS3 collapsible sections

This commit is contained in:
str4d
2016-05-23 13:25:18 +00:00
parent 9d3dec8577
commit 6b7db094a9
4 changed files with 29 additions and 9 deletions

View File

@@ -2054,12 +2054,14 @@ public class I2PSnarkServlet extends BasicServlet {
// *not* enctype="multipart/form-data", so that the input type=file sends the filename, not the file
out.write("<form action=\"_post\" method=\"POST\">\n");
writeHiddenInputs(out, req, "Add");
out.write("<div class=\"addtorrentsection\"><span class=\"snarkConfigTitle\">");
out.write("<div class=\"addtorrentsection\">");
out.write("<input class=\"toggle_input\" id=\"toggle_addtorrent\" type=\"checkbox\"><label class=\"toggleview\" for=\"toggle_addtorrent\">");
out.write(toThemeImg("add"));
out.write(' ');
out.write(_t("Add Torrent"));
out.write("</label>");
out.write("</span><hr>\n<table border=\"0\"><tr><td>");
out.write("<hr>\n<table border=\"0\"><tr><td>");
out.write(_t("From URL"));
out.write(":<td><input type=\"text\" name=\"nofilter_newURL\" size=\"85\" value=\"" + newURL + "\" spellcheck=\"false\"");
out.write(" title=\"");
@@ -2091,11 +2093,11 @@ public class I2PSnarkServlet extends BasicServlet {
// *not* enctype="multipart/form-data", so that the input type=file sends the filename, not the file
out.write("<form action=\"_post\" method=\"POST\">\n");
writeHiddenInputs(out, req, "Create");
out.write("<span class=\"snarkConfigTitle\">");
out.write("<input class=\"toggle_input\" id=\"toggle_createtorrent\" type=\"checkbox\"><label class=\"toggleview\" for=\"toggle_createtorrent\">");
out.write(toThemeImg("create"));
out.write(' ');
out.write(_t("Create Torrent"));
out.write("</span><hr>\n<table border=\"0\"><tr><td>");
out.write("</label><hr>\n<table border=\"0\"><tr><td>");
//out.write("From file: <input type=\"file\" name=\"newFile\" size=\"50\" value=\"" + newFile + "\" /><br>\n");
out.write(_t("Data to seed"));
out.write(":<td>"

View File

@@ -402,7 +402,7 @@ td:first-child {
line-height: 130% !important;
}
.snarkConfigTitle {
.snarkConfigTitle, label.toggleview {
font-size: 10.5pt;
font-weight: bold;
padding: 1px 15px 4px 12px;
@@ -423,7 +423,7 @@ div.newtorrentsection .snarkConfigTitle, div.addtorrentsection .snarkConfigTitle
padding-top: 0 !important;
}
.snarkConfigTitle img {
.snarkConfigTitle img, label.toggleview img {
margin-right: -3px;
padding-bottom: 3px;
}
@@ -887,3 +887,9 @@ input.trackerhome {
input.trackerannounce {
width: 230px;
}
/* toggle create/add panel view */
input.toggle_input { /* hide checkbox and use label as faux panel heading */
display: none;
}

View File

@@ -454,7 +454,7 @@ table.SnarkDirInfo {
line-height: 130% !important;
}
.snarkConfigTitle {
.snarkConfigTitle, label.toggleview {
font-size: 11pt;
font-weight: bold;
padding: 0 25px 3px 25px;
@@ -921,3 +921,9 @@ input.trackerhome {
input.trackerannounce {
width: 230px;
}
/* toggle create/add panel view */
input.toggle_input { /* hide checkbox and use label as faux panel heading */
display: none;
}

View File

@@ -466,7 +466,7 @@ thead img.disable, img.disable:hover {
line-height: 130% !important;
}
.snarkConfigTitle {
.snarkConfigTitle, label.toggleview {
font-size: 11pt;
font-weight: bold;
padding: 0 15px 3px 12px;
@@ -484,7 +484,7 @@ thead img.disable, img.disable:hover {
box-shadow: 0 1px 1px #777;
}
.snarkConfigTitle img {
.snarkConfigTitle img, label.toggleview img {
margin-right: -3px;
}
.snarkConfig {
@@ -938,3 +938,9 @@ input.trackerhome {
input.trackerannounce {
width: 230px;
}
/* toggle create/add panel view */
input.toggle_input { /* hide checkbox and use label as faux panel heading */
display: none;
}