Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ Optional parameters are listed below.
| `rangeEnd` | Date | Same as `rangeStart`, but for the end boundary. e.g. passing in `new Date()` will prevent the user from being able to get to the next month. |
| `cancelText` | string | default is `Cancel` can be changed to the text you desire. |
| `weekStart` | number | default is `0` witch is Sunday, Monday is `1` and so on |
| `name` | string | name of the input. |


### CSS
Expand Down
1 change: 1 addition & 0 deletions demo/app.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import { Component, Input } from '@angular/core';
selector: 'my-app',
template: `
<material-datepicker
name="input-date-name"
[(date)]="date"
(onSelect)="onSelect($event)"
dateFormat="YYYY-MM-DD"
Expand Down
2 changes: 2 additions & 0 deletions src/datepicker.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -208,6 +208,7 @@ interface ValidationResult {
[ngStyle]="{'font-family': fontFamily}"
>
<input
[name]="name"
[disabled]="disabled"
class="datepicker__input"
[placeholder]="placeholder"
Expand Down Expand Up @@ -335,6 +336,7 @@ export class DatepickerComponent implements OnInit, OnChanges {
// data
@Input() placeholder: string = 'Select a date';
@Input() inputText: string;
@Input() name: string;
// view logic
@Input() showCalendar: boolean;
@Input() cancelText: string = 'Cancel';
Expand Down