-
Notifications
You must be signed in to change notification settings - Fork 1
/
cards!.html
161 lines (132 loc) · 5.46 KB
/
cards!.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
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
<!DOCTYPE html>
<html ng-app="CardsApp">
<head>
<!--Import Google Icon Font-->
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
<link href="https://fonts.googleapis.com/css?family=Roboto&display=swap" rel="stylesheet">
<link href="https://fonts.googleapis.com/css?family=Roboto+Mono&display=swap" rel="stylesheet">
<!--Import materialize.css-->
<link type="text/css" rel="stylesheet" href="./materialize/css/materialize.css" media="screen,projection" />
<!--Let browser know website is optimized for mobile-->
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<!--Linking manifest-->
<link rel="manifest" href="/cards/manifest.json">
</head>
<body ng-controller="CardsController" style="font-family:Roboto Mono">
<!-- Floating action button -->
<div class="fixed-action-btn">
<a class="btn-floating btn-large yellow lighten-1">
<i class="large material-icons black-text" ng-click="addcard()">add</i>
</a>
</div>
<!--Main Grid-->
<div class="row"
style="font-family:-apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif">
<div class="col s12">
<div class="navbar-fixed">
<nav class="nav-wrapper yellow lighten-1">
<div>
<a class="center black-text" style="font-family: 'Roboto Mono'; font-size: 1.8em">
Flash Cards
</a>
<a href="#" data-target="mobile-demo" class="sidenav-trigger"><i
class="material-icons black-text">menu</i></a>
<ul id="nav-mobile" class="right hide-on-med-and-down">
</ul>
</div>
</nav>
</div>
<ul id="mobile-demo" class="sidenav" style="font-family: 'Roboto Mono'">
<li>
<div class="user-view">
<div class="background yellow lighten-1">
<br>
</div>
<a href="#user"><img class="circle" src="res/icons/icons-192.png"></a>
<a href="#name"><span class="name black-text">
<h5>Flash Cards</h5>
</span></a>
<hr>
</div>
</li>
<li><a href="#!">Flash Cards (beta) v 1.4</a></li>
<li>
<div class="divider"></div>
</li>
<li><a class="subheader">About</a></li>
<li><a class="waves-effect" href="#!">Work in progress</a></li>
</ul>
</div>
</div>
<div class="row">
<div class="col" ng-repeat="card in cards track by $index">
<div class="card sticky-action z-depth-2 activator" style="display:block; min-height: 360px;">
<br>
<div class="card-image waves-effect waves-block waves-light center" style="text-align:-webkit-center"
ng-click="expand($index)" onclick="expand($index)">
<img class="responsive-image activator" ng-src={{card.pic}} >
</div>
<div class="card-content activator">
<br>
<span class="card-title activator grey-text text-darken-4" style="font-size: 1.4em">{{card.title}}
<i class="material-icons right">more_vert</i></span>
<p><a href="#">{{card.option}}</a></p>
</div>
<!-- Card Reveal ( Answer )-->
<div class="card-reveal" style="padding-bottom: 0px; padding-top: 10px; ">
<span class="card-title grey-text text-darken-4">{{card.title}}<i class="material-icons right">close</i>
</span>
<br>
<div class="row">
<div class="col s12">
<div class="row" ng-repeat="num in nums" style="padding-left: 5px">
<p class="col s12 row">
<label class="col">
<input name="group1" type="checkbox" ng-model="(card.qopts)[num]" style="border-right-color:red" />
<span style="color: {{resCol[num]}}">{{card.ans[num].val}}</span>
<br>
</label>
</p>
</div>
</div>
</div>
<div class="card-action">
<div class="row center">
<button class="btn yellow accent 4 col s6" style="color: black; overflow:auto;"ng-click="log($index)">{{submit[$index]}}</button>
<i class="material-icons col s2 blue-text" ng-click="nav_share($index)" >share</i>
<i class="material-icons col s2" ng-click="nav_edit($index)">edit</i>
<i class="material-icons col s2 modal-trigger red-text" data-target="modal1"
onclick="localStorage.setItem('rn',$index)">delete</i>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="col">
<br>
<br>
<br>
</div>
<!-- Modal Structure -->
<div id="modal1" class="modal center">
<div class="modal-content red white-text">
<h4>Delete ?</h4>
</div>
<div style="text-align: center">
<i class="material-icons modal-close " data-target="modal1" style=" color:red; font-size: 15em"
ng-click="deleteCard(localStorage.getItem('rn'))">delete</i>
</div>
</div>
<!--JavaScript at end of body for optimized loading-->
<script type="text/javascript" src="./materialize/js/materialize.js"></script>
<script type="text/javascript" src="./angular/angular.min.js"></script>
<script src="./main.js"></script>
<script src="./material_init.js"></script>
<script>
function expand(num) {
document.getElementById('box'+num).click();
}
</script>
</body>
</html>