forked from andoulla/angular-video
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
79 lines (63 loc) · 2.6 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
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
<!DOCTYPE html>
<html>
<head>
<title>AngularJs Video Directive</title>
</head>
<body ng-app="myApp">
<div style="margin: 0px auto">
<h1>anguVideo</h1>
<p>
This is a directive that takes in a vimeo or a youtube url and converts it into an embedded friendly url and the displays it.
</p>
<p>
<strong>Note:</strong> If an embedded friendly url is provided then the directive will simply gets the trusted resource url using angular's trustAsResourceUrl() functionality and then display the video
</p>
<h5> Url formats:</h5>
<ul>
<li>http://www.youtube.com/watch?v=[xyzxyz]</li>
<li>http://youtu.be/[xyzxyz]</li>
<li>http://www.youtube.com/embed/[xyzxyz]</li>
<li>http://vimeo.com/[xyzxyz]</li>
</ul>
<h3> Attributes</h3>
<p>
width: width="[number]%" or width="[number]" - for px
<br> <br>
height: height="[number]"
</p>
<br> <br>
<h3>YouTube Examples</h3>
<hr>
<div>http://www.youtube.com/watch?v=vabnZ9-ex7o</div>
<div anguvideo url="http://www.youtube.com/watch?v=vabnZ9-ex7o" width="250" height="250"></div>
<br> <br>
<div>http://youtu.be/5EVMjnHFg-w</div>
<anguvideo url="http://youtu.be/5EVMjnHFg-w" width="300" height="400"></anguvideo>
<br> <br>
<div>http://www.youtube.com/embed/u9hauSrihYQ</div>
<anguvideo url="http://www.youtube.com/embed/u9hauSrihYQ" width="50%" height="300"></anguvideo>
<h3>Vimeo Examples</h3>
<hr>
<div>http://vimeo.com/35514005</div>
<anguvideo url="http://vimeo.com/35514005" width="50%" height="500"></anguvideo>
<br> <br>
<h3>Azure Example</h3>
<hr>
<div>http://empowercompany.streaming.mediaservices.windows.net/fd9acbe7-cb2d-4f5b-a5bd-4af2dce75155/E-INFORMACOES_DE_VENDAS.ism/manifest(format=m3u8-aapl)</div>
<anguvideo url="http://empowercompany.streaming.mediaservices.windows.net/fd9acbe7-cb2d-4f5b-a5bd-4af2dce75155/E-INFORMACOES_DE_VENDAS.ism/manifest(format=m3u8-aapl)" width="50%" height="500"></anguvideo>
<br> <br>
</div>
<script src="//code.jquery.com/jquery-latest.min.js"></script>
<script src="./bower_components/angular/angular.js"></script>
<script src="./bower_components/angular-load/dist/angular-load.min.js"></script>
<script src="shared/player.service.js"></script>
<script src="./js/app.js"></script>
<script src="js/anguvideo.js"></script>
<script src="components/youtube/controller.js"></script>
<script src="components/youtube/config.js"></script>
<script src="components/vimeo/controller.js"></script>
<script src="components/vimeo/config.js"></script>
<script src="components/azure/controller.js"></script>
<script src="components/azure/config.js"></script>
</body>
</html>