Calendar adding issue, css hover still doesn't work; sidebar closes on mode change, fixed #64

This commit is contained in:
Kenneth Jao 2016-08-29 23:32:14 -04:00
parent 156fa11930
commit 8a0a18b454
3 changed files with 13 additions and 11 deletions

View File

@ -763,7 +763,7 @@ input, textarea {
} }
} }
.fc-day:not(.fc-past):not(.fc-other-month) { .fc-day:not(.fc-past) {
box-shadow: inset 0 0 0 99999px rgba(0,0,0,0.1); box-shadow: inset 0 0 0 99999px rgba(0,0,0,0.1);
-webkit-transition: box-shadow 0.4s ease; -webkit-transition: box-shadow 0.4s ease;
@ -772,7 +772,7 @@ input, textarea {
transition: box-shadow 0.4s ease; transition: box-shadow 0.4s ease;
} }
.fc-day:not(.fc-past):not(.fc-other-month):hover { .fc-day:not(.fc-past):hover {
box-shadow: inset 0 0 0 99999px rgba(0,0,0,0.15); box-shadow: inset 0 0 0 99999px rgba(0,0,0,0.15);
} }
@ -806,6 +806,7 @@ input, textarea {
} }
#commentSubmit { #commentSubmit {
margin-bottom: 0;
padding: 2%; padding: 2%;
background-color: rgba(255,255,255,0.1); background-color: rgba(255,255,255,0.1);

View File

@ -147,11 +147,6 @@
{{#unless newWork}} {{#unless newWork}}
<div id="workComments"> <div id="workComments">
<h3>Comments</h3> <h3>Comments</h3>
<div id="comment" style="max-height:{{commentDim}}">
{{#each work 'comments'}}
{{> comment}}
{{/each}}
</div>
<div> <div>
<textarea id="workComment" rows="4" cols="50" maxlength="200"></textarea><br> <textarea id="workComment" rows="4" cols="50" maxlength="200"></textarea><br>
<div> <div>
@ -159,6 +154,11 @@
<div id="commentSubmit">Submit</div> <div id="commentSubmit">Submit</div>
</div> </div>
</div> </div>
<div id="comment" style="max-height:{{commentDim}}">
{{#each work 'comments'}}
{{> comment}}
{{/each}}
</div>
</div> </div>
{{/unless}} {{/unless}}
</div> </div>

View File

@ -292,7 +292,7 @@ Template.main.helpers({
openDivFade(document.getElementsByClassName("overlay")[0]); openDivFade(document.getElementsByClassName("overlay")[0]);
}, },
dayClick: function(date, jsEvent, view) { dayClick: function(date, jsEvent, view) {
if(jsEvent.target.className.includes("fc-other-month") || jsEvent.target.className.includes("fc-past")) return; if(jsEvent.target.className.includes("fc-past")) return;
Session.set("calCreWork",true); Session.set("calCreWork",true);
Session.set("calWorkDate",date.format()); Session.set("calWorkDate",date.format());
Session.set("sidebar","menuContainer"); Session.set("sidebar","menuContainer");
@ -432,6 +432,7 @@ Template.main.events({
Session.set("mode", "classes"); Session.set("mode", "classes");
openDivFade(modeHolder); openDivFade(modeHolder);
}, 300); }, 300);
Session.set("sidebar",null);
}, },
'click .calendar' () { 'click .calendar' () {
if (Session.get("mode") === "calendar") return; if (Session.get("mode") === "calendar") return;
@ -441,6 +442,7 @@ Template.main.events({
Session.set("mode", "calendar"); Session.set("mode", "calendar");
openDivFade(modeHolder); openDivFade(modeHolder);
}, 300); }, 300);
Session.set("sidebar",null);
}, },
'click' (event) { 'click' (event) {
var e = event.target.className; var e = event.target.className;
@ -458,9 +460,8 @@ Template.main.events({
!e.includes("fa-cog") && !e.includes("fa-cog") &&
!e.includes("fa-bars") && !e.includes("fa-bars") &&
!document.getElementById("menuContainer").contains(event.target) && !document.getElementById("menuContainer").contains(event.target) &&
!document.getElementById("optionsContainer").contains(event.target) && !document.getElementById("optionsContainer").contains(event.target) &&
!(event.target.className.includes("fc-today") || !(event.target.className.includes("fc-day") && !event.target.className.includes("fc-past"))) {
(event.target.className.includes("fc-future") && !event.target.className.includes("fc-other-month")))) {
if(Session.get("calCreWork")) { if(Session.get("calCreWork")) {
Session.set("calCreWork",false); Session.set("calCreWork",false);
} }