1
<!doctype html>
2
<html lang="en">
3
  <head>
4
    <meta charset="utf-8">
5
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
    <title> CLink: Community Linked Open Cultuur Data </title>
7
8
    <meta name="description" content="Sweet Maker, Social, Semantic, Web, Decentralized, Makes Sweet, Sweet Swagger, Swtr, swtr">
9
    <link href="{{ url_for('static', filename='css/bootstrap.min.css') }}" rel="stylesheet">
10
    <link href="{{ url_for('static', filename='css/bootstrap-theme.min.css') }}" rel="stylesheet">
11
    <link href="{{ url_for('static', filename='css/annotorious.css') }}" rel="stylesheet">
12
    <link href="{{ url_for('static', filename='css/swtmaker.css') }}" rel="stylesheet">
13
    <link href="{{ url_for('static', filename='css/bootstrap-tags.css') }}"  rel="stylesheet">
14
  </head>
15
16
  <body>
17
    <!-- navigation and branding of the app -->
18
    <header id="header" class="navbar navbar-inverse" role="navigation">
19
      <div class="container-fluid">
20
        <!-- Brand and toggle get grouped for better mobile display -->
21
        <div class="navbar-header">
22
          <button type="button" class="navbar-toggle" data-toggle="collapse"
23
            data-target="#swtr-navbar-collapse">
24
25
            <span class="sr-only">Toggle navigation</span>
26
            <span class="icon-bar"></span>
27
            <span class="icon-bar"></span>
28
            <span class="icon-bar"></span>
29
          </button>
30
          <a class="navbar-brand" href="#/home">
31
            CLink: Community Linked Open Cultuur Data
32
          </a>
33
        </div>
34
        <!-- Collect the nav links, forms, and other content for toggling -->
35
        <div class="collapse navbar-collapse" id="swtr-navbar-collapse">
36
          <ul class="nav navbar-nav navbar-right">
37
            <li class="active"> <a href="#/home" title="Home">
38
              <span class="glyphicon glyphicon-home"></span>
39
            </a></li>
40
            <li> <a href="#/search" title="Search External Sources">
41
              <span class="glyphicon glyphicon-search"></span>
42
            </a></li>
43
            <li> <a href="#/play" title="My Playarea">
44
                <span class="glyphicon glyphicon-user"></span>
45
            </a></li>
46
47
            <li> <a href="#/linked-data" title="Linked Data">
48
              <span class="glyphicon glyphicon-globe"></span>
49
            </a></li>
50
            <li> <a id="sign-in" href="#" title="">
51
              <span id="signinview"> Sign In </span>
52
            </a></li>
53
          </ul>
54
        </div>
55
      </div>
56
    </header>
57
58
    <div id="swtr-root" class="container">
59
      <div id="helpview-container"></div>
60
61
      <div id="home-page" class="page">
62
        <div class="jumbotron">
63
          <h1> CLink: Community Linked Open Cultuur Data </h1>
64
          <p>
65
            There are over 30 data sets in <a href="http://www.opencultuurdata.nl">
66
            Open Cultuur Data.</a> Using CLink, one can
67
            bookmark, annotate, tag and discover the social enrichment of the data
68
            by a community of interest.
69
          </p>
70
          <p>
71
            CLink provides annotation and tagging of images that are searchable in
72
            the <a href="http://www.opencultuurdata.nl">OCD</a> dataset and also
73
            tagging and connecting to images that are outside the dataset.
74
            The annotations/tags of a person are announced and made available for
75
            other users who can further filter the users of interest and tags or
76
            datasets of interest.
77
          </p>
78
          <!-- <p> -->
79
          <!--   <a class="btn btn-info btn-lg" href="#/search">Start Searching and Tagging</a> -->
80
          <!-- </p> -->
81
          <div class="row home-links">
82
            <div class="col-md-4">
83
              <a href="#/search" class="btn btn-info btn-lg">
84
                <span class="glyphicon glyphicon-search"></span>
85
                Search
86
              </a>
87
            </div>
88
            <div class="col-md-4">
89
              <a href="#/play" class="btn btn-info btn-lg">
90
                <span class="glyphicon glyphicon-user"></span>
91
                Personal PlayArea
92
              </a>
93
            </div>
94
            <div class="col-md-4">
95
              <a href="#/linked-data" class="btn btn-info btn-lg">
96
                <span class="glyphicon glyphicon-globe"></span>
