Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
T
trs
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Taddeüs Kroes
trs
Commits
a679aff9
Commit
a679aff9
authored
Nov 19, 2012
by
Taddeüs Kroes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Applied Twitter Bootstrap layout
parent
a1b82033
Changes
8
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
294 additions
and
242 deletions
+294
-242
src/frontend/css/editor.css
src/frontend/css/editor.css
+42
-124
src/frontend/js/editor.js
src/frontend/js/editor.js
+189
-100
src/frontend/tpl/editor.html
src/frontend/tpl/editor.html
+48
-18
static/bootstrap/css/bootstrap.min.css
static/bootstrap/css/bootstrap.min.css
+9
-0
static/bootstrap/img/glyphicons-halflings-white.png
static/bootstrap/img/glyphicons-halflings-white.png
+0
-0
static/bootstrap/img/glyphicons-halflings.png
static/bootstrap/img/glyphicons-halflings.png
+0
-0
static/bootstrap/js/bootstrap.min.js
static/bootstrap/js/bootstrap.min.js
+6
-0
static/img/load.gif
static/img/load.gif
+0
-0
No files found.
src/frontend/css/editor.css
View file @
a679aff9
html
{
background-color
:
#ccddef
;
margin
:
0
;
padding
:
0
;
}
body
{
margin
:
0
;
padding
:
20px
;
font
:
16px
/
24px
Verdana
,
Arial
,
sans
;
padding-top
:
40px
;
background-color
:
#f9f9f9
;
}
#loader
{
background
:
url(/static/img/load.gif)
no-repeat
scroll
0
0
transparent
;
height
:
31px
;
width
:
31px
;
.alert
{
display
:
none
;
position
:
absolute
;
margin-top
:
-5px
;
margin-left
:
16px
;
}
.panel
{
background-color
:
#fff
;
border
:
3px
solid
#bbb
;
cursor
:
text
;
min-height
:
400px
;
padding-bottom
:
10px
;
position
:
absolute
;
top
:
58px
;
width
:
47%
;
}
#error
{
/*display: none;*/
font-size
:
12px
;
clear
:
both
;
margin-top
:
20px
;
position
:
absolute
;
margin
:
10px
0
0
;
}
#input
{
float
:
left
;
left
:
2%
;
}
#input
textarea
{
width
:
100%
;
border
:
0
;
margin
:
0
;
padding
:
0
;
height
:
388px
;
overflow-y
:
visible
;
font
:
16px
/
24px
Verdana
,
Arial
,
sans
;
outline
:
0
;
}
.box
{
padding
:
10px
15px
0
15px
;
}
#math
{
float
:
right
;
right
:
2%
;
.alert
strong
{
margin-right
:
8px
;
}
#math
.box
{
padding
:
10px
15px
0
40px
;
background
:
no-repeat
scroll
15px
13px
transparent
;
.math-input
{
width
:
436px
!important
;
min-height
:
314px
;
padding
:
7px
11px
;
line-height
:
26px
;
overflow
:
hidden
;
}
#math
.box.correct
{
background-image
:
url(/static/img/tick.png)
;
}
#math
.box.wrong
{
background-image
:
url(/static/img/cross.png)
;
}
#math
.box.no-progress
{
background-image
:
url(/static/img/error.png)
;
}
#math
.hint
{
padding
:
10px
15px
0
40px
;
background
:
url(/static/img/info.png)
no-repeat
scroll
15px
13px
transparent
;
color
:
#666
;
font-size
:
14px
;
line-height
:
20px
;
.pretty-print
{
background-color
:
#fff
;
border-color
:
#ccc
;
min-height
:
300px
;
padding
:
14px
19px
;
}
#math
.hint
.MathJax
{
color
:
#000
;
.box
,
.hint
{
position
:
relative
;
margin
:
5px
0
;
padding-left
:
20px
;
}
#control-buttons
{
height
:
21px
;
left
:
2%
;
line-height
:
0
;
margin-bottom
:
16px
;
.label
,
.icon
{
position
:
absolute
;
vertical-align
:
top
;
top
:
50%
;
}
.separator
{
border-right
:
1px
solid
#999
;
display
:
inline-block
;
width
:
0
;
height
:
21px
;
margin
:
1px
5px
;
vertical-align
:
top
;
.label
{
margin-top
:
-9px
;
left
:
-8px
;
}
.panel
.label
{
background-color
:
#fff
;
border
:
1px
solid
#ccc
;
clear
:
both
;
float
:
left
;
font-size
:
10px
;
line-height
:
14px
;
margin-left
:
4px
;
margin-top
:
-12px
;
padding
:
2px
;
.icon
{
margin-top
:
-8px
;
left
:
0
;
}
/* Codemirror should not resize the input area. */
/*
.CodeMirror-scroll {
height: auto;
overflow: visible;
.current-line
{
border-right
:
3px
solid
#ddd
;
}
.
CodeMirror-line
s {
padding: 0 !important
;
.
credit
s
{
text-align
:
center
;
}
*/
#
credits
{
clear
both
;
left
:
0
;
right
:
0
;
b
ottom
:
0
;
position
:
fixed
;
font-size
:
10
px
;
color
:
#666
;
text-align
:
center
;
#
loader
{
display
:
inline-block
;
visibility
:
hidden
;
position
:
relative
;
b
ackground
:
url(/static/img/load.gif)
no-repeat
;
height
:
16px
;
width
:
16
px
;
top
:
8px
;
margin-left
:
10px
;
}
src/frontend/js/editor.js
View file @
a679aff9
This diff is collapsed.
Click to expand it.
src/frontend/tpl/editor.html
View file @
a679aff9
...
...
@@ -3,33 +3,63 @@
<head>
<meta
http-equiv=
"content-type"
content=
"text/html; charset=utf-8"
>
<title>
Mathematical term rewriting frontend
</title>
<script
type=
"text/javascript"
src=
"/static/js/jquery-1.8.2.min.js"
></script>
<script
type=
"text/javascript"
src=
"/static/external/mathjax/MathJax.js?config=AM_HTMLorMML-full"
></script>
<link
rel=
"stylesheet"
href=
"/static/bootstrap/css/bootstrap.min.css"
>
<link
rel=
"stylesheet"
href=
"/static/frontend/css/editor.css"
>
</head>
<body>
<div
id=
"control-buttons"
><button
onclick=
window.clear_input()
>
clear
</button><div
class=
"separator"
></div><button
onclick=
window.validate_input()
>
validate
</button><button
onclick=
window.hint_input()
>
hint
</button><button
onclick=
window.step_input()
>
step
</button><button
onclick=
window.answer_input()
>
answer
</button><div
id=
"loader"
></div></div>
<div
class=
"navbar navbar-inverse navbar-fixed-top"
>
<div
class=
"navbar-inner"
>
<div
class=
"container"
>
<a
class=
"brand"
href=
""
>
Mathematical Term Rewriting
</a>
<ul
class=
"nav"
>
<li
class=
"active"
><a
href=
"index.html"
>
Editor
</a></li>
<li><a
href=
"tutorial.html"
>
Tutorial
</a></li>
</ul>
</div>
</div>
</div>
<div
id=
"error"
></div>
<div
class=
"container"
>
<div
id=
"error"
class=
"alert alert-error"
>
<button
type=
"button"
class=
"close"
>
×
</button>
<strong>
Error
</strong>
<span
class=
"text"
></span>
</div>
<div
id=
"input"
class=
"panel"
>
<div
class=
"label"
>
Input view
</div>
<div
class=
"box"
>
<textarea
id=
"MathInput"
></textarea>
<div
class=
"row"
>
<div
class=
"span12"
>
<div
class=
"btn-toolbar"
>
<button
id=
"btn-clear"
class=
"btn"
>
clear
</button>
<div
class=
"btn-group"
>
<button
id=
"btn-validate"
class=
"btn btn-info"
>
validate
</button>
<button
id=
"btn-hint"
class=
"btn btn-info"
>
hint
</button>
<button
id=
"btn-step"
class=
"btn btn-info"
>
step
</button>
</div>
<button
id=
"btn-answer"
class=
"btn"
>
answer
</button>
<div
id=
"loader"
></div>
</div>
</div>
</div>
</div>
<div
id=
"math"
class=
"panel"
>
<div
class=
"label"
>
Math view
</div>
</div>
<div
class=
"row"
>
<div
class=
"span6"
>
<textarea
id=
"math-input"
class=
"span6 math-input"
></textarea>
</div>
<div
class=
"span6"
>
<div
id=
"pretty-print"
class=
"well pretty-print"
></div>
</div>
</div>
<div
id=
"credits"
>
Idea and feedback by
<a
href=
"http://homepages.cwi.nl/~apt/"
target=
_window
>
Prof.dr.
K.R. Apt
</a>
, implementation by Taddeüs Kroes and
<a
href=
"http://smvv.kompiler.org"
target=
_window
>
Sander van
Veen
</a>
.
</div>
<div
class=
"row"
>
<div
class=
"span12 credits"
>
Idea and feedback by
<a
href=
"http://homepages.cwi.nl/~apt/"
target=
"_blank"
>
Prof.dr. K.R. Apt
</a>
,
implementation by Taddeüs Kroes and
<a
href=
"http://smvv.kompiler.org"
target=
"_blank"
>
Sander van Veen
</a>
.
</div>
</div>
</div>
<script
type=
"text/javascript"
src=
"/static/js/jquery-1.8.2.min.js"
></script>
<script
type=
"text/javascript"
src=
"/static/bootstrap/js/bootstrap.min.js"
></script>
<script
type=
"text/javascript"
src=
"/static/external/mathjax/MathJax.js?config=AM_HTMLorMML-full"
></script>
<script
type=
"text/javascript"
src=
"/static/frontend/js/editor.js"
></script>
</body>
</html>
static/bootstrap/css/bootstrap.min.css
0 → 100644
View file @
a679aff9
This diff is collapsed.
Click to expand it.
static/bootstrap/img/glyphicons-halflings-white.png
0 → 100644
View file @
a679aff9
8.57 KB
static/bootstrap/img/glyphicons-halflings.png
0 → 100644
View file @
a679aff9
12.5 KB
static/bootstrap/js/bootstrap.min.js
0 → 100644
View file @
a679aff9
This diff is collapsed.
Click to expand it.
static/img/load.gif
View replaced file @
a1b82033
View file @
a679aff9
2.55 KB
|
W:
|
H:
1.7 KB
|
W:
|
H:
2-up
Swipe
Onion skin
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment