Problem creating guidelines.

This commit is contained in:
Michael Zhang 2016-03-09 22:33:34 -06:00
parent f0799bfbb1
commit 17846f7b17
14 changed files with 3783 additions and 24 deletions

1
Vagrantfile vendored
View file

@ -13,7 +13,6 @@ Vagrant.configure(2) do |config|
config.vm.synced_folder "scripts", "/home/vagrant/scripts"
config.vm.synced_folder "web", "/srv/http/ctf"
config.vm.provision :shell, path: "/vagrant/deploy", run: "always", privileged: false
config.vm.provision :shell, :path => "scripts/setup.sh"
config.ssh.forward_agent = true

View file

@ -27,6 +27,10 @@ server {
try_files /index.html /index.html;
}
location ~ /static {
root /srv/http/static;
}
location ~ /api {
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;

View file

@ -0,0 +1,61 @@
# Problem Format
This survey problem serves as an example for future problems. Each problem must be placed in its own directory, under the directory of its category (for organization). For the name of the folder, please use the ID of the problem (`pid`), which should be the name of the problem represented by lowercase words separated by dashes; don't include problem value. The program will automatically load the problems into the database.
The directory *must* contain a `problem.json`; this information will be loaded into the database. Refer to the following example:
```javascript
{
"pid": "survey", // required
"title": "Survey", // required
"description": "Take our survey.", // required - can use HTML
"hint": "No hint!", // optional - defaults to ""
"category": "Miscellaneous", // required
"autogen": false, // optional - defaults to false
"programming": false, // optional - defaults to false
"value": 20, // required - integer out of 800
"bonus": 0, // optional - defaults to 0; see below for details
"threshold": 0, // recommended - defaults to 0; see below for details
"weightmap": { } // recommended - defaults to {}
}
```
## Bonus Points
Bonus points encourage teams to finish solving a problem first. Rather than an array of three values like last year, we're going to have bonus-point templates. Each of the following integers is a code for a certain "template", and bonus points will be assigned accordingly.
| Code | 3rd | 2nd | 1st |
|------|-----|-----|-----|
| 0 | 0% | 0% | 0% |
| 1 | 1% | 2% | 3% |
| 2 | 1% | 3% | 5% |
| 3 | 3% | 5% | 8% |
| 4 | 6% | 8% | 10% |
| 5 | 8% | 12% | 20% |
The table indicates how many percent bonus a team should receive if they solve a problem first, second, or third. Low problems such as the survey should not yield bonus points; only high-valued points should have bonus points in order to encourage teams t o solve them first.
## Problem Unlocking
Problem unlocking is managed through a mechanism that involves a threshold and weightmap. The weightmap is a dictionary mapping problem IDs to weight. The threshold is the minimum amount needed in order to unlock that particular problem. Take, for example, an abridged version of last year's Launch Code problem's JSON:
```javascript
{
"pid": "launch-code",
"threshold": 5,
"weightmap": {
"php3": 1,
"faster-math": 1,
"biggerisbetter": 1,
"cave-johnson": 1,
"blackmesa": 1,
"rsa3": 1,
"yandere": 1,
"rsi": 1,
"adoughbee": 1,
"infinity_star": 1
}
}
```
That means in order to unlock Launch Code, a team would have to have solved five of the problems listed, since each problem has weight 1. It's also possible to add higher weights to a particular problem to promote solving that problem.

View file

@ -1,6 +1,7 @@
from flask import Blueprint, jsonify
from decorators import admins_only, api_wrapper
from models import db, Problems, Files
from schemas import verify_to_schema, check
import json
@ -23,4 +24,21 @@ def problem_data():
"threshold": problem.threshold,
"weightmap": json.loads(problem.weightmap)
})
return { "success": 1, "problems": problems_return }
return { "success": 1, "problems": problems_return }
"""
@blueprint.route("/problems/submit", methods=["POST"])
@api_wrapper
@admins_only
def problem_submit():
params = utils.flat_multi(request.form)
verify_to_schema(UserSchema, params)
title = params.get("title")
ProblemSubmissionSchema = Schema({
Required("title"): check(
([str, Length(min=4, max=64)], "The title should be between 4 and 64 characters long."),
),
}, extra=True)
"""

