summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlex Xu (Hello71) <alex_y_xu@yahoo.ca>2017-07-13 10:37:12 -0400
committerAlex Xu (Hello71) <alex_y_xu@yahoo.ca>2017-07-13 10:47:37 -0400
commitde9d285ad24576bf7d38968cd01c129312abe651 (patch)
tree75714d9b5827583b7afe20c0a70a2d8d20ca69b3
parent521610e1a7905b5e94d05d95e3317a921a742690 (diff)
downloaduoft-artsci-exam-filter-de9d285ad24576bf7d38968cd01c129312abe651.tar.xz
uoft-artsci-exam-filter-de9d285ad24576bf7d38968cd01c129312abe651.zip
Improve help messages.
-rw-r--r--uoft-artsci-exam-filter.user.js13
1 files changed, 7 insertions, 6 deletions
diff --git a/uoft-artsci-exam-filter.user.js b/uoft-artsci-exam-filter.user.js
index e7614b2..1cbc8c1 100644
--- a/uoft-artsci-exam-filter.user.js
+++ b/uoft-artsci-exam-filter.user.js
@@ -2,7 +2,7 @@
// @name University of Toronto Arts & Science Exam Schedule Filter
// @namespace https://alxu.ca/
// @match http://www.artsci.utoronto.ca/current/exams/*
-// @version 1.2
+// @version 1.3
// @grant none
// @downloadURL https://alxu.ca/uoft-artsci-exam-filter.user.js
// @require https://www.kryogenix.org/code/browser/sorttable/sorttable.js#sha512=33bdc388d816cab2190ee33918143074a3d1bc8da315b0d6117eb8233d8a7ed51752aa26419296c06120c6faee6053d4589fca2a7590846139d69e84cb600808
@@ -98,10 +98,11 @@ var dofilter = function (myname, mycourses) {
var ourctnr = document.createElement("div");
ourctnr.appendChild(document.createTextNode("Filter by name: "));
-var makeInput = function (attr, size) {
+var makeInput = function (attr, size, placeholder) {
var input = document.createElement("input");
input.type = "text";
input.size = size;
+ input.placeholder = placeholder;
if (storage[attr])
input.value = storage[attr];
input.addEventListener("input", function () {
@@ -113,16 +114,16 @@ var makeInput = function (attr, size) {
ourctnr.appendChild(input);
};
-makeInput("name", "4");
+makeInput("name", "5", "SMIT");
ourctnr.appendChild(document.createTextNode(", courses: "));
-makeInput("courses", "50");
+makeInput("courses", "50", "ENG10 CO100/101 CLA204/L0101");
ourctnr.appendChild(document.createElement("br"));
-ourctnr.appendChild(document.createTextNode("Courses should be separated by spaces and sections preceded by slash."));
+ourctnr.appendChild(document.createTextNode("For name, you should enter the first few letters of your surname (not your given name, obviously)."));
ourctnr.appendChild(document.createElement("br"));
-ourctnr.appendChild(document.createTextNode("Example: ABC101 XYZ201/L0301"));
+ourctnr.appendChild(document.createTextNode("Courses should be separated by spaces and sections preceded by slash. You can omit the start or end of a field. For example: entering \"BC10 XYZ201/L0301\" for courses will show only courses containing \"BC10\" as well as section L0301 of course XYZ201."));
tbl.parentNode.insertBefore(ourctnr, tbl);