Skip to content
This repository was archived by the owner on Mar 4, 2023. It is now read-only.

Commit 96f1c10

Browse files
author
eksrvb
committed
polishing
1 parent 5ce5aee commit 96f1c10

File tree

6 files changed

+28
-81
lines changed

6 files changed

+28
-81
lines changed

.gitlab-ci.yml

Lines changed: 0 additions & 64 deletions
This file was deleted.

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
Please read this **before** usage!
33
This material calendar is just beginning. As in the angular material components, a beautiful calendar is to be generated by simple integration. Cooperation is welcome.
44

5+
> Note: tthe following changes from version 3.0.0 onwards will no longer be compatible with this api. All necessary changes are documented. Version 3.0.0 is coming soon ;)
6+
57
### Live demo
68
[Open demo on Stackblitz](https://stackblitz.com/github/e-netsupport/material-calendar-demo)
79

projects/lib-workspace/src/app/app.component.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030

3131
</div>
3232

33-
<calendar-panels [mode]="mode" [placeholderDay]="placeholder" year="2020" month="5" [monthsBefore]="monthsBefore"
33+
<calendar-panels [mode]="mode" [placeholderDay]="placeholder" year="2021" month="5" [monthsBefore]="monthsBefore"
3434
[monthsAfter]="monthsAfter" [config]="calendarConfig" (clickDate)="testMethod($event)">
3535
</calendar-panels>
3636

projects/lib-workspace/src/app/app.component.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ export class AppComponent implements OnInit {
1717
monthsAfter = 0;
1818

1919
calendarConfig: CalendarConfig = {
20-
panelBgColor: '#00677f', // 00677f 006105
20+
panelBgColor: '#ffffff',
2121
autoTextColor: true,
2222
textColor: '#fff',
2323
useHolidays: false,
@@ -26,7 +26,7 @@ export class AppComponent implements OnInit {
2626
displayYear: true,
2727
firstDayOfWeekMonday: true,
2828
calendarWeek: true,
29-
todayColor: '#fff',
29+
todayColor: '#000000',
3030
panelWidth: '90%',
3131
switches: true,
3232
}

projects/material-calendar/src/lib/calendar-panels/calendar-panels.component.html

Lines changed: 21 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -2,19 +2,24 @@
22
<button mat-flat-button class="slideButton"
33
*ngIf="config.switches && mode == 'monthly' && (monthsBefore != 0 || monthsAfter != 0)"
44
(click)="onMonthBackward()">
5-
<span class="material-icons">
5+
<!-- <span class="material-icons">
66
keyboard_arrow_left
7-
</span>
7+
</span> -->
8+
<svg xmlns="http://www.w3.org/2000/svg" height="24px" viewBox="0 0 24 24" width="24px">
9+
<path d="M0 0h24v24H0z" fill="none" />
10+
<path d="M15.41 7.41L14 6l-6 6 6 6 1.41-1.41L10.83 12z" />
11+
</svg>
812
</button>
913
<div class="month mat-elevation-z8" *ngFor="let monat of calendar.months" [style.width]="panelWidth">
1014
<mat-grid-list cols="{{config.calendarWeek? 8 : 7}}" rowHeight="1:1">
1115
<mat-grid-tile colspan="{{config.calendarWeek? 8 : 7}}" rowspan="1">
1216
<button mat-icon-button
1317
*ngIf="config.switches && mode == 'monthly' && (monthsBefore == 0 && monthsAfter == 0)"
1418
(click)="onMonthBackward()">
15-
<span class="material-icons">
16-
keyboard_arrow_left
17-
</span>
19+
<svg xmlns="http://www.w3.org/2000/svg" height="24px" viewBox="0 0 24 24" width="24px">
20+
<path d="M0 0h24v24H0z" fill="none" />
21+
<path d="M15.41 7.41L14 6l-6 6 6 6 1.41-1.41L10.83 12z" />
22+
</svg>
1823
</button>
1924

2025
<h3 class="displayMonthName" *ngIf="!config.displayYear">{{monat.name}}</h3>
@@ -23,9 +28,11 @@ <h3 class="displayMonthName" *ngIf="config.displayYear">{{monat.name}} {{monat.y
2328
<button mat-icon-button
2429
*ngIf="config.switches && mode == 'monthly' && (monthsBefore == 0 && monthsAfter == 0)"
2530
(click)="onMonthForward()">
26-
<span class="material-icons">
27-
keyboard_arrow_right
28-
</span>
31+
<svg xmlns="http://www.w3.org/2000/svg" height="24px" viewBox="0 0 24 24" width="24px"
32+
fill="#000000">
33+
<path d="M0 0h24v24H0z" fill="none" />
34+
<path d="M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z" />
35+
</svg>
2936
</button>
3037
</mat-grid-tile>
3138
<mat-grid-tile *ngIf="config.calendarWeek" colspan="1" rowspan="1"></mat-grid-tile>
@@ -44,7 +51,8 @@ <h3 class="displayMonthName" *ngIf="config.displayYear">{{monat.name}} {{monat.y
4451
<a>{{day.day}}</a>
4552
</mat-grid-tile>
4653

47-
<mat-grid-tile (click)="onClick(day)" *ngIf="day.type === 'date'" colspan="1" rowspan="1" matTooltip="test" class="date"
54+
<mat-grid-tile (click)="onClick(day)" *ngIf="day.type === 'date'" colspan="1" rowspan="1"
55+
matTooltip="test" class="date"
4856
[ngClass]="[day.isWeekendDay? 'Weekend' : '', day.isHoliday && config.useHolidays ? 'Holiday' : '']">
4957
<div [ngClass]="day.date.setHours(0, 0, 0, 0) == today? 'today': ''">
5058
<a>{{day.day}}</a>
@@ -58,8 +66,9 @@ <h3 class="displayMonthName" *ngIf="config.displayYear">{{monat.name}} {{monat.y
5866
<button mat-flat-button class="slideButton"
5967
*ngIf="config.switches && mode == 'monthly' && (monthsBefore != 0 || monthsAfter != 0)"
6068
(click)="onMonthForward()">
61-
<span class="material-icons">
62-
keyboard_arrow_right
63-
</span>
69+
<svg xmlns="http://www.w3.org/2000/svg" height="24px" viewBox="0 0 24 24" width="24px" fill="#000000">
70+
<path d="M0 0h24v24H0z" fill="none" />
71+
<path d="M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z" />
72+
</svg>
6473
</button>
6574
</div>

projects/material-calendar/src/lib/calendar-panels/calendar-panels.component.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,15 +13,15 @@ export class CalendarPanelsComponent implements OnInit {
1313

1414
private _mode: string;
1515
private _config: CalendarConfig = {
16-
panelBgColor: '#00677f', // 00677f 006105
16+
panelBgColor: '#ffffff', // 00677f 006105
1717
autoTextColor: true,
1818
textColor: '#fff',
1919
useHolidays: false,
2020
holidayColor: 'rgb(253, 173, 0)',
2121
holidayTextColor: 'rgb(253, 173, 0)',
2222
displayYear: true,
2323
firstDayOfWeekMonday: true,
24-
todayColor: '#fff',
24+
todayColor: '#000000',
2525
panelWidth: '100%',
2626
calendarWeek: true,
2727
switches: false,

0 commit comments

Comments
 (0)