commit 1df798bc907f331ce976ad53df9cc635013e91f4 Author: TLRZ Seyfferth Date: Tue Jan 21 19:53:11 2020 +0100 initial commit diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..950955b --- /dev/null +++ b/.gitignore @@ -0,0 +1,15 @@ +# Linux +*~ +*.swp + +# Windows +Thumbs.db +desktop.ini + +# Mac OS X +.DS_Store +._* + +# Composer +/composer.phar +/vendor diff --git a/.htaccess b/.htaccess new file mode 100644 index 0000000..5b2d88b --- /dev/null +++ b/.htaccess @@ -0,0 +1,22 @@ + + RewriteEngine On + # May be required to access sub directories + #RewriteBase / + + # Deny access to internal dirs and files by passing the URL to Pico + RewriteRule ^(config|content|vendor|CHANGELOG\.md|composer\.(json|lock|phar))(/|$) index.php [L] + RewriteRule (^\.|/\.)(?!well-known(/|$)) index.php [L] + + # Enable URL rewriting + RewriteCond %{REQUEST_FILENAME} !-f + RewriteCond %{REQUEST_FILENAME} !-d + RewriteRule ^ index.php [L] + + + # Let Pico know about available URL rewriting + SetEnv PICO_URL_REWRITING 1 + + + +# Prevent file browsing +Options -Indexes -MultiViews diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..91a34cf --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2012 The Pico Community + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..e9a24bc --- /dev/null +++ b/README.md @@ -0,0 +1,34 @@ +Pico +==== + +[![License](https://picocms.github.io/badges/pico-license.svg)](https://github.com/picocms/pico-composer/blob/master/LICENSE) +[![Version](https://picocms.github.io/badges/pico-version.svg)](https://github.com/picocms/pico-composer#install) +[![Freenode IRC Webchat](https://picocms.github.io/badges/pico-chat.svg)](https://webchat.freenode.net/?channels=%23picocms) +[![Open Bounties on Bountysource](https://www.bountysource.com/badge/team?team_id=198139&style=bounties_received)](https://www.bountysource.com/teams/picocms) + +Pico is a stupidly simple, blazing fast, flat file CMS. + +Visit us at http://picocms.org/ and see http://picocms.org/about/ for more info. + +This is Pico's [Composer][] starter project. `picocms/pico-composer` is the frame for basically all Pico installations starting with Pico 2.0, but doesn't consist of any considerable code itself. It's main purpose is to simply depend on Pico. Please refer to the ["Install"][MainRepoInstall] and ["Upgrade"][MainRepoUpgrade] sections of our main repository for information about how to install, upgrade and use Pico. + +Screenshot +---------- + +![Pico Screenshot](https://picocms.github.io/screenshots/pico-21.png) + +Getting Help +------------ + +Please refer to the ["Getting Help" section][MainRepoGettingHelp] of our main repository. + +Contributing +------------ + +Please refer to the ["Contributing" section][MainRepoContributing] of our main repository. + +[Composer]: https://getcomposer.org/ +[MainRepoInstall]: https://github.com/picocms/Pico#install +[MainRepoUpgrade]: https://github.com/picocms/Pico#upgrade +[MainRepoGettingHelp]: https://github.com/picocms/Pico#getting-help +[MainRepoContributing]: https://github.com/picocms/Pico#contributing diff --git a/assets/.gitignore b/assets/.gitignore new file mode 100644 index 0000000..71beeb7 --- /dev/null +++ b/assets/.gitignore @@ -0,0 +1 @@ +# This file is meant to be empty diff --git a/composer.json b/composer.json new file mode 100644 index 0000000..e099267 --- /dev/null +++ b/composer.json @@ -0,0 +1,36 @@ +{ + "name": "picocms/pico-composer", + "type": "project", + "description": "Pico is a flat file CMS, this means there is no administration backend and database to deal with. You simply create .md files in the \"content\" folder and that becomes a page.", + "keywords": [ "pico", "picocms", "pico-cms", "simple", "flat-file", "cms", "content-management", "website", "markdown-to-html", "php", "markdown", "yaml", "twig", "composer-project" ], + "homepage": "http://picocms.org/", + "license": "MIT", + "authors": [ + { + "name": "Daniel Rudolf", + "email": "picocms.org@daniel-rudolf.de", + "role": "Lead Developer" + }, + { + "name": "The Pico Community", + "homepage": "http://picocms.org/" + }, + { + "name": "Contributors", + "homepage": "https://github.com/picocms/pico-composer/graphs/contributors" + } + ], + "support": { + "docs": "http://picocms.org/docs", + "issues": "https://github.com/picocms/Pico/issues", + "source": "https://github.com/picocms/Pico" + }, + "require": { + "picocms/pico": "^2.1", + "picocms/pico-theme": "^2.1", + "picocms/pico-deprecated": "^2.1", + "picocms/composer-installer": "^1.0" + }, + "minimum-stability": "beta", + "prefer-stable": true +} diff --git a/composer.lock b/composer.lock new file mode 100644 index 0000000..432e160 --- /dev/null +++ b/composer.lock @@ -0,0 +1,546 @@ +{ + "_readme": [ + "This file locks the dependencies of your project to a known state", + "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", + "This file is @generated automatically" + ], + "content-hash": "c572de982113b017edeaa4b6ec598816", + "packages": [ + { + "name": "erusev/parsedown", + "version": "1.8.0-beta-7", + "source": { + "type": "git", + "url": "https://github.com/erusev/parsedown.git", + "reference": "fe7a50eceb4a3c867cc9fa9c0aa906b1067d1955" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/erusev/parsedown/zipball/fe7a50eceb4a3c867cc9fa9c0aa906b1067d1955", + "reference": "fe7a50eceb4a3c867cc9fa9c0aa906b1067d1955", + "shasum": "" + }, + "require": { + "ext-mbstring": "*", + "php": ">=5.3.0" + }, + "require-dev": { + "phpunit/phpunit": "^4.8.35" + }, + "type": "library", + "autoload": { + "psr-0": { + "Parsedown": "" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Emanuil Rusev", + "email": "hello@erusev.com", + "homepage": "http://erusev.com" + } + ], + "description": "Parser for Markdown.", + "homepage": "http://parsedown.org", + "keywords": [ + "markdown", + "parser" + ], + "time": "2019-03-17T18:47:21+00:00" + }, + { + "name": "erusev/parsedown-extra", + "version": "0.8.0-beta-1", + "source": { + "type": "git", + "url": "https://github.com/erusev/parsedown-extra.git", + "reference": "e756b1bf8642ab1091403e902b0503f1cec7527d" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/erusev/parsedown-extra/zipball/e756b1bf8642ab1091403e902b0503f1cec7527d", + "reference": "e756b1bf8642ab1091403e902b0503f1cec7527d", + "shasum": "" + }, + "require": { + "erusev/parsedown": "^1.8.0|^1.8.0-beta-4", + "ext-dom": "*", + "ext-mbstring": "*", + "php": ">=5.3.6" + }, + "require-dev": { + "phpunit/phpunit": "^4.8.35" + }, + "type": "library", + "autoload": { + "psr-0": { + "ParsedownExtra": "" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Emanuil Rusev", + "email": "hello@erusev.com", + "homepage": "http://erusev.com" + } + ], + "description": "An extension of Parsedown that adds support for Markdown Extra.", + "homepage": "https://github.com/erusev/parsedown-extra", + "keywords": [ + "markdown", + "markdown extra", + "parsedown", + "parser" + ], + "time": "2018-05-08T21:54:32+00:00" + }, + { + "name": "picocms/composer-installer", + "version": "v1.0.1", + "source": { + "type": "git", + "url": "https://github.com/picocms/composer-installer.git", + "reference": "6b5036c83aa091ed76e2a76ed9335885f95a7db7" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/picocms/composer-installer/zipball/6b5036c83aa091ed76e2a76ed9335885f95a7db7", + "reference": "6b5036c83aa091ed76e2a76ed9335885f95a7db7", + "shasum": "" + }, + "type": "composer-installer", + "extra": { + "class": "Pico\\Composer\\Installer\\PluginInstaller" + }, + "autoload": { + "psr-4": { + "Pico\\Composer\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Daniel Rudolf", + "email": "picocms.org@daniel-rudolf.de", + "role": "Lead Developer" + }, + { + "name": "The Pico Community", + "homepage": "http://picocms.org/" + }, + { + "name": "Contributors", + "homepage": "https://github.com/picocms/composer-installer/graphs/contributors" + } + ], + "description": "A composer plugin responsible for installing plugins and themes for Pico, a stupidly simple, blazing fast, flat file CMS.", + "homepage": "http://picocms.org/", + "keywords": [ + "composer", + "composer-installer", + "composer-plugin", + "pico", + "pico-cms", + "picocms", + "picocms-installer", + "picocms-plugin", + "picocms-theme" + ], + "time": "2019-11-24T22:50:47+00:00" + }, + { + "name": "picocms/pico", + "version": "v2.1.1", + "source": { + "type": "git", + "url": "https://github.com/picocms/Pico.git", + "reference": "b49936fb3a389b89c1bca659b7841f34c04b95bd" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/picocms/Pico/zipball/b49936fb3a389b89c1bca659b7841f34c04b95bd", + "reference": "b49936fb3a389b89c1bca659b7841f34c04b95bd", + "shasum": "" + }, + "require": { + "erusev/parsedown": "1.8.0-beta-7", + "erusev/parsedown-extra": "0.8.0-beta-1", + "php": ">=5.3.6", + "symfony/yaml": "^2.8", + "twig/twig": "^1.36" + }, + "suggest": { + "picocms/composer-installer": "This Composer plugin is responsible for installing Pico plugins and themes using the Composer package manager.", + "picocms/pico-deprecated": "PicoDeprecated's purpose is to maintain backward compatibility to older versions of Pico.", + "picocms/pico-theme": "Pico requires a theme to actually display the contents of your website. This is Pico's official default theme." + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0.x-dev", + "dev-pico-2.1": "2.1.x-dev" + } + }, + "autoload": { + "psr-0": { + "Pico": "lib/", + "PicoPluginInterface": "lib/", + "AbstractPicoPlugin": "lib/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Gilbert Pellegrom", + "email": "gilbert@pellegrom.me", + "role": "Project Founder" + }, + { + "name": "Daniel Rudolf", + "email": "picocms.org@daniel-rudolf.de", + "role": "Lead Developer" + }, + { + "name": "The Pico Community", + "homepage": "http://picocms.org/" + }, + { + "name": "Contributors", + "homepage": "https://github.com/picocms/Pico/graphs/contributors" + } + ], + "description": "Pico is a flat file CMS, this means there is no administration backend and database to deal with. You simply create .md files in the \"content\" folder and that becomes a page.", + "homepage": "http://picocms.org/", + "keywords": [ + "Simple", + "cms", + "content-management", + "flat-file", + "markdown", + "markdown-to-html", + "php", + "pico", + "pico-cms", + "picocms", + "twig", + "website", + "yaml" + ], + "time": "2019-12-31T15:33:55+00:00" + }, + { + "name": "picocms/pico-deprecated", + "version": "v2.1.1", + "source": { + "type": "git", + "url": "https://github.com/picocms/pico-deprecated.git", + "reference": "9554c025626bcba4f9160d3f2dabf18376402a1f" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/picocms/pico-deprecated/zipball/9554c025626bcba4f9160d3f2dabf18376402a1f", + "reference": "9554c025626bcba4f9160d3f2dabf18376402a1f", + "shasum": "" + }, + "require": { + "php": ">=5.3.0", + "picocms/pico": "self.version" + }, + "type": "pico-plugin", + "extra": { + "branch-alias": { + "dev-master": "2.0.x-dev", + "dev-pico-2.1": "2.1.x-dev" + } + }, + "autoload": { + "classmap": [ + "PicoDeprecated.php", + "lib/", + "plugins/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Daniel Rudolf", + "email": "picocms.org@daniel-rudolf.de", + "role": "Lead Developer" + }, + { + "name": "The Pico Community", + "homepage": "http://picocms.org/" + }, + { + "name": "Contributors", + "homepage": "https://github.com/picocms/pico-deprecated/graphs/contributors" + } + ], + "description": "This is Pico's official PicoDeprecated plugin. Pico is a stupidly simple, blazing fast, flat file CMS.", + "homepage": "http://picocms.org/", + "keywords": [ + "compatibility", + "deprecation", + "pico", + "pico-deprecated", + "picocms", + "picocms-plugin" + ], + "time": "2019-12-31T15:36:04+00:00" + }, + { + "name": "picocms/pico-theme", + "version": "v2.1.1", + "source": { + "type": "git", + "url": "https://github.com/picocms/pico-theme.git", + "reference": "a79b9875b1d2dd182617454ad73af3c7caa47682" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/picocms/pico-theme/zipball/a79b9875b1d2dd182617454ad73af3c7caa47682", + "reference": "a79b9875b1d2dd182617454ad73af3c7caa47682", + "shasum": "" + }, + "require": { + "picocms/pico": "self.version" + }, + "type": "pico-theme", + "extra": { + "installer-name": "default", + "branch-alias": { + "dev-master": "2.0.x-dev", + "dev-pico-2.1": "2.1.x-dev" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Daniel Rudolf", + "email": "picocms.org@daniel-rudolf.de", + "role": "Lead Developer" + }, + { + "name": "The Pico Community", + "homepage": "http://picocms.org/" + }, + { + "name": "Contributors", + "homepage": "https://github.com/picocms/pico-theme/graphs/contributors" + } + ], + "description": "This is Pico's official default theme. Pico is a stupidly simple, blazing fast, flat file CMS.", + "homepage": "http://picocms.org/", + "keywords": [ + "default-theme", + "pico", + "pico-theme", + "picocms", + "picocms-theme" + ], + "time": "2019-12-31T15:37:35+00:00" + }, + { + "name": "symfony/polyfill-ctype", + "version": "v1.13.1", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-ctype.git", + "reference": "f8f0b461be3385e56d6de3dbb5a0df24c0c275e3" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/f8f0b461be3385e56d6de3dbb5a0df24c0c275e3", + "reference": "f8f0b461be3385e56d6de3dbb5a0df24c0c275e3", + "shasum": "" + }, + "require": { + "php": ">=5.3.3" + }, + "suggest": { + "ext-ctype": "For best performance" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.13-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Polyfill\\Ctype\\": "" + }, + "files": [ + "bootstrap.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Gert de Pagter", + "email": "BackEndTea@gmail.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill for ctype functions", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "ctype", + "polyfill", + "portable" + ], + "time": "2019-11-27T13:56:44+00:00" + }, + { + "name": "symfony/yaml", + "version": "v2.8.52", + "source": { + "type": "git", + "url": "https://github.com/symfony/yaml.git", + "reference": "02c1859112aa779d9ab394ae4f3381911d84052b" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/yaml/zipball/02c1859112aa779d9ab394ae4f3381911d84052b", + "reference": "02c1859112aa779d9ab394ae4f3381911d84052b", + "shasum": "" + }, + "require": { + "php": ">=5.3.9", + "symfony/polyfill-ctype": "~1.8" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.8-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Yaml\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Yaml Component", + "homepage": "https://symfony.com", + "time": "2018-11-11T11:18:13+00:00" + }, + { + "name": "twig/twig", + "version": "v1.42.4", + "source": { + "type": "git", + "url": "https://github.com/twigphp/Twig.git", + "reference": "e587180584c3d2d6cb864a0454e777bb6dcb6152" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/twigphp/Twig/zipball/e587180584c3d2d6cb864a0454e777bb6dcb6152", + "reference": "e587180584c3d2d6cb864a0454e777bb6dcb6152", + "shasum": "" + }, + "require": { + "php": ">=5.5.0", + "symfony/polyfill-ctype": "^1.8" + }, + "require-dev": { + "psr/container": "^1.0", + "symfony/debug": "^3.4|^4.2", + "symfony/phpunit-bridge": "^4.4@dev|^5.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.42-dev" + } + }, + "autoload": { + "psr-0": { + "Twig_": "lib/" + }, + "psr-4": { + "Twig\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com", + "homepage": "http://fabien.potencier.org", + "role": "Lead Developer" + }, + { + "name": "Twig Team", + "homepage": "https://twig.symfony.com/contributors", + "role": "Contributors" + }, + { + "name": "Armin Ronacher", + "email": "armin.ronacher@active-4.com", + "role": "Project Founder" + } + ], + "description": "Twig, the flexible, fast, and secure template language for PHP", + "homepage": "https://twig.symfony.com", + "keywords": [ + "templating" + ], + "time": "2019-11-11T16:49:32+00:00" + } + ], + "packages-dev": [], + "aliases": [], + "minimum-stability": "beta", + "stability-flags": [], + "prefer-stable": true, + "prefer-lowest": false, + "platform": [], + "platform-dev": [] +} diff --git a/config/.gitignore b/config/.gitignore new file mode 100644 index 0000000..71beeb7 --- /dev/null +++ b/config/.gitignore @@ -0,0 +1 @@ +# This file is meant to be empty diff --git a/config/config.yml b/config/config.yml new file mode 100644 index 0000000..51e962f --- /dev/null +++ b/config/config.yml @@ -0,0 +1,66 @@ +## +# Basic +# +site_title: chrosey.de # The title of your website +base_url: + ~ # Pico will try to guess its base URL, if this fails, override it here; + # Example: https://example.com/pico/ +rewrite_url: true # A boolean (true or false) indicating whether URL rewriting is forced +debug: ~ # Set this to true to enable Pico's debug mode +timezone: ~ # Your PHP installation might require you to manually specify a timezone + +## +# Theme +# +theme: chrosey # The name of your custom theme +themes_url: + ~ # Pico will try to guess the URL to the themes dir of your installation; + # If this fails, override it here. Example: https://example.com/pico/themes/ +theme_config: # Additional theme-specific config + widescreen: true # Default theme: Use more horizontal space (i.e. make the site container wider) +twig_config: # Twig template engine config + autoescape: html # Let Twig escape variables by default + strict_variables: false # If set to true, Twig will bail out when unset variables are being used + charset: utf-8 # The charset used by Twig templates + debug: ~ # Enable Twig's debug mode + cache: false # Enable Twig template caching by specifying a path to a writable directory + auto_reload: ~ # Recompile Twig templates whenever the source code changes + +## +# Content +# +date_format: + %D %T # Pico's default date format; + # See https://php.net/manual/en/function.strftime.php for more info +pages_order_by_meta: author # Sort pages by meta value "author" (set "pages_order_by" to "meta") +pages_order_by: alpha # Change how Pico sorts pages ("alpha" for alphabetical order, "date", or "meta") +pages_order: asc # Sort pages in ascending ("asc") or descending ("desc") order +content_dir: ~ # The path to Pico's content directory +content_ext: .md # The file extension of your Markdown files +content_config: # Parsedown Markdown parser config + extra: true # Use the Parsedown Extra parser to support extended markup; + # See https://michelf.ca/projects/php-markdown/extra/ for more info + breaks: + false # A boolean indicating whether breaks in the markup should be reflected in the + # parsed contents of the page + escape: + false # Escape HTML markup in your content files; don't confuse this with some sort of + # safe mode, enabling this doesn't allow you to process untrusted user input! + auto_urls: true # Automatically link URLs found in your markup +assets_dir: assets/ # The path to Pico's assets directory +assets_url: + ~ # Pico will try to guess the URL to the assets dir of your installation; + # If this fails, override it here. Example: https://example.com/pico/assets/ + +## +# Plugins +# +plugins_url: + ~ # Pico will try to guess the URL to the plugins dir of your installation; + # If this fails, override it here. Example: https://example.com/pico/plugins/ +DummyPlugin.enabled: false # Force the plugin "DummyPlugin" to be disabled + +## +# Custom +# +my_custom_setting: Hello World! # You can access custom settings in themes using {{ config.my_custom_setting }} diff --git a/config/config.yml.template b/config/config.yml.template new file mode 100644 index 0000000..159585b --- /dev/null +++ b/config/config.yml.template @@ -0,0 +1,59 @@ +## +# Basic +# +site_title: Pico # The title of your website +base_url: ~ # Pico will try to guess its base URL, if this fails, override it here; + # Example: https://example.com/pico/ +rewrite_url: ~ # A boolean (true or false) indicating whether URL rewriting is forced +debug: ~ # Set this to true to enable Pico's debug mode +timezone: ~ # Your PHP installation might require you to manually specify a timezone + +## +# Theme +# +theme: default # The name of your custom theme +themes_url: ~ # Pico will try to guess the URL to the themes dir of your installation; + # If this fails, override it here. Example: https://example.com/pico/themes/ +theme_config: # Additional theme-specific config + widescreen: false # Default theme: Use more horizontal space (i.e. make the site container wider) +twig_config: # Twig template engine config + autoescape: html # Let Twig escape variables by default + strict_variables: false # If set to true, Twig will bail out when unset variables are being used + charset: utf-8 # The charset used by Twig templates + debug: ~ # Enable Twig's debug mode + cache: false # Enable Twig template caching by specifying a path to a writable directory + auto_reload: ~ # Recompile Twig templates whenever the source code changes + +## +# Content +# +date_format: %D %T # Pico's default date format; + # See https://php.net/manual/en/function.strftime.php for more info +pages_order_by_meta: author # Sort pages by meta value "author" (set "pages_order_by" to "meta") +pages_order_by: alpha # Change how Pico sorts pages ("alpha" for alphabetical order, "date", or "meta") +pages_order: asc # Sort pages in ascending ("asc") or descending ("desc") order +content_dir: ~ # The path to Pico's content directory +content_ext: .md # The file extension of your Markdown files +content_config: # Parsedown Markdown parser config + extra: true # Use the Parsedown Extra parser to support extended markup; + # See https://michelf.ca/projects/php-markdown/extra/ for more info + breaks: false # A boolean indicating whether breaks in the markup should be reflected in the + # parsed contents of the page + escape: false # Escape HTML markup in your content files; don't confuse this with some sort of + # safe mode, enabling this doesn't allow you to process untrusted user input! + auto_urls: true # Automatically link URLs found in your markup +assets_dir: assets/ # The path to Pico's assets directory +assets_url: ~ # Pico will try to guess the URL to the assets dir of your installation; + # If this fails, override it here. Example: https://example.com/pico/assets/ + +## +# Plugins +# +plugins_url: ~ # Pico will try to guess the URL to the plugins dir of your installation; + # If this fails, override it here. Example: https://example.com/pico/plugins/ +DummyPlugin.enabled: false # Force the plugin "DummyPlugin" to be disabled + +## +# Custom +# +my_custom_setting: Hello World! # You can access custom settings in themes using {{ config.my_custom_setting }} diff --git a/content/.gitignore b/content/.gitignore new file mode 100644 index 0000000..71beeb7 --- /dev/null +++ b/content/.gitignore @@ -0,0 +1 @@ +# This file is meant to be empty diff --git a/content/about/index.md b/content/about/index.md new file mode 100644 index 0000000..c7fe7d6 --- /dev/null +++ b/content/about/index.md @@ -0,0 +1,8 @@ +--- +Title: Über mich +Description: Das bin ich +Author: Christian Seyfferth +Date: 2020-01-21 +Robots: noindex,nofollow +Template: templates/index +--- \ No newline at end of file diff --git a/content/blog/HalloWelt.md b/content/blog/HalloWelt.md new file mode 100644 index 0000000..967791f --- /dev/null +++ b/content/blog/HalloWelt.md @@ -0,0 +1,10 @@ +--- +Title: Hallo Welt +Description: Erster Blogeintrag mit PicoCMS +Author: Christian Seyfferth +Date: 2020-01-21 17:00 +Robots: noindex,nofollow +Template: templates/blog/item +--- +# Hallo Welt +dies ist mein erster Blogeintrag \ No newline at end of file diff --git a/content/blog/VerstehtMich.md b/content/blog/VerstehtMich.md new file mode 100644 index 0000000..fd42c33 --- /dev/null +++ b/content/blog/VerstehtMich.md @@ -0,0 +1,11 @@ +--- +Title: Versteht mich nicht +Description: Zweiter Blogeintrag mit PicoCMS +Author: Christian Seyfferth +Date: 2020-01-21 19:00 +Robots: noindex,nofollow +Template: templates/blog/item +Type: news +--- +# Etwas verwirrung +dies ist mein zweiter Blogeintrag \ No newline at end of file diff --git a/content/blog/index.md b/content/blog/index.md new file mode 100644 index 0000000..fd5ba8b --- /dev/null +++ b/content/blog/index.md @@ -0,0 +1,8 @@ +--- +Title: Blog +Description: This description will go in the meta description tag +Author: Christian Seyfferth +Date: 2020-01-21 +Robots: noindex,nofollow +Template: templates/index +--- \ No newline at end of file diff --git a/content/index.md b/content/index.md new file mode 100644 index 0000000..f5edbfb --- /dev/null +++ b/content/index.md @@ -0,0 +1,11 @@ +--- +Title: Home +Description: Startseite +Author: Christian Seyfferth +Date: 2020-01-21 +Robots: noindex,nofollow +Template: templates/index +--- + +# Hallo Welt +Willkommen auf meiner Seite. Ich hoffe sie gefällt dir. \ No newline at end of file diff --git a/content/projekte/index.md b/content/projekte/index.md new file mode 100644 index 0000000..0e8ea8c --- /dev/null +++ b/content/projekte/index.md @@ -0,0 +1,10 @@ +--- +Title: Meine Projekte +Description: Daran arbeite ich +Author: Christian Seyfferth +Date: 2020-01-21 +Robots: noindex,nofollow +Template: templates/index +--- + +# Projekte \ No newline at end of file diff --git a/index.php b/index.php new file mode 100644 index 0000000..993554a --- /dev/null +++ b/index.php @@ -0,0 +1,33 @@ + + * + * SPDX-License-Identifier: MIT + * License-Filename: LICENSE + */ + +// load dependencies +// pico-composer MUST be installed as root package +if (is_file(__DIR__ . '/vendor/autoload.php')) { + require_once(__DIR__ . '/vendor/autoload.php'); +} else { + die("Cannot find 'vendor/autoload.php'. Run `composer install`."); +} + +// instance Pico +$pico = new Pico( + __DIR__, // root dir + 'config/', // config dir + 'plugins/', // plugins dir + 'themes/' // themes dir +); + +// override configuration? +//$pico->setConfig(array()); + +// run application +echo $pico->run(); diff --git a/plugins/.gitignore b/plugins/.gitignore new file mode 100644 index 0000000..a9f7294 --- /dev/null +++ b/plugins/.gitignore @@ -0,0 +1,2 @@ +# You should add plugins installed by Composer here +/PicoDeprecated diff --git a/themes/.gitignore b/themes/.gitignore new file mode 100644 index 0000000..107394a --- /dev/null +++ b/themes/.gitignore @@ -0,0 +1,2 @@ +# You should add themes installed by Composer here +/default diff --git a/themes/chrosey/CHANGELOG.md b/themes/chrosey/CHANGELOG.md new file mode 100644 index 0000000..4564e49 --- /dev/null +++ b/themes/chrosey/CHANGELOG.md @@ -0,0 +1,118 @@ +Pico Default Theme Changelog +============================ + +**Note:** This changelog only provides technical information about the changes + introduced with a particular Pico version, and is meant to supplement + the actual code changes. The information in this changelog are often + insufficient to understand the implications of larger changes. Please + refer to both the UPGRADE and NEWS sections of the docs for more + details. + +### Version 2.1.1 +Released: 2019-12-31 + +No changes + +### Version 2.1.0 +Released: 2019-11-24 + +``` +* [New] Add Pico's official logo and tagline +* [New] Add some utility classes for typography and images +* [Changed] Improve documentation of `pico-theme.yml` +* [Changed] Various small improvements +``` + +### Version 2.1.0-beta.1 +Released: 2019-11-03 + +``` +* [Changed] Add basic `pico-theme.yml` to use API v3, enable Twig's autoescape + feature (no changes necessary) and register `Social` meta header +* [Changed] Use Pico's `pages` Twig function to create the main navigation +* [Changed] Improve formatting of definition lists and inline code snippets +* [Changed] Improve JSDoc class docs +* [Changed] Various small improvements +``` + +### Version 2.0.5-beta.1 +Released: 2019-01-03 + +``` +* [New] Add `2.0.x-dev` alias for master branch to `composer.json` +``` + +### Version 2.0.4 +Released: 2018-12-17 + +No changes + +### Version 2.0.3 +Released: 2018-12-03 + +No changes + +### Version 2.0.2 +Released: 2018-08-12 + +No changes + +### Version 2.0.1 +Released: 2018-07-29 + +No changes + +### Version 2.0.0 +Released: 2018-07-01 + +``` +* [New] Add Bountysource +* [Changed] Improve documentation +``` + +### Version 2.0.0-beta.3 +Released: 2018-04-07 + +No changes + +### Version 2.0.0-beta.2 +Released: 2018-01-21 + +``` +* [Fixed] Fix sliding animation of collapsible menu in IE 9 +* [Changed] Move Fontello font to `icon/` directory +* [Changed] Move stylesheets to `css/` directory +* [Changed] Improve Fontello font copyright notice +* [Changed] Add Droid Sans and Droid Sans Mono font files to `font/` directory, + making Pico's default theme fully self-containing +``` + +### Version 2.0.0-beta.1 +Released: 2017-11-05 + +**Note:** Pico's default theme was completely rewritten from scratch for + Pico 2.0 and moved to this separate repository. This changelog only + provides basic information about the most important changes compared + to Pico 1.0. It therefore doesn't include the changes made before + this release. The rewrite breaks backwards compatibility (BC). + +``` +* [New] Rewrite Pico's default theme from scratch with a much cleaner, more + modern, but still "stupidly simple" structure; the new theme officially + supports Internet Explorer 9+ as well as all versions of the major + desktop and mobile browsers, as long as they are still officially + supported by their respective vendor +* [New] Pico's default theme is now a fully responsive theme, adapting the + layout to the viewing environment (desktops vs. tablets vs. smartphones + vs. ...) +* [New] Add a collapsible page menu for small screens (menu slides up/down) +* [New] Add basic form themeing +* [New] Support a "widescreen" mode, demonstrating how themes can adjust their + behavior using config parameters (i.e. Pico's `config/config.yml`) +* [Changed] Show top-level pages in the website's navigation only (i.e. show + `page.md` and `sub/index.md`, but not `sub/page.md`) +* [Changed] Hide pages starting with a `_` in the website's navigation +* [Changed] Move Pico's social icons from `index.md` to `_meta.md`, + demonstrating how themes can use YAML-only meta pages to support + dynamic content +``` diff --git a/themes/chrosey/LICENSE b/themes/chrosey/LICENSE new file mode 100644 index 0000000..91a34cf --- /dev/null +++ b/themes/chrosey/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2012 The Pico Community + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/themes/chrosey/README.md b/themes/chrosey/README.md new file mode 100644 index 0000000..56bf903 --- /dev/null +++ b/themes/chrosey/README.md @@ -0,0 +1,67 @@ +Pico Default Theme +================== + +This is the repository of Pico's official default theme. + +Pico is a stupidly simple, blazing fast, flat file CMS. See http://picocms.org/ for more info. + +Please refer to [`picocms/Pico`](https://github.com/picocms/Pico) to get info about how to contribute or getting help. + +Screenshot +---------- + +![Pico Screenshot](https://picocms.github.io/screenshots/pico-21.png) + +Install +------- + +You usually don't have to install this theme manually, it's shipped together with [Pico's pre-built release packages](https://github.com/picocms/Pico/releases/latest) and a default dependency of [`picocms/pico-composer`](https://github.com/picocms/pico-composer). + +If you're using a custom theme, you can safely remove this theme. + +If you use a `composer`-based installation of Pico and want to either remove or install Pico's default theme, simply open a shell on your server and navigate to Pico's install directory (e.g. `/var/www/html`). Run `composer remove picocms/pico-theme` to remove the theme, or run `composer require picocms/pico-theme` (via [Packagist.org](https://packagist.org/packages/picocms/pico-theme)) to install the theme. + +If you rather use one of Pico's pre-built release packages, it is best to simply leave Pico's default theme as it is - it won't hurt... :wink: The reason for this is, that the theme is part of Pico's pre-built release packages, thus it will be automatically re-installed when updating Pico. However, if you really want to remove the theme, simply delete the `themes/default` directory in Pico's install directory (e.g. `/var/www/html`). If you want to install Pico's default theme, you must first create a empty `themes/default` directory on your server, [download the version of the theme](https://github.com/picocms/pico-theme/releases) matching the version of your Pico installation and upload all containing files (i.a. `index.twig`) into said `themes/default` directory (resulting in `themes/default/index.twig`). + +The versioning of Pico's default theme strictly follows the version of Pico's core. You *must not* use a version of the theme that doesn't match the version of Pico's core (e.g. version 2.0.1 is *not compatible* with Pico 2.0.0). If you're using a `composer`-based installation of Pico, simply use a version constaint like `^2.0` - `picocms/pico-theme` ensures that its version matches Pico's version. Even if you're using one of Pico's pre-built release packages, you don't have to take care of anything - a matching version of the theme is part of Pico's pre-built release packages anyway. + +Usage +----- + +Pico's default theme isn't really intended to be used for a productive website, it's rather a starting point for creating your own theme. Simply copy the theme's directory (`themes/default/` to e.g. `themes/my_theme/`) and add the following line to your `config/config.yml`: + +```yaml +theme: my_theme +``` + +You can now edit the theme's stylesheets and JavaScript to fit your needs. If you rather want to use a third-party theme, simply add the theme's directory to your `themes/` directory (e.g. `themes/some_other_theme/`) and update your `config/config.yml` accordingly. Pico's default theme is now completely disabled and won't ever interfere with your custom theme or your website in general anymore. If you want to use Pico's default theme again, either remove the line or replace it by `theme: default`. + +Anyway, since Pico's default theme is meant to be a starting point for your own theme, it demonstrates how themes can allow one to tweak a theme's behavior. For this reason it supports a "Widescreen" mode: By adding `theme_config.widescreen: true` to your `config/config.yml`, the theme's main container grows from 768px to 1152px breadth due to adding `class="widescreen"` to the website's `` element. Pico's default theme furthermore supports displaying both a logo and a tagline in its header, as well as adding social buttons to its footer. Rather than using Pico's config for this, it uses the YAML Frontmatter of the `content/_meta.md` Markdown file. Here's `content/_meta.md` from Pico's sample contents: + +```yaml +--- +Logo: %theme_url%/img/pico-white.svg +Tagline: Making the web easy. +Social: + - title: Visit us on GitHub + url: https://github.com/picocms/Pico + icon: octocat + - title: Join us on Freenode IRC Webchat + url: https://webchat.freenode.net/?channels=%23picocms + icon: chat +--- +``` + +You should also check out the theme's `pico-theme.yml`: First of all it tells Pico to use the latest API version for themes and adjusts Pico's default Twig config. But more importantly it also registers the mentioned `widescreen` theme config as well as the meta headers `Logo`, `Tagline` and `Social`. + +Getting Help +------------ + +Please refer to the ["Getting Help" section](https://github.com/picocms/Pico#getting-help) of our main repository. + +Contributing +------------ + +Please refer to the ["Contributing" section](https://github.com/picocms/Pico#contributing) of our main repository. + +By contributing to Pico, you accept and agree to the *Developer Certificate of Origin* for your present and future contributions submitted to Pico. Please refer to the ["Developer Certificate of Origin" section](https://github.com/picocms/Pico/blob/master/CONTRIBUTING.md#developer-certificate-of-origin) in the `CONTRIBUTING.md` of our main repository. diff --git a/themes/chrosey/composer.json b/themes/chrosey/composer.json new file mode 100644 index 0000000..308f40e --- /dev/null +++ b/themes/chrosey/composer.json @@ -0,0 +1,38 @@ +{ + "name": "picocms/pico-theme", + "type": "pico-theme", + "description": "This is Pico's official default theme. Pico is a stupidly simple, blazing fast, flat file CMS.", + "keywords": [ "pico", "picocms", "picocms-theme", "pico-theme", "default-theme" ], + "homepage": "http://picocms.org/", + "license": "MIT", + "authors": [ + { + "name": "Daniel Rudolf", + "email": "picocms.org@daniel-rudolf.de", + "role": "Lead Developer" + }, + { + "name": "The Pico Community", + "homepage": "http://picocms.org/" + }, + { + "name": "Contributors", + "homepage": "https://github.com/picocms/pico-theme/graphs/contributors" + } + ], + "support": { + "docs": "http://picocms.org/themes/default/", + "issues": "https://github.com/picocms/pico-theme/issues", + "source": "https://github.com/picocms/pico-theme" + }, + "require": { + "picocms/pico": "self.version" + }, + "extra": { + "installer-name": "default", + "branch-alias": { + "dev-master": "2.0.x-dev", + "dev-pico-2.1": "2.1.x-dev" + } + } +} diff --git a/themes/chrosey/css/normalize.css b/themes/chrosey/css/normalize.css new file mode 100644 index 0000000..192eb9c --- /dev/null +++ b/themes/chrosey/css/normalize.css @@ -0,0 +1,349 @@ +/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */ + +/* Document + ========================================================================== */ + +/** + * 1. Correct the line height in all browsers. + * 2. Prevent adjustments of font size after orientation changes in iOS. + */ + +html { + line-height: 1.15; /* 1 */ + -webkit-text-size-adjust: 100%; /* 2 */ +} + +/* Sections + ========================================================================== */ + +/** + * Remove the margin in all browsers. + */ + +body { + margin: 0; +} + +/** + * Render the `main` element consistently in IE. + */ + +main { + display: block; +} + +/** + * Correct the font size and margin on `h1` elements within `section` and + * `article` contexts in Chrome, Firefox, and Safari. + */ + +h1 { + font-size: 2em; + margin: 0.67em 0; +} + +/* Grouping content + ========================================================================== */ + +/** + * 1. Add the correct box sizing in Firefox. + * 2. Show the overflow in Edge and IE. + */ + +hr { + box-sizing: content-box; /* 1 */ + height: 0; /* 1 */ + overflow: visible; /* 2 */ +} + +/** + * 1. Correct the inheritance and scaling of font size in all browsers. + * 2. Correct the odd `em` font sizing in all browsers. + */ + +pre { + font-family: monospace, monospace; /* 1 */ + font-size: 1em; /* 2 */ +} + +/* Text-level semantics + ========================================================================== */ + +/** + * Remove the gray background on active links in IE 10. + */ + +a { + background-color: transparent; +} + +/** + * 1. Remove the bottom border in Chrome 57- + * 2. Add the correct text decoration in Chrome, Edge, IE, Opera, and Safari. + */ + +abbr[title] { + border-bottom: none; /* 1 */ + text-decoration: underline; /* 2 */ + text-decoration: underline dotted; /* 2 */ +} + +/** + * Add the correct font weight in Chrome, Edge, and Safari. + */ + +b, +strong { + font-weight: bolder; +} + +/** + * 1. Correct the inheritance and scaling of font size in all browsers. + * 2. Correct the odd `em` font sizing in all browsers. + */ + +code, +kbd, +samp { + font-family: monospace, monospace; /* 1 */ + font-size: 1em; /* 2 */ +} + +/** + * Add the correct font size in all browsers. + */ + +small { + font-size: 80%; +} + +/** + * Prevent `sub` and `sup` elements from affecting the line height in + * all browsers. + */ + +sub, +sup { + font-size: 75%; + line-height: 0; + position: relative; + vertical-align: baseline; +} + +sub { + bottom: -0.25em; +} + +sup { + top: -0.5em; +} + +/* Embedded content + ========================================================================== */ + +/** + * Remove the border on images inside links in IE 10. + */ + +img { + border-style: none; +} + +/* Forms + ========================================================================== */ + +/** + * 1. Change the font styles in all browsers. + * 2. Remove the margin in Firefox and Safari. + */ + +button, +input, +optgroup, +select, +textarea { + font-family: inherit; /* 1 */ + font-size: 100%; /* 1 */ + line-height: 1.15; /* 1 */ + margin: 0; /* 2 */ +} + +/** + * Show the overflow in IE. + * 1. Show the overflow in Edge. + */ + +button, +input { /* 1 */ + overflow: visible; +} + +/** + * Remove the inheritance of text transform in Edge, Firefox, and IE. + * 1. Remove the inheritance of text transform in Firefox. + */ + +button, +select { /* 1 */ + text-transform: none; +} + +/** + * Correct the inability to style clickable types in iOS and Safari. + */ + +button, +[type="button"], +[type="reset"], +[type="submit"] { + -webkit-appearance: button; +} + +/** + * Remove the inner border and padding in Firefox. + */ + +button::-moz-focus-inner, +[type="button"]::-moz-focus-inner, +[type="reset"]::-moz-focus-inner, +[type="submit"]::-moz-focus-inner { + border-style: none; + padding: 0; +} + +/** + * Restore the focus styles unset by the previous rule. + */ + +button:-moz-focusring, +[type="button"]:-moz-focusring, +[type="reset"]:-moz-focusring, +[type="submit"]:-moz-focusring { + outline: 1px dotted ButtonText; +} + +/** + * Correct the padding in Firefox. + */ + +fieldset { + padding: 0.35em 0.75em 0.625em; +} + +/** + * 1. Correct the text wrapping in Edge and IE. + * 2. Correct the color inheritance from `fieldset` elements in IE. + * 3. Remove the padding so developers are not caught out when they zero out + * `fieldset` elements in all browsers. + */ + +legend { + box-sizing: border-box; /* 1 */ + color: inherit; /* 2 */ + display: table; /* 1 */ + max-width: 100%; /* 1 */ + padding: 0; /* 3 */ + white-space: normal; /* 1 */ +} + +/** + * Add the correct vertical alignment in Chrome, Firefox, and Opera. + */ + +progress { + vertical-align: baseline; +} + +/** + * Remove the default vertical scrollbar in IE 10+. + */ + +textarea { + overflow: auto; +} + +/** + * 1. Add the correct box sizing in IE 10. + * 2. Remove the padding in IE 10. + */ + +[type="checkbox"], +[type="radio"] { + box-sizing: border-box; /* 1 */ + padding: 0; /* 2 */ +} + +/** + * Correct the cursor style of increment and decrement buttons in Chrome. + */ + +[type="number"]::-webkit-inner-spin-button, +[type="number"]::-webkit-outer-spin-button { + height: auto; +} + +/** + * 1. Correct the odd appearance in Chrome and Safari. + * 2. Correct the outline style in Safari. + */ + +[type="search"] { + -webkit-appearance: textfield; /* 1 */ + outline-offset: -2px; /* 2 */ +} + +/** + * Remove the inner padding in Chrome and Safari on macOS. + */ + +[type="search"]::-webkit-search-decoration { + -webkit-appearance: none; +} + +/** + * 1. Correct the inability to style clickable types in iOS and Safari. + * 2. Change font properties to `inherit` in Safari. + */ + +::-webkit-file-upload-button { + -webkit-appearance: button; /* 1 */ + font: inherit; /* 2 */ +} + +/* Interactive + ========================================================================== */ + +/* + * Add the correct display in Edge, IE 10+, and Firefox. + */ + +details { + display: block; +} + +/* + * Add the correct display in all browsers. + */ + +summary { + display: list-item; +} + +/* Misc + ========================================================================== */ + +/** + * Add the correct display in IE 10+. + */ + +template { + display: none; +} + +/** + * Add the correct display in IE 10. + */ + +[hidden] { + display: none; +} diff --git a/themes/chrosey/css/style.css b/themes/chrosey/css/style.css new file mode 100644 index 0000000..e9ae73e --- /dev/null +++ b/themes/chrosey/css/style.css @@ -0,0 +1,128 @@ +@import url('https://fonts.googleapis.com/css?family=Alegreya|Allura|Caveat|Lato&display=swap'); + +:root { + --fore-color: black; + --secondary-fore-color: slategray; + --back-color: lightgray; + --secondary-back-color: #222; + --blockquote-color: #f57c00; + --pre-color: #1565c0; + --border-color: slategray; + --secondary-border-color: #aaa; + --heading-ratio: 1.19; + --universal-margin: 0.5rem; + --universal-padding: 0.5rem; + --universal-border-radius: 0.125rem; + --a-link-color: #0277bd; + --a-visited-color: #01579b; + + --nav-back-color: var(--back-color); + --nav-hover-back-color: rgba(0, 0, 0, 0.3); + --nav-fore-color: var(--fore-color); + --nav-border-color: var(--border-color); + --nav-link-color: var(--a-link-color); +} + +html { + background-color: var(--back-color); + font-family: 'Lato', sans-serif; +} + +* { + vertical-align: middle; +} + +blockquote { + font-family: 'Allura', sans-serif; +} + +body { + display: grid; + grid-template-columns: repeat(3, minmax(250px, 1fr)); + grid-template-rows: max-content; + grid-gap: 2rem; +} + +a { + text-decoration: none; +} + +a:link { + color: var(--a-link-color); +} + +a:visited { + color: var(--a-visited-color); +} + +a:hover, +a:focus { + text-decoration: underline; +} + +nav { + background: var(--nav-back-color); + color: var(--nav-fore-color); + border: 0.0625rem solid var(--nav-border-color); + border-radius: var(--universal-border-radius); + margin: var(--universal-margin); +} + +nav * { + padding: var(--universal-padding) calc(1.5 * var(--universal-padding)); +} + +a.nav-item:visited { + display: block; + color: var(--nav-link-color); + border-radius: var(--universal-border-radius); + transition: background 0.3s; +} + +.nav-item:hover, +.nav-item:focus, +.nav-item:visited:hover, +.nav-item:visited:focus { + text-decoration: none; + background: var(--nav-hover-back-color); +} + +.nav-item { + position: relative; + display: block; + transition: background .2s; + text-decoration: none; +} + +.nav-item.level-1, +.nav-item.level-2 { + position: relative; + margin-left: calc(2 * var(--universal-padding)); +} + +.nav-item.level-2 { + margin-left: calc(4 * var(--universal-padding)); +} + +.nav-item.level-1:before, +.nav-item.level-2:before { + position: absolute; + top: -0.0625rem; + content: ""; + height: 100%; + border: 0.0625rem solid var(--nav-border-color); + border-left: 0; +} + +.nav-item.level-1:before { + left: calc(var(--universal-padding) - 1 * var(--universal-padding)); +} + +.nav-item.level-2:before { + left: calc(var(--universal-padding) - 3 * var(--universal-padding)); +} + +header { + grid-column: 2 / 4; + background: lightblue; +} \ No newline at end of file diff --git a/themes/chrosey/js/site.js b/themes/chrosey/js/site.js new file mode 100644 index 0000000..e69de29 diff --git a/themes/chrosey/templates/blog/index.twig b/themes/chrosey/templates/blog/index.twig new file mode 100644 index 0000000..01ca44a --- /dev/null +++ b/themes/chrosey/templates/blog/index.twig @@ -0,0 +1,81 @@ + + + + + + + + {% if meta.title %}{{ meta.title }} | {% endif %}{{ site_title }} + {% if meta.description %} + + {% endif %} + {% if meta.robots %} + + {% endif %} + + {% if current_page %} + + {% endif %} + + + + + + + +
+ {{ site_title }} +
+ +
+
+ {% for page in pages("blog")|sort_by("time")|reverse if not page.hidden %} +
+

