aboutsummaryrefslogtreecommitdiff
path: root/imports/codemirror/mode/less
diff options
context:
space:
mode:
authorJon Reid2012-03-06 18:08:37 -0800
committerJon Reid2012-03-06 18:08:37 -0800
commit6056fdb63b5f4690115e63ee50e8d7dac309ba64 (patch)
tree5fbe386e4c7732fb84b98c9539b186898f076c7b /imports/codemirror/mode/less
parentbcfb704b04587f95a13c474cf0598ba90ec3b371 (diff)
parenta12603cfcfe9d82def3b972dcbcc80f1e790ad85 (diff)
downloadninja-6056fdb63b5f4690115e63ee50e8d7dac309ba64.tar.gz
Merge branch 'Timeline-uber' into timeline-serialized
Diffstat (limited to 'imports/codemirror/mode/less')
-rw-r--r--imports/codemirror/mode/less/index.html588
-rw-r--r--imports/codemirror/mode/less/less.js189
2 files changed, 777 insertions, 0 deletions
diff --git a/imports/codemirror/mode/less/index.html b/imports/codemirror/mode/less/index.html
new file mode 100644
index 00000000..bd3ef198
--- /dev/null
+++ b/imports/codemirror/mode/less/index.html
@@ -0,0 +1,588 @@
1<!doctype html>
2<html>
3 <head>
4 <title>CodeMirror: LESS mode</title>
5 <link rel="stylesheet" href="../../lib/codemirror.css">
6 <script src="../../lib/codemirror.js"></script>
7 <script src="less.js"></script>
8 <style>.CodeMirror {background: #f8f8f8; border: 1px solid #ddd;}</style>
9 <link rel="stylesheet" href="../../doc/docs.css">
10 <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
11 </head>
12 <body>
13 <h1>CodeMirror: LESS mode</h1>
14 <form><textarea id="code" name="code">
15/* Some LESS code */
16
17video {
18 background-image:url('paper.gif');
19}
20
21.pre_class {
22 width: 500px;
23 height: 250px;
24 background-image: url(sheep.png), url(betweengrassandsky.png);
25 background-position: center bottom, left top;
26 background-repeat: no-repeat;
27}
28
29@color: #4D926F;
30
31#header {
32 color: @color;
33 color: #000000;
34}
35h2 {
36 color: @color;
37}
38
39.rounded-corners (@radius: 5px) {
40 border-radius: @radius;
41 -webkit-border-radius: @radius;
42 -moz-border-radius: @radius;
43}
44
45#header {
46 .rounded-corners;
47}
48#footer {
49 .rounded-corners(10px);
50}
51
52.box-shadow (@x: 0, @y: 0, @blur: 1px, @alpha) {
53 @val: @x @y @blur rgba(0, 0, 0, @alpha);
54
55 box-shadow: @val;
56 -webkit-box-shadow: @val;
57 -moz-box-shadow: @val;
58}
59.box { @base: #f938ab;
60 color: saturate(@base, 5%);
61 border-color: lighten(@base, 30%);
62 div { .box-shadow(0, 0, 5px, 0.4) }
63}
64
65@import url("something.css");
66
67@light-blue: hsl(190, 50%, 65%);
68@light-yellow: desaturate(#fefec8, 10%);
69@dark-yellow: desaturate(darken(@light-yellow, 10%), 40%);
70@darkest: hsl(20, 0%, 15%);
71@dark: hsl(190, 20%, 30%);
72@medium: hsl(10, 60%, 30%);
73@light: hsl(90, 40%, 20%);
74@lightest: hsl(90, 20%, 90%);
75@highlight: hsl(80, 50%, 90%);
76@blue: hsl(210, 60%, 20%);
77@alpha-blue: hsla(210, 60%, 40%, 0.5);
78
79.box-shadow (@x, @y, @blur, @alpha) {
80 @value: @x @y @blur rgba(0, 0, 0, @alpha);
81 box-shadow: @value;
82 -moz-box-shadow: @value;
83 -webkit-box-shadow: @value;
84}
85.border-radius (@radius) {
86 border-radius: @radius;
87 -moz-border-radius: @radius;
88 -webkit-border-radius: @radius;
89}
90
91.border-radius (@radius, bottom) {
92 border-top-right-radius: 0;
93 border-top-left-radius: 0;
94 -moz-border-top-right-radius: 0;
95 -moz-border-top-left-radius: 0;
96 -webkit-border-top-left-radius: 0;
97 -webkit-border-top-right-radius: 0;
98}
99.border-radius (@radius, right) {
100 border-bottom-left-radius: 0;
101 border-top-left-radius: 0;
102 -moz-border-bottom-left-radius: 0;
103 -moz-border-top-left-radius: 0;
104 -webkit-border-bottom-left-radius: 0;
105 -webkit-border-top-left-radius: 0;
106}
107.box-shadow-inset (@x, @y, @blur, @color) {
108 box-shadow: @x @y @blur @color inset;
109 -moz-box-shadow: @x @y @blur @color inset;
110 -webkit-box-shadow: @x @y @blur @color inset;
111}
112.code () {
113 font-family: 'Bitstream Vera Sans Mono',
114 'DejaVu Sans Mono',
115 'Monaco',
116 Courier,
117 monospace !important;
118}
119.wrap () {
120 text-wrap: wrap;
121 white-space: pre-wrap; /* css-3 */
122 white-space: -moz-pre-wrap; /* Mozilla, since 1999 */
123 white-space: -pre-wrap; /* Opera 4-6 */
124 white-space: -o-pre-wrap; /* Opera 7 */
125 word-wrap: break-word; /* Internet Explorer 5.5+ */
126}
127
128html { margin: 0 }
129body {
130 background-color: @darkest;
131 margin: 0 auto;
132 font-family: Arial, sans-serif;
133 font-size: 100%;
134 overflow-x: hidden;
135}
136nav, header, footer, section, article {
137 display: block;
138}
139a {
140 color: #b83000;
141}
142h1 a {
143 color: black;
144 text-decoration: none;
145}
146a:hover {
147 text-decoration: underline;
148}
149h1, h2, h3, h4 {
150 margin: 0;
151 font-weight: normal;
152}
153ul, li {
154 list-style-type: none;
155}
156code { .code; }
157code {
158 .string, .regexp { color: @dark }
159 .keyword { font-weight: bold }
160 .comment { color: rgba(0, 0, 0, 0.5) }
161 .number { color: @blue }
162 .class, .special { color: rgba(0, 50, 100, 0.8) }
163}
164pre {
165 padding: 0 30px;
166 .wrap;
167}
168blockquote {
169 font-style: italic;
170}
171body > footer {
172 text-align: left;
173 margin-left: 10px;
174 font-style: italic;
175 font-size: 18px;
176 color: #888;
177}
178
179#logo {
180 margin-top: 30px;
181 margin-bottom: 30px;
182 display: block;
183 width: 199px;
184 height: 81px;
185 background: url(/images/logo.png) no-repeat;
186}
187nav {
188 margin-left: 15px;
189}
190nav a, #dropdown li {
191 display: inline-block;
192 color: white;
193 line-height: 42px;
194 margin: 0;
195 padding: 0px 15px;
196 text-shadow: -1px -1px 1px rgba(0, 0, 0, 0.5);
197 text-decoration: none;
198 border: 2px solid transparent;
199 border-width: 0 2px;
200 &:hover {
201 .dark-red;
202 text-decoration: none;
203 }
204}
205.dark-red {
206 @red: @medium;
207 border: 2px solid darken(@red, 25%);
208 border-left-color: darken(@red, 15%);
209 border-right-color: darken(@red, 15%);
210 border-bottom: 0;
211 border-top: 0;
212 background-color: darken(@red, 10%);
213}
214
215.content {
216 margin: 0 auto;
217 width: 980px;
218}
219
220#menu {
221 position: absolute;
222 width: 100%;
223 z-index: 3;
224 clear: both;
225 display: block;
226 background-color: @blue;
227 height: 42px;
228 border-top: 2px solid lighten(@alpha-blue, 20%);
229 border-bottom: 2px solid darken(@alpha-blue, 25%);
230 .box-shadow(0, 1px, 8px, 0.6);
231 -moz-box-shadow: 0 0 0 #000; // Because firefox sucks.
232
233 &.docked {
234 background-color: hsla(210, 60%, 40%, 0.4);
235