summaryrefslogtreecommitdiffstats
path: root/web/html
diff options
context:
space:
mode:
Diffstat (limited to 'web/html')
-rw-r--r--web/html/css/aurweb.css6
-rw-r--r--web/html/images/pin.min.svg1
-rw-r--r--web/html/images/pin.svg3
-rw-r--r--web/html/images/unpin.min.svg1
-rw-r--r--web/html/images/unpin.svg4
-rw-r--r--web/html/index.php2
-rw-r--r--web/html/pkgbase.php4
7 files changed, 18 insertions, 3 deletions
diff --git a/web/html/css/aurweb.css b/web/html/css/aurweb.css
index 11af747..82b83d9 100644
--- a/web/html/css/aurweb.css
+++ b/web/html/css/aurweb.css
@@ -101,7 +101,7 @@
color: #999;
}
-.delete-comment-form, .edit-comment {
+.delete-comment-form, .pin-comment-form, .edit-comment {
float: right;
margin-left: 8px;
}
@@ -112,13 +112,13 @@
top: 1px;
}
-.delete-comment, .edit-comment {
+.delete-comment, .edit-comment, .pin-comment {
-webkit-filter: grayscale(100%);
filter: grayscale(100%);
opacity: 0.6;
}
-.delete-comment:hover, .edit-comment:hover {
+.delete-comment:hover, .edit-comment:hover, .pin-comment:hover {
-webkit-filter: none;
filter: none;
opacity: 1;
diff --git a/web/html/images/pin.min.svg b/web/html/images/pin.min.svg
new file mode 100644
index 0000000..ac08903
--- /dev/null
+++ b/web/html/images/pin.min.svg
@@ -0,0 +1 @@
+<svg xmlns="http://www.w3.org/2000/svg" width="8" height="8" viewBox="0 0 8 8"><path style="fill:#3366aa;fill-opacity:1" d="M1.34 0a.5.5 0 0 0 .16 1h.5v2h-1c-.55 0-1 .45-1 1h3v3l.44 1 .56-1v-3h3c0-.55-.45-1-1-1h-1v-2h.5a.5.5 0 1 0 0-1h-4a.5.5 0 0 0-.09 0 .5.5 0 0 0-.06 0z" /></svg>
diff --git a/web/html/images/pin.svg b/web/html/images/pin.svg
new file mode 100644
index 0000000..b4ee9eb
--- /dev/null
+++ b/web/html/images/pin.svg
@@ -0,0 +1,3 @@
+<svg xmlns="http://www.w3.org/2000/svg" width="8" height="8" viewBox="0 0 8 8">
+ <path style="fill:#3366aa;fill-opacity:1" d="M1.34 0a.5.5 0 0 0 .16 1h.5v2h-1c-.55 0-1 .45-1 1h3v3l.44 1 .56-1v-3h3c0-.55-.45-1-1-1h-1v-2h.5a.5.5 0 1 0 0-1h-4a.5.5 0 0 0-.09 0 .5.5 0 0 0-.06 0z" />
+</svg>
diff --git a/web/html/images/unpin.min.svg b/web/html/images/unpin.min.svg
new file mode 100644
index 0000000..3cf2413
--- /dev/null
+++ b/web/html/images/unpin.min.svg
@@ -0,0 +1 @@
+<svg xmlns="http://www.w3.org/2000/svg" width="8" height="8" viewBox="0 0 8 8"><path style="fill:#3366aa;fill-opacity:1" d="M1.34 0a.5.5 0 0 0 .16 1h.5v2h-1c-.55 0-1 .45-1 1h3v3l.44 1 .56-1v-3h3c0-.55-.45-1-1-1h-1v-2h.5a.5.5 0 1 0 0-1h-4a.5.5 0 0 0-.09 0 .5.5 0 0 0-.06 0z" /><path style="fill:#3366aa;fill-opacity:1" d="m6.4 0l1 1-6.4 6.8-1-1z" /></svg>
diff --git a/web/html/images/unpin.svg b/web/html/images/unpin.svg
new file mode 100644
index 0000000..de89715
--- /dev/null
+++ b/web/html/images/unpin.svg
@@ -0,0 +1,4 @@
+<svg xmlns="http://www.w3.org/2000/svg" width="8" height="8" viewBox="0 0 8 8">
+ <path style="fill:#3366aa;fill-opacity:1" d="M1.34 0a.5.5 0 0 0 .16 1h.5v2h-1c-.55 0-1 .45-1 1h3v3l.44 1 .56-1v-3h3c0-.55-.45-1-1-1h-1v-2h.5a.5.5 0 1 0 0-1h-4a.5.5 0 0 0-.09 0 .5.5 0 0 0-.06 0z" />
+ <path style="fill:#3366aa;fill-opacity:1" d="m6.4 0l1 1 -6.4 6.8 -1 -1z" />
+</svg>
diff --git a/web/html/index.php b/web/html/index.php
index ec99bb7..e99d22f 100644
--- a/web/html/index.php
+++ b/web/html/index.php
@@ -182,6 +182,8 @@ if (!empty($tokens[1]) && '/' . $tokens[1] == get_pkg_route()) {
break;
case "/images/x.min.svg":
case "/images/pencil.min.svg":
+ case "/images/pin.min.svg":
+ case "/images/unpin.min.svg":
header("Content-Type: image/svg+xml");
readfile("./$path");
break;
diff --git a/web/html/pkgbase.php b/web/html/pkgbase.php
index cbbf3cc..45b8084 100644
--- a/web/html/pkgbase.php
+++ b/web/html/pkgbase.php
@@ -99,6 +99,10 @@ if (check_token()) {
list($ret, $output) = pkgbase_notify($ids, false);
} elseif (current_action("do_DeleteComment")) {
list($ret, $output) = pkgbase_delete_comment();
+ } elseif (current_action("do_PinComment")) {
+ list($ret, $output) = pkgbase_pin_comment();
+ } elseif (current_action("do_UnpinComment")) {
+ list($ret, $output) = pkgbase_pin_comment(true);
} elseif (current_action("do_SetKeywords")) {
list($ret, $output) = pkgbase_set_keywords($base_id, preg_split("/[\s,;]+/", $_POST['keywords'], -1, PREG_SPLIT_NO_EMPTY));
} elseif (current_action("do_FileRequest")) {