{{ page.title }}

+

{{ page.date_formatted }}

+

{{ page.description }}

+
+ {% endfor %} + {{ content }} +
+
+ + + + + + + + diff --git a/themes/chrosey/templates/blog/item.twig b/themes/chrosey/templates/blog/item.twig new file mode 100644 index 0000000..fcd1467 --- /dev/null +++ b/themes/chrosey/templates/blog/item.twig @@ -0,0 +1,42 @@ + + + + + + + {% if meta.title %}{{ meta.title }} | {% endif %}{{ site_title }} + {% if meta.description %} + + {% endif %} + {% if meta.robots %} + + {% endif %} + + {% if current_page %} + + {% endif %} + + + + + +
+ {{ meta.title }} - {{ site_title }} +
+ +
+
+ {{ content }} +
+
+ + + + + + + diff --git a/themes/chrosey/templates/index.twig b/themes/chrosey/templates/index.twig new file mode 100644 index 0000000..b2964e9 --- /dev/null +++ b/themes/chrosey/templates/index.twig @@ -0,0 +1,66 @@ + + + + + + + + {% if meta.title %}{{ meta.title }} | {% endif %}{{ site_title }} + {% if meta.description %} + + {% endif %} + {% if meta.robots %} + + {% endif %} + + {% if current_page %} + + {% endif %} + + + + + + +
+ + + {{ site_title }} + +
+ +
+
+ {{ content }} +
+
+ + + + + + + +