diff --git a/css/popup.css b/css/popup.css index 8afefb99..c9435231 100644 --- a/css/popup.css +++ b/css/popup.css @@ -35,7 +35,7 @@ body { } ul{ - margin-bottom: 20px; + margin-bottom: 20px; } .settings { @@ -47,9 +47,13 @@ ul{ vertical-align: middle; box-shadow: 0 2px 5px 0 rgba(0, 0, 0, 0.16), 0 2px 10px 0 rgba(0, 0, 0, 0.12); transition: 0.3s; - padding: 7px 7px 5px 7px; + padding: 7px 5px 5px 7px; + margin-right: 10px; border-radius: 7px; } +.settings:hover{ + box-shadow: 0 4px 10px 0 rgba(0, 0, 0, 0.2), 0 4px 20px 0 rgba(0, 0, 0, 0.19); +} .matbut { border: none; outline: none; @@ -167,6 +171,9 @@ input{ width: 80px; border-radius: 5px; } +input:focus { + outline: 0; +} input[type=number]::-webkit-inner-spin-button, input[type=number]::-webkit-outer-spin-button { -webkit-appearance: none; @@ -176,7 +183,7 @@ input[type=number]::-webkit-outer-spin-button { } ::placeholder{ - color:#ff691a; + color:#ffbd9a; } .select-style { diff --git a/js/popup.js b/js/popup.js index ae976cc4..22b915d2 100644 --- a/js/popup.js +++ b/js/popup.js @@ -183,6 +183,7 @@ $(document).ready(function () { $("#class_id").show(); $("#semesters").show(); $("#semcon").show(); + $('#class_id').focus(); } }); $('#import').click(function () { @@ -399,16 +400,20 @@ function getInfo(sem, unique) { var object = $('
').html(response).contents(); var c = getCourseObject(object, link); console.log(c); - chrome.runtime.sendMessage({ - command: "courseStorage", - course: c, - action: "add" - }, function () { + if(c.coursename){ chrome.runtime.sendMessage({ - command: "updateCourseList" + command: "courseStorage", + course: c, + action: "add" + }, function () { + chrome.runtime.sendMessage({ + command: "updateCourseList" + }); + setCourseList(); }); - setCourseList(); - }); + } else { + alert("There Was An Error.") + } } }