-
Notifications
You must be signed in to change notification settings - Fork 1
/
index.html
250 lines (210 loc) · 13.7 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
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
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
<!DOCTYPE html>
<html lang="en" ng-app="generatorApp">
<head>
<meta charset="UTF-8">
<link rel="stylesheet" href="app.css">
<link rel="stylesheet" href="lib/bootstrap.css">
<link rel="stylesheet" href="lib/angular-material.min.css">
<link rel="stylesheet" href="lib/font-awesome/css/all.css">
<link href="lib/hopscotch_tour/css/hopscotch.css" rel="stylesheet">
<title> JSON schema document generator</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="shortcut icon" href="https://fairsharing.org/static/img/fairsharing-favicon.ico">
</head>
<body ng-controller="documenterController as documenter" class="json_documenter" md-theme="altTheme">
<div class="main" id ="mainContainer">
<!-- ERRORS -->
<div class="container mainPage error" ng-show="documenter.errors.length>0 ">
<h2> There is one or more errors with your request </h2>
<div ng-repeat="items in documenter.errors">
<div ng-if="(items | typeOf) === 'object'">
<div ng-repeat="(itemKey, itemVal) in items">
<label class="descriptionLabel">{{itemKey}}: </label> {{itemVal}}
</div>
</div>
<div ng-if="(item | typeOf) === 'array'">
{{item}}
<div ng-repeat="item in items">
<div ng-repeat="(itemKey, itemVal) in item">
<label class="descriptionLabel">{{itemKey}}: </label> {{itemVal}}
</div>
</div>
</div>
</div>
</div>
<!-- MENU -->
<div id="pageTop" class="container menuBar">
<div class="row">
<md-toolbar class="md-menu-toolbar">
<div layout="row" id="settingMenu">
<md-toolbar-filler layout="" layout-align="center center">
<i class="fas fa-cog" ng-click="documenter.display_menu()" id="settingButton"></i>
</md-toolbar-filler>
<div class="settings" id="settings">
<div class="menuCard">
<div class="cardheader">Set your settings</div>
<div class="cardbody">
<md-content>
<form name="setSettings">
<md-input-container class="md-block">
<label>Schema URL</label>
<input required=""
name="next_target"
ng-model="documenter.next_target"
ng-value="documenter.target">
<div ng-messages="setSettings.next_target.$error" role="alert">
<div ng-message-exp="['required']">
You must enter a file URI (URL or local path)
</div>
</div>
</md-input-container>
<md-input-container class="md-block">
<label>Mapping URL for context files</label>
<input name="mapping_target"
ng-model="documenter.next_mapping"
ng-value="documenter.mapping_target">
</md-input-container>
</form>
<button class="reloadButton" ng-click="documenter.reload()"> Reload with new parameters</button>
</md-content>
</div>
</div>
</div>
<div style="display:block;width:100%">
<div class="container-fluid">
<div class="row">
<h2 class="col-10 md-toolbar-tools">JSON-Schema documenter </h2>
<div class="col-2 legend">
<i id='legend' class="fas fa-comment"
data-toggle="tooltip"
data-placement="bottom"
data-html="true"
title="
<div class='legend'>
<label>Legend</label>
<div>
<div class='legend_item'>
<div class='legend_color greenLeg'></div> <span> This field is required </span>
</div>
<div class='legend_item'>
<div class='legend_color blueLeg'></div> <span> This field is not required </span>
</div>
</div>
</div>
"
field-name=null
tooltip>
</i>
</div>
</div>
</div>
<div class="container-fluid" style="background-color: white;">
<div class="row">
<!-- menu button -->
<div class="col-10">
<md-menu-bar>
<md-menu>
<button aria-label="Open menu" ng-show="documenter.loaded"
ng-click="$mdMenu.open($event)" id="schemaMenu">
<span class="fas fa-chevron-down" style="margin-right:10px"></span>
{{documenter.raw_schemas[documenter.main_schema].title}}
<md-tooltip style="padding:10px">
Click to display dependency schemas
</md-tooltip>
</button>
<md-menu-content width="4">
<div class="container">
<div class="row">
<div class="col-6 menuItem"
ng-repeat="(specName, spec) in documenter.loaded_specs track by $index">
<a ng-href="#{{specName|removeExtraStr}}"
target="_self"
class="menuItemLink">
{{spec.title}}
</a>
</div>
</div>
</div>
</md-menu-content>
</md-menu>
</md-menu-bar>
</div>
<!-- take tour button -->
<div class="col-2" ng-if="documenter.trigger_tour">
<button class="takeTour" onclick="hopscotch.startTour(tour);">Take a tour</button>
</div>
</div>
</div>
</div>
</div>
</md-toolbar>
</div>
</div>
<!-- Loader -->
<div class="container" ng-show="!documenter.loaded">
<div class="row">
<div class="col-12 loader">
<div class="main_container">Loading ... !</div>
</div>
</div>
</div>
<!-- SCHEMAS -->
<div class="container mainPage" ng-show="documenter.loaded" id="schemas">
<div class="row mainPage">
<div ng-repeat="(key, item) in documenter.loaded_specs"
class="col-lg-12 col-sm-12 col-md-12 schema"
schema-loader="documenter.loaded_specs[key]"
schema-name="key"
container="documenter">
</div>
</div>
</div>
<!-- footer -->
<div id="footer" class="container menuBar" ng-show="documenter.loaded">
<div class="row">
<md-toolbar class="md-menu-toolbar">
<div layout="row">
<md-toolbar-filler layout="" layout-align="center center"> </md-toolbar-filler>
<div style="display:block;width:100%">
<h2 class="md-toolbar-tools">
<p>This web application is licensed under <a target="_blank" href="https://github.com/FAIRsharing/json_documenter/blob/master/LICENSE"> BSD-3.</a> The source code is available in <a href="https://github.com/fairsharing/jsonschema-documenter">GitHub</a>.<BR>
Developed and maintained by <a href="mailto:[email protected]">Batista Dominique</a> and <a href="https://github.com/agbeltran">Alejandra Gonzalez-Beltran</a> for the <a href="https://fairsharing.org">FAIRsharing</a> team, Oxford e-Research Centre, Engineering Science, University of Oxford.</p>
</h2>
<md-menu-bar>
<div class="container">
<div class="row">
<a href="https://fairsharing.org/" target="_blank" class="col-lg-4 col-md-4 col-sm-12">
<img id="fairSharing" src="assets/FAIRsharing.svg" />
</a>
<a href="https://www.oerc.ox.ac.uk/" target="_blank" class="col-lg-2 col-md-2 col-sm-5">
<img id="oerc" src="assets/oerc.jpg" />
</a>
<a href="https://www.ox.ac.uk/" target="_blank" class="col-lg-2 col-md-2 col-sm-5">
<img id="uni" src="assets/university_of_oxford.png"/>
</a>
</div>
</div>
</md-menu-bar>
</div>
</div>
</md-toolbar>
</div>
</div>
<!-- back to top arrow -->
<a id="backToTop" ng-show="documenter.loaded" href="#pageTop" target="_self" class="backUp fas fa-arrow-up">
</a>
</div>
<script type="text/javascript" src="lib/jquery.min.js"></script>
<script type="text/javascript" src="lib/bootstrap.min.js"></script>
<script type="text/javascript" src="lib/angular.js"></script>
<script type="text/javascript" src="lib/angular-material.js"></script>
<script type="text/javascript" src="lib/angular-aria.min.js"></script>
<script type="text/javascript" src="lib/angular-animate.min.js"></script>
<script type="text/javascript" src="lib/angular-messages.min.js"></script>
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/angularjs/1.6.7/angular-route.min.js"></script>
<script src="lib/hopscotch_tour/js/hopscotch.js"></script>
<script src="myTour.js"></script>
<script src="myapp.js"></script>
<script type="text/javascript" src="loaderFactory.js"></script>
</body>
</html>