97
                Linked Data
98
              </a>
99
            </div>
100
          </div>
101
        </div>
102
        <hr/>
103
        <p>
104
          <h3>
105
              <span class="glyphicon glyphicon-search"></span>
106
              Search
107
          </h3>
108
          <h4>
109
            Search uses <a href="opencultuurdata.nl">opencultuurdata.nl</a>
110
            APIs to look for images from the datases provided by OCD collection.
111
            One can then start annotating an image of interest.
112
            Such an image is marked and is available in the play
113
            area [<span class="glyphicon glyphicon-user"></span>] of the user.
114
          </h4>
115
        </p>
116
        <p>
117
          <h3>
118
            <span class="glyphicon glyphicon-user"></span>
119
            Personal PlayArea
120
          </h3>
121
          <h4>
122
            A user can view all annotated images. The tags used in
123
            annotations are also shown as a list and can be used for filtering the
124
            set of images. User can also choose to annotate an image outside the
125
            OCD collection by using the image URL.
126
          </h4>
127
        </p>
128
        <p>
129
          <h3>
130
            <span class="glyphicon glyphicon-globe"></span>
131
            Linked Data
132
          </h3>
133
          <h4>
134
            All images that are tagged by all users are available for browsing,
135
            filtering based on selecting or deselecting users (and their
136
            annotations); and also by selecting and deselecting tags of interest.
137
          </h4>
138
        </p>
139
140
        <hr/>
141
142
        <footer>
143
          <!--p>This app is part of the <a href="http://www.opencultuurdata.nl/challenge-english/">
144
            Open Cuultur Data challenge</a>
145
          </p-->
146
          <p>
147
            We use <a href="https://login.persona.org/about">Mozilla Persona</a> for identifying
148
            users, <a href="http://annotorious.github.io/">Annotorious</a> for image annotation and
149
            <a href="http://janastu.org/technoscience/index.php/Sweet_Web">SWeeT Web</a>
150
            for assimilating the linked open data announced by users. [opensource cc]
151
          </p>
152
          <p>
153
            [<b>Clink</b>: Middle English clinken, probably from Middle Dutch klinken, of
154
            imitative origin.]
155
          </p>
156
          <p style="font-size: 0.8em;">
157
            Made with &hearts; by <a href="//twitter.com/rayanon">Anon Ray</a>
158
            and <a href="//twitter.com/arvindkhadri">Arvind Khadri</a>
159
          </p>
160
        </footer>
161
      </div>
162
163
      <div id="play-page" class="page"></div>
164
165
      <!-- the search page -->
166
      <div id="search-page" class="page"></div>
167
168
      <div id="linked-data-page" class="page">
169
        <div id="tag-cloud">
170
          <div class="col-md-5">
171
            <label>Tags:</label>
172
            <ul class="list-group" id="tags-tag-cloud"></ul>
173
          </div>
174
          <div class="col-md-5">
175
            <label>Users:</label>
176
            <ul class="list-group" id="user-tag-cloud"></ul>
177
          </div>
178
        </div>
179
        <div id="gallery">
180
        </div>
181
      </div>
182
183
    </div>
184
    <div id="app-overlay"></div>
185
186
    <script>
187
      window.swtr = window.swtr || {};
188
      swtr.swtstoreURL = function() { return '{{ config.swtstoreURL }}'; }
189
      swtr.endpoints = {
190
        'get': '/api/sweets/q',
191
        'post': '/api/sweets',
192
        'auth': '/oauth/authorize',
193
        'login': '/auth/login',
194
        'logout': '/auth/logout'
195
      };
196
      swtr.access_token = '{{ access_token }}';
197
      swtr.refresh_token = '{{ refresh_token }}';
198
      swtr.app_id = '{{ config.app_id }}';
199
      swtr.oauth_redirect_uri = '{{ config.redirect_uri }}';
200
      window.onload = function() {
201
        swtr.init();
202
      };
203
    </script>
204
    <script src="{{ url_for('static', filename='js/lib/jquery-1.10.2.min.js') }}"></script>
205
    <script src="{{ url_for('static', filename='js/lib/d3.js') }}"></script>
206
    <script src="{{ url_for('static', filename='js/lib/d3.layout.cloud.js') }}"></script>
207
    <script src="{{ url_for('static', filename='js/lib/bootstrap.min.js') }}"></script>