View file

@ -20,8 +20,8 @@
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery-timeago/1.4.3/jquery.timeago.min.js" integrity="sha384-Bap3DetwPgo4GEFvaIDVSIrz5G0mUAUsfCUcEsi+JrrNu7dyj3gBmuAG4hDIGg/4" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/smooth-scroll/7.1.1/js/smooth-scroll.min.js" integrity="sha384-bznoxhRX5dRiE60JhQSru8t7g2RPG9lwqvyut8sjFFWmsAlp+R38e7DiATv1YyIu" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery-cookie/1.4.1/jquery.cookie.min.js" integrity="sha384-tSi+YsgNwyohDGfW/VhY51IK3RKAPYDcj1sNXJ16oRAyDP++K0NCzSCUW78EMFmf" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/ckeditor/4.5.4/ckeditor.js" integrity="sha384-N2/iPbB6nrU8RupS9WXTBZ1d2TRMI9qixvmdYNC+cbc12q9+YRW0Kw99QZfmYQzq" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/ace/1.2.2/ace.js" integrity="sha384-niN+bRlaXMBoq/f5L4zKOEYGxuD0YRGBocto9LP2fB1UiMfxrymATRN4GqjVUt6J" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/epiceditor/0.2.2/js/epiceditor.min.js" integrity="sha384-jV5EM0s4BWbqIJxNwLbyMfgHMQWPkSn2oytRUMPSne2YaT5TAYcl7R0m1c1XsfAb" crossorigin="anonymous"></script>
<script src="/js/easyctf.js"></script>
<script src="/js/admin.js"></script>
</head>

2899
web/js/epiceditor.js Normal file

File diff suppressed because it is too large Load diff

5
web/js/epiceditor.min.js vendored Normal file

File diff suppressed because one or more lines are too long

View file

