mirror of
https://github.com/DarrenOfficial/dpaste.git
synced 2024-11-23 03:46:37 +11:00
Cleanup
This commit is contained in:
parent
4f2cf9dcbc
commit
0fc6801213
5 changed files with 20 additions and 22 deletions
|
@ -1,10 +1,5 @@
|
|||
/*jshint strict:false */
|
||||
|
||||
if (typeof console === "undefined" || typeof console.log === "undefined") {
|
||||
console = {};
|
||||
console.log = function () { };
|
||||
}
|
||||
|
||||
// -----------------------------------------------------------------------------
|
||||
// Add data-platform to the body tag to show platform related shortcuts
|
||||
// -----------------------------------------------------------------------------
|
||||
|
@ -68,12 +63,12 @@ if (curLine.startsWith('#L')) {
|
|||
}
|
||||
}
|
||||
|
||||
let lines = document.querySelectorAll('.snippet-code li');
|
||||
const lines = document.querySelectorAll('.snippet-code li');
|
||||
lines.forEach(function(el) {
|
||||
el.onclick = function() {
|
||||
el.classList.toggle('marked');
|
||||
let hash = 'L';
|
||||
let marked = document.querySelectorAll('.snippet-code li.marked');
|
||||
const marked = document.querySelectorAll('.snippet-code li.marked');
|
||||
marked.forEach(function(line) {
|
||||
if (hash !== 'L') {
|
||||
hash += ',';
|
||||
|
|
|
@ -84,6 +84,10 @@ ul#snippetOptions {
|
|||
text-decoration: underline;
|
||||
}
|
||||
|
||||
strong {
|
||||
font-weight: $baseFontBold;
|
||||
}
|
||||
|
||||
li {
|
||||
margin: 0;
|
||||
padding: 0 7px;
|
||||
|
|
|
@ -1,9 +1,6 @@
|
|||
/*
|
||||
|
||||
Generic Content pages and Text based lexer.
|
||||
|
||||
*/
|
||||
|
||||
// Generic content pages such as About/404/500
|
||||
// and base styles for text based lexer.
|
||||
article {
|
||||
padding: 0 $boxPadding 40px $boxPadding;
|
||||
margin-top: 30px;
|
||||
|
@ -21,12 +18,10 @@ article {
|
|||
h1, h2, h3, h4, h5, h6 {
|
||||
font-weight: $baseFontRegular;
|
||||
line-height: 1.3em;
|
||||
padding-bottom: 5px;
|
||||
border-bottom: 1px solid $borderColor;
|
||||
}
|
||||
|
||||
p {
|
||||
margin: 30px 0;
|
||||
margin: 10px 0 20px 0;
|
||||
}
|
||||
|
||||
strong, b {
|
||||
|
@ -64,17 +59,24 @@ article {
|
|||
font-style: italic;
|
||||
}
|
||||
|
||||
// reStructuredText Specific
|
||||
dl, ul, ol, table {
|
||||
p { margin: 0; }
|
||||
}
|
||||
}
|
||||
|
||||
// Specific styles for text based lexer
|
||||
article.snippet-text {
|
||||
h1, h2, h3, h4, h5, h6 {
|
||||
padding-bottom: 5px;
|
||||
border-bottom: 1px solid $borderColor;
|
||||
}
|
||||
|
||||
.admonition {
|
||||
padding: 10px 10px;
|
||||
margin: 20px 0;
|
||||
background-color: $metaBgColor;
|
||||
|
||||
.admonition-title {
|
||||
.admonition-title {
|
||||
margin: 0;
|
||||
font-weight: $baseFontBold;
|
||||
}
|
||||
|
@ -97,6 +99,7 @@ article {
|
|||
}
|
||||
|
||||
|
||||
// Content pages (About page)
|
||||
article.content-page {
|
||||
h2 { margin-top: 0; }
|
||||
}
|
||||
|
|
|
@ -19,9 +19,7 @@
|
|||
{% block options %}
|
||||
<ul id="snippetOptions">
|
||||
<li>
|
||||
{% blocktrans with snippet.lexer_name as name %}{{ name }} Snippet{% endblocktrans %}
|
||||
<li class="sep"></li>
|
||||
<li>
|
||||
<strong>{{ snippet.lexer_name }}</strong>
|
||||
{% if snippet.expire_type == 1 %}
|
||||
{% blocktrans with date=snippet.expires|timeuntil %}Expires in: {{ date }}{% endblocktrans %}
|
||||
{% elif snippet.expire_type == 2 %}
|
||||
|
|
|
@ -34,8 +34,6 @@ def inlinestatic(path):
|
|||
:param path: (string) Filename of the file to include.
|
||||
:return: (string) The included File or an empty string `''` if the
|
||||
file was not found, and DEBUG is disabled.
|
||||
|
||||
|
||||
"""
|
||||
# Filename in build/ directory (when in Watch mode)
|
||||
filename = find(path)
|
||||
|
|
Loading…
Reference in a new issue