I came across a tutorial online at "" that explains how to create an event calendar in Ionic. I followed the tutorial and successfully implemented it, but I now have a specific issue. I want to make Saturdays and Sundays unselectable, meaning users should not be able to set events on those days.
Below is my calendar HTML file:
<ion-header>
<ion-navbar color="BlueNew">
<ion-title>
Home
</ion-title>
<ion-buttons start>
<button ion-button icon-only (click)="addEvent()">
<ion-icon name="mail"></ion-icon>
</button>
</ion-buttons>
</ion-navbar>
</ion-header>
<ion-content>
<p style="text-align:center;">{{ viewTitle }}</p>
<ion-navbar color="white">
<ion-buttons end>
<button ion-button [disabled]="isToday" (click)="today ()">Today</button>
<button ion-button (click)="changeMode('day')">D</button>
<button ion-button (click)="changeMode('week')">W</button>
<button ion-button (click)="changeMode('month')">M</button>
</ion-buttons>
</ion-navbar>
<calendar [eventSource]="eventSource"
[calendarMode]="calendar.mode"
[currentDate]="calendar.currentDate"
(onEventSelected)="onEventSelected($event)"
(onTitleChanged)="onViewTitleChanged($event)"
(onTimeSelected)="onTimeSelected($event)"
step="30"
startHour="9"
endHour="19"
allDayLabel=""
class="calendar">
</calendar>