You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+1-1
Original file line number
Diff line number
Diff line change
@@ -141,7 +141,7 @@ This library is not optimised for mobile. Due to the complex nature of a calenda
141
141
All parts of this calendar can be customised via the use of an `ng-template`. The recipe for applying one is as follows:
142
142
143
143
- Find the template you would like to customise for the month, week or day view component. You can find all available custom templates by reading the [documentation](https://mattlewis92.github.io/angular-calendar/docs/) for each component. For this example we will pick the [`cellTemplate`](https://mattlewis92.github.io/angular-calendar/docs/components/CalendarMonthViewComponent.html#cellTemplate) from the month view.
144
-
- Next find the corresponding child component that will render the template by viewing the source. For our example of the month view cell it is [this component](https://github.com/mattlewis92/angular-calendar/blob/main/projects/angular-calendar/src/modules/month/calendar-month-cell.component.ts)
144
+
- Next find the corresponding child component that will render the template by viewing the source. For our example of the month view cell it is [this component](https://github.com/mattlewis92/angular-calendar/blob/main/projects/angular-calendar/src/modules/month/calendar-month-view/calendar-month-cell/calendar-month-cell.component.ts)
145
145
- Now copy the [template source](https://github.com/mattlewis92/angular-calendar/blob/be842da460a803ebb570418bc10e11fab56bd7b9/projects/angular-calendar/src/modules/month/calendar-month-cell.component.ts#L15-L72) for your chosen template into your own component and modify as your see fit.
146
146
- Finally pass the template to the components input: `<mwl-calendar-month-view [cellTemplate]="cellTemplateId" />`
147
147
- You can see an e2e working example of this [here](https://mattlewis92.github.io/angular-calendar/#/custom-templates)
Copy file name to clipboardExpand all lines: projects/angular-calendar/src/modules/common/calendar-angular-date-formatter/calendar-angular-date-formatter.provider.spec.ts
Copy file name to clipboardExpand all lines: projects/angular-calendar/src/modules/common/calendar-angular-date-formatter/calendar-angular-date-formatter.provider.ts
Copy file name to clipboardExpand all lines: projects/angular-calendar/src/modules/common/calendar-moment-date-formatter/calendar-moment-date-formatter.provider.spec.ts
Copy file name to clipboardExpand all lines: projects/angular-calendar/src/modules/common/calendar-moment-date-formatter/calendar-moment-date-formatter.provider.ts
Copy file name to clipboardExpand all lines: projects/angular-calendar/src/modules/common/calendar-native-date-formatter/calendar-native-date-formatter.provider.spec.ts
Copy file name to clipboardExpand all lines: projects/angular-calendar/src/modules/common/calendar-native-date-formatter/calendar-native-date-formatter.provider.ts
* This will use <a href="https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Global_Objects/Intl" target="_blank">Intl</a> API to do all date formatting.
Copy file name to clipboardExpand all lines: projects/angular-calendar/src/modules/common/calendar-previous-view/calendar-previous-view.directive.spec.ts
0 commit comments