-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
61256c1
commit a82b91c
Showing
34 changed files
with
1,426 additions
and
1,474 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,16 @@ | ||
import { TestBed } from '@angular/core/testing'; | ||
|
||
import { ResizeService } from './resize.service'; | ||
|
||
describe('ResizeService', () => { | ||
let service: ResizeService; | ||
|
||
beforeEach(() => { | ||
TestBed.configureTestingModule({}); | ||
service = TestBed.inject(ResizeService); | ||
}); | ||
|
||
it('should be created', () => { | ||
expect(service).toBeTruthy(); | ||
}); | ||
}); | ||
import { TestBed } from '@angular/core/testing'; | ||
|
||
import { ResizeService } from './resize.service'; | ||
|
||
describe('ResizeService', () => { | ||
let service: ResizeService; | ||
|
||
beforeEach(() => { | ||
TestBed.configureTestingModule({}); | ||
service = TestBed.inject(ResizeService); | ||
}); | ||
|
||
it('should be created', () => { | ||
expect(service).toBeTruthy(); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,151 +1,124 @@ | ||
<div class="gcc-calendar-wrapper" [ngClass]="{'loading': loading}"> | ||
|
||
<div class="header"> | ||
|
||
<!-- Left Actions--> | ||
<div class="left-actions"> | ||
|
||
<!-- Add Event --> | ||
<app-button theme="black" | ||
matButtonType="mat-icon-button" | ||
[tooltip]="'Add Event' | translate" | ||
[tooltipDirection]="TooltipDirection.Above" | ||
[ariaLabel]="'Add Event'" | ||
[disabled]="loading" | ||
[clickFunc]="toggleEventForm"> | ||
<i class="fa-solid fa-calendar-plus fa-lg"></i> | ||
</app-button> | ||
|
||
<!-- Search --> | ||
<app-button theme="black" | ||
matButtonType="mat-icon-button" | ||
[tooltip]="searchActive ? ('Close Search' | translate) : ('Search' | translate)" | ||
[tooltipDirection]="TooltipDirection.Above" | ||
[ariaLabel]="searchActive ? ('Close Search' | translate) : ('Search' | translate)" | ||
[disabled]="loading" | ||
[clickFunc]="toggleSearch"> | ||
<i [ngClass]="searchActive ? 'fa-xmark' : 'fa-magnifying-glass'" | ||
class="fa-solid fa-lg"> | ||
</i> | ||
</app-button> | ||
</div> | ||
|
||
<!-- Middle Actions--> | ||
<div class="middle-actions"> | ||
|
||
<!-- Nav Previous--> | ||
<app-button theme="black" | ||
matButtonType="mat-icon-button" | ||
[tooltip]="translations.calendar.controls.previous.title_month | translate" | ||
[tooltipDirection]="TooltipDirection.Left" | ||
[ariaLabel]="translations.calendar.controls.previous.aria_month | translate" | ||
[disabled]="loading" | ||
(click)="navigateCalendar(-1)"> | ||
<i class="fa-solid fa-angle-left fa-lg"></i> | ||
</app-button> | ||
|
||
<!-- Date --> | ||
<span>{{ date | localizedDate : 'MMMM YYYY' | titlecase }}</span> | ||
|
||
<!-- Nav Next --> | ||
<app-button theme="black" | ||
matButtonType="mat-icon-button" | ||
[tooltip]="translations.calendar.controls.next.title_month | translate" | ||
[tooltipDirection]="TooltipDirection.Right" | ||
[ariaLabel]="translations.calendar.controls.next.aria_month | translate" | ||
[disabled]="loading" | ||
(click)="navigateCalendar(1)"> | ||
<i class="fa-solid fa-angle-right fa-lg"></i> | ||
</app-button> | ||
</div> | ||
<div class="gcc-calendar-wrapper" [ngClass]="{ loading: loading }"> | ||
<div class="header"> | ||
<!-- Left Actions--> | ||
<div class="left-actions"> | ||
<!-- Add Event --> | ||
<app-button | ||
theme="black" | ||
matButtonType="mat-icon-button" | ||
[tooltip]="'Add Event' | translate" | ||
[tooltipDirection]="TooltipDirection.Above" | ||
[ariaLabel]="'Add Event'" | ||
[disabled]="loading" | ||
[clickFunc]="toggleEventForm" | ||
> | ||
<i class="fa-solid fa-calendar-plus fa-lg"></i> | ||
</app-button> | ||
|
||
<!-- Search --> | ||
<app-button | ||
theme="black" | ||
matButtonType="mat-icon-button" | ||
[tooltip]="searchActive ? ('Close Search' | translate) : ('Search' | translate)" | ||
[tooltipDirection]="TooltipDirection.Above" | ||
[ariaLabel]="searchActive ? ('Close Search' | translate) : ('Search' | translate)" | ||
[disabled]="loading" | ||
[clickFunc]="toggleSearch" | ||
> | ||
<i [ngClass]="searchActive ? 'fa-xmark' : 'fa-magnifying-glass'" class="fa-solid fa-lg"> </i> | ||
</app-button> | ||
</div> | ||
|
||
<!-- Right Actions --> | ||
<div class="right-actions"> | ||
<!-- Middle Actions--> | ||
<div class="middle-actions"> | ||
<!-- Nav Previous--> | ||
<app-button | ||
theme="black" | ||
matButtonType="mat-icon-button" | ||
[tooltip]="translations.calendar.controls.previous.title_month | translate" | ||
[tooltipDirection]="TooltipDirection.Left" | ||
[ariaLabel]="translations.calendar.controls.previous.aria_month | translate" | ||
[disabled]="loading" | ||
(click)="navigateCalendar(-1)" | ||
> | ||
<i class="fa-solid fa-angle-left fa-lg"></i> | ||
</app-button> | ||
|
||
<!-- Date --> | ||
<span>{{ date | localizedDate: 'MMMM YYYY' | titlecase }}</span> | ||
|
||
<!-- Nav Next --> | ||
<app-button | ||
theme="black" | ||
matButtonType="mat-icon-button" | ||
[tooltip]="translations.calendar.controls.next.title_month | translate" | ||
[tooltipDirection]="TooltipDirection.Right" | ||
[ariaLabel]="translations.calendar.controls.next.aria_month | translate" | ||
[disabled]="loading" | ||
(click)="navigateCalendar(1)" | ||
> | ||
<i class="fa-solid fa-angle-right fa-lg"></i> | ||
</app-button> | ||
</div> | ||
|
||
<!-- Filter --> | ||
<!-- <app-button theme="black" | ||
<!-- Right Actions --> | ||
<div class="right-actions"> | ||
<!-- Filter --> | ||
<!-- <app-button theme="black" | ||
matButtonType="mat-icon-button" | ||
[tooltip]="'TODO' | translate" | ||
[tooltipDirection]="TooltipDirection.Above" | ||
[ariaLabel]="'TODO' | translate" | ||
[disabled]="loading"> | ||
<i class="fa-solid fa-ellipsis-vertical fa-lg"></i> | ||
</app-button> --> | ||
</div> | ||
</div> | ||
</div> | ||
|
||
<!-- Search --> | ||
<app-calendar-search *ngIf="searchActive" | ||
[date]="date" | ||
[events]="events"> | ||
</app-calendar-search> | ||
<!-- Search --> | ||
<app-calendar-search *ngIf="searchActive" [date]="date" [events]="events"> </app-calendar-search> | ||
|
||
<div> | ||
<!-- Days of the Week --> | ||
<div class="weekdays"> | ||
@for (weekday of weekdays; track $index) { | ||
<div class="day" [class.today]="weekday.isToday"> | ||
{{ weekday.title | translate }} | ||
</div> | ||
} | ||
<div> | ||
<!-- Days of the Week --> | ||
<div class="weekdays"> | ||
@for (weekday of weekdays; track $index) { | ||
<div class="day" [class.today]="weekday.isToday"> | ||
{{ weekday.title | translate }} | ||
</div> | ||
} | ||
</div> | ||
|
||
<div class="calendar" [ngStyle]="calendarStyle"> | ||
<!-- Previous Month's Days --> | ||
@for (day of datesPaddingPre; track $index) { | ||
<app-calendar-day [calendarDate]="day" | ||
[outsideOfMonth]="true" | ||
[loading]="loading" | ||
(dayClick)="dayClick(day)"> | ||
</app-calendar-day> | ||
} | ||
<!-- Current Month's Days --> | ||
@for (day of dates; track $index) { | ||
<app-calendar-day [calendarDate]="day" | ||
[active]="$index === activeDayIndex" | ||
[loading]="loading" | ||
(dayClick)="dayClick(day)"> | ||
</app-calendar-day> | ||
} | ||
<!-- Next Month's Days --> | ||
@for (day of datesPaddingPost; track $index) { | ||
<app-calendar-day [calendarDate]="day" | ||
[outsideOfMonth]="true" | ||
[loading]="loading" | ||
(dayClick)="dayClick(day)"> | ||
</app-calendar-day> | ||
} | ||
</div> | ||
<div class="calendar" [ngStyle]="calendarStyle"> | ||
<!-- Previous Month's Days --> | ||
@for (day of datesPaddingPre; track $index) { | ||
<app-calendar-day [calendarDate]="day" [outsideOfMonth]="true" [loading]="loading" (dayClick)="dayClick(day)"> </app-calendar-day> | ||
} | ||
<!-- Current Month's Days --> | ||
@for (day of dates; track $index) { | ||
<app-calendar-day [calendarDate]="day" [active]="$index === activeDayIndex" [loading]="loading" (dayClick)="dayClick(day)"> </app-calendar-day> | ||
} | ||
<!-- Next Month's Days --> | ||
@for (day of datesPaddingPost; track $index) { | ||
<app-calendar-day [calendarDate]="day" [outsideOfMonth]="true" [loading]="loading" (dayClick)="dayClick(day)"> </app-calendar-day> | ||
} | ||
</div> | ||
</div> | ||
</div> | ||
|
||
<!-- Events --> | ||
<app-calendar-events *ngIf="activeDayIndex > -1 && !loading" | ||
[calendarDate]="dates[activeDayIndex]" | ||
(eventEdit)="editEvent($event)" | ||
(eventDelete)="deleteEvent($event)"> | ||
</app-calendar-events> | ||
<app-calendar-events *ngIf="activeDayIndex > -1 && !loading" [calendarDate]="dates[activeDayIndex]" (eventEdit)="editEvent($event)" (eventDelete)="deleteEvent($event)"> </app-calendar-events> | ||
|
||
<!-- Event Form --> | ||
<mat-card *ngIf="eventFormActive && !loading" class="event-form"> | ||
|
||
<app-event-form [form]="eventFormGroup" | ||
[model]="eventFormData"> | ||
</app-event-form> | ||
|
||
<div class="actions"> | ||
<!-- Save --> | ||
<app-button theme="secondary-2" | ||
[disabled]="loading || !eventFormValid()" | ||
[clickFunc]="saveEventForm"> | ||
{{ editEventId ? (translations.forms.save | translate) : (translations.forms.create | translate) }} | ||
</app-button> | ||
|
||
<!-- Cancel --> | ||
<app-button theme="secondary-2" | ||
[disabled]="loading" | ||
[clickFunc]="toggleEventForm"> | ||
Cancel | ||
</app-button> | ||
</div> | ||
</mat-card> | ||
<app-event-form [form]="eventFormGroup" [model]="eventFormData"> </app-event-form> | ||
|
||
<div class="actions"> | ||
<!-- Save --> | ||
<app-button theme="secondary-2" [disabled]="loading || !eventFormValid()" [clickFunc]="saveEventForm"> | ||
{{ editEventId ? (translations.forms.save | translate) : (translations.forms.create | translate) }} | ||
</app-button> | ||
|
||
<!-- Cancel --> | ||
<app-button theme="secondary-2" [disabled]="loading" [clickFunc]="toggleEventForm"> Cancel </app-button> | ||
</div> | ||
</mat-card> |
Oops, something went wrong.