Improve syntax highlighting of code
Squashed commit of the following: commit eb55e94ed89a1b8ccd1db10a36efd28d8896f316 Author: Jonny Barnes <jonny@jonnybarnes.uk> Date: Thu Jan 24 18:45:00 2019 +0000 Remove un-needed use statments, fix tests now we have 2 articles commit f1c12c1b43d071fe0484407a9692ee4184542437 Author: Jonny Barnes <jonny@jonnybarnes.uk> Date: Wed Jan 23 19:39:56 2019 +0000 Remove prism files commit 3a1d12d9181600f661593c662dbc18d152413b28 Author: Jonny Barnes <jonny@jonnybarnes.uk> Date: Wed Jan 23 19:39:24 2019 +0000 Use the new css file in the search page commit 119b6b5163c217a15770004a45b07bacdfb766f0 Author: Jonny Barnes <jonny@jonnybarnes.uk> Date: Wed Jan 23 19:36:14 2019 +0000 Recompress assets commit afae245d0211dd31fcc131cecb0fab4084895612 Author: Jonny Barnes <jonny@jonnybarnes.uk> Date: Sun Jan 20 19:33:56 2019 +0000 Style codeblocks in articles as well commit 53be0a2023755c2f16ba1560d88f9c66675b581d Author: Jonny Barnes <jonny@jonnybarnes.uk> Date: Sun Jan 20 19:23:25 2019 +0000 Styled codeblocks are now on the notes pages commit 818add06f349874501cc44baf332dc63dfdcfab1 Author: Jonny Barnes <jonny@jonnybarnes.uk> Date: Sun Jan 20 19:08:56 2019 +0000 Install spatie’s commonmark highlighter, use it for notes commit fb69d98b2bd3bb56540854fe16200c027e5ef6b2 Author: Jonny Barnes <jonny@jonnybarnes.uk> Date: Sun Jan 20 18:54:27 2019 +0000 Remove links to prism code in the notes pages commit dc89fcd4711b25e8407be9b25b58cd4cd1e9980e Author: Jonny Barnes <jonny@jonnybarnes.uk> Date: Sun Jan 20 18:54:11 2019 +0000 Add a note to the seeder which has a code block
This commit is contained in:
parent
ffa9756cb7
commit
427b79f278
103 changed files with 287 additions and 251 deletions
|
@ -4,11 +4,16 @@ declare(strict_types=1);
|
|||
|
||||
namespace App\Models;
|
||||
|
||||
use League\CommonMark\Environment;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Builder;
|
||||
use Cviebrock\EloquentSluggable\Sluggable;
|
||||
use League\CommonMark\CommonMarkConverter;
|
||||
use Illuminate\Database\Eloquent\SoftDeletes;
|
||||
use League\CommonMark\Block\Element\FencedCode;
|
||||
use League\CommonMark\Block\Element\IndentedCode;
|
||||
use Spatie\CommonMarkHighlighter\FencedCodeRenderer;
|
||||
use Spatie\CommonMarkHighlighter\IndentedCodeRenderer;
|
||||
|
||||
class Article extends Model
|
||||
{
|
||||
|
@ -57,15 +62,12 @@ class Article extends Model
|
|||
*/
|
||||
public function getHtmlAttribute(): string
|
||||
{
|
||||
$markdown = new CommonMarkConverter();
|
||||
$html = $markdown->convertToHtml($this->main);
|
||||
// changes <pre><code>[lang] ~> <pre><code data-language="lang">
|
||||
$match = '/<pre><code>\[(.*)\]\n/';
|
||||
$replace = '<pre><code class="language-$1">';
|
||||
$text = preg_replace($match, $replace, $html);
|
||||
$default = preg_replace('/<pre><code>/', '<pre><code class="language-markdown">', $text);
|
||||
$environment = Environment::createCommonMarkEnvironment();
|
||||
$environment->addBlockRenderer(FencedCode::class, new FencedCodeRenderer());
|
||||
$environment->addBlockRenderer(IndentedCode::class, new IndentedCodeRenderer());
|
||||
$commonMarkConverter = new CommonMarkConverter([], $environment);
|
||||
|
||||
return $default;
|
||||
return $commonMarkConverter->convertToHtml($this->main);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -9,17 +9,19 @@ use Twitter;
|
|||
use Normalizer;
|
||||
use GuzzleHttp\Client;
|
||||
use Laravel\Scout\Searchable;
|
||||
use League\CommonMark\Converter;
|
||||
use League\CommonMark\DocParser;
|
||||
use Jonnybarnes\IndieWeb\Numbers;
|
||||
use League\CommonMark\Environment;
|
||||
use League\CommonMark\HtmlRenderer;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Jonnybarnes\EmojiA11y\EmojiModifier;
|
||||
use Illuminate\Database\Eloquent\Builder;
|
||||
use League\CommonMark\CommonMarkConverter;
|
||||
use App\Exceptions\TwitterContentException;
|
||||
use Illuminate\Database\Eloquent\SoftDeletes;
|
||||
use League\CommonMark\Block\Element\FencedCode;
|
||||
use League\CommonMark\Block\Element\IndentedCode;
|
||||
use Jonnybarnes\CommonmarkLinkify\LinkifyExtension;
|
||||
use Spatie\CommonMarkHighlighter\FencedCodeRenderer;
|
||||
use Spatie\CommonMarkHighlighter\IndentedCodeRenderer;
|
||||
|
||||
class Note extends Model
|
||||
{
|
||||
|
@ -513,7 +515,9 @@ class Note extends Model
|
|||
{
|
||||
$environment = Environment::createCommonMarkEnvironment();
|
||||
$environment->addExtension(new LinkifyExtension());
|
||||
$converter = new Converter(new DocParser($environment), new HtmlRenderer($environment));
|
||||
$environment->addBlockRenderer(FencedCode::class, new FencedCodeRenderer());
|
||||
$environment->addBlockRenderer(IndentedCode::class, new IndentedCodeRenderer());
|
||||
$converter = new CommonMarkConverter([], $environment);
|
||||
|
||||
return $converter->convertToHtml($note);
|
||||
}
|
||||
|
|
|
@ -30,6 +30,7 @@
|
|||
"ramsey/uuid": "^3.5",
|
||||
"sensiolabs/security-checker": "^5.0",
|
||||
"spatie/browsershot": "~3.0",
|
||||
"spatie/commonmark-highlighter": "^1.0",
|
||||
"thujohn/twitter": "~2.0"
|
||||
},
|
||||
"require-dev": {
|
||||
|
|
111
composer.lock
generated
111
composer.lock
generated
|
@ -4,7 +4,7 @@
|
|||
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
||||
"This file is @generated automatically"
|
||||
],
|
||||
"content-hash": "20507240812c8f4034c9b81c6860f088",
|
||||
"content-hash": "e64d4d2f1552ebf50112a6122f6ee690",
|
||||
"packages": [
|
||||
{
|
||||
"name": "aws/aws-sdk-php",
|
||||
|
@ -3813,6 +3813,65 @@
|
|||
],
|
||||
"time": "2018-07-19T23:38:55+00:00"
|
||||
},
|
||||
{
|
||||
"name": "scrivo/highlight.php",
|
||||
"version": "v9.13.1.1",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/scrivo/highlight.php.git",
|
||||
"reference": "93834559fa181b6f34a3f639eaab5f9a9856ec99"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/scrivo/highlight.php/zipball/93834559fa181b6f34a3f639eaab5f9a9856ec99",
|
||||
"reference": "93834559fa181b6f34a3f639eaab5f9a9856ec99",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"ext-json": "*",
|
||||
"ext-mbstring": "*"
|
||||
},
|
||||
"require-dev": {
|
||||
"phpunit/phpunit": "^4.8|^5.7",
|
||||
"symfony/finder": "^2.8"
|
||||
},
|
||||
"type": "library",
|
||||
"autoload": {
|
||||
"psr-0": {
|
||||
"Highlight\\": ""
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"BSD-3-Clause"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Geert Bergman",
|
||||
"homepage": "http://www.scrivo.org/",
|
||||
"role": "Project Author"
|
||||
},
|
||||
{
|
||||
"name": "Vladimir Jimenez",
|
||||
"homepage": "https://allejo.io",
|
||||
"role": "Contributor"
|
||||
},
|
||||
{
|
||||
"name": "Martin Folkers",
|
||||
"homepage": "https://twobrain.io",
|
||||
"role": "Contributor"
|
||||
}
|
||||
],
|
||||
"description": "Server side syntax highlighter that supports 185 languages. It's a PHP port of highlight.js",
|
||||
"keywords": [
|
||||
"code",
|
||||
"highlight",
|
||||
"highlight.js",
|
||||
"highlight.php",
|
||||
"syntax"
|
||||
],
|
||||
"time": "2019-01-15T05:54:20+00:00"
|
||||
},
|
||||
{
|
||||
"name": "sensiolabs/security-checker",
|
||||
"version": "v5.0.3",
|
||||
|
@ -3915,6 +3974,56 @@
|
|||
],
|
||||
"time": "2019-01-10T09:13:44+00:00"
|
||||
},
|
||||
{
|
||||
"name": "spatie/commonmark-highlighter",
|
||||
"version": "1.0.1",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/spatie/commonmark-highlighter.git",
|
||||
"reference": "cab33e2d2a87011a4f44db71ceed2a89f692f930"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/spatie/commonmark-highlighter/zipball/cab33e2d2a87011a4f44db71ceed2a89f692f930",
|
||||
"reference": "cab33e2d2a87011a4f44db71ceed2a89f692f930",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"league/commonmark": "^0.18.0",
|
||||
"php": "^7.1",
|
||||
"scrivo/highlight.php": "v9.13.1.1"
|
||||
},
|
||||
"require-dev": {
|
||||
"larapack/dd": "^1.0",
|
||||
"phpunit/phpunit": "^7.0",
|
||||
"spatie/phpunit-snapshot-assertions": "^1.3"
|
||||
},
|
||||
"type": "library",
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Spatie\\CommonMarkHighlighter\\": "src"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"MIT"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Sebastian De Deyne",
|
||||
"email": "sebastian@spatie.be",
|
||||
"homepage": "https://spatie.be",
|
||||
"role": "Developer"
|
||||
}
|
||||
],
|
||||
"description": "Highlight your markdown code blocks with league/commonmark",
|
||||
"homepage": "https://github.com/spatie/commonmark-highlighter",
|
||||
"keywords": [
|
||||
"commonmark-highlighter",
|
||||
"spatie"
|
||||
],
|
||||
"time": "2019-01-16T15:37:34+00:00"
|
||||
},
|
||||
{
|
||||
"name": "spatie/image",
|
||||
"version": "1.5.3",
|
||||
|
|
|
@ -17,5 +17,30 @@ class ArticlesTableSeeder extends Seeder
|
|||
'main' => 'This is *my* new blog. It uses `Markdown`.',
|
||||
'published' => 1,
|
||||
]);
|
||||
|
||||
$articleWithCode = <<<EOF
|
||||
I wrote some code.
|
||||
|
||||
I liked writing this:
|
||||
|
||||
```php
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
class Foo
|
||||
{
|
||||
public function __construct()
|
||||
{
|
||||
echo 'Foo class constructed';
|
||||
}
|
||||
}
|
||||
```
|
||||
EOF;
|
||||
Article::create([
|
||||
'title' => 'Some code I did',
|
||||
'main' => $articleWithCode,
|
||||
'published' => 1,
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -108,5 +108,16 @@ class NotesTableSeeder extends Seeder
|
|||
$noteCapitalHashtag = Note::create([
|
||||
'note' => 'A #TwoWord hashtag',
|
||||
]);
|
||||
sleep(1);
|
||||
$noteWithCodeContent = <<<EOF
|
||||
A note with some code:
|
||||
```php
|
||||
<?php
|
||||
|
||||
echo 'Hello World';
|
||||
EOF;
|
||||
$noteWithCode = Note::create([
|
||||
'note' => $noteWithCodeContent,
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
|
2
public/assets/css/app.css
vendored
2
public/assets/css/app.css
vendored
File diff suppressed because one or more lines are too long
Binary file not shown.
Binary file not shown.
|
@ -1 +1 @@
|
|||
{"version":3,"sources":["../../../resources/assets/sass/_border-box.scss","../../../resources/assets/sass/_base-font.scss","../../../resources/assets/sass/_header.scss","../../../resources/assets/sass/_variables.scss","../../../resources/assets/sass/_main.scss","../../../resources/assets/sass/_hovercard.scss","../../../resources/assets/sass/_notes.scss","../../../resources/assets/sass/_pagination.scss","../../../resources/assets/sass/_contacts-page.scss","../../../resources/assets/sass/_projects.scss","../../../resources/assets/sass/_footer.scss","../../../resources/assets/sass/_admin-form.scss","../../../resources/assets/sass/_form.scss","../../../resources/assets/sass/_likes.scss","../../../resources/assets/sass/_bridgy-links.scss","../../../resources/assets/sass/_emoji.scss","../../../resources/assets/sass/_mapbox.scss","../../../resources/assets/sass/_colors.scss","../../../resources/assets/sass/_styles.scss","../../../resources/assets/sass/_tags.scss"],"names":[],"mappings":"AAKA,KACI,qBAAsB,CACzB,qBAKG,kBAAmB,CACtB,KCVG,eACA,gCAAiC,CACpC,gBAGG,oBAAqB,CACxB,WCNG,aACA,cACA,mBACA,WACA,eCJgB,CDKnB,cAGG,eACA,cAAe,CAClB,eAGG,cAAe,CAClB,KEdG,aACA,sBACA,oBACA,gBACA,cACA,iBACA,cAAe,CAClB,WAIG,gBAAiB,CACpB,aCZG,iBAAkB,CACrB,qBAGG,iBAAkB,CACrB,2BAGG,WAAY,CACf,WAGG,kBACA,mBACA,8BACA,qBACA,iBACA,YACA,WACA,UACA,WACA,uBACA,kBACA,mCACA,YAAa,CAChB,8BAGG,YAAa,CAChB,0BAGG,WACA,WAAY,CACf,sBAGG,YAAa,CCnCjB,MACI,aACA,sBACA,cAAe,CAClB,UAGG,eACA,eAAgB,CACnB,eAGG,aACA,mBACA,6BAA8B,CACjC,MAGG,WACA,UAAW,CACd,YCtBG,aACA,mBACA,6BACA,eACA,oBAAqB,CACxB,cCLG,eACA,aACA,2BACA,8BACA,eAAgB,CACnB,kBAGG,WACA,WAAY,CACf,UCVG,cAAe,CAClB,gBCDG,gBACA,cACA,gBAAiB,CACpB,OAGG,gBACA,cACA,aACA,sBACA,kBAAmB,CACtB,YCXG,gBACA,kBAAmB,CACtB,MCFG,aACA,qBAAsB,CACzB,UAGG,aACA,qBAAsB,CACzB,aAGG,kBAAmB,CACtB,WCXG,eAAgB,CACnB,qDCAG,YAAa,CAChB,2BCAG,iBAAkB,CACrB,gFAIG,kBACA,cACA,UACA,aACA,OACA,cACA,qBACA,yBACA,oBACA,oCACA,yBACA,kCACA,WACA,cACA,0CAAkC,AAAlC,iCAAkC,CACrC,2BAGG,KACI,aACA,6BACA,wCACA,0BACA,qBAAkC,CAGtC,GACI,aACA,kCACA,yBACA,WACA,mCAAgD,CAAA,CAIxD,AApBC,mBAGG,KACI,aACA,6BACA,wCACA,0BACA,qBAAkC,CAGtC,GACI,aACA,kCACA,yBACA,WACA,mCAAgD,CAAA,CAIxD,aACI,kCACI,kCAAmC,CACtC,CC9CL,KACI,YAAa,CAChB,oBAGG,kBAAmB,CACtB,QAGG,y4HACA,wBACA,WACA,WAAY,CACf,UAGG,kBACA,MACA,OACA,iBACA,cAAe,CAClB,gBAGG,gBACA,gBAAiB,CACpB,KCzBG,gCACA,kBAAmB,CACtB,WAGG,8BACA,kBAAmB,CACtB,YAIG,iBAAkB,CACrB,KCZG,kCAEA,yBACA,4BAAoB,AAApB,mBAAoB,CACvB,KAGG,oBAAqB,CACxB,aAGG,oBAAqB,CACxB,MCVG,SACA,gBACA,SAAU,CACb,SAGG,WACA,oBAAqB,CACxB,kBAIG,wBACA,0BACA,mBACA,qBACA,cACA,mBACA,sBACA,kBACA,qBACA,qBACA,qBAAsB,CACzB,YAGG,0BACA,uCACA,oCACA,oCACA,WACA,kBACA,QACA,KAAM,CACT,WAGG,4BACA,kBAAmB,CACtB,kBAGG,4BAA6B,CAChC","file":"app.css"}
|
||||
{"version":3,"sources":["../../../resources/assets/sass/_border-box.scss","../../../resources/assets/sass/_base-font.scss","../../../resources/assets/sass/_header.scss","../../../resources/assets/sass/_variables.scss","../../../resources/assets/sass/_main.scss","../../../resources/assets/sass/_articles.scss","../../../resources/assets/sass/_hovercard.scss","../../../resources/assets/sass/_notes.scss","../../../resources/assets/sass/_pagination.scss","../../../resources/assets/sass/_contacts-page.scss","../../../resources/assets/sass/_projects.scss","../../../resources/assets/sass/_footer.scss","../../../resources/assets/sass/_admin-form.scss","../../../resources/assets/sass/_form.scss","../../../resources/assets/sass/_likes.scss","../../../resources/assets/sass/_bridgy-links.scss","../../../resources/assets/sass/_emoji.scss","../../../resources/assets/sass/_mapbox.scss","../../../resources/assets/sass/_colors.scss","../../../resources/assets/sass/_styles.scss","../../../resources/assets/sass/_tags.scss"],"names":[],"mappings":"AAKA,KACI,qBAAsB,CACzB,qBAKG,kBAAmB,CACtB,KCVG,eACA,gCAAiC,CACpC,gBAGG,oBAAqB,CACxB,WCNG,aACA,cACA,mBACA,WACA,eCJgB,CDKnB,cAGG,eACA,cAAe,CAClB,eAGG,cAAe,CAClB,KEdG,aACA,sBACA,oBACA,gBACA,cACA,iBACA,cAAe,CAClB,WAIG,gBAAiB,CACpB,kBCZG,oBACA,iBAAkB,CACrB,aCFG,iBAAkB,CACrB,qBAGG,iBAAkB,CACrB,2BAGG,WAAY,CACf,WAGG,kBACA,mBACA,8BACA,qBACA,iBACA,YACA,WACA,UACA,WACA,uBACA,kBACA,mCACA,YAAa,CAChB,8BAGG,YAAa,CAChB,0BAGG,WACA,WAAY,CACf,sBAGG,YAAa,CCnCjB,MACI,aACA,sBACA,cAAe,CAClB,UAGG,eACA,eAAgB,CACnB,eAGG,aACA,mBACA,6BAA8B,CACjC,MAGG,WACA,UAAW,CACd,eAGG,oBACA,iBAAkB,CACrB,YC3BG,aACA,mBACA,6BACA,eACA,oBAAqB,CACxB,cCLG,eACA,aACA,2BACA,8BACA,eAAgB,CACnB,kBAGG,WACA,WAAY,CACf,UCVG,cAAe,CAClB,gBCDG,gBACA,cACA,gBAAiB,CACpB,OAGG,gBACA,cACA,aACA,sBACA,kBAAmB,CACtB,YCXG,gBACA,kBAAmB,CACtB,MCFG,aACA,qBAAsB,CACzB,UAGG,aACA,qBAAsB,CACzB,aAGG,kBAAmB,CACtB,WCXG,eAAgB,CACnB,qDCAG,YAAa,CAChB,2BCAG,iBAAkB,CACrB,gFAIG,kBACA,cACA,UACA,aACA,OACA,cACA,qBACA,yBACA,oBACA,oCACA,yBACA,kCACA,WACA,cACA,0CAAkC,AAAlC,iCAAkC,CACrC,2BAGG,KACI,aACA,+BACA,wCACA,0BACA,qBAAkC,CAGtC,GACI,aACA,kCACA,yBACA,WACA,mCAAgD,CAAA,CAIxD,AApBC,mBAGG,KACI,aACA,+BACA,wCACA,0BACA,qBAAkC,CAGtC,GACI,aACA,kCACA,yBACA,WACA,mCAAgD,CAAA,CAIxD,aACI,kCACI,kCAAmC,CACtC,CC9CL,KACI,YAAa,CAChB,oBAGG,kBAAmB,CACtB,QAGG,y4HACA,wBACA,WACA,WAAY,CACf,UAGG,kBACA,MACA,OACA,iBACA,cAAe,CAClB,gBAGG,gBACA,gBAAiB,CACpB,KCzBG,gCACA,kBAAmB,CACtB,WAGG,8BACA,kBAAmB,CACtB,YAIG,iBAAkB,CACrB,KCZG,kCAEA,yBACA,4BAAoB,AAApB,mBAAoB,CACvB,KAGG,oBAAqB,CACxB,aAGG,oBAAqB,CACxB,MCVG,SACA,gBACA,SAAU,CACb,SAGG,WACA,oBAAqB,CACxB,kBAIG,wBACA,0BACA,mBACA,qBACA,cACA,mBACA,sBACA,kBACA,qBACA,qBACA,qBAAsB,CACzB,YAGG,0BACA,uCACA,oCACA,oCACA,WACA,kBACA,QACA,KAAM,CACT,WAGG,4BACA,kBAAmB,CACtB,kBAGG,4BAA6B,CAChC","file":"app.css"}
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
80
public/assets/highlight/zenburn.css
vendored
Normal file
80
public/assets/highlight/zenburn.css
vendored
Normal file
|
@ -0,0 +1,80 @@
|
|||
/*
|
||||
|
||||
Zenburn style from voldmar.ru (c) Vladimir Epifanov <voldmar@voldmar.ru>
|
||||
based on dark.css by Ivan Sagalaev
|
||||
|
||||
*/
|
||||
|
||||
.hljs {
|
||||
display: block;
|
||||
overflow-x: auto;
|
||||
padding: 0.5em;
|
||||
background: #3f3f3f;
|
||||
color: #dcdcdc;
|
||||
}
|
||||
|
||||
.hljs-keyword,
|
||||
.hljs-selector-tag,
|
||||
.hljs-tag {
|
||||
color: #e3ceab;
|
||||
}
|
||||
|
||||
.hljs-template-tag {
|
||||
color: #dcdcdc;
|
||||
}
|
||||
|
||||
.hljs-number {
|
||||
color: #8cd0d3;
|
||||
}
|
||||
|
||||
.hljs-variable,
|
||||
.hljs-template-variable,
|
||||
.hljs-attribute {
|
||||
color: #efdcbc;
|
||||
}
|
||||
|
||||
.hljs-literal {
|
||||
color: #efefaf;
|
||||
}
|
||||
|
||||
.hljs-subst {
|
||||
color: #8f8f8f;
|
||||
}
|
||||
|
||||
.hljs-title,
|
||||
.hljs-name,
|
||||
.hljs-selector-id,
|
||||
.hljs-selector-class,
|
||||
.hljs-section,
|
||||
.hljs-type {
|
||||
color: #efef8f;
|
||||
}
|
||||
|
||||
.hljs-symbol,
|
||||
.hljs-bullet,
|
||||
.hljs-link {
|
||||
color: #dca3a3;
|
||||
}
|
||||
|
||||
.hljs-deletion,
|
||||
.hljs-string,
|
||||
.hljs-built_in,
|
||||
.hljs-builtin-name {
|
||||
color: #cc9393;
|
||||
}
|
||||
|
||||
.hljs-addition,
|
||||
.hljs-comment,
|
||||
.hljs-quote,
|
||||
.hljs-meta {
|
||||
color: #7f9f7f;
|
||||
}
|
||||
|
||||
|
||||
.hljs-emphasis {
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
.hljs-strong {
|
||||
font-weight: bold;
|
||||
}
|
BIN
public/assets/highlight/zenburn.css.br
Normal file
BIN
public/assets/highlight/zenburn.css.br
Normal file
Binary file not shown.
BIN
public/assets/highlight/zenburn.css.gz
Normal file
BIN
public/assets/highlight/zenburn.css.gz
Normal file
Binary file not shown.
2
public/assets/js/a11y.js
vendored
2
public/assets/js/a11y.js
vendored
|
@ -1,2 +1,2 @@
|
|||
!function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},n.r=function(e){Object.defineProperty(e,"__esModule",{value:!0})},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=11)}({11:function(e,t,n){"use strict";function r(){var e=document.querySelectorAll("link[rel=stylesheet]"),t=!1,n=!0,r=!1,o=void 0;try{for(var u,c=e[Symbol.iterator]();!(n=(u=c.next()).done);n=!0)"/assets/frontend/a11y.css/a11y-en.css"==u.value.attributes.href.nodeValue&&(t=!0)}catch(e){r=!0,o=e}finally{try{n||null==c.return||c.return()}finally{if(r)throw o}}return t}document.querySelector('input[name="a11y.css"]').addEventListener("change",function(){this.checked?function(){if(0==r()){var e=document.createElement("link");e.setAttribute("rel","stylesheet"),e.setAttribute("href","/assets/frontend/a11y.css/a11y-en.css"),document.querySelector("head").appendChild(e)}}():function(){if(1==r()){var e=document.querySelector('link[href="/assets/frontend/a11y.css/a11y-en.css"]');document.querySelector("head").removeChild(e)}}()})}});
|
||||
!function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},n.r=function(e){Object.defineProperty(e,"__esModule",{value:!0})},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=10)}({10:function(e,t,n){"use strict";function r(){var e=document.querySelectorAll("link[rel=stylesheet]"),t=!1,n=!0,r=!1,o=void 0;try{for(var u,c=e[Symbol.iterator]();!(n=(u=c.next()).done);n=!0)"/assets/frontend/a11y.css/a11y-en.css"==u.value.attributes.href.nodeValue&&(t=!0)}catch(e){r=!0,o=e}finally{try{n||null==c.return||c.return()}finally{if(r)throw o}}return t}document.querySelector('input[name="a11y.css"]').addEventListener("change",function(){this.checked?function(){if(0==r()){var e=document.createElement("link");e.setAttribute("rel","stylesheet"),e.setAttribute("href","/assets/frontend/a11y.css/a11y-en.css"),document.querySelector("head").appendChild(e)}}():function(){if(1==r()){var e=document.querySelector('link[href="/assets/frontend/a11y.css/a11y-en.css"]');document.querySelector("head").removeChild(e)}}()})}});
|
||||
//# sourceMappingURL=a11y.js.map
|
Binary file not shown.
Binary file not shown.
File diff suppressed because one or more lines are too long
2
public/assets/js/colours.js
vendored
2
public/assets/js/colours.js
vendored
|
@ -1,2 +1,2 @@
|
|||
!function(e){var t={};function r(o){if(t[o])return t[o].exports;var n=t[o]={i:o,l:!1,exports:{}};return e[o].call(n.exports,n,n.exports,r),n.l=!0,n.exports}r.m=e,r.c=t,r.d=function(e,t,o){r.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:o})},r.r=function(e){Object.defineProperty(e,"__esModule",{value:!0})},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=10)}({10:function(e,t,r){"use strict";var o=document.querySelector("#colourScheme").getAttribute("href").split("/").pop();document.getElementById("colourSchemeSelect").value=o;var n=document.getElementById("colourSchemeForm");n.childNodes[5].addEventListener("click",function(e){e.preventDefault();var t=document.getElementById("colourSchemeSelect").value,r=document.querySelector("#colourScheme"),o=r.getAttribute("href").split("/");o.pop(),o.push(t),r.setAttribute("href",o.join("/"));var c=new FormData(n);fetch("/update-colour-scheme",{method:"POST",credentials:"same-origin",body:c}).catch(function(e){console.warn(e)})})}});
|
||||
!function(e){var t={};function r(o){if(t[o])return t[o].exports;var n=t[o]={i:o,l:!1,exports:{}};return e[o].call(n.exports,n,n.exports,r),n.l=!0,n.exports}r.m=e,r.c=t,r.d=function(e,t,o){r.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:o})},r.r=function(e){Object.defineProperty(e,"__esModule",{value:!0})},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=9)}({9:function(e,t,r){"use strict";var o=document.querySelector("#colourScheme").getAttribute("href").split("/").pop();document.getElementById("colourSchemeSelect").value=o;var n=document.getElementById("colourSchemeForm");n.childNodes[5].addEventListener("click",function(e){e.preventDefault();var t=document.getElementById("colourSchemeSelect").value,r=document.querySelector("#colourScheme"),o=r.getAttribute("href").split("/");o.pop(),o.push(t),r.setAttribute("href",o.join("/"));var c=new FormData(n);fetch("/update-colour-scheme",{method:"POST",credentials:"same-origin",body:c}).catch(function(e){console.warn(e)})})}});
|
||||
//# sourceMappingURL=colours.js.map
|
Binary file not shown.
Binary file not shown.
|
@ -1 +1 @@
|
|||
{"version":3,"sources":["webpack:///webpack/bootstrap","webpack:///colours.js"],"names":["installedModules","__webpack_require__","moduleId","exports","module","i","l","modules","call","m","c","d","name","getter","o","Object","defineProperty","configurable","enumerable","get","r","value","n","__esModule","default","object","property","prototype","hasOwnProperty","p","s","10","e","t","css","document","querySelector","getAttribute","split","pop","getElementById","form","childNodes","addEventListener","preventDefault","newCss","link","parts","push","setAttribute","join","formData","FormData","fetch","method","credentials","body","catch","error","console","warn"],"mappings":"aACA,IAAAA,EAAAA,GAGA,SAAAC,EAAAC,GAGA,GAAAF,EAAAE,GACA,OAAAF,EAAAE,GAAAC,QAGA,IAAAC,EAAAJ,EAAAE,GAAAA,CACAG,EAAAH,EACAI,GAAAA,EACAH,QAAAA,IAUA,OANAI,EAAAL,GAAAM,KAAAJ,EAAAD,QAAAC,EAAAA,EAAAD,QAAAF,GAGAG,EAAAE,GAAAA,EAGAF,EAAAD,QAKAF,EAAAQ,EAAAF,EAGAN,EAAAS,EAAAV,EAGAC,EAAAU,EAAA,SAAAR,EAAAS,EAAAC,GACAZ,EAAAa,EAAAX,EAAAS,IACAG,OAAAC,eAAAb,EAAAS,EAAAA,CACAK,cAAAA,EACAC,YAAAA,EACAC,IAAAN,KAMAZ,EAAAmB,EAAA,SAAAjB,GACAY,OAAAC,eAAAb,EAAA,aAAA,CAAiDkB,OAAAA,KAIjDpB,EAAAqB,EAAA,SAAAlB,GACA,IAAAS,EAAAT,GAAAA,EAAAmB,WACA,WAA2B,OAAAnB,EAAAoB,SAC3B,WAAiC,OAAApB,GAEjC,OADAH,EAAAU,EAAAE,EAAA,IAAAA,GACAA,GAIAZ,EAAAa,EAAA,SAAAW,EAAAC,GAAsD,OAAAX,OAAAY,UAAAC,eAAApB,KAAAiB,EAAAC,IAGtDzB,EAAA4B,EAAA,GAIA5B,EAAAA,EAAA6B,EAAA,KAAA,CAAAC,GAAA,SAAAC,EAAAC,EAAAb,GAAA,aCjEA,IAEIc,EAFOC,SAASC,cAAc,iBAEnBC,aAAa,QAAQC,MAAM,KAAKC,MAG/CJ,SAASK,eAAe,sBAAsBnB,MAAQa,EAGtD,IAAIO,EAAON,SAASK,eAAe,oBACzBC,EAAKC,WAAW,GACtBC,iBAAiB,QAAS,SAAUX,GACpCA,EAAEY,iBACF,IAAIC,EAASV,SAASK,eAAe,sBAAsBnB,MACvDyB,EAAOX,SAASC,cAAc,iBAE9BW,EADMD,EAAKT,aAAa,QACZC,MAAM,KACtBS,EAAMR,MACNQ,EAAMC,KAAKH,GACXC,EAAKG,aAAa,OAAQF,EAAMG,KAAK,MACrC,IAAIC,EAAW,IAAIC,SAASX,GAC5BY,MAAM,wBAAA,CACFC,OAAQ,OACRC,YAAa,cACbC,KAAML,IACPM,MAAM,SAAUC,GACfC,QAAQC,KAAKF","file":"public/assets/js/colours.js.map","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, {\n \t\t\t\tconfigurable: false,\n \t\t\t\tenumerable: true,\n \t\t\t\tget: getter\n \t\t\t});\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 10);\n","//colours.js\n\nlet link = document.querySelector('#colourScheme');\n\nlet css = link.getAttribute('href').split('/').pop();\n\n// update selected item in colour scheme list\ndocument.getElementById('colourSchemeSelect').value = css;\n\n// fix form\nlet form = document.getElementById('colourSchemeForm');\nlet btn = form.childNodes[5];\nbtn.addEventListener('click', function (e) {\n e.preventDefault();\n let newCss = document.getElementById('colourSchemeSelect').value;\n let link = document.querySelector('#colourScheme');\n let css = link.getAttribute('href');\n let parts = css.split('/');\n parts.pop();\n parts.push(newCss);\n link.setAttribute('href', parts.join('/'));\n let formData = new FormData(form);\n fetch('/update-colour-scheme', {\n method: 'POST',\n credentials: 'same-origin',\n body: formData\n }).catch(function (error) {\n console.warn(error);\n });\n});\n"]}
|
||||
{"version":3,"sources":["webpack:///webpack/bootstrap","webpack:///colours.js"],"names":["installedModules","__webpack_require__","moduleId","exports","module","i","l","modules","call","m","c","d","name","getter","o","Object","defineProperty","configurable","enumerable","get","r","value","n","__esModule","default","object","property","prototype","hasOwnProperty","p","s","9","e","t","css","document","querySelector","getAttribute","split","pop","getElementById","form","childNodes","addEventListener","preventDefault","newCss","link","parts","push","setAttribute","join","formData","FormData","fetch","method","credentials","body","catch","error","console","warn"],"mappings":"aACA,IAAAA,EAAAA,GAGA,SAAAC,EAAAC,GAGA,GAAAF,EAAAE,GACA,OAAAF,EAAAE,GAAAC,QAGA,IAAAC,EAAAJ,EAAAE,GAAAA,CACAG,EAAAH,EACAI,GAAAA,EACAH,QAAAA,IAUA,OANAI,EAAAL,GAAAM,KAAAJ,EAAAD,QAAAC,EAAAA,EAAAD,QAAAF,GAGAG,EAAAE,GAAAA,EAGAF,EAAAD,QAKAF,EAAAQ,EAAAF,EAGAN,EAAAS,EAAAV,EAGAC,EAAAU,EAAA,SAAAR,EAAAS,EAAAC,GACAZ,EAAAa,EAAAX,EAAAS,IACAG,OAAAC,eAAAb,EAAAS,EAAAA,CACAK,cAAAA,EACAC,YAAAA,EACAC,IAAAN,KAMAZ,EAAAmB,EAAA,SAAAjB,GACAY,OAAAC,eAAAb,EAAA,aAAA,CAAiDkB,OAAAA,KAIjDpB,EAAAqB,EAAA,SAAAlB,GACA,IAAAS,EAAAT,GAAAA,EAAAmB,WACA,WAA2B,OAAAnB,EAAAoB,SAC3B,WAAiC,OAAApB,GAEjC,OADAH,EAAAU,EAAAE,EAAA,IAAAA,GACAA,GAIAZ,EAAAa,EAAA,SAAAW,EAAAC,GAAsD,OAAAX,OAAAY,UAAAC,eAAApB,KAAAiB,EAAAC,IAGtDzB,EAAA4B,EAAA,GAIA5B,EAAAA,EAAA6B,EAAA,IAAA,CAAAC,EAAA,SAAAC,EAAAC,EAAAb,GAAA,aCjEA,IAEIc,EAFOC,SAASC,cAAc,iBAEnBC,aAAa,QAAQC,MAAM,KAAKC,MAG/CJ,SAASK,eAAe,sBAAsBnB,MAAQa,EAGtD,IAAIO,EAAON,SAASK,eAAe,oBACzBC,EAAKC,WAAW,GACtBC,iBAAiB,QAAS,SAAUX,GACpCA,EAAEY,iBACF,IAAIC,EAASV,SAASK,eAAe,sBAAsBnB,MACvDyB,EAAOX,SAASC,cAAc,iBAE9BW,EADMD,EAAKT,aAAa,QACZC,MAAM,KACtBS,EAAMR,MACNQ,EAAMC,KAAKH,GACXC,EAAKG,aAAa,OAAQF,EAAMG,KAAK,MACrC,IAAIC,EAAW,IAAIC,SAASX,GAC5BY,MAAM,wBAAA,CACFC,OAAQ,OACRC,YAAa,cACbC,KAAML,IACPM,MAAM,SAAUC,GACfC,QAAQC,KAAKF","file":"public/assets/js/colours.js.map","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, {\n \t\t\t\tconfigurable: false,\n \t\t\t\tenumerable: true,\n \t\t\t\tget: getter\n \t\t\t});\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 9);\n","//colours.js\n\nlet link = document.querySelector('#colourScheme');\n\nlet css = link.getAttribute('href').split('/').pop();\n\n// update selected item in colour scheme list\ndocument.getElementById('colourSchemeSelect').value = css;\n\n// fix form\nlet form = document.getElementById('colourSchemeForm');\nlet btn = form.childNodes[5];\nbtn.addEventListener('click', function (e) {\n e.preventDefault();\n let newCss = document.getElementById('colourSchemeSelect').value;\n let link = document.querySelector('#colourScheme');\n let css = link.getAttribute('href');\n let parts = css.split('/');\n parts.pop();\n parts.push(newCss);\n link.setAttribute('href', parts.join('/'));\n let formData = new FormData(form);\n fetch('/update-colour-scheme', {\n method: 'POST',\n credentials: 'same-origin',\n body: formData\n }).catch(function (error) {\n console.warn(error);\n });\n});\n"]}
|
2
public/assets/js/links.js
vendored
2
public/assets/js/links.js
vendored
|
@ -1,2 +1,2 @@
|
|||
!function(t){var e={};function r(n){if(e[n])return e[n].exports;var o=e[n]={i:n,l:!1,exports:{}};return t[n].call(o.exports,o,o.exports,r),o.l=!0,o.exports}r.m=t,r.c=e,r.d=function(t,e,n){r.o(t,e)||Object.defineProperty(t,e,{configurable:!1,enumerable:!0,get:n})},r.r=function(t){Object.defineProperty(t,"__esModule",{value:!0})},r.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(e,"a",e),e},r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r.p="",r(r.s=9)}({9:function(t,e,r){"use strict";var n=/watch\?v=([A-Za-z0-9\-_]+)\b/,o=/https:\/\/play\.spotify\.com\/(.*)\b/,a=document.querySelectorAll(".e-content"),u=!0,c=!1,i=void 0;try{for(var l,s=a[Symbol.iterator]();!(u=(l=s.next()).done);u=!0){var d=l.value,f=d.textContent.match(n);if(f){var p=document.createElement("div");p.classList.add("container");var m=document.createElement("iframe");m.classList.add("youtube"),m.setAttribute("src","https://www.youtube.com/embed/"+f[1]),m.setAttribute("frameborder",0),m.setAttribute("allowfullscreen","true"),p.appendChild(m),d.appendChild(p)}var b=d.textContent.match(o);if(b){var y=b[1].replace("/",":"),v=document.createElement("iframe");v.classList.add("spotify"),v.setAttribute("src","https://embed.spotify.com/?uri=spotify:"+y),v.setAttribute("frameborder",0),v.setAttribute("allowtransparency","true"),d.appendChild(v)}}}catch(t){c=!0,i=t}finally{try{u||null==s.return||s.return()}finally{if(c)throw i}}}});
|
||||
!function(t){var e={};function r(n){if(e[n])return e[n].exports;var o=e[n]={i:n,l:!1,exports:{}};return t[n].call(o.exports,o,o.exports,r),o.l=!0,o.exports}r.m=t,r.c=e,r.d=function(t,e,n){r.o(t,e)||Object.defineProperty(t,e,{configurable:!1,enumerable:!0,get:n})},r.r=function(t){Object.defineProperty(t,"__esModule",{value:!0})},r.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(e,"a",e),e},r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r.p="",r(r.s=8)}({8:function(t,e,r){"use strict";var n=/watch\?v=([A-Za-z0-9\-_]+)\b/,o=/https:\/\/play\.spotify\.com\/(.*)\b/,a=document.querySelectorAll(".e-content"),u=!0,c=!1,i=void 0;try{for(var l,s=a[Symbol.iterator]();!(u=(l=s.next()).done);u=!0){var d=l.value,f=d.textContent.match(n);if(f){var p=document.createElement("div");p.classList.add("container");var m=document.createElement("iframe");m.classList.add("youtube"),m.setAttribute("src","https://www.youtube.com/embed/"+f[1]),m.setAttribute("frameborder",0),m.setAttribute("allowfullscreen","true"),p.appendChild(m),d.appendChild(p)}var b=d.textContent.match(o);if(b){var y=b[1].replace("/",":"),v=document.createElement("iframe");v.classList.add("spotify"),v.setAttribute("src","https://embed.spotify.com/?uri=spotify:"+y),v.setAttribute("frameborder",0),v.setAttribute("allowtransparency","true"),d.appendChild(v)}}}catch(t){c=!0,i=t}finally{try{u||null==s.return||s.return()}finally{if(c)throw i}}}});
|
||||
//# sourceMappingURL=links.js.map
|
Binary file not shown.
Binary file not shown.
File diff suppressed because one or more lines are too long
2
public/assets/js/maps.js
vendored
2
public/assets/js/maps.js
vendored
File diff suppressed because one or more lines are too long
Binary file not shown.
Binary file not shown.
File diff suppressed because one or more lines are too long
Binary file not shown.
2
public/assets/js/piwik.js
vendored
2
public/assets/js/piwik.js
vendored
|
@ -1,2 +1,2 @@
|
|||
!function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},n.r=function(e){Object.defineProperty(e,"__esModule",{value:!0})},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=7)}({6:function(e,t){var n,r,o=e.exports={};function i(){throw new Error("setTimeout has not been defined")}function u(){throw new Error("clearTimeout has not been defined")}function c(e){if(n===setTimeout)return setTimeout(e,0);if((n===i||!n)&&setTimeout)return n=setTimeout,setTimeout(e,0);try{return n(e,0)}catch(t){try{return n.call(null,e,0)}catch(t){return n.call(this,e,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:i}catch(e){n=i}try{r="function"==typeof clearTimeout?clearTimeout:u}catch(e){r=u}}();var s,a=[],l=!1,f=-1;function h(){l&&s&&(l=!1,s.length?a=s.concat(a):f=-1,a.length&&p())}function p(){if(!l){var e=c(h);l=!0;for(var t=a.length;t;){for(s=a,a=[];++f<t;)s&&s[f].run();f=-1,t=a.length}s=null,l=!1,function(e){if(r===clearTimeout)return clearTimeout(e);if((r===u||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(e);try{r(e)}catch(t){try{return r.call(null,e)}catch(t){return r.call(this,e)}}}(e)}}function d(e,t){this.fun=e,this.array=t}function m(){}o.nextTick=function(e){var t=new Array(arguments.length-1);if(1<arguments.length)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];a.push(new d(e,t)),1!==a.length||l||c(p)},d.prototype.run=function(){this.fun.apply(null,this.array)},o.title="browser",o.browser=!0,o.env={},o.argv=[],o.version="",o.versions={},o.on=m,o.addListener=m,o.once=m,o.off=m,o.removeListener=m,o.removeAllListeners=m,o.emit=m,o.prependListener=m,o.prependOnceListener=m,o.listeners=function(e){return[]},o.binding=function(e){throw new Error("process.binding is not supported")},o.cwd=function(){return"/"},o.chdir=function(e){throw new Error("process.chdir is not supported")},o.umask=function(){return 0}},7:function(e,t,n){"use strict";(function(e){var t=e.env.PIWIK_ID,n=e.env.PIWIK_URL,r=r||[];r.push(["setTrackerUrl",n]),r.push(["setSiteId",t]),r.push(["trackPageView"]),r.push(["enableLinkTracking"])}).call(this,n(6))}});
|
||||
!function(e){var t={};function r(n){if(t[n])return t[n].exports;var u=t[n]={i:n,l:!1,exports:{}};return e[n].call(u.exports,u,u.exports,r),u.l=!0,u.exports}r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:n})},r.r=function(e){Object.defineProperty(e,"__esModule",{value:!0})},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=6)}({6:function(e,t,r){"use strict";var n=n||[];n.push(["setTrackerUrl","https://analytics.jmb.lv/piwik.php"]),n.push(["setSiteId","1"]),n.push(["trackPageView"]),n.push(["enableLinkTracking"])}});
|
||||
//# sourceMappingURL=piwik.js.map
|
Binary file not shown.
Binary file not shown.
File diff suppressed because one or more lines are too long
Binary file not shown.
File diff suppressed because one or more lines are too long
166
public/assets/prism/prism.css
vendored
166
public/assets/prism/prism.css
vendored
|
@ -1,166 +0,0 @@
|
|||
/* http://prismjs.com/download.html?themes=prism-okaidia&languages=markup+css+clike+javascript+bash+c+csharp+cpp+ruby+css-extras+diff+git+go+http+ini+json+latex+lua+makefile+markdown+nginx+objectivec+php+php-extras+python+rust+sass+scss+sql+swift+vim+wiki+yaml&plugins=line-numbers+autolinker */
|
||||
/**
|
||||
* okaidia theme for JavaScript, CSS and HTML
|
||||
* Loosely based on Monokai textmate theme by http://www.monokai.nl/
|
||||
* @author ocodia
|
||||
*/
|
||||
|
||||
code[class*="language-"],
|
||||
pre[class*="language-"] {
|
||||
color: #f8f8f2;
|
||||
background: none;
|
||||
text-shadow: 0 1px rgba(0, 0, 0, 0.3);
|
||||
font-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace;
|
||||
text-align: left;
|
||||
white-space: pre;
|
||||
word-spacing: normal;
|
||||
word-break: normal;
|
||||
word-wrap: normal;
|
||||
line-height: 1.5;
|
||||
|
||||
-moz-tab-size: 4;
|
||||
-o-tab-size: 4;
|
||||
tab-size: 4;
|
||||
|
||||
-webkit-hyphens: none;
|
||||
-moz-hyphens: none;
|
||||
-ms-hyphens: none;
|
||||
hyphens: none;
|
||||
}
|
||||
|
||||
/* Code blocks */
|
||||
pre[class*="language-"] {
|
||||
padding: 1em;
|
||||
margin: .5em 0;
|
||||
overflow: auto;
|
||||
border-radius: 0.3em;
|
||||
}
|
||||
|
||||
:not(pre) > code[class*="language-"],
|
||||
pre[class*="language-"] {
|
||||
background: #272822;
|
||||
}
|
||||
|
||||
/* Inline code */
|
||||
:not(pre) > code[class*="language-"] {
|
||||
padding: .1em;
|
||||
border-radius: .3em;
|
||||
white-space: normal;
|
||||
}
|
||||
|
||||
.token.comment,
|
||||
.token.prolog,
|
||||
.token.doctype,
|
||||
.token.cdata {
|
||||
color: slategray;
|
||||
}
|
||||
|
||||
.token.punctuation {
|
||||
color: #f8f8f2;
|
||||
}
|
||||
|
||||
.namespace {
|
||||
opacity: .7;
|
||||
}
|
||||
|
||||
.token.property,
|
||||
.token.tag,
|
||||
.token.constant,
|
||||
.token.symbol,
|
||||
.token.deleted {
|
||||
color: #f92672;
|
||||
}
|
||||
|
||||
.token.boolean,
|
||||
.token.number {
|
||||
color: #ae81ff;
|
||||
}
|
||||
|
||||
.token.selector,
|
||||
.token.attr-name,
|
||||
.token.string,
|
||||
.token.char,
|
||||
.token.builtin,
|
||||
.token.inserted {
|
||||
color: #a6e22e;
|
||||
}
|
||||
|
||||
.token.operator,
|
||||
.token.entity,
|
||||
.token.url,
|
||||
.language-css .token.string,
|
||||
.style .token.string,
|
||||
.token.variable {
|
||||
color: #f8f8f2;
|
||||
}
|
||||
|
||||
.token.atrule,
|
||||
.token.attr-value,
|
||||
.token.function {
|
||||
color: #e6db74;
|
||||
}
|
||||
|
||||
.token.keyword {
|
||||
color: #66d9ef;
|
||||
}
|
||||
|
||||
.token.regex,
|
||||
.token.important {
|
||||
color: #fd971f;
|
||||
}
|
||||
|
||||
.token.important,
|
||||
.token.bold {
|
||||
font-weight: bold;
|
||||
}
|
||||
.token.italic {
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
.token.entity {
|
||||
cursor: help;
|
||||
}
|
||||
|
||||
pre.line-numbers {
|
||||
position: relative;
|
||||
padding-left: 3.8em;
|
||||
counter-reset: linenumber;
|
||||
}
|
||||
|
||||
pre.line-numbers > code {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.line-numbers .line-numbers-rows {
|
||||
position: absolute;
|
||||
pointer-events: none;
|
||||
top: 0;
|
||||
font-size: 100%;
|
||||
left: -3.8em;
|
||||
width: 3em; /* works for line-numbers below 1000 lines */
|
||||
letter-spacing: -1px;
|
||||
border-right: 1px solid #999;
|
||||
|
||||
-webkit-user-select: none;
|
||||
-moz-user-select: none;
|
||||
-ms-user-select: none;
|
||||
user-select: none;
|
||||
|
||||
}
|
||||
|
||||
.line-numbers-rows > span {
|
||||
pointer-events: none;
|
||||
display: block;
|
||||
counter-increment: linenumber;
|
||||
}
|
||||
|
||||
.line-numbers-rows > span:before {
|
||||
content: counter(linenumber);
|
||||
color: #999;
|
||||
display: block;
|
||||
padding-right: 0.8em;
|
||||
text-align: right;
|
||||
}
|
||||
.token a {
|
||||
color: inherit;
|
||||
}
|
Binary file not shown.
Binary file not shown.
37
public/assets/prism/prism.js
vendored
37
public/assets/prism/prism.js
vendored
File diff suppressed because one or more lines are too long
Binary file not shown.
Binary file not shown.
6
resources/assets/sass/_articles.scss
vendored
Normal file
6
resources/assets/sass/_articles.scss
vendored
Normal file
|
@ -0,0 +1,6 @@
|
|||
//articles.scss
|
||||
|
||||
.h-entry pre code {
|
||||
padding: 1.5rem 2rem;
|
||||
border-radius: 4px;
|
||||
}
|
5
resources/assets/sass/_notes.scss
vendored
5
resources/assets/sass/_notes.scss
vendored
|
@ -25,5 +25,10 @@
|
|||
height: 1em;
|
||||
}
|
||||
|
||||
.note pre code {
|
||||
padding: 1.5rem 2rem;
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
//style the pagination links
|
||||
@import "pagination";
|
||||
|
|
1
resources/assets/sass/app.scss
vendored
1
resources/assets/sass/app.scss
vendored
|
@ -12,6 +12,7 @@
|
|||
//layouts
|
||||
@import "header";
|
||||
@import "main";
|
||||
@import "articles";
|
||||
@import "notes";
|
||||
@import "contacts-page";
|
||||
@import "projects";
|
||||
|
|
|
@ -29,6 +29,5 @@
|
|||
@stop
|
||||
|
||||
@section('scripts')
|
||||
<script src="/assets/prism/prism.js"></script>
|
||||
<link rel="stylesheet" href="/assets/prism/prism.css">
|
||||
<link rel="stylesheet" href="/assets/highlight/zenburn.css">
|
||||
@stop
|
||||
|
|
|
@ -17,6 +17,5 @@
|
|||
@stop
|
||||
|
||||
@section('scripts')
|
||||
<script src="/assets/prism/prism.js"></script>
|
||||
<link rel="stylesheet" href="/assets/prism/prism.css">
|
||||
<link rel="stylesheet" href="/assets/highlight/zenburn.css">
|
||||
@stop
|
||||
|
|
|
@ -19,11 +19,8 @@
|
|||
@if (Request::path() == '/')@include('templates.bio')@endif
|
||||
|
||||
@section('scripts')
|
||||
|
||||
<link rel="stylesheet" href="/assets/highlight/zenburn.css">
|
||||
<script defer src="/assets/js/links.js"></script>
|
||||
<link rel="stylesheet" href="/assets/frontend/mapbox-gl.css">
|
||||
<script defer src="/assets/js/maps.js"></script>
|
||||
|
||||
<script defer src="/assets/prism/prism.js"></script>
|
||||
<link rel="stylesheet" href="/assets/prism/prism.css">
|
||||
@stop
|
||||
|
|
|
@ -45,11 +45,8 @@
|
|||
@stop
|
||||
|
||||
@section('scripts')
|
||||
|
||||
<link rel="stylesheet" href="/assets/highlight/zenburn.css">
|
||||
<script defer src="/assets/js/links.js"></script>
|
||||
<link rel="stylesheet" href="/assets/frontend/mapbox-gl.css">
|
||||
<script defer src="/assets/js/maps.js"></script>
|
||||
|
||||
<script src="/assets/prism/prism.js"></script>
|
||||
<link rel="stylesheet" href="/assets/prism/prism.css">
|
||||
@stop
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Reference in a new issue