-
Notifications
You must be signed in to change notification settings - Fork 17
/
Copy pathindex.html
54 lines (46 loc) · 1.46 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
<!DOCTYPE html>
<html ng-app="ExampleApp">
<head>
<title>Datetime input UI element for AngularJS</title>
<link rel="stylesheet" type="text/css" href="dist/datetime-inputs.min.css">
<meta name="viewport" content="width=500,user-scalable=0">
<style>
body {
box-sizing: border-box;
width: 500px;
height: 100vh;
min-height: 100vh;
margin: 0;
padding: 15px;
color: #333;
font-family: sans-serif;
}
</style>
</head>
<body ng-controller="MainCtrl">
<h1>Date</h1>
<date-input date="now" on-change="print(now)" placeholder="Click Me"></date-input>
<br />
<br />
<br />
<h1>Time</h1>
<time-input time="now" on-change="print(now)" placeholder="Click Me"></time-input>
<br />
<br />
<br />
<h1>Datetime</h1>
<datetime-input datetime="now" on-change="print(now)" placeholder="Click Me"></datetime-input>
<script src="https://unpkg.com/[email protected]/min/moment.min.js" charset="utf-8"></script>
<script src="https://unpkg.com/[email protected]/angular.min.js" charset="utf-8"></script>
<script src="https://unpkg.com/[email protected]/dist/scroll-events.min.js" charset="utf-8"></script>
<script src="dist/datetime-inputs.min.js"></script>
<script>
angular.module('ExampleApp', ['g1b.datetime-inputs']).
controller('MainCtrl', function ($scope) {
$scope.print = function (datetime) {
console.log('datetime', datetime);
};
});
</script>
</body>
</html>