forked from iconic/SVGInjector
-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathangular-simple.html
39 lines (36 loc) · 1.21 KB
/
angular-simple.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
<!DOCTYPE html>
<html lang="en" ng-app="svginjectordemo">
<head>
<title>SVGInjector Example: Simple</title>
<style>
.icon--thumb {
width:64px;
height:64px;
display: block;
margin: 100px auto;
}
.red {
color: red;
}
.green {
color: green;
}
</style>
</head>
<body>
<svg class="icon icon--thumb red" data-src="assets/svg/thumb-up.svg" title="I like it!" alt="thumb" onclick="console.log('clicked');"/>
<svg class="icon icon--thumb green" data-src="assets/svg/thumb-up.svg" title="I like it!" alt="thumb" onclick="console.log('clicked');"/>
<svg data-src="assets/svg/logo-gradients.svg">
<title>Default Tilte replace</title>
<desc>Same thing for description</desc>
</svg>
<svg data-src="assets/svg/circle.svg" />
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.5.11/angular.min.js"></script>
<script src="../dist/svg-injector.min.js"></script>
<script>
// define the module with the name of the ng-app directive and define
// the `svginjector` module as dependency
angular.module('svginjectordemo', ['svginjector']);
</script>
</body>
</html>