@ -7,6 +7,9 @@
width: 100%;
height: 200px;
}
.epiceditor-edit-mode {
border: 1px solid #999 !important;
}
</style>
<ul class="nav nav-tabs" role="tablist">
@ -16,7 +19,7 @@
<div class="tab-content">
<div role="tabpanel" class="tab-pane active" id="problems">
<div class="row">
<div class="col-sm-12 col-md-6">
<div class="col-sm-12 col-md-3">
<div class="panel-group" id="problems" role="tablist" aria-multiselectable="true">
<div class="well" ng-show="problems.length==0">There are no problems to show!</div>
<!-- <div class="panel panel-default">
@ -35,7 +38,7 @@
</div> -->
</div>
</div>
<div class="col-sm-12 col-md-6">
<div class="col-sm-12 col-md-9">
<div class="panel panel-default">
<div class="panel-heading" role="tab" id="heading-new">
<h4 class="panel-title">
@ -89,7 +92,7 @@
<div class="col-sm-12 form-group">
<label class="col-sm-12" for="description"><small>Description</small></label>
<div class="col-sm-12">
<textarea id="new_description" name="description"></textarea>
<div id="description"></div>
</div>
</div>
</div>
@ -132,27 +135,46 @@
</div>
</div>
<div role="tabpanel" class="tab-pane" id="filesystem">
<div class="well">Nothing here yet.</div>
<div class="row">
<div class="col-sm-12 col-md-3">
<div class="">
</div>
</div>
<div class="col-sm-12 col-md-9">
</div>
</div>
</div>
</div>
<script type="text/javascript">
$("ul[role=tablist]").tab();
$("a[role=tab]").click(function(e) {
e.preventDefault();
$(document).ready(function() {
$("ul[role=tablist]").tab();
$("a[role=tab]").click(function(e) {
e.preventDefault();
});
$(".selectpicker").selectpicker();
var config = {
toolbar: [
{ name: "basicstyles", items: [ "Bold", "Italic", "Underline" ] },
{ name: "links", items: [ "Link" ] },
{ name: "paragraph", items: [ "NumberedList", "BulletedList", "-", "Outdent", "Indent", "-", "Blockquote" ] },
{ name: "tools", items: [ "Maximize" ] },
{ name: "document", items: [ "Source" ] },
]
};
var editor = new EpicEditor({
container: "description",
theme: {
base: "https://cdnjs.cloudflare.com/ajax/libs/epiceditor/0.2.2/themes/base/epiceditor.css",
preview: "https://cdnjs.cloudflare.com/ajax/libs/epiceditor/0.2.2/themes/preview/github.css",
editor: "https://cdnjs.cloudflare.com/ajax/libs/epiceditor/0.2.2/themes/editor/epic-light.css"
},
button: {
bar: "show"
}
}).load();
var new_grader = ace.edit("new_grader");
new_grader.setTheme("ace/theme/tomorrow");
new_grader.getSession().setMode("ace/mode/python");
});
$(".selectpicker").selectpicker();
var config = {
toolbar: [
{ name: "basicstyles", items: [ "Bold", "Italic", "Underline" ] },
{ name: "links", items: [ "Link" ] },
{ name: "paragraph", items: [ "NumberedList", "BulletedList", "-", "Outdent", "Indent", "-", "Blockquote" ] },
{ name: "tools", items: [ "Maximize" ] },
{ name: "document", items: [ "Source" ] },
]
};
CKEDITOR.replace("new_description", config);
var new_grader = ace.edit("new_grader");
new_grader.setTheme("ace/theme/tomorrow");
new_grader.getSession().setMode("ace/mode/python");
</script>

View file

@ -0,0 +1,70 @@
html, body, iframe, div {
margin:0;
padding:0;
}
#epiceditor-utilbar {
position:fixed;
bottom:10px;
right:10px;
}
#epiceditor-utilbar button {
display:block;
float:left;
width:30px;
height:30px;
border:none;
background:none;
}
#epiceditor-utilbar button.epiceditor-toggle-preview-btn {
background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB4AAAAeCAYAAAA7MK6iAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAf9JREFUeNrsVu1twjAQLZmAEcIGYYKGDWACkgkSkPiQ+CifAoEgyQTQDegEpROQDZoRMgH0HToj1yIglKr90Vg62T6f/e4d9gu50+n09BctlwFnwP8TOAgCA10VRr2ZELaHhbBXx3HCVMC+71voXmD6g4Qi2NB13e1DwAAkZhtmmKYRcxsJhHeBPc8bMMufbDU0PxF4vV4TSyth8477csI6lTV/a71er9tioonBarXaIAmLErliNWyqoM8nrJPpHFNLWLcI4xvj5XKpMo2ZgcvzIvs+75S0wKwPPB/CnpWXsG00Gra2WCwshekOVoC9Sb6IGN1ge2HNsWK+B0iJqxAL5oSpYeDJJW02mxVYLAWSGfDtebylA68Bc4wh+ahK5PcxLh6PR5GUpym/iTOfz89PqNVqhRI4iQf1/o174HNMVYDSGeTDmXQ3znogCGrtdpsYVBhER1aH2Wzm8iE7UR74DMTWGNxUQWmNYqTEzq8APoo9sJ8wKoR5eU7T6VQVjZAvx4YvDJWt1Ol0QsTqkppF8EW8/12OhTnSpT2LCe2/KiCTyUQVkJgPuwgb6XG32w05Xui4q0imLLNDxA/uSuZ4PNaZqZlSsejDYfd6veihj8RoNDK5XOUHAen3Dfr9/j7VZxEJ6AwuxCCvhMTM7oNAARhl/0Ay4Az419qXAAMAfBdK7281j6YAAAAASUVORK5CYII=);
}
#epiceditor-utilbar button.epiceditor-toggle-edit-btn {
background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB4AAAAeCAYAAAA7MK6iAAAAGX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NrsV8tthDAQhYgCtoV04BKghK2En5AQBw4IITjwq2RLgBJcwpawHZAxMpGDYGwTFPaQkUbG1sybj58NmNM0GVfIh3GRXBbYEid932N9d1zXHWWAGAb4m+9VsUA0H5SubKkKIGA4qyUC2qKBxSCe541HKln7dV2nVbHRtq0Nw7CXGNtz/jzwqjZ5odtqTOagQRC82KRpGkcS/L2Ok7lXZV3Xp7Q6DMNR2mqNthMhKXLqzcUCc6Wgn3wU1wlX1PboHs8tjaLoyVtLT7JFK2ZZM6CZvWyE+X1Voaj3la3DMA63epGqqm4wfyCBH8xmz1+Z1WVZ2vyqU2HvHtv9OI4PsRpjL91YV2a7pcB8onmOifYFUhSFLQCTnQtkDpokyYv73JBtcAQsA3zGTXJBEgNXgrF3CcrBZGwnC+4uqxHnH+zN8/ybvexZwvZNhlsHbrt5CyCgDtu1XosUe58K4kuOF9EKnKYp20eVrxDUJssyreM0bDg4kIw0EfCbftvqQ6KKYf7/wvyVfAkwAMjqoFSaWbrBAAAAAElFTkSuQmCC);
}
@media
only screen and (-webkit-min-device-pixel-ratio: 2),
only screen and ( min--moz-device-pixel-ratio: 2),
only screen and ( -o-min-device-pixel-ratio: 2/1),
only screen and ( min-device-pixel-ratio: 2),
only screen and ( min-resolution: 192dpi),
only screen and ( min-resolution: 2dppx) {
#epiceditor-utilbar button.epiceditor-toggle-preview-btn {
background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADwAAAA8CAMAAAANIilAAAABrVBMVEWIiIiHh4eIiIiJiYmEhISEhISEhISMjIyNjY2MjIyNjY2MjIyFhYWDg4OFhYWKioqKioqBgYGJiYmJiYmJiYmKioqKioqFhYWIiIiJiYmIiIiJiYmIiIiGhoaIiIiGhoaIiIiHh4eHh4eGhoaFhYWKioqFhYWEhISFhYWEhISDg4ONjY2NjY2MjIyHh4eMjIyLi4uCgoKCgoKCgoKBgYGBgYGOjo6Ojo6BgYGPj4+Ojo6Hh4eNjY2Pj4+BgYGNjY2BgYGHh4eQkJ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SkaljK0R6inJTEinLQo5aSFE889kkqUWvsCdM37ZcnHYnrNBhably5QyoJDtFuJK1xMF3mHgVlkHM2e4eYB02Xxfts/NwXBuSMWLIG7sTmbb/+Hzj3fy1wuQD6N3DMX5/g0VHDDQ3aXAR4jXsEb5/co9fbLN2KdlJbO/zmM5a0qH+KukXxOnfzoO5GmTr5M7mOoktP4xrfUyffIvQ118pNBiTvq5AeDxNV//W+CFX4Doxg1lHC8FNUAAAAASUVORK5CYII=);
background-size: 30px 30px;
}
#epiceditor-utilbar button.epiceditor-fullscreen-btn {
background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADwAAAA8CAMAAAANIilAAAAA5FBMVEWPj4+JiYmJiYmCgoKGhoaPj4+Li4uEhISAgICNjY2Li4uNjY2QkJCFhYWEhISLi4uHh4eHh4eIiIiHh4eGhoaHh4eEhISOjo6EhISJiYmFhYWJiYmFhYWNjY2NjY2Hh4eOjo6CgoKGhoaKioqKioqJiYmKioqDg4ODg4OBgYGGhoaKioqKioqLi4uMjIyMjIyIiIiIiIiMjIyOjo6GhoaDg4ONjY2EhISPj4+CgoIAAACJiYmHh4eIiIiFhYWCgoKPj4+Li4uAgICKioqEhISGhoaBgYGOjo6MjIyQkJCNjY2Dg4O2Jy/OAAAAO3RSTlMQz0DPEHDPz0DvMDBAQBBAQBAQz88wMM/v7zAw788Q7xAQQM9AEBDPEEAwMO/v7zDvMEBA70BAQEBAAAENmbYAAAG1SURBVHja7dftM0JREMdxD5GkEEqKpBJRSc8rQq7Q////2Dnm3t85jtkTmmGG75t7Z3c/t9fN0Tf6x1/Dz0ZrZGZf/BJ8a9QjM/vCwks9Px5aBcslC+P3nPVmi8dcczrcHHM2flug1CHRYcoYNd0YFlrAL1yHqPOC9g9IdbAfjHAjYFjoT+FI1MfRiAM/cZdEl0+oVidVvRaMcAOMgJWGBUYSVhrWjdfvjKqrq1Vzsu7Cy1Vo7XXZhYuj0ahwfHY+sjo/Oy7woyhitkTQsESsZawstG6VlvDCfIlUmfSVVjpDqtL8goBLbKFhsRcwalxcB100CDkxLLQbJxKwpvb3At7Y2iRuJzd4V26HuM2tDQkPWMOamu1Awkeetx2qtDy/lvZaCW173pGIWetA/xBbF+ZgiVgjGcdutLJ7xO1l9VnMiWGhJdzl4vx4CNpN+ifJXUy7RPEuZ2C1AIY1NG5kHI4Dx8MynnBtovYkqHzi25OyP8ONiKFh3djQsCIecn2i/lBvMU+UXxwi3HyE832jvD0RsLuP8CN3Oh0+feRmixE+g7CdLb43WiEz++Jb+M//x/gB/ArCl0G4nsFuEQAAAABJRU5ErkJggg==);
background-size: 30px 30px;
}
}
#epiceditor-utilbar button:last-child {
margin-left:15px;
}
#epiceditor-utilbar button:hover {
cursor:pointer;
}
.epiceditor-edit-mode #epiceditor-utilbar button.epiceditor-toggle-edit-btn {
display:none;
}
.epiceditor-preview-mode #epiceditor-utilbar button.epiceditor-toggle-preview-btn {
display:none;
}

