Add a nice cleanup of holidayUtils.js
This commit is contained in:
+11
-11
@@ -253,6 +253,7 @@
|
||||
$: visibleHolidaysCount = holidays.filter(h => !h.hidden).length;
|
||||
|
||||
function toggleWeekendDay(dayNumber: number) {
|
||||
console.log('Toggling weekend day:', dayNumber);
|
||||
if (weekendDays.includes(dayNumber)) {
|
||||
weekendDays = weekendDays.filter(d => d !== dayNumber);
|
||||
} else {
|
||||
@@ -554,7 +555,6 @@
|
||||
.content-box li {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
.content-box button {
|
||||
@@ -603,7 +603,7 @@
|
||||
justify-content: space-between;
|
||||
padding: 8px;
|
||||
border-radius: 4px;
|
||||
gap: 10px;
|
||||
gap: 5px;
|
||||
}
|
||||
|
||||
.holidays-list li:hover {
|
||||
@@ -710,15 +710,6 @@
|
||||
|
||||
<div class="content-box" id="calendar">
|
||||
<div class="calendar-key">
|
||||
<div class="key-item">
|
||||
<div class="key-label">
|
||||
<span class="color-box weekend"></span>
|
||||
<span>Weekend</span>
|
||||
</div>
|
||||
<a href="#" on:click|preventDefault={() => showWeekendSettings = !showWeekendSettings} class="edit-link">
|
||||
(edit)
|
||||
</a>
|
||||
</div>
|
||||
<div class="key-item">
|
||||
<div class="key-label">
|
||||
<span class="color-box optimized"></span>
|
||||
@@ -736,6 +727,15 @@
|
||||
</a>
|
||||
{/if}
|
||||
</div>
|
||||
<div class="key-item">
|
||||
<div class="key-label">
|
||||
<span class="color-box weekend"></span>
|
||||
<span>Weekend</span>
|
||||
</div>
|
||||
<a href="#" on:click|preventDefault={() => showWeekendSettings = !showWeekendSettings} class="edit-link">
|
||||
(edit)
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{#if showHolidaysList || showWeekendSettings}
|
||||
|
||||
Reference in New Issue
Block a user