-
Notifications
You must be signed in to change notification settings - Fork 0
/
index_April25.html
233 lines (177 loc) · 10.3 KB
/
index_April25.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
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
<html>
<head>
<title>Surveillance Stories</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script>
<link href='http://fonts.googleapis.com/css?family=Montserrat:400,700' rel='stylesheet' type='text/css'>
<link href='http://fonts.googleapis.com/css?family=Lato:100,300,400,700,900,100italic,300italic,400italic,700italic,900italic' rel='stylesheet' type='text/css'>
<style type="text/css">
body {
margin:1em;
padding:0;
font-family:'Lato';
font-weight: 300;
font-size:100%;
line-height:150%;
width:100%;
}
div#main {
text-align:center;
}
div#header {
height:100px;
top:0px;
margin-left:auto;
margin-right:auto;
width:100%;
background:ccc;
position:fixed;
z-index: 1;
}
div#highlight {
/* display:none; why doesn't this work? */
z-index: 55;
position:absolute; /* can i position this relative (close to) where the scrubber is? i guess that would make it a tooltip*/
margin-left:20px;
height:auto;
width:200px;
background:ffc;
}
div#story {
margin-top:120px;
margin-left:30px;
margin-right:50px;
text-align:left;
}
div#scrubber {
top:120px;
position:fixed;
background:black;
height:30px;
width:10px;
}
div.dot {
background: black;
position:absolute;
border-radius: 50%;
height:10px;
width:10px;
}
div.dot.system {
background:#D97D80;
}
div.dot.identity {
background:#FAC466;
}
div.dot.behavior {
background:#50BEFF;
}
div.dotblue {
position:absolute;
background:red;
height:10px;
width:10px;
}
div#scrubber:hover {
background:ffc;
}
span.annotation {
display:none;
font-size:9pt;
font-family:'Lato';
font-weight: 400;
color:#888;
text-align:left;
padding:1em;
margin:1em;
line-height: 150%;
}
span.annotation.system {background:blue; color:white;}
span.annotation span.headline {font-size:30;}
/* FILTERS */
span.system {
background:#D97D80;
}
span.identity {
background:#FAC466;
}
span.identity:hover {
background:#FAC466;
}
span.behavior {
background:#50BEFF;
}
span.behavior:hover {
background:#50BEFF;
}
</style>
<script>
$(document).ready(
function(){
$('body').click(function(e) {
$('div#highlight').html("");
});
$(".statement").click(function(e){
// filter , click listeners .. go get everything that is class .statement (which is really filter) when it is clicked, call function (e) which is event == which can have mouse position ,et c
var offset = $(this).attr('offset'); // when clicked on it loads offset which has % value
var kid = $(this).children('span.annotation');
var newkid = kid.clone();
newkid.css({display: 'block'}); // html elements display, none, inline, block, block has most control using "position" absolute
$("div#highlight").html(newkid);
var rect = this.getBoundingClientRect() // this means: refers to the context of the variable it is executing
$("div#highlight").css({
top: rect.top+window.scrollY-50
});
e.stopPropagation();
});
function drawDots() { //
$(".dot").remove(); // empty the canvas
var statements = $(".statement"); //fetch all statements
for (var i = 0; i < statements.length; i++) { // i is 0, immediately check the conditions,
var statement = statements[i] // firststatement is the variable name is getting statement 1 which is the 2nd highlight
var rect = statement.getBoundingClientRect() // 2nd statement is the 2nd highlight, calling a fucntion on that html element that returns the total size / distances of that hightlight
if ($(statement).hasClass("system")){
className="system";
}
if ($(statement).hasClass("identity")){
className="identity";
}
if ($(statement).hasClass("behavior")){
className="behavior";
}
var dot = $('<div class="dot '+className+'"></div>') // create html elements (the dots)
$("div#dotcontainer").append(dot) // select the container, append is a jquery function that inserts a dot visually
dot.css({top: rect.top+window.scrollY}) // for the dot that we just created, set the top value
}
}
drawDots(); // excuted once on load
$( window ).resize(drawDots); // if window is resized, escuted the functiont hat is draw dots
});
</script>
</head>
<body>
<div id="main">
<div id="header">
<div id="headline"></div>
<div id="body"></div>
</div>
<div id="dotcontainer"></div>
<div id="highlight">
</div>
<div id="story">
<p>I saw what was happening, <span class="statement system">but I didn’t know how to feel. Richard was breaking the law and risking his job for this girl.<span class="annotation system"><span class="headline">"Lorem ipsum dolor sit amet,</span><br><span class="body">consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.</span>
<span class="anno-right"> Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum."</span></span></span> He used his authority to access private information, to learn about John, to justify fears, and to contact me at my home, the only private places I had left. I wa there in the strings, just waiting to be pulled: Victim, Nicole Jones, Single, White, Female, Born 1983, Living, Austin, Texas.</p>
<p>I put Richard’s <span class="statement identity">business card in my pocket and thought about national security<span class="annotation">"Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.
<span class="anno-right"> Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat culpa qui officia deserunt mollit anim id est laborum."</span></span></span>. Was it okay for him to be here, as a government employee, asking me for a favor? Was I even surprised? Would he threaten to kill me if I talked about it, the way John had?</p>
<p>I didn’t know what to do or what the right thing was. This was all happening in the gray areas between victim, criminal, government, and network. <span class="statement behavior" offset="90%">business card in my pocket and thought about national security<span class="annotation"><span class="anno-left">"Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.</span>
<span class="anno-right"> A man with a lot of power and responsibility was at my door, pleading for help. He seemed genuinely kind and concerned. He asked me to tell a story that I alone could tell. I never really had that chance before. I was too young to testify during the trial. The authorities were afraid it would be too painful for me, and I’m sure they were right.</p>
<p>I saw what was happening, <span class="statement system" offset="20%">but I didn’t know how to feel. Richard was breaking the law and risking his job for this girl.<span class="annotation"><span class="anno-left">"Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.</span>
<span class="anno-right"> Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum."</span></span></span> He used his authority to access private information, to learn about John, to justify fears, and to contact me at my home, the only private places I had left. I wa there in the strings, just waiting to be pulled: Victim, Nicole Jones, Single, White, Female, Born 1983, Living, Austin, Texas.</p>
<p>I put Richard’s <span class="statement identity" offset="50%">business card in my pocket and thought about national security<span class="annotation"><span class="anno-left">"Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.</span>
<span class="anno-right"> Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat culpa qui officia deserunt mollit anim id est laborum."</span></span></span>. Was it okay for him to be here, as a government employee, asking me for a favor? Was I even surprised? Would he threaten to kill me if I talked about it, the way John had?</p>
<p>I didn’t know what to do or what the right thing was. This was all happening in the gray areas between victim, criminal, government, and network. <span class="statement behavior" offset="90%">business card in my pocket and thought about national security<span class="annotation"><span class="anno-left">"Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.</span>
<span class="anno-right"> A man with a lot of power and responsibility was at my door, pleading for help. He seemed genuinely kind and concerned. He asked me to tell a story that I alone could tell. I never really had that chance before. I was too young to testify during the trial. The authorities were afraid it would be too painful for me, and I’m sure they were right.</p>
</div>
</div>
</body>
</html>