View file

@ -0,0 +1,13 @@
html { padding:10px; }
body {
border:0;
background:rgb(41,41,41);
font-family:monospace;
font-size:14px;
padding:10px;
color:#ddd;
line-height:1.35em;
margin:0;
padding:0;
}

View file

@ -0,0 +1,12 @@
html { padding:10px; }
body {
border:0;
background:#fcfcfc;
font-family:monospace;
font-size:14px;
padding:10px;
line-height:1.35em;
margin:0;
padding:0;
}

View file

@ -0,0 +1,167 @@
body {
font-family: Georgia, "Times New Roman", Times, serif;
line-height: 1.5;
font-size: 87.5%;
word-wrap: break-word;
margin: 2em;
padding: 0;
border: 0;
outline: 0;
background: #fff;
}
h1,
h2,
h3,
h4,
h5,
h6 {
margin: 1.0em 0 0.5em;
font-weight: inherit;
}
h1 {
font-size: 1.357em;
color: #000;
}
h2 {
font-size: 1.143em;
}
p {
margin: 0 0 1.2em;
}
del {
text-decoration: line-through;
}
tr:nth-child(odd) {
background-color: #dddddd;
}
img {
outline: 0;
}
code {
background-color: #f2f2f2;
background-color: rgba(40, 40, 0, 0.06);
}
pre {
background-color: #f2f2f2;
background-color: rgba(40, 40, 0, 0.06);
margin: 10px 0;
overflow: hidden;
padding: 15px;
white-space: pre-wrap;
}
pre code {
font-size: 100%;
background-color: transparent;
}
blockquote {
background: #f7f7f7;
border-left: 1px solid #bbb;
font-style: italic;
margin: 1.5em 10px;
padding: 0.5em 10px;
}
blockquote:before {
color: #bbb;
content: "\201C";
font-size: 3em;
line-height: 0.1em;
margin-right: 0.2em;
vertical-align: -.4em;
}
blockquote:after {
color: #bbb;
content: "\201D";
font-size: 3em;
line-height: 0.1em;
vertical-align: -.45em;
}
blockquote > p:first-child {
display: inline;
}
table {
font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
border: 0;
border-spacing: 0;
font-size: 0.857em;
margin: 10px 0;
width: 100%;
}
table table {
font-size: 1em;
}
table tr th {
background: #757575;
background: rgba(0, 0, 0, 0.51);
border-bottom-style: none;
}
table tr th,
table tr th a,
table tr th a:hover {
color: #FFF;
font-weight: bold;
}
table tbody tr th {
vertical-align: top;
}
tr td,
tr th {
padding: 4px 9px;
border: 1px solid #fff;
text-align: left; /* LTR */
}
tr:nth-child(odd) {
background: #e4e4e4;
background: rgba(0, 0, 0, 0.105);
}
tr,
tr:nth-child(even) {
background: #efefef;
background: rgba(0, 0, 0, 0.063);
}
a {
color: #0071B3;
}
a:hover,
a:focus {
color: #018fe2;
}
a:active {
color: #23aeff;
}
a:link,
a:visited {
text-decoration: none;
}
a:hover,
a:active,
a:focus {
text-decoration: underline;
}

