Skip to content

Commit e4fc062

Browse files
committed
1 parent 5357609 commit e4fc062

File tree

3 files changed

+236
-0
lines changed

3 files changed

+236
-0
lines changed

demo/assets/css/prism.css

Lines changed: 226 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,226 @@
1+
/* PrismJS 1.20.0
2+
https://prismjs.com/download.html#themes=prism-tomorrow&languages=markup+css+clike+javascript+scss&plugins=line-highlight+line-numbers */
3+
/**
4+
* prism.js tomorrow night eighties for JavaScript, CoffeeScript, CSS and HTML
5+
* Based on https://github.com/chriskempson/tomorrow-theme
6+
* @author Rose Pritchard
7+
*/
8+
9+
code[class*="language-"],
10+
pre[class*="language-"] {
11+
color: #ccc;
12+
background: none;
13+
font-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace;
14+
font-size: 1em;
15+
text-align: left;
16+
white-space: pre;
17+
word-spacing: normal;
18+
word-break: normal;
19+
word-wrap: normal;
20+
line-height: 1.5;
21+
22+
-moz-tab-size: 4;
23+
-o-tab-size: 4;
24+
tab-size: 4;
25+
26+
-webkit-hyphens: none;
27+
-moz-hyphens: none;
28+
-ms-hyphens: none;
29+
hyphens: none;
30+
31+
}
32+
33+
/* Code blocks */
34+
pre[class*="language-"] {
35+
padding: 1em;
36+
margin: .5em 0;
37+
overflow: auto;
38+
}
39+
40+
:not(pre) > code[class*="language-"],
41+
pre[class*="language-"] {
42+
background: #2d2d2d;
43+
}
44+
45+
/* Inline code */
46+
:not(pre) > code[class*="language-"] {
47+
padding: .1em;
48+
border-radius: .3em;
49+
white-space: normal;
50+
}
51+
52+
.token.comment,
53+
.token.block-comment,
54+
.token.prolog,
55+
.token.doctype,
56+
.token.cdata {
57+
color: #999;
58+
}
59+
60+
.token.punctuation {
61+
color: #ccc;
62+
}
63+
64+
.token.tag,
65+
.token.attr-name,
66+
.token.namespace,
67+
.token.deleted {
68+
color: #e2777a;
69+
}
70+
71+
.token.function-name {
72+
color: #6196cc;
73+
}
74+
75+
.token.boolean,
76+
.token.number,
77+
.token.function {
78+
color: #f08d49;
79+
}
80+
81+
.token.property,
82+
.token.class-name,
83+
.token.constant,
84+
.token.symbol {
85+
color: #f8c555;
86+
}
87+
88+
.token.selector,
89+
.token.important,
90+
.token.atrule,
91+
.token.keyword,
92+
.token.builtin {
93+
color: #cc99cd;
94+
}
95+
96+
.token.string,
97+
.token.char,
98+
.token.attr-value,
99+
.token.regex,
100+
.token.variable {
101+
color: #7ec699;
102+
}
103+
104+
.token.operator,
105+
.token.entity,
106+
.token.url {
107+
color: #67cdcc;
108+
}
109+
110+
.token.important,
111+
.token.bold {
112+
font-weight: bold;
113+
}
114+
.token.italic {
115+
font-style: italic;
116+
}
117+
118+
.token.entity {
119+
cursor: help;
120+
}
121+
122+
.token.inserted {
123+
color: green;
124+
}
125+
126+
pre[data-line] {
127+
position: relative;
128+
padding: 1em 0 1em 3em;
129+
}
130+
131+
.line-highlight {
132+
position: absolute;
133+
left: 0;
134+
right: 0;
135+
padding: inherit 0;
136+
margin-top: 1em; /* Same as .prism’s padding-top */
137+
138+
background: hsla(24, 20%, 50%,.08);
139+
background: linear-gradient(to right, hsla(24, 20%, 50%,.1) 70%, hsla(24, 20%, 50%,0));
140+
141+
pointer-events: none;
142+
143+
line-height: inherit;
144+
white-space: pre;
145+
}
146+
147+
.line-highlight:before,
148+
.line-highlight[data-end]:after {
149+
content: attr(data-start);
150+
position: absolute;
151+
top: .4em;
152+
left: .6em;
153+
min-width: 1em;
154+
padding: 0 .5em;
155+
background-color: hsla(24, 20%, 50%,.4);
156+
color: hsl(24, 20%, 95%);
157+
font: bold 65%/1.5 sans-serif;
158+
text-align: center;
159+
vertical-align: .3em;
160+
border-radius: 999px;
161+
text-shadow: none;
162+
box-shadow: 0 1px white;
163+
}
164+
165+
.line-highlight[data-end]:after {
166+
content: attr(data-end);
167+
top: auto;
168+
bottom: .4em;
169+
}
170+
171+
.line-numbers .line-highlight:before,
172+
.line-numbers .line-highlight:after {
173+
content: none;
174+
}
175+
176+
pre[id].linkable-line-numbers span.line-numbers-rows {
177+
pointer-events: all;
178+
}
179+
pre[id].linkable-line-numbers span.line-numbers-rows > span:before {
180+
cursor: pointer;
181+
}
182+
pre[id].linkable-line-numbers span.line-numbers-rows > span:hover:before {
183+
background-color: rgba(128, 128, 128, .2);
184+
}
185+
186+
pre[class*="language-"].line-numbers {
187+
position: relative;
188+
padding-left: 3.8em;
189+
counter-reset: linenumber;
190+
}
191+
192+
pre[class*="language-"].line-numbers > code {
193+
position: relative;
194+
white-space: inherit;
195+
}
196+
197+
.line-numbers .line-numbers-rows {
198+
position: absolute;
199+
pointer-events: none;
200+
top: 0;
201+
font-size: 100%;
202+
left: -3.8em;
203+
width: 3em; /* works for line-numbers below 1000 lines */
204+
letter-spacing: -1px;
205+
border-right: 1px solid #999;
206+
207+
-webkit-user-select: none;
208+
-moz-user-select: none;
209+
-ms-user-select: none;
210+
user-select: none;
211+
212+
}
213+
214+
.line-numbers-rows > span {
215+
display: block;
216+
counter-increment: linenumber;
217+
}
218+
219+
.line-numbers-rows > span:before {
220+
content: counter(linenumber);
221+
color: #999;
222+
display: block;
223+
padding-right: 0.8em;
224+
text-align: right;
225+
}
226+

demo/assets/img/navbar.png

137 KB
Loading

0 commit comments

Comments
 (0)