208
    <script src="{{ url_for('static', filename='js/lib/underscore-1.5.2.min.js') }}"></script>
209
    <script src="{{ url_for('static', filename='js/lib/backbone-1.0.0.min.js') }}"></script>
210
    <script src="{{ url_for('static', filename='js/lib/annotorious.debug.js') }}"></script>
211
    <script src="{{ url_for('static', filename='js/lib/custom-fields-plugin.js') }}"></script>
212
    <script src="{{ url_for('static', filename='js/oauth.js') }}"></script>
213
    <script src="{{ url_for('static', filename='js/lib/bootstrap-tags.min.js') }}"></script>
214
    <script src="{{ url_for('static', filename='js/img_swtr.js') }}"></script>
215
    <script src="{{ url_for('static', filename='js/main.js') }}"></script>
216
217
    <!-- underscore.js templates -->
218
    <script type="text/template" id="helpview-template">
219
      <div class="row">
220
        <div class="col-md-8">
221
          <div id="helpview" class="bg-info">
222
            <span class="label label-primary">Tip</span>
223
            <span id="helpview-text"></span>
224
            <a class="close">&times;</a>
225
          </div>
226
        </div>
227
        <div class="col-md-4"></div>
228
      </div>
229
    </script>
230
    <script type="text/template" id="sweet-template">
231
      <li class="sweet">
232
        <a href="#">@<%= who %></a> <strong>#<%= what %></strong>
233
        /<a href="<%= where %>"><%= where.substr(0, 30) + '...' %></a>
234
        <p><%= how %></p>
235
      </li>
236
    </script>
237
    <!--script type="text/template" id="dropdown-template">
238
      <div id="tags-input"></div>
239
      <select class="form-control" id="custom-dropdown">
240
        <option value="comment" selected>Comment</option>
241
        <option value="title" >Title</option>
242
        <option value="tags">Tags</option>
243
        <option value="link">Link</option>
244
      </select>
245
    </script-->
246
    <script type="text/template" id="customEdit-template">
247
     <textarea id="title-input" class="annotorious-editor-text goog-textarea" placeholder="Add
248
       Title" tabindex="1" rows="2" style="overflow-y: hidden; overflow-x:
249
       auto; box-sizing: border-box; height: 23px; padding-bottom:
250
       4px;"></textarea>
251
    <textarea id="link-input" class="annotorious-editor-text goog-textarea" placeholder="Add
252
      Links" tabindex="1" rows="3" style="overflow-y: hidden; overflow-x: auto;
253
      box-sizing: border-box; height: 23px; padding-bottom: 4px;"></textarea>
254
   <div id="tags-input" class="annotorious-editor-text goog-textarea"
255
     placeholder="" tabindex="1" rows="4" style="overflow-y: auto; overflow-x:
256
     hidden;
257
     box-sizing: border-box; height: 23px; padding-bottom: 4px;"></textarea> 
258
    </script>
259
    <script type="text/template" id="popup-template">
260
      <span class="annotorious-popup-text">
261
        <ul class="custom-style-popup">
262
          <li class="custom-popup-line" ><span>Title: </span><%= Label %></li>
263
          <li class="custom-popup-line"><span>Comment: </span><%= Comment %></li>
264
          <li class="custom-popup-line"><span>Tags: </span><%= Tags %></li>
265
          <li class="custom-popup-line"><span>Related Links: </span><%= Links %></li>
266
        </ul>
267
      </span>
268
    </script>
269
    <script type="text/template" id="play-page-template">
270
      <!-- second row: image URL input box and Load button -->
271
        <div class="row" id="user-input-row">
272
          <div class="col-md-8">
273
            <form class="form-inline" role="form">
274
              <div class="form-group col-md-11">
275
                <label class="sr-only" for="user-input">Enter URL of an image or web page</label>
276
                <input class="form-control" type="text"
277
                  placeholder="Enter URL of an image or web page" id="user-input">
278
              </div>
279
              <button type="submit" class="btn btn-info" id="user-input-submit">Load</button>
280
            </form>
281
          </div>
282
          <div class="col-md-4">
283
          </div>
284
        </div> <!-- end second row -->
285
        <!-- third row - control panel? -->
286
        <div class="row" id="control-panel">
287
          <div class="col-md-8">
288
            <form class="form-inline" role="form">
289
              <div class="form-group">
290
                <button class="btn btn-default" id="sweet">Publish</button>