View file

@ -0,0 +1,368 @@
html { padding:0 10px; }
body {
margin:0;
padding:0;
background:#fff;
}
#epiceditor-wrapper{
background:white;
}
#epiceditor-preview{
padding-top:10px;
padding-bottom:10px;
font-family: Helvetica,arial,freesans,clean,sans-serif;
font-size:13px;
line-height:1.6;
}
#epiceditor-preview>*:first-child{
margin-top:0!important;
}
#epiceditor-preview>*:last-child{
margin-bottom:0!important;
}
#epiceditor-preview a{
color:#4183C4;
text-decoration:none;
}
#epiceditor-preview a:hover{
text-decoration:underline;
}
#epiceditor-preview h1,
#epiceditor-preview h2,
#epiceditor-preview h3,
#epiceditor-preview h4,
#epiceditor-preview h5,
#epiceditor-preview h6{
margin:20px 0 10px;
padding:0;
font-weight:bold;
-webkit-font-smoothing:antialiased;
}
#epiceditor-preview h1 tt,
#epiceditor-preview h1 code,
#epiceditor-preview h2 tt,
#epiceditor-preview h2 code,
#epiceditor-preview h3 tt,
#epiceditor-preview h3 code,
#epiceditor-preview h4 tt,
#epiceditor-preview h4 code,
#epiceditor-preview h5 tt,
#epiceditor-preview h5 code,
#epiceditor-preview h6 tt,
#epiceditor-preview h6 code{
font-size:inherit;
}
#epiceditor-preview h1{
font-size:28px;
color:#000;
}
#epiceditor-preview h2{
font-size:24px;
border-bottom:1px solid #ccc;
color:#000;
}
#epiceditor-preview h3{
font-size:18px;
}
#epiceditor-preview h4{
font-size:16px;
}
#epiceditor-preview h5{
font-size:14px;
}
#epiceditor-preview h6{
color:#777;
font-size:14px;
}
#epiceditor-preview p,
#epiceditor-preview blockquote,
#epiceditor-preview ul,
#epiceditor-preview ol,
#epiceditor-preview dl,
#epiceditor-preview li,
#epiceditor-preview table,
#epiceditor-preview pre{
margin:15px 0;
}
#epiceditor-preview hr{
background:transparent url('../../images/modules/pulls/dirty-shade.png') repeat-x 0 0;
border:0 none;
color:#ccc;
height:4px;
padding:0;
}
#epiceditor-preview>h2:first-child,
#epiceditor-preview>h1:first-child,
#epiceditor-preview>h1:first-child+h2,
#epiceditor-preview>h3:first-child,
#epiceditor-preview>h4:first-child,
#epiceditor-preview>h5:first-child,
#epiceditor-preview>h6:first-child{
margin-top:0;
padding-top:0;
}
#epiceditor-preview h1+p,
#epiceditor-preview h2+p,
#epiceditor-preview h3+p,
#epiceditor-preview h4+p,
#epiceditor-preview h5+p,
#epiceditor-preview h6+p{
margin-top:0;
}
#epiceditor-preview li p.first{
display:inline-block;
}
#epiceditor-preview ul,
#epiceditor-preview ol{
padding-left:30px;
}
#epiceditor-preview ul li>:first-child,
#epiceditor-preview ol li>:first-child{
margin-top:0;
}
#epiceditor-preview ul li>:last-child,
#epiceditor-preview ol li>:last-child{
margin-bottom:0;
}
#epiceditor-preview dl{
padding:0;
}
#epiceditor-preview dl dt{
font-size:14px;
font-weight:bold;
font-style:italic;
padding:0;
margin:15px 0 5px;
}
#epiceditor-preview dl dt:first-child{
padding:0;
}
#epiceditor-preview dl dt>:first-child{
margin-top:0;
}
#epiceditor-preview dl dt>:last-child{
margin-bottom:0;
}
#epiceditor-preview dl dd{
margin:0 0 15px;
padding:0 15px;
}
#epiceditor-preview dl dd>:first-child{
margin-top:0;
}
#epiceditor-preview dl dd>:last-child{
margin-bottom:0;
}
#epiceditor-preview blockquote{
border-left:4px solid #DDD;
padding:0 15px;
color:#777;
}
#epiceditor-preview blockquote>:first-child{
margin-top:0;
}
#epiceditor-preview blockquote>:last-child{
margin-bottom:0;
}
#epiceditor-preview table{
padding:0;
border-collapse: collapse;
border-spacing: 0;
font-size: 100%;
font: inherit;
}
#epiceditor-preview table tr{
border-top:1px solid #ccc;
background-color:#fff;
margin:0;
padding:0;
}
#epiceditor-preview table tr:nth-child(2n){
background-color:#f8f8f8;
}
#epiceditor-preview table tr th{
font-weight:bold;
}
#epiceditor-preview table tr th,
#epiceditor-preview table tr td{
border:1px solid #ccc;
text-align:left;
margin:0;
padding:6px 13px;
}
#epiceditor-preview table tr th>:first-child,
#epiceditor-preview table tr td>:first-child{
margin-top:0;
}
#epiceditor-preview table tr th>:last-child,
#epiceditor-preview table tr td>:last-child{
margin-bottom:0;
}
#epiceditor-preview img{
max-width:100%;
}
#epiceditor-preview span.frame{
display:block;
overflow:hidden;
}
#epiceditor-preview span.frame>span{
border:1px solid #ddd;
display:block;
float:left;
overflow:hidden;
margin:13px 0 0;
padding:7px;
width:auto;
}
#epiceditor-preview span.frame span img{
display:block;
float:left;
}
#epiceditor-preview span.frame span span{
clear:both;
color:#333;
display:block;
padding:5px 0 0;
}
#epiceditor-preview span.align-center{
display:block;
overflow:hidden;
clear:both;
}
#epiceditor-preview span.align-center>span{
display:block;
overflow:hidden;
margin:13px auto 0;
text-align:center;
}
#epiceditor-preview span.align-center span img{
margin:0 auto;
text-align:center;
}
#epiceditor-preview span.align-right{
display:block;
overflow:hidden;
clear:both;
}
#epiceditor-preview span.align-right>span{
display:block;
overflow:hidden;
margin:13px 0 0;
text-align:right;
}
#epiceditor-preview span.align-right span img{
margin:0;
text-align:right;
}
#epiceditor-preview span.float-left{
display:block;
margin-right:13px;
overflow:hidden;
float:left;
}
#epiceditor-preview span.float-left span{
margin:13px 0 0;
}
#epiceditor-preview span.float-right{
display:block;
margin-left:13px;
overflow:hidden;
float:right;
}
#epiceditor-preview span.float-right>span{
display:block;
overflow:hidden;
margin:13px auto 0;
text-align:right;
}
#epiceditor-preview code,
#epiceditor-preview tt{
margin:0 2px;
padding:0 5px;
white-space:nowrap;
border:1px solid #eaeaea;
background-color:#f8f8f8;
border-radius:3px;
}
#epiceditor-preview pre>code{
margin:0;
padding:0;
white-space:pre;
border:none;
background:transparent;
}
#epiceditor-preview .highlight pre,
#epiceditor-preview pre{
background-color:#f8f8f8;
border:1px solid #ccc;
font-size:13px;
line-height:19px;
overflow:auto;
padding:6px 10px;
border-radius:3px;
}
#epiceditor-preview pre code,
#epiceditor-preview pre tt{
background-color:transparent;
border:none;
}

