Merge remote-tracking branch 'remotes/origin/d3version'

This commit is contained in:
Daniel Seifert 2018-09-07 13:01:00 +02:00
commit 7e53ad4b4a
69 changed files with 3828 additions and 534 deletions

View File

@ -1,5 +1,5 @@
{
"name": "daux/daux.io",
"name": "d3/daux.io",
"type": "project",
"license": "MIT",
"description": "Documentation generator that uses a simple folder structure and Markdown files to create custom documentation on the fly",

192
daux/d3processor.php Normal file
View File

@ -0,0 +1,192 @@
<?php
namespace Todaymade\Daux\Extension;
use League\CommonMark\Block\Element\BlockQuote;
use League\CommonMark\Block\Element\Document;
use League\CommonMark\Block\Element\Paragraph;
use League\CommonMark\Environment;
use League\CommonMark\ElementRendererInterface;
use League\CommonMark\InlineParserContext;
use League\CommonMark\HtmlElement;
use League\CommonMark\Inline\Parser\AbstractInlineParser;
use League\CommonMark\Block\Renderer\BlockRendererInterface;
use League\CommonMark\Inline\Renderer\InlineRendererInterface;
USE League\CommonMark\Block\Element\AbstractBlock;
USE League\CommonMark\Inline\Element\AbstractInline;
use League\CommonMark\Inline\Element\Code;
use League\CommonMark\Inline\Element\Text;
use League\CommonMark\Util\Configuration;
use Todaymade\Daux\Daux;
use Symfony\Component\Console\Output\NullOutput;
class d3Parser extends AbstractInlineParser
{
public function getCharacters() {
return ['v', 'V'];
}
public function parse(InlineParserContext $inlineContext)
{
$cursor = $inlineContext->getCursor();
if ($cursor->match('/D3/')) {
$inlineContext->getContainer()->appendChild(new Code('d3logo'));
return true;
}
return false;
}
}
class d3BlockQuoteRenderer implements BlockRendererInterface
{
public function render(AbstractBlock $block, ElementRendererInterface $htmlRenderer, $inTightList = false)
{
if (!($block instanceof BlockQuote)) {
throw new \InvalidArgumentException('Incompatible block type: ' . get_class($block));
}
$attrs = [];
foreach ($block->getData('attributes', []) as $key => $value) {
$attrs[$key] = $htmlRenderer->escape($value, true);
}
$filling = $htmlRenderer->renderBlocks($block->children());
if ($filling === '') {
return new HtmlElement('blockquote', $attrs, $htmlRenderer->getOption('inner_separator', "\n"));
}
if (stristr($filling, '[!!]')) {
$attrs['class'] = isset($attrs['class']) ? $attrs['class'].' alert alert-danger' : 'alert alert-danger';
$filling = "<i class='fas fa-exclamation-circle'></i> ".trim(str_replace('[!!]', '', $filling));
}
if (stristr($filling, '[!]')) {
$attrs['class'] = isset($attrs['class']) ? $attrs['class'].' alert alert-warning' : 'alert alert-warning';
$filling = "<i class='fas fa-exclamation-triangle'></i> ".trim(str_replace('[!]', '', $filling));
}
if (stristr($filling, '[i]')) {
$attrs['class'] = isset($attrs['class']) ? $attrs['class'].' alert alert-info' : 'alert alert-info';
$filling = "<i class='fas fa-info-circle'></i> ".trim(str_replace('[i]', '', $filling));
}
return new HtmlElement(
'blockquote',
$attrs,
$htmlRenderer->getOption('inner_separator', "\n") . $filling . $htmlRenderer->getOption('inner_separator', "\n")
);
}
}
class d3ParagraphRenderer implements BlockRendererInterface
{
public function render(AbstractBlock $block, ElementRendererInterface $htmlRenderer, $inTightList = false)
{
if (!($block instanceof Paragraph)) {
throw new \InvalidArgumentException('Incompatible block type: ' . get_class($block));
}
$pattern1 = '/\[\s*?(.{3,})\s*?\]/Uis';
$replace1 = '<span class="navi_element">\\1</span>';
if ($inTightList) {
$content = $htmlRenderer->renderInlines($block->children());
$content = preg_replace($pattern1, $replace1, $content);
return $content;
} else {
$attrs = [];
foreach ($block->getData('attributes', []) as $key => $value) {
$attrs[$key] = $htmlRenderer->escape($value, true);
}
$content = $htmlRenderer->renderInlines($block->children());
$content = preg_replace($pattern1, $replace1, $content);
return new HtmlElement('p', $attrs, $content);
}
}
}
class d3DocumentRenderer implements BlockRendererInterface
{
public function render(AbstractBlock $block, ElementRendererInterface $htmlRenderer, $inTightList = false)
{
if (!($block instanceof Document)) {
throw new \InvalidArgumentException('Incompatible block type: ' . get_class($block));
}
$wholeDoc = $htmlRenderer->renderBlocks($block->children());
$output = new NullOutput();
$daux = new Daux(Daux::STATIC_MODE, $output);
foreach ($_SERVER['argv'] as $arg) {
if (stristr($arg, '--source=')) {
$docsdir = trim(str_replace('--source=', '', $arg));
$daux->getParams()->setDocumentationDirectory($docsdir);
}
}
$daux->initializeConfiguration();
$params = $daux->getParams();
if (isset($params['variables'])) {
$variables = $params['variables'];
if (isset($variables) && is_array($variables) && count($variables)) {
foreach ($variables as $varname => $varvalue) {
$pattern = '/{\$'.$varname.'}/mU';
$wholeDoc = preg_replace($pattern, $varvalue, $wholeDoc);
}
}
}
return $wholeDoc === '' ? '' : $wholeDoc . "\n";
}
}
class d3TextRenderer implements InlineRendererInterface
{
/**
* @var Configuration
*/
protected $config;
/**
* @param AbstractInline $inline
* @param ElementRendererInterface $htmlRenderer
* @return HtmlElement|mixed|string
* @throws \Todaymade\Daux\Exception
*/
public function render(AbstractInline $inline, ElementRendererInterface $htmlRenderer)
{
if (!($inline instanceof Text)) {
throw new \InvalidArgumentException('Incompatible inline type: ' . get_class($inline));
}
$content = $htmlRenderer->escape($inline->getContent());
$search = array(
'D3', 'D³', 'D&sup3;'
);
$replace = "<i class='fab fa-d3 d3fa-color-blue'></i>";
$content = str_replace($search, $replace, $content);
return $content;
}
}
class d3processor extends \Todaymade\Daux\Processor
{
public function extendCommonMarkEnvironment(Environment $environment)
{
// format important and info code blocks
$environment->addBlockRenderer('League\CommonMark\Block\Element\BlockQuote', new d3BlockQuoteRenderer());
$environment->addBlockRenderer('League\CommonMark\Block\Element\Paragraph', new d3ParagraphRenderer());
$environment->addBlockRenderer('League\CommonMark\Block\Element\Document', new d3DocumentRenderer());
$environment->addInlineRenderer('League\CommonMark\Inline\Element\Text', new d3TextRenderer());
}
}

View File

@ -43,14 +43,22 @@ class GeneratorHelper
throw new RuntimeException("Cannot copy '$source' to '$destination'");
}
$aExclDirs = array(
'scss',
'templates'
);
$aExclFiles = array(
'config.json'
);
while (false !== ($file = readdir($dir))) {
if ($file != '.' && $file != '..') {
if (is_dir($source . DIRECTORY_SEPARATOR . $file)) {
if (is_dir($source . DIRECTORY_SEPARATOR . $file) && false == in_array($file, $aExclDirs)) {
static::copyRecursive(
$source . DIRECTORY_SEPARATOR . $file,
$destination . DIRECTORY_SEPARATOR . $file
);
} else {
} elseif (false == in_array($file, $aExclFiles)) {
copy($source . DIRECTORY_SEPARATOR . $file, $destination . DIRECTORY_SEPARATOR . $file);
}
}

10
themes/d3/config.json Normal file
View File

@ -0,0 +1,10 @@
{
"favicon": "<theme_url>img/favicon.png",
"css": ["<theme_url>css/theme-blue.min.css","<theme_url>css/d3.css"],
"js": [
"<theme_url>js/jquery-1.11.3.min.js",
"<theme_url>js/highlight.pack.js",
"<theme_url>js/daux.js",
"<theme_url>js/fontawesome-all.js"
]
}

198
themes/d3/css/d3.css Normal file
View File

@ -0,0 +1,198 @@
.s-content table th{
//background-color: #336ed6;
}
.Brand{
color: #fff;
}
.s-content p {
margin-bottom: 1.0em;
}
body,
.Homepage {
background-color: #f7f7f7;
}
.HomepageFooter{
color : #fff;
}
.HomepageFooter__links a{
color : #fff;
}
.HomepageFooter__links li{
color : #fff;
}
.SearchResults .SearchResults__url a,
a{
color: #028fe8;
}
.s-content pre {
background : #f5f5f5;
}
.svg-inline--fa.d3fa-color-blue, .fa.fa-d3color-blue {
color: #028fe8;
}
.Navbar .svg-inline--fa.d3fa-color-blue, .Navbar .fa.fa-d3color-blue,
.Brand .svg-inline--fa.d3fa-color-blue, .Brand .fa.fa-d3color-blue{
color: white;
}
.HomepageFooter__links li{
float: left;
min-width: 70px;
}
.HomepageFooter__links li a {
padding-right: 40px;
}
blockquote.alert a {
text-decoration: none !important;
font-weight: 700;
}
blockquote.alert.alert-danger {
color: #ce2c2c;
background-color: #f2dede;
border-color: #ce2c2c;
}
blockquote.alert.alert-danger a {
color: #843534;
}
blockquote.alert.alert-warning {
color: #e39c37;
background-color: #fcf8e3;
border-color: #e39c37;
}
blockquote.alert.alert-warning a {
color: #66512c;
}
blockquote.alert.alert-info {
color: #31708f;
background-color: #d9edf7;
border-color: #31708f;
}
blockquote.alert.alert-info a {
color: #245269;
}
blockquote.alert.alert-success {
color: #3c763d;
background-color: #dff0d8;
border-color: #d6e9c6;
}
blockquote.alert.alert-success a {
color: #2b542c;
}
.s-content blockquote.alert svg {
float: left;
margin: 4px 12px 0 0;
}
.HomepageTitle .title,
.HomepageTitle .details {
width: 80%;
margin: 40px auto;
max-width: 500px;
}
.HomepageTitle h2,
.HomepageTitle div {
width: auto;
margin: unset;
text-align: left;
}
.HomepageTitle h2 {
font-size: 43px;
}
.HomepageTitle div {
font-size: 24px;
}
.HomepageTitle .details div {
font-size: 15px;
}
aside .Links a {
font-size: 14px;
}
.Navbar,
.Brand,
.Links,
.Columns__left.Collapsible {
background-color: #028fe8;
}
.Navbar {
height: auto;
min-height: 50px;
display: inline-table;
width: 100%;
}
span.navi_element {
border: 1px #c5c5cb;
border-style: solid solid none;
border-radius: 5px 5px 0 0;
padding: 0 5px;
background-color: #f7f7f7;
}
.Nav {
background-color: #f7f7f7;
}
.Links a{
color: #f7f7f7;
}
.Links a:hover {
text-decoration: underline;
}
.Links hr {
border-color: #028fe8;
}
.HomepageFooter,
.Search {
background-color: #028fe8;
}
.Search {
margin: 10px;
}
li {
margin-bottom: 7px;
}
.Search__field {
border-radius: 4px;
}
.versionselector {
padding: 0 20px;
font-family: "Roboto Slab",-apple-system,".SFNSText-Regular","San Francisco","Roboto","Segoe UI","Helvetica Neue","Lucida Grande",Arial,sans-serif;
font-size: 14px;
color: #f7f7f7;
}

10
themes/d3/css/theme-blue.min.css vendored Normal file

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

Before

Width:  |  Height:  |  Size: 81 KiB

After

Width:  |  Height:  |  Size: 81 KiB

View File

Before

Width:  |  Height:  |  Size: 81 KiB

After

Width:  |  Height:  |  Size: 81 KiB

View File

Before

Width:  |  Height:  |  Size: 81 KiB

After

Width:  |  Height:  |  Size: 81 KiB

BIN
themes/d3/img/favicon.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.6 KiB

3082
themes/d3/js/fontawesome-all.js vendored Normal file

File diff suppressed because one or more lines are too long

View File

@ -391,7 +391,6 @@ ul.TableOfContents {
padding-left: 2.25em;
}
// stylelint-disable-next-line selector-max-compound-selectors
li li li li a {
padding-left: 3em;
}

View File

@ -0,0 +1,116 @@
<?php $this->layout('theme::layout/00_layout') ?>
<?php $this->start('classes') ?>homepage<?php $this->stop() ?>
<div class="Navbar NoPrint">
<div class="Container">
<?php $this->insert('theme::partials/navbar_content', ['params' => $params]); ?>
</div>
</div>
<div class="Homepage">
<div class="HomepageTitle Container">
<div class="title">
<?= ($params['title'])? '<h2>' . $params['title'] . '</h2>' : '' ?>
<?= ($params['titledesc'])? '<div>' . $params['titledesc'] . '</div>' : '' ?>
</div>
<?= ($params['image'])? '<img class="homepage-image img-responsive" src="' . $params['image'] . '" alt="' . $params['title'] . '">' : '' ?>
<div class="details">
<?= ($params['author'])? '<div>' . $this->translate("author") . ': ' . $params['author'] . '</div>' : '' ?>
<?= ($params['moduledate'])? '<div>' . $this->translate("moduledate") . ': ' . $params['moduledate'] . '</div>' : '' ?>
<?= ($params['moduleversion'])? '<div>' . $this->translate("version") . ': ' . $params['moduleversion'] . '</div>' : '' ?>
<?php
if (isset($params['versionselector']) && $params['versionselector'] &&
isset($params['versiondirectoryindex']) && $params['versiondirectoryindex']) {
echo "<div>";
echo $this->translate("selectversion").': ';
$code = '
<select onchange="window.location.href=this.options[this.selectedIndex].value" size="1">
<?php
$versionpath = implode("/", array_slice(explode("/", $_SERVER[\'SCRIPT_NAME\']), '. $params['versiondirectoryindex'] .'));
$modulepath = implode("/", array_slice(explode("/", $_SERVER[\'SCRIPT_NAME\']), 0, '. $params['versiondirectoryindex'] .'));
$path = str_replace($versionpath, "", $_SERVER[\'SCRIPT_FILENAME\']);
$paths = explode(\'/\', $versionpath);
$currpath = $paths[0];
$dirs = array_filter(glob($path . \'/*\'), \'is_dir\');
arsort($dirs);
foreach ($dirs as $dir) {
$dir = str_replace($path.\'/\', \'\', $dir);
$selected = ($dir === $currpath) ? \'selected="selected"\' : "";
echo \'<option value="\'. $modulepath .\'/\'. $dir .\'" \'. $selected .\'>\'. $dir .\'</option>\';
}
?>
';
echo $code;
echo "</select>";
echo "</div>";
}
?>
<?= ($params['editors'])? '<div>' . $this->translate("editors") . ': ' . $params['editors'] . '</div>' : '' ?>
</div>
</div>
<div class="HomepageButtons">
<div class="Container">
<?php
if ($params['html']['repo']) {
echo '<a href="https://github.com/' . $params['html']['repo'] . '" class="Button Button--secondary Button--hero">' . $this->translate("View_on_github") . '</a>';
}
$view_doc = $this->translate("View_documentation");
foreach ($page['entry_page'] as $key => $node) {
echo '<a href="' . $node . '" class="Button Button--primary Button--hero">' . str_replace("__VIEW_DOCUMENTATION__", $view_doc, $key) . '</a>';
}
if(isset($params['html']['buttons']) && is_array($params['html']['buttons'])) {
foreach ($params['html']['buttons'] as $name => $link ) {
echo '<a href="' . $link . '" class="Button Button--secondary Button--hero">' . $name . '</a>';
}
}
?>
</div>
</div>
</div>
<div class="HomepageContent">
<div class="Container">
<div class="Container--inner">
<div class="doc_content s-content">
<?= $page['content']; ?>
</div>
</div>
</div>
</div>
<div class="HomepageFooter">
<div class="Container">
<div class="Container--inner">
<?php if (!empty($params['html']['links'])) { ?>
<ul class="HomepageFooter__links">
<?php foreach ($params['html']['links'] as $name => $url) {
echo '<li><a href="' . $url . '" target="_blank">' . $name . '</a></li>';
} ?>
</ul>
<?php } ?>
<?php if (!empty($params['html']['twitter'])) { ?>
<div class="HomepageFooter__twitter">
<?php foreach ($params['html']['twitter'] as $handle) { ?>
<div class="Twitter">
<iframe allowtransparency="true" frameborder="0" scrolling="no" style="width:162px; height:20px;" src="https://platform.twitter.com/widgets/follow_button.html?screen_name=<?= $handle; ?>&amp;show_count=false"></iframe>
</div>
<?php } ?>
</div>
<?php } ?>
</div>
</div>
</div>

View File

@ -0,0 +1,80 @@
<!DOCTYPE html>
<html class="no-js" lang="<?=$params['language'] ?>">
<head>
<title><?= strip_tags($page['title']); ?> <?= ($page['title'] != $params['title'])? '- ' . strip_tags($params['title']) : "" ?></title>
<?php //SEO meta tags...
if (array_key_exists('attributes', $page) && array_key_exists('description', $page['attributes'])) {
echo " <meta name=\"description\" content=\"{$page['attributes']['description']}\">\n";
} elseif (array_key_exists('tagline', $params)) {
echo " <meta name=\"description\" content=\"{$params['tagline']}\">\n";
}
if (array_key_exists('attributes', $page) && array_key_exists('keywords', $page['attributes'])) {
echo " <meta name=\"keywords\" content=\"{$page['attributes']['keywords']}\">\n";
}
if (array_key_exists('attributes', $page) && array_key_exists('author', $page['attributes'])) {
echo " <meta name=\"author\" content=\"{$page['attributes']['author']}\">\n";
} elseif (array_key_exists('author', $params)) {
echo " <meta name=\"author\" content=\"{$params['author']}\">\n";
}
?>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<link rel="icon" href="<?= $params['theme']['favicon']; ?>" type="image/x-icon">
<!-- Mobile -->
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<!-- Font -->
<?php foreach ($params['theme']['fonts'] as $font) {
echo "<link href='$font' rel='stylesheet' type='text/css'>";
} ?>
<!-- CSS -->
<?php foreach ($params['theme']['css'] as $css) {
echo "<link href='$css' rel='stylesheet' type='text/css'>";
} ?>
<?php if ($params['html']['search']) { ?>
<!-- Tipue Search -->
<link href="<?= $base_url; ?>tipuesearch/tipuesearch.css" rel="stylesheet">
<?php } ?>
<!--[if lt IE 9]>
<script src="<?= $base_url; ?>themes/d3/js/html5shiv-3.7.3.min.js"></script>
<![endif]-->
</head>
<body class="<?= $params['html']['float'] ? 'with-float' : ''; ?> <?= $this->section('classes'); ?>">
<?= $this->section('content'); ?>
<?php
if ($params['html']['google_analytics']) {
$this->insert('theme::partials/google_analytics', ['analytics' => $params['html']['google_analytics'], 'host' => array_key_exists('host', $params) ? $params['host'] : '']);
}
if ($params['html']['piwik_analytics']) {
$this->insert('theme::partials/piwik_analytics', ['url' => $params['html']['piwik_analytics'], 'id' => $params['html']['piwik_analytics_id']]);
}
?>
<!-- JS -->
<?php foreach ($params['theme']['js'] as $js) {
echo '<script src="' . $js . '"></script>';
} ?>
<?php if ($params['html']['search']) { ?>
<!-- Tipue Search -->
<script type="text/javascript" src="<?php echo $base_url; ?>tipuesearch/tipuesearch.js"></script>
<script>
window.onunload = function(){}; // force $(document).ready to be called on back/forward navigation in firefox
$(function() {
tipuesearch({
'base_url': '<?php echo $base_url?>'
});
});
</script>
<?php } ?>
</body>
</html>

View File

@ -0,0 +1,117 @@
<?php $this->layout('theme::layout/00_layout') ?>
<div class="Columns content">
<aside class="Columns__left Collapsible">
<button type="button" class="Button Collapsible__trigger">
<span class="Collapsible__trigger__bar"></span>
<span class="Collapsible__trigger__bar"></span>
<span class="Collapsible__trigger__bar"></span>
</button>
<?php $this->insert('theme::partials/navbar_content', ['params' => $params]); ?>
<div class="Collapsible__content">
<!-- Navigation -->
<?php
$rendertree = $tree;
$path = '';
if ($page['language'] !== '') {
$rendertree = $tree[$page['language']];
$path = $page['language'];
}
echo $this->get_navigation($rendertree, $path, isset($params['request']) ? $params['request'] : '', $base_page, $params['mode']);
?>
<?php
if (isset($params['versionselector']) && $params['versionselector'] &&
isset($params['versiondirectoryindex']) && $params['versiondirectoryindex']) {
echo "<div class='versionselector'>";
echo $this->translate("selectversion").': ';
$code = '
<select onchange="window.location.href=this.options[this.selectedIndex].value" size="1">
<?php
$versionpath = implode("/", array_slice(explode("/", $_SERVER[\'SCRIPT_NAME\']), '. $params['versiondirectoryindex'] .'));
$modulepath = implode("/", array_slice(explode("/", $_SERVER[\'SCRIPT_NAME\']), 0, '. $params['versiondirectoryindex'] .'));
$path = str_replace($versionpath, "", $_SERVER[\'SCRIPT_FILENAME\']);
$paths = explode(\'/\', $versionpath);
$currpath = $paths[0];
$dirs = array_filter(glob($path . \'/*\'), \'is_dir\');
arsort($dirs);
foreach ($dirs as $dir) {
$dir = str_replace($path.\'/\', \'\', $dir);
$selected = ($dir === $currpath) ? \'selected="selected"\' : "";
echo \'<option value="\'. $modulepath .\'/\'. $dir .\'" \'. $selected .\'>\'. $dir .\'</option>\';
}
?>
';
echo $code;
echo "</select>";
echo "</div>";
}
?>
<div class="Links">
<?php if (!empty($params['html']['links'])) { ?>
<hr/>
<?php foreach ($params['html']['links'] as $name => $url) { ?>
<a href="<?= $url ?>" target="_blank"><?= $name ?></a>
<br />
<?php } ?>
<?php } ?>
</div>
<?php if ($params['html']['toggle_code']) { ?>
<div class="CodeToggler">
<hr/>
<?php if ($params['html']['float']) { ?>
<span class="CodeToggler__text"><?=$this->translate("CodeBlocks_title") ?></span>
<div class="ButtonGroup" role="group">
<button class="Button Button--default Button--small CodeToggler__button CodeToggler__button--hide"><?=$this->translate("CodeBlocks_hide") ?></button>
<button class="Button Button--default Button--small CodeToggler__button CodeToggler__button--below"><?=$this->translate("CodeBlocks_below") ?></button>
<button class="Button Button--default Button--small CodeToggler__button CodeToggler__button--float"><?=$this->translate("CodeBlocks_inline") ?></button>
</div>
<?php } else { ?>
<label class="Checkbox"><?=$this->translate("CodeBlocks_show") ?>
<input type="checkbox" class="CodeToggler__button--main" checked="checked"/>
<div class="Checkbox__indicator"></div>
</label>
<?php } ?>
</div>
<?php } ?>
<?php if (!empty($params['html']['twitter'])) { ?>
<div class="Twitter">
<hr/>
<?php foreach ($params['html']['twitter'] as $handle) { ?>
<iframe allowtransparency="true" frameborder="0" scrolling="no" style="width:162px; height:20px;" src="https://platform.twitter.com/widgets/follow_button.html?screen_name=<?= $handle; ?>&amp;show_count=false"></iframe>
<br />
<br />
<?php } ?>
</div>
<?php } ?>
<?php if (!empty($params['html']['powered_by'])) { ?>
<div class="PoweredBy">
<hr/>
<?= $params['html']['powered_by'] ?>
</div>
<?php } ?>
</div>
</aside>
<div class="Columns__right <?= $params['html']['float'] ? 'Columns__right--float' : 'Columns__right--full'; ?>">
<div class="Columns__right__content">
<div class="doc_content">
<?= $this->section('content'); ?>
</div>
</div>
</div>
</div>

View File

@ -0,0 +1,11 @@
<a class="Brand" href="<?= $params['base_page'] . $params['index']->getUri(); ?>"><?= ($page['title'] != $params['title']) ? $params['title'] : $params['author']; ?></a>
<?php if ($params['html']['search']) { ?>
<div class="Search">
<svg class="Search__icon" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 451 451">
<path d="M447.05 428l-109.6-109.6c29.4-33.8 47.2-77.9 47.2-126.1C384.65 86.2 298.35 0 192.35 0 86.25 0 .05 86.3.05 192.3s86.3 192.3 192.3 192.3c48.2 0 92.3-17.8 126.1-47.2L428.05 447c2.6 2.6 6.1 4 9.5 4s6.9-1.3 9.5-4c5.2-5.2 5.2-13.8 0-19zM26.95 192.3c0-91.2 74.2-165.3 165.3-165.3 91.2 0 165.3 74.2 165.3 165.3s-74.1 165.4-165.3 165.4c-91.1 0-165.3-74.2-165.3-165.4z"/>
</svg>
<input type="search" id="tipue_search_input" class="Search__field" placeholder="<?=$this->translate("Search_placeholder") ?>" autocomplete="on"
results=25 autosave=text_search>
</div>
<?php } ?>

View File

@ -1,26 +0,0 @@
{
"favicon": "<theme_url>img/favicon.png",
"js": [
"<theme_url>js/jquery-1.11.3.min.js",
"<theme_url>js/highlight.pack.js",
"<theme_url>js/daux.js"
],
"variants": {
"blue": {
"favicon": "<theme_url>img/favicon-blue.png",
"css": ["<theme_url>css/theme-blue.min.css"]
},
"green": {
"favicon": "<theme_url>img/favicon-green.png",
"css": ["<theme_url>css/theme-green.min.css"]
},
"navy": {
"favicon": "<theme_url>img/favicon-navy.png",
"css": ["<theme_url>css/theme-navy.min.css"]
},
"red": {
"favicon": "<theme_url>img/favicon-red.png",
"css": ["<theme_url>css/theme-red.min.css"]
}
}
}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.0 KiB

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1,58 +0,0 @@
:root {
--font-family-text: -apple-system,
".SFNSText-Regular",
"San Francisco",
"Roboto",
"Segoe UI",
"Helvetica Neue",
"Lucida Grande",
Arial,
sans-serif;
--font-family-monospace: Monaco, Menlo, Consolas, "Lucida Console", "Courier New", monospace;
--font-family-heading: "Roboto Slab", var(--font-family-text);
}
/*! Generated by Font Squirrel (https://www.fontsquirrel.com) */
@font-face {
font-family: "Roboto Slab";
font-style: normal;
font-weight: 300;
src: url("../fonts/robotoslab-light.eot");
src:
url("../fonts/robotoslab-light.eot?#iefix") format("embedded-opentype"),
url("../fonts/robotoslab-light.woff2") format("woff2"),
url("../fonts/robotoslab-light.woff") format("woff"),
url("../fonts/robotoslab-light.ttf") format("truetype"),
url("../fonts/robotoslab-light.svg#roboto_slablight") format("svg");
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215;
}
@font-face {
font-family: "Roboto Slab";
font-style: normal;
font-weight: 400;
src: url("../fonts/robotoslab-regular.eot");
src:
url("../fonts/robotoslab-regular.eot?#iefix") format("embedded-opentype"),
url("../fonts/robotoslab-regular.woff2") format("woff2"),
url("../fonts/robotoslab-regular.woff") format("woff"),
url("../fonts/robotoslab-regular.ttf") format("truetype"),
url("../fonts/robotoslab-regular.svg#roboto_slabregular") format("svg");
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215;
}
@font-face {
font-family: "Roboto Slab";
font-style: normal;
font-weight: 700;
src: url("../fonts/robotoslab-bold.eot");
src:
url("../fonts/robotoslab-bold.eot?#iefix") format("embedded-opentype"),
url("../fonts/robotoslab-bold.woff2") format("woff2"),
url("../fonts/robotoslab-bold.woff") format("woff"),
url("../fonts/robotoslab-bold.ttf") format("truetype"),
url("../fonts/robotoslab-bold.svg#roboto_slabbold") format("svg");
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215;
}

View File

@ -1,49 +0,0 @@
* {
text-shadow: none !important;
color: #000 !important; // Black prints faster: h5bp.com/s
background: transparent !important;
box-shadow: none !important;
}
h1, h2, h3, h4, h5, h6 {
page-break-after: avoid;
page-break-before: auto;
}
pre, blockquote {
border: 1px solid #999;
font-style: italic;
page-break-inside: avoid;
}
img {
page-break-inside: avoid;
border: 0; /* Some browsers like to show a border around images. Switch it off */
}
a,
a:visited { text-decoration: underline; }
abbr[title]:after { content: " (" attr(title) ")"; }
q {
quotes: none;
&:before { content: ""; }
&:after { content: " (" attr(cite) ")"; }
}
.PageBreak {
display: block;
page-break-before: always;
}
.NoPrint { display: none; }
/* Hide the navigation */
aside { display: none; }
a[href]:after {
content: " (" attr(href) ")";
}

View File

@ -1,200 +0,0 @@
h1, h2, h3, h4, h5, h6 {
font-family: var(--font-family-heading);
font-weight: 300;
}
.s-content {
padding: 15px 25px 25px;
background-color: white;
body {
font-size: 15px;
}
h1, h2, h3, h4, h5, h6 {
font-weight: 300;
-webkit-font-smoothing: antialiased;
cursor: text;
line-height: 1.4em;
margin-top: 0.3em;
margin-bottom: 0.3em;
tt, code {
font-size: inherit;
}
i {
font-size: 0.7em;
}
p {
margin-top: 0;
}
}
h1 { // 40px
font-size: 2.6666666667em;
color: black;
}
h2 { // 30px
font-size: 2em;
border-bottom: 1px solid #eee;
color: black;
}
h3 { // 26px
font-size: 1.7333333333em;
}
h4 { // 22px
font-size: 1.4666666667em;
}
h5 { // 18px
font-size: 1.2em;
}
h6 { // 16px
font-size: 1.0666666667em;
color: #555;
}
a {
text-decoration: underline;
}
p { // 15px
line-height: 1.8em;
margin-bottom: 20px;
}
ul, ol {
padding-left: 30px;
}
ul p {
margin: 0;
}
ul ul {
margin: 0;
}
dl {
padding: 0;
dt {
font-weight: bold;
font-style: italic;
padding: 0;
margin: 15px 0 5px;
}
dt:first-child {
padding: 0;
}
dd {
margin: 0 0 15px;
padding: 0 15px;
}
}
blockquote {
font-size: 1.2em;
border-left: 4px solid #ddd;
padding: 7px 15px;
color: #666;
p {
font-size: inherit;
}
}
table {
width: 100%;
padding: 0;
border-collapse: collapse;
tr {
border-top: 1px solid #eee;
background-color: white;
margin: 0;
padding: 0;
}
tr:nth-child(2n) {
background-color: #f8f8f8;
}
th {
font-weight: bold;
border: 1px solid #eee;
background: #eee;
margin: 0;
padding: 6px 13px;
}
td {
border: 1px solid #eee;
margin: 0;
padding: 6px 13px;
}
}
ul,
ol,
blockquote,
dl dt,
dl dd,
table th,
table td {
> :first-child {
margin-top: 0;
}
> :last-child {
margin-bottom: 0;
}
}
img {
max-width: 100%;
display: block;
margin: 0 auto;
}
code {
font-family: var(--font-family-monospace);
}
code, tt {
margin: 0 2px;
padding: 0 5px;
white-space: nowrap;
border: 1px solid #eaeaea;
background-color: #f8f8f8;
border-radius: 3px;
}
pre {
background: #fdf6e3;
color: #657b83;
line-height: 1.5em;
overflow: auto;
padding: 20px;
margin: 0 -20px 20px -20px;
code {
margin: 0;
padding: 0;
white-space: pre;
}
code, tt {
background-color: transparent;
border: none;
}
}
}

View File

@ -1,58 +0,0 @@
// Core variables and mixins
@import "vendor/highlight.scss";
@import "_fonts.scss";
@import "_typography.scss";
* {
-webkit-overflow-scrolling: touch;
-webkit-tap-highlight-color: transparent;
-webkit-touch-callout: none;
}
html, body {
height: 100%;
}
body {
text-rendering: optimizeLegibility;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
font-family: var(--font-family-text);
}
a {
color: #337ab7;
text-decoration: none;
}
a:focus, a:hover {
color: #23527c;
text-decoration: underline;
}
p {
margin: 0 0 1em;
}
hr {
clear: both;
margin: 1em 0;
border: 0;
border-top: 1px solid #ddd;
}
img {
max-width: 100% !important;
}
.PageBreak { display: none; }
@media screen {
body {
margin: 1em;
}
}
@media print {
@import "_print.scss";
}

View File

@ -1,90 +0,0 @@
/* http://jmblog.github.com/color-themes-for-google-code-highlightjs */
/* Tomorrow Comment */
.hljs-comment {
color: hsl(207, 35%, 35%);
}
/* Tomorrow Red */
.hljs-variable,
.hljs-attribute,
.hljs-tag,
.hljs-regexp,
.ruby .hljs-constant,
.xml .hljs-tag .hljs-title,
.xml .hljs-pi,
.xml .hljs-doctype,
.html .hljs-doctype,
.css .hljs-id,
.css .hljs-class,
.css .hljs-pseudo {
color: #c82829;
}
/* Tomorrow Orange */
.hljs-number,
.hljs-preprocessor,
.hljs-pragma,
.hljs-built_in,
.hljs-literal,
.hljs-constant,
.hljs-function .hljs-title {
color: hsl(50, 100%, 60%);
}
/* Tomorrow Yellow */
.ruby .hljs-class .hljs-title,
.css .hljs-rules .hljs-attribute {
color: #eab700;
}
/* Tomorrow Green */
.hljs-string,
.hljs-value,
.hljs-inheritance,
.hljs-header,
.ruby .hljs-symbol,
.xml .hljs-cdata {
color: hsl(0, 100%, 70%);
}
/* Tomorrow Aqua */
.css .hljs-hexcolor {
color: #3e999f;
}
/* Tomorrow Blue */
.hljs-function .keyword,
.python .hljs-decorator,
.python .hljs-title,
.ruby .hljs-function .hljs-title,
.ruby .hljs-title .hljs-keyword,
.perl .hljs-sub,
.javascript .hljs-title,
.coffeescript .hljs-title {
color: hsl(207, 70%, 60%);
}
/* Tomorrow Purple */
.hljs-keyword,
.javascript .hljs-function {
color: hsl(207, 95%, 70%);
}
.hljs {
display: block;
background: white;
color: #4d4d4c;
padding: 0.5em;
font-family: "Anonymous Pro", "Inconsolata", "Monaco", monospace;
}
.coffeescript .javascript,
.javascript .xml,
.tex .hljs-formula,
.xml .javascript,
.xml .vbscript,
.xml .css,
.xml .hljs-cdata {
opacity: 0.5;
}