291
              </div>
292
            </form>
293
          </div>
294
          <div class="col-md-4"></div>
295
        </div> <!-- end third row -- >
296
        <!-- fourth row: the image annotation window -->
297
        <div class="row">
298
          <div id="img-annotation-wrapper" class="col-md-12 col-xs-12 col-lg-12 col-sm-12 well">
299
            <div id="img-anno-controls">
300
              <form class="form-inline" role="form">
301
                <div class="form-group">
302
                  <label class="checkbox-inline">
303
                    <input type="checkbox" id="toggle-anno-areas"> Show annotated areas
304
                  </label>
305
                </div>
306
              </form>
307
            </div>
308
          {% if url %}
309
            <img src="{{ url }}" id="annotatable-img" class="img-responsive" alt="Annotation Workbench">
310
          {% else %}
311
            <img src="" id="annotatable-img" class="img-responsive" alt="Annotation Workbench">
312
          {% endif %}
313
          </div>
314
        </div> <!-- end fourth row -->
315
316
        <div id="sweet-list-wrapper">
317
          <ul id="sweet-list"></ul>
318
          <div class="btn-grp">
319
            <button class="btn btn-default" id="sweet-cancel">Cancel</button>
320
            <button class="btn btn-primary" id="post-sweet">Sweet</button>
321
          </div>
322
        </div>
323
    </script>
324
    <script type="text/template" id="search-page-template">
325
      <div class="row" id="search-user-input-row">
326
        <div class="col-md-8">
327
          <form class="form-inline" role="form">
328
            <div class="form-group col-md-11">
329
              <label class="sr-only" for="search-user-input">Enter search query</label>
330
              <input class="form-control" type="text"
331
                placeholder="Enter search query" id="search-user-input">
332
            </div>
333
            <button type="submit" class="btn btn-info" id="search-user-input-submit">
334
              Go
335
            </button>
336
          </form>
337
        </div>
338
        <div class="col-md-4">
339
        </div>
340
      </div>
341
    </script>
342
    <script type="text/template" id="ocd-view-base-template">
343
      <div id="ocd-hud">
344
        <span id="ocd-total-results"></span>
345
      </div>
346
      <div id="ocd-results"></div>
347
      <ul class="pager">
348
        <li class="previous"> <a href="#">&laquo; Previous </a></li>
349
        <li class="next"> <a href="#"> Next &raquo; </a></li>
350
      </ul>
351
    </script>
352
    <script type="text/template" id="ocd-item-template">
353
      <div class="col-sm-6 col-md-4 ocd-item">
354
        <h4> <%= title %> </h4>
355
        <div class="media">
356
          <a href="<%= media_url %>">
357
            <img src="" class="responsive thumb-image">
358
          </a>
359
        </div>
360
        <div class="text">Authors: <%= authors %> </div>
361
        <div class="text">Description: <%= description %> </div>
362
      </div>
363
    </script>
364
    <script type="text/template" id="ocd-item-cover-template">
365
      <div class="ocd-item-cover">
366
        Mark and load this image to annotate
367
        <button class="btn btn-xs btn-default pull-left ocd-item-mark">Mark</button>
368
        <a class="close">&times;</a>
369
        <div class="clearfix"></div>
370
      </div>
371
    </script>
372
    <script type="text/template" id="filter-users">
373
      <ul>
374
        <label>
375
          <input type="checkbox" name="<%= who %>" checked="checked">
376
          <%= who %>
377
        </label>
378
      </ul>
379
    </script>
380
    <script type="text/template" id="filter-tags">
381
      <ul>
382
        <input type="checkbox" checked="checked" name=<%= tag %>>
383
        <label><%= tag %></label>
384
      </ul>
385
    </script>
386
    <script type="text/template" id="gallery-item-template">
387
      <div class="col-md-4 col-sm-6 ocd-item">
388
        <div class="media">
389
          <img src="<%= how.src %>" class="responsive thumb-image">
390
        </div>
391
        <div class="text">Author: <%= who %> </div>
392
        <div class="text">Tags: <%= how.tags %> </div>
393
      </div>
394
    </script>
395
    <script type="text/template" id="linked-data-list-template">
396
      <li class="list-group-item">
397
        <span class="badge"> <%= weight %> </span>
398
        <p><%= who %></p>
399
      </li>
400
    </script>
401
  </body>
402
</html>