-
Notifications
You must be signed in to change notification settings - Fork 16
/
index.html
247 lines (224 loc) · 9.67 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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>blockd3</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="a visual editor for d3">
<meta name="author" content="nicholas bollweg">
<link rel="shortcut icon" href="./favicon.ico" />
{% if env == "dev" %}
{% for style in styles %}
<link rel="stylesheet" href="./{{ style }}">
{% endfor %}
{% else %}
<link rel="stylesheet" href="./css/blockd3-min.css">
{% endif %}
<link rel="stylesheet" id="theme_link">
<link rel="stylesheet" id="code_theme_link">
<!-- Le HTML5 shim, for IE6-8 support of HTML5 elements -->
<!--[if lt IE 9]>
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
</head>
<body id="editor">
<div id="navbar" class="navbar navbar-fixed-top">
<div class="navbar-inner">
<div class="container">
<a class="brand" href="#">
<img id="logo" src="./svg/logo.svg"/>
<span class="hidden-phone">blockd3</span>
</a>
<div>
<div id="actions" class="nav">
<a id="run" class="btn btn-success" href="#run">
<i class="icon-bolt"></i>
<span class="hidden-phone">Run</span>
</a>
<a id="stop" class="btn btn-danger" href="#stop">
<i class="icon-off"></i>
<span class="hidden-phone">Stop</span>
</a>
<div class="btn-group">
<a class="btn dropdown-toggle btn-primary" data-toggle="dropdown" href="#">
<i class="icon-hdd"></i>
<span class="hidden-phone">Save</span>
</a>
<ul class="dropdown-menu">
<li><a id="save_xml" href="#">To XML File</a></li>
</ul>
</div>
<div class="btn-group">
<a class="btn dropdown-toggle btn-info" data-toggle="dropdown" href="#" id="load_menu">
<i class="icon-folder-open"></i>
<span class="hidden-phone">Load</span>
</a>
<ul class="dropdown-menu">
<li><a id="load_xml" href="#">From XML File</a></li>
<li class="nav-header">Examples</li>
{% for example_name, example in examples %}
<li>
<a href="#example" data-blockd3-example="{{ example }}">{{ example_name }}
</a>
</li>
{% endfor %}
</ul>
<form id="file_form">
<input type="file" id="load"/>
</form>
</div>
<a id="show_alerts" class="btn btn-warning" href="#alerts">
<i class="icon-exclamation-sign"></i>
<span class="hidden-phone">Alerts</span>
</a>
<a id="discard" href="#discard" class="btn btn-danger">
<i class="icon-trash"></i>
<span class="hidden-phone">Discard</span>
</a>
<div class="btn-group">
<a class="btn dropdown-toggle btn-inverse" data-toggle="dropdown" href="#themes">
<i class="icon-wrench"></i>
<span class="hidden-phone">Options</span>
</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu" id="change_theme">
<a tabindex="-1" href="#">UI Themes</a>
<ul class="dropdown-menu">
<li class="active">
<a href="#theme" data-blockd3-theme="">
<i>Default</i>
</a>
</li>
{% for theme_name, theme in themes %}
<li>
<a href="#theme" data-blockd3-theme="{{ theme }}">{{ theme_name }}</a>
</li>
{% endfor %}
</ul>
</li>
<li class="dropdown-submenu" id="change_code_theme">
<a tabindex="-1" href="#">Code Themes</a>
<ul class="dropdown-menu">
<li class="active">
<a href="#code_theme" data-blockd3-theme="defult">
<i>Default</i>
</a>
</li>
{% for theme_name, theme in code_themes %}
<li>
<a href="#theme" data-blockd3-code-theme="{{ theme }}">{{ theme_name }}</a>
</li>
{% endfor %}
</ul>
</li>
</ul>
</div>
</div>
<div class="nav pull-right">
<a id="show_about" href="#about" role="button" class="btn" data-toggle="modal">
<i class="icon-heart"></i>
<span class="hidden-phone">About</span>
</a>
</div>
</div><!--/.nav-collapse -->
</div>
</div>
</div>
<div id="about" class="modal hide fade">
<div class="modal-header inverse">
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
<h3>About blockd3</h3>
</div>
<div class="modal-body">
<dl>
<dt><i class="icon-beaker"></i> Contributors</dt>
<dd>
<ul>
<li><a href="//github.com/bollwyvl" target="_blank" >bollwyvl</a></li>
<li><a href="//github.com/qneutron" target="_blank" >qneutron</a></li>
</ul>
</dd>
<dt><i class="icon-cogs"></i> Automated Testing</dt>
<dd><a href="//travis-ci.org">Travis-CI</a> <a class="nav" target="_blank" href="//travis-ci.org/bollwyvl/blockd3">
<img id="travis_placeholder" src=""/>
</a></dd>
<dt><i class="icon-github-sign"></i> Repository & Hosting</dt>
<dd>
<a class="nav" target="_blank" href="//github.com/bollwyvl/blockd3">
GitHub
</a>
</dd>
<dt><i class="icon-bullhorn"></i> Built With</dt>
<dd>
<ul>
<li><a href="//code.google.com/p/blockly">Blockly</a></li>
<li><a href="http://d3js.org">d3</a></li>
<li><a href="//github.com/bollwyvl/blockd3">b4</a></li>
<li><a href="//github.com/twitter/bootstrap">bootstrap</a></li>
<li>
<a href="//github.com/marijnh/CodeMirror">CodeMirror</a>
</li>
<li>
<a class="nav" href="//bootswatch.com/">Bootswatch</a>
</li>
</dd>
<dt><i class=" icon-legal"></i> LEGAL</dt>
<dd>blockd3 is Free Software licensed under the
<a href="//www.apache.org/licenses/LICENSE-2.0.html">
Apache Public License 2.0
</a>
</dd>
</div>
<div class="modal-footer">
<a href="#" class="btn" data-dismiss="modal">Back to blockd3</a>
</div>
</div>
<div id="container" class="container-fluid" style="display:none;">
<!-- Example row of columns -->
<div id="panes" class="row-fluid">
<div id="content_blockly" class="span7 pane full_height">
<a name="blockly"></a>
<h2>Blockly</h2>
</div>
<div id="content_d3" class="span5 well">
<a name="d3"></a>
<h2>SVG</h2>
</div>
<div id="content_javascript" class="span5 pane half_height well">
<h2>JavaScript</h2>
<textarea id="textarea_javascript"></textarea>
</div>
<div id="content_xml">
<a name="xml"></a>
<textarea id="textarea_xml"></textarea>
</div>
</div>
<div id="alert" class="alert">
<button type="button" class="close">×</button>
<h3>Alert History</h3>
<ul></ul>
</div>
<div id="discard_confirm" class="modal hide fade">
<div class="modal-header">
<a href="#" class="close" data-dismiss="modal" aria-hidden="true">×</a>
<h3>Confirm Discard</h3>
</div>
<div class="modal-body">
<p>You are about to delete <span class="block_count">one block</span>.</p>
<p>Do you want to proceed?</p>
</div>
<div class="modal-footer">
<a href="#" data-dismiss="modal" class="btn btn-danger">Yes</a>
<a href="#" data-dismiss="modal" aria-hidden="true" class="btn btn-secondary">No</a>
</div>
</div>
</div> <!-- /container -->
{% if env == "dev" %}
{% for script in scripts %}
<script type="text/javascript" src="./{{ script }}"></script>
{% endfor %}
{% else %}
<script type="text/javascript" src="./js/blockd3-min.js"></script>
{% endif %}
</body>
</html>