diff --git a/public/css/components/calendar.css b/public/css/components/calendar.css index 8df453d6d..4657bbb3f 100644 --- a/public/css/components/calendar.css +++ b/public/css/components/calendar.css @@ -1,5 +1,6 @@ :root{ --fhc-calendar-pane-height: calc(100vh - 220px); + --fhc-calendar-past: #F5E9D7 } .fhc-calendar-week-page-header { @@ -188,7 +189,7 @@ .fhc-calendar-past { - background-color:#F5E9D7; + background-color: var(--fhc-calendar-past); border-color: #E8E8E8; opacity: 0.5; } diff --git a/public/js/components/Calendar/Calendar.js b/public/js/components/Calendar/Calendar.js index 0bae84583..fe987a643 100644 --- a/public/js/components/Calendar/Calendar.js +++ b/public/js/components/Calendar/Calendar.js @@ -8,7 +8,6 @@ import CalendarMinimized from './Minimized.js'; import CalendarDate from '../../composables/CalendarDate.js'; import CalendarDates from '../../composables/CalendarDates.js'; - const todayDate = new Date(new Date().setHours(0, 0, 0, 0)); const today = todayDate.getTime() diff --git a/public/js/components/Calendar/Day/Page.js b/public/js/components/Calendar/Day/Page.js index 85a9cbc84..4342dd1ce 100644 --- a/public/js/components/Calendar/Day/Page.js +++ b/public/js/components/Calendar/Day/Page.js @@ -93,6 +93,18 @@ export default { } }, computed: { + overlayStyle() { + return { + 'background-color': '#F5E9D7', + 'position': 'absolute', + 'pointer-events': 'none', + 'z-index': 2, + height: this.getDayTimePercent + '%', + width: '100%', + opacity: 0.5, + overflow: 'hidden' + } + }, pageHeaderStyle() { return { 'z-index': 4, @@ -307,7 +319,6 @@ export default { // calculate the minutes percentage of the total minutes timePercentage = ((currentMinutes - (this.hours[0] * 60)) / (this.hours.length * 60)) * 100; // calculate the relative position of the time percentage - console.log('height: ', height) position = height * (timePercentage / 100); this.hourPosition = position; @@ -365,6 +376,7 @@ export default {