Skip to content
This repository was archived by the owner on Sep 5, 2024. It is now read-only.

Commit 0046467

Browse files
Splaktarmmalerba
authored andcommitted
docs(calendar): add calendar demo (#11295)
this is needed as there are some bugs in this area it needs to be easier to submit reproductions
1 parent 560adb8 commit 0046467

File tree

5 files changed

+28
-23
lines changed

5 files changed

+28
-23
lines changed

src/components/datepicker/_demoCalendar/index.html

-8
This file was deleted.

src/components/datepicker/_demoCalendar/script.js

-12
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
<md-content ng-controller="AppCtrl as ctrl" layout="column" layout-gt-sm="row"
2+
layout-padding ng-cloak>
3+
<div layout="column" flex-order="1" flex-order-gt-sm="0">
4+
<md-subheader>Start Date</md-subheader>
5+
<md-calendar ng-model="ctrl.startDate"></md-calendar>
6+
</div>
7+
<div layout="column" flex-order="1" flex-order-gt-sm="1">
8+
<md-subheader>End Date</md-subheader>
9+
<md-calendar ng-model="ctrl.endDate"></md-calendar>
10+
</div>
11+
<div layout="column" flex-order="0" flex-order-gt-sm="2">
12+
<md-subheader>Dates</md-subheader>
13+
<div>
14+
<label>Start</label>
15+
<div>{{ctrl.startDate | date:shortDate}}</div>
16+
</div>
17+
<div><label>End</label>
18+
<div>{{ctrl.endDate | date:shortDate}}</div>
19+
</div>
20+
</div>
21+
</md-content>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
angular.module('calendarDemo', ['ngMaterial']).controller('AppCtrl', function() {
2+
this.startDate = new Date();
3+
this.endDate = new Date();
4+
this.endDate.setDate(this.endDate.getDate() + 5);
5+
});
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
/** Demo styles for mdCalendar. */
2-
3-
md-calendar {
4-
margin: 1px;
2+
label {
3+
font-size: x-small;
54
}

0 commit comments

Comments
 (0)