View file

@ -0,0 +1,121 @@
html { padding:0 10px; }
body {
margin:0;
padding:10px 0;
background:#000;
}
#epiceditor-preview h1,
#epiceditor-preview h2,
#epiceditor-preview h3,
#epiceditor-preview h4,
#epiceditor-preview h5,
#epiceditor-preview h6,
#epiceditor-preview p,
#epiceditor-preview blockquote {
margin: 0;
padding: 0;
}
#epiceditor-preview {
background:#000;
font-family: "Helvetica Neue", Helvetica, "Hiragino Sans GB", Arial, sans-serif;
font-size: 13px;
line-height: 18px;
color: #ccc;
}
#epiceditor-preview a {
color: #fff;
}
#epiceditor-preview a:hover {
color: #00ff00;
text-decoration: none;
}
#epiceditor-preview a img {
border: none;
}
#epiceditor-preview p {
margin-bottom: 9px;
}
#epiceditor-preview h1,
#epiceditor-preview h2,
#epiceditor-preview h3,
#epiceditor-preview h4,
#epiceditor-preview h5,
#epiceditor-preview h6 {
color: #cdcdcd;
line-height: 36px;
}
#epiceditor-preview h1 {
margin-bottom: 18px;
font-size: 30px;
}
#epiceditor-preview h2 {
font-size: 24px;
}
#epiceditor-preview h3 {
font-size: 18px;
}
#epiceditor-preview h4 {
font-size: 16px;
}
#epiceditor-preview h5 {
font-size: 14px;
}
#epiceditor-preview h6 {
font-size: 13px;
}
#epiceditor-preview hr {
margin: 0 0 19px;
border: 0;
border-bottom: 1px solid #ccc;
}
#epiceditor-preview blockquote {
padding: 13px 13px 21px 15px;
margin-bottom: 18px;
font-family:georgia,serif;
font-style: italic;
}
#epiceditor-preview blockquote:before {
content:"\201C";
font-size:40px;
margin-left:-10px;
font-family:georgia,serif;
color:#eee;
}
#epiceditor-preview blockquote p {
font-size: 14px;
font-weight: 300;
line-height: 18px;
margin-bottom: 0;
font-style: italic;
}
#epiceditor-preview code, #epiceditor-preview pre {
font-family: Monaco, Andale Mono, Courier New, monospace;
}
#epiceditor-preview code {
background-color: #000;
color: #f92672;
padding: 1px 3px;
font-size: 12px;
-webkit-border-radius: 3px;
-moz-border-radius: 3px;
border-radius: 3px;
}
#epiceditor-preview pre {
display: block;
padding: 14px;
color:#66d9ef;
margin: 0 0 18px;
line-height: 16px;
font-size: 11px;
border: 1px solid #d9d9d9;
white-space: pre-wrap;
word-wrap: break-word;
}
#epiceditor-preview pre code {
background-color: #000;
color:#ccc;
font-size: 11px;
padding: 0;
}