-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
60 lines (51 loc) · 2.04 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Calendar Exercise</title>
<link href='css/styles.css' rel='stylesheet' type='text/css'>
</head>
<body ng-app="myCalendar" ng-controller="calendarCtrl">
<div class="holidaybox" ng-show="showHolidays">
<ul>
<li ng-repeat="day in showHolidays">{{day.name}}</li>
</ul>
</div>
<div class="container">
<div class="center">
<h4>Search a day:</h4>
<div class="form">
<input ng-model="inputDate" type="text" placeholder="mm/dd/yyyy" ></input>
<input ng-model="inputDays" type="text" placeholder="Number of days"></input>
<input ng-model="inputCountry" type="text" placeholder="Country Code (Example: US)"></input>
<button ng-click="generateCalendar()">View</button>
<div ng-show="errormsg" style="margin-top: 6px;"><span class="errorbox">{{ errormsg }}</span></div>
</div>
<div class="calendar" ng-repeat="data in calendars">
<div class="weekdays" ng-if="$index === 0">
<div class="wd">S</div>
<div class="wd">M</div>
<div class="wd">T</div>
<div class="wd">W</div>
<div class="wd">T</div>
<div class="wd">F</div>
<div class="wd">S</div>
</div>
<div class="header form">
{{ data.title | date:'MMMM yyyy' }}
</div>
<div class="days">
<div class="wd {{ day.class}} " ng-repeat="day in data.calendar" ng-mousemove="hoverDay($event,day)" ng-mouseleave="clearDay()">
<span ng-if="day.date">{{ day.date | date:'dd' }}</span>
</div>
<div style="clear: both;"></div>
</div>
</div>
<div class="noCalendar" ng-hide="calendars"><h4>Please use the search form the generate a new calendar</h4></div>
</div>
</div>
</body>
<script src="scripts/jquery.min.js" type="text/javascript"></script>
<script src="scripts/angular.min.js" type="text/javascript"></script>
<script src="scripts/controller.js" type="text/javascript"></script>
</html>