diff --git a/composer.json b/composer.json
index 4978860..fdeabef 100644
--- a/composer.json
+++ b/composer.json
@@ -9,7 +9,10 @@
"vendor-dir": "system/vendor",
"allow-plugins": {
"composer/installers": true
- }
+ },
+ "platform": {
+ "php": "8.0.0"
+ }
},
"require": {
"php": "^8.0",
@@ -21,8 +24,8 @@
"slim/flash": "^0.4.0",
"slim/csrf": "^1.2",
"vlucas/valitron": "^1.4",
- "symfony/yaml": "^6.0",
- "symfony/event-dispatcher": "^6.0",
+ "symfony/yaml": "^5.4",
+ "symfony/event-dispatcher": "^5.4",
"erusev/parsedown": "^1.8.0-beta-4",
"erusev/parsedown-extra": "dev-master",
"jbroadway/urlify": "1.1.3",
diff --git a/composer.lock b/composer.lock
index 66e966e..f5438a2 100644
--- a/composer.lock
+++ b/composer.lock
@@ -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": "841b98a23a247d8faad15d86df8cbeba",
+ "content-hash": "c3d172c51dcde3725ee22925a93865a5",
"packages": [
{
"name": "akrabat/proxy-detection-middleware",
@@ -342,20 +342,20 @@
},
{
"name": "laminas/laminas-permissions-acl",
- "version": "2.16.0",
+ "version": "2.14.0",
"source": {
"type": "git",
"url": "https://github.com/laminas/laminas-permissions-acl.git",
- "reference": "9f85ee3b1940cd5a1c4151ca16fdb738c162480b"
+ "reference": "86cecb540cf8f2e088d70d8acef1fc9203ed5023"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/laminas/laminas-permissions-acl/zipball/9f85ee3b1940cd5a1c4151ca16fdb738c162480b",
- "reference": "9f85ee3b1940cd5a1c4151ca16fdb738c162480b",
+ "url": "https://api.github.com/repos/laminas/laminas-permissions-acl/zipball/86cecb540cf8f2e088d70d8acef1fc9203ed5023",
+ "reference": "86cecb540cf8f2e088d70d8acef1fc9203ed5023",
"shasum": ""
},
"require": {
- "php": "~8.1.0 || ~8.2.0 || ~8.3.0"
+ "php": "~8.0.0 || ~8.1.0 || ~8.2.0"
},
"conflict": {
"laminas/laminas-servicemanager": "<3.0",
@@ -363,11 +363,11 @@
},
"require-dev": {
"laminas/laminas-coding-standard": "~2.5.0",
- "laminas/laminas-servicemanager": "^3.21",
- "phpbench/phpbench": "^1.2.10",
- "phpunit/phpunit": "^10.1.3",
- "psalm/plugin-phpunit": "^0.18.4",
- "vimeo/psalm": "^5.12"
+ "laminas/laminas-servicemanager": "^3.19",
+ "phpbench/phpbench": "^1.2",
+ "phpunit/phpunit": "^9.5.26",
+ "psalm/plugin-phpunit": "^0.18.0",
+ "vimeo/psalm": "^5.0"
},
"suggest": {
"laminas/laminas-servicemanager": "To support Laminas\\Permissions\\Acl\\Assertion\\AssertionManager plugin manager usage"
@@ -402,7 +402,7 @@
"type": "community_bridge"
}
],
- "time": "2023-10-18T07:50:34+00:00"
+ "time": "2023-02-01T16:19:54+00:00"
},
{
"name": "laravel/serializable-closure",
@@ -1515,25 +1515,25 @@
},
{
"name": "symfony/deprecation-contracts",
- "version": "v3.3.0",
+ "version": "v2.5.2",
"source": {
"type": "git",
"url": "https://github.com/symfony/deprecation-contracts.git",
- "reference": "7c3aff79d10325257a001fcf92d991f24fc967cf"
+ "reference": "e8b495ea28c1d97b5e0c121748d6f9b53d075c66"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/7c3aff79d10325257a001fcf92d991f24fc967cf",
- "reference": "7c3aff79d10325257a001fcf92d991f24fc967cf",
+ "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/e8b495ea28c1d97b5e0c121748d6f9b53d075c66",
+ "reference": "e8b495ea28c1d97b5e0c121748d6f9b53d075c66",
"shasum": ""
},
"require": {
- "php": ">=8.1"
+ "php": ">=7.1"
},
"type": "library",
"extra": {
"branch-alias": {
- "dev-main": "3.4-dev"
+ "dev-main": "2.5-dev"
},
"thanks": {
"name": "symfony/contracts",
@@ -1562,7 +1562,7 @@
"description": "A generic function and convention to trigger deprecation notices",
"homepage": "https://symfony.com",
"support": {
- "source": "https://github.com/symfony/deprecation-contracts/tree/v3.3.0"
+ "source": "https://github.com/symfony/deprecation-contracts/tree/v2.5.2"
},
"funding": [
{
@@ -1578,43 +1578,48 @@
"type": "tidelift"
}
],
- "time": "2023-05-23T14:45:45+00:00"
+ "time": "2022-01-02T09:53:40+00:00"
},
{
"name": "symfony/event-dispatcher",
- "version": "v6.3.2",
+ "version": "v5.4.26",
"source": {
"type": "git",
"url": "https://github.com/symfony/event-dispatcher.git",
- "reference": "adb01fe097a4ee930db9258a3cc906b5beb5cf2e"
+ "reference": "5dcc00e03413f05c1e7900090927bb7247cb0aac"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/adb01fe097a4ee930db9258a3cc906b5beb5cf2e",
- "reference": "adb01fe097a4ee930db9258a3cc906b5beb5cf2e",
+ "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/5dcc00e03413f05c1e7900090927bb7247cb0aac",
+ "reference": "5dcc00e03413f05c1e7900090927bb7247cb0aac",
"shasum": ""
},
"require": {
- "php": ">=8.1",
- "symfony/event-dispatcher-contracts": "^2.5|^3"
+ "php": ">=7.2.5",
+ "symfony/deprecation-contracts": "^2.1|^3",
+ "symfony/event-dispatcher-contracts": "^2|^3",
+ "symfony/polyfill-php80": "^1.16"
},
"conflict": {
- "symfony/dependency-injection": "<5.4",
- "symfony/service-contracts": "<2.5"
+ "symfony/dependency-injection": "<4.4"
},
"provide": {
"psr/event-dispatcher-implementation": "1.0",
- "symfony/event-dispatcher-implementation": "2.0|3.0"
+ "symfony/event-dispatcher-implementation": "2.0"
},
"require-dev": {
"psr/log": "^1|^2|^3",
- "symfony/config": "^5.4|^6.0",
- "symfony/dependency-injection": "^5.4|^6.0",
- "symfony/error-handler": "^5.4|^6.0",
- "symfony/expression-language": "^5.4|^6.0",
- "symfony/http-foundation": "^5.4|^6.0",
- "symfony/service-contracts": "^2.5|^3",
- "symfony/stopwatch": "^5.4|^6.0"
+ "symfony/config": "^4.4|^5.0|^6.0",
+ "symfony/dependency-injection": "^4.4|^5.0|^6.0",
+ "symfony/error-handler": "^4.4|^5.0|^6.0",
+ "symfony/expression-language": "^4.4|^5.0|^6.0",
+ "symfony/http-foundation": "^4.4|^5.0|^6.0",
+ "symfony/service-contracts": "^1.1|^2|^3",
+ "symfony/stopwatch": "^4.4|^5.0|^6.0"
+ },
+ "suggest": {
+ "symfony/dependency-injection": "",
+ "symfony/http-kernel": ""
},
"type": "library",
"autoload": {
@@ -1642,7 +1647,7 @@
"description": "Provides tools that allow your application components to communicate with each other by dispatching events and listening to them",
"homepage": "https://symfony.com",
"support": {
- "source": "https://github.com/symfony/event-dispatcher/tree/v6.3.2"
+ "source": "https://github.com/symfony/event-dispatcher/tree/v5.4.26"
},
"funding": [
{
@@ -1658,30 +1663,33 @@
"type": "tidelift"
}
],
- "time": "2023-07-06T06:56:43+00:00"
+ "time": "2023-07-06T06:34:20+00:00"
},
{
"name": "symfony/event-dispatcher-contracts",
- "version": "v3.3.0",
+ "version": "v2.5.2",
"source": {
"type": "git",
"url": "https://github.com/symfony/event-dispatcher-contracts.git",
- "reference": "a76aed96a42d2b521153fb382d418e30d18b59df"
+ "reference": "f98b54df6ad059855739db6fcbc2d36995283fe1"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/symfony/event-dispatcher-contracts/zipball/a76aed96a42d2b521153fb382d418e30d18b59df",
- "reference": "a76aed96a42d2b521153fb382d418e30d18b59df",
+ "url": "https://api.github.com/repos/symfony/event-dispatcher-contracts/zipball/f98b54df6ad059855739db6fcbc2d36995283fe1",
+ "reference": "f98b54df6ad059855739db6fcbc2d36995283fe1",
"shasum": ""
},
"require": {
- "php": ">=8.1",
+ "php": ">=7.2.5",
"psr/event-dispatcher": "^1"
},
+ "suggest": {
+ "symfony/event-dispatcher-implementation": ""
+ },
"type": "library",
"extra": {
"branch-alias": {
- "dev-main": "3.4-dev"
+ "dev-main": "2.5-dev"
},
"thanks": {
"name": "symfony/contracts",
@@ -1718,7 +1726,7 @@
"standards"
],
"support": {
- "source": "https://github.com/symfony/event-dispatcher-contracts/tree/v3.3.0"
+ "source": "https://github.com/symfony/event-dispatcher-contracts/tree/v2.5.2"
},
"funding": [
{
@@ -1734,27 +1742,26 @@
"type": "tidelift"
}
],
- "time": "2023-05-23T14:45:45+00:00"
+ "time": "2022-01-02T09:53:40+00:00"
},
{
"name": "symfony/finder",
- "version": "v6.3.5",
+ "version": "v5.4.27",
"source": {
"type": "git",
"url": "https://github.com/symfony/finder.git",
- "reference": "a1b31d88c0e998168ca7792f222cbecee47428c4"
+ "reference": "ff4bce3c33451e7ec778070e45bd23f74214cd5d"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/symfony/finder/zipball/a1b31d88c0e998168ca7792f222cbecee47428c4",
- "reference": "a1b31d88c0e998168ca7792f222cbecee47428c4",
+ "url": "https://api.github.com/repos/symfony/finder/zipball/ff4bce3c33451e7ec778070e45bd23f74214cd5d",
+ "reference": "ff4bce3c33451e7ec778070e45bd23f74214cd5d",
"shasum": ""
},
"require": {
- "php": ">=8.1"
- },
- "require-dev": {
- "symfony/filesystem": "^6.0"
+ "php": ">=7.2.5",
+ "symfony/deprecation-contracts": "^2.1|^3",
+ "symfony/polyfill-php80": "^1.16"
},
"type": "library",
"autoload": {
@@ -1782,7 +1789,7 @@
"description": "Finds files and directories via an intuitive fluent interface",
"homepage": "https://symfony.com",
"support": {
- "source": "https://github.com/symfony/finder/tree/v6.3.5"
+ "source": "https://github.com/symfony/finder/tree/v5.4.27"
},
"funding": [
{
@@ -1798,7 +1805,7 @@
"type": "tidelift"
}
],
- "time": "2023-09-26T12:56:25+00:00"
+ "time": "2023-07-31T08:02:31+00:00"
},
{
"name": "symfony/polyfill-ctype",
@@ -2129,28 +2136,31 @@
},
{
"name": "symfony/yaml",
- "version": "v6.3.7",
+ "version": "v5.4.30",
"source": {
"type": "git",
"url": "https://github.com/symfony/yaml.git",
- "reference": "9758b6c69d179936435d0ffb577c3708d57e38a8"
+ "reference": "c6980e82a6656f6ebfabfd82f7585794cb122554"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/symfony/yaml/zipball/9758b6c69d179936435d0ffb577c3708d57e38a8",
- "reference": "9758b6c69d179936435d0ffb577c3708d57e38a8",
+ "url": "https://api.github.com/repos/symfony/yaml/zipball/c6980e82a6656f6ebfabfd82f7585794cb122554",
+ "reference": "c6980e82a6656f6ebfabfd82f7585794cb122554",
"shasum": ""
},
"require": {
- "php": ">=8.1",
- "symfony/deprecation-contracts": "^2.5|^3",
+ "php": ">=7.2.5",
+ "symfony/deprecation-contracts": "^2.1|^3",
"symfony/polyfill-ctype": "^1.8"
},
"conflict": {
- "symfony/console": "<5.4"
+ "symfony/console": "<5.3"
},
"require-dev": {
- "symfony/console": "^5.4|^6.0"
+ "symfony/console": "^5.3|^6.0"
+ },
+ "suggest": {
+ "symfony/console": "For validating YAML files using the lint command"
},
"bin": [
"Resources/bin/yaml-lint"
@@ -2181,7 +2191,7 @@
"description": "Loads and dumps YAML files",
"homepage": "https://symfony.com",
"support": {
- "source": "https://github.com/symfony/yaml/tree/v6.3.7"
+ "source": "https://github.com/symfony/yaml/tree/v5.4.30"
},
"funding": [
{
@@ -2197,7 +2207,7 @@
"type": "tidelift"
}
],
- "time": "2023-10-28T23:31:00+00:00"
+ "time": "2023-10-27T18:36:14+00:00"
},
{
"name": "twig/twig",
@@ -2342,5 +2352,8 @@
"php": "^8.0"
},
"platform-dev": [],
+ "platform-overrides": {
+ "php": "8.0.0"
+ },
"plugin-api-version": "2.3.0"
}
diff --git a/content/00-welcome/05-todos.txt b/content/00-welcome/05-todos.txt
new file mode 100644
index 0000000..263d190
--- /dev/null
+++ b/content/00-welcome/05-todos.txt
@@ -0,0 +1 @@
+["# ToDos Version 2","[TOC]","## System settings","* DONE: Migrate from backend to frontend with vue and api\n* DONE: Redesign\n* DONE: License feature\n* DONE: Enhance with plugins","## Visual Editor ","* DONE: Refactor and redesign\n* DONE: Fix toc component in new block\n* DONE: Fix hr component in new block\n* DONE: finish shortcode component\n* DONE: Fix inline formats\n* DONE: fix lenght of page\n* DONE: Fix design of new block at the end (background color)\n* DONE: Move Block\n* DONE: Fix headline design\n* DONE: Fix save on two enter\n* DONE: fix quote design\n* DONE: Fix toc preview\n* DONE: disable enable \n* DONE: Add load sign (from navigation)\n* DONE: File is not published from tmp to media\/files if you save the block.","## Raw Editor","* DONE: Refactor and redesign\n* DONE: Integrate highlighting","## Navigation","* DONE: Refactor and redesign\n* DONE: fix status in navigation\n* DONE: refresh navigation after changes","## Publish Controller","* DONE: Refactor and redesign\n* DONE: Create \n* DONE: publish\n* DONE: unpublish\n* DONE: discard\n* DONE: delete\n* DONE: save draft\n* DONE: switch to raw","## Meta Tabs","* DONE: Refactor and redesign\n* DONE: Enhance with plugins","## Medialib","* DONE: Refactor and redesign","## Posts","* DONE: Refactor and redesign","## Plugins","* Asset Class in progress","## Frontend","* DONE: Refactor\n* DONE: Test restrictions","## Other big tasks","* DONE: System setup\n* DONE: Recover Password","## Medium tasks","* DONE: Merge processAssets modell\n* DONE: Table of content duplicated for published pages\n* DONE: Session handling: csrf fail and session start error if restrictions are active\n* DONE: Image and files for meta","## Open tasks","* DONE: Sitemap and ping\n* DONE: Version check\n* DONE: Proxy support\n* DONE: SVG checker: https:\/\/github.com\/TribalSystems\/SVG-Sanitizer\n* DONE: Backend form builder\n* DONE: Image generation on the fly\n* DONE: Delete folder in base level\n* DONE: Make folder delete easier with glob or scandir\n* DONE: fix error messages (check models)\n* DONE: error status codes (check middleware)\n* DONE: Warn if open another block\n* DONE: Customfields not styled yet\n* DOING: Fix error api systemnavi + validate\n* FIXED: System stores html or sends wrong error messsages\n* FIXED: Wrong frontend navigation if unpublished pages\n* DONE: Icon for hidden pages\n* DOING: Responsive design\n* DONE: Captcha integration\n* DONE: Solution for logo and favicon\n* FIXED: Raw editor jumps if you edit long text at the end\n* DONE: Typemill Utilities\n* DONE: Update CSS for themes\n* DONE: test with different user rights\n* Markdown secure rendering\n* finish youtube component\n* BUG: Error fields in account form not styled correctly\n* BUG: Codefield jumps on editing\n* False for owner on live?","## Dark Mode","* DONE: system \n* DONE: content-navigation\n* DONE: visual editor preview\n* DONE: visual editor edit modes\n* DONE: raw editor\n* DONE: meta\n* DONE: other tabs\n* DONE: modals\n* DONE: medialib\n* DONE: publish-bar.","## Feedback GitHub","* FIXED: Website restriction\n* NO ERROR: Change slug of blog\n* FIXED: undefined array key \"title\" in TwigMetaExtension on line 25\n* FIXED: CSS for navigation\n* DONE: Test with 8.2.7 (deprecation reports)\n* NOT REPRODUCED: Meta from home folder?\n* automatic generated password in firefox\n* FIXED: upload hero image in landinpage\n* FIXED: Restriction for custom css to 10000 characters\n* NOT REPRODUCED: Custom css l\u00f6schen => false","## later","* Handle formdata centrally ???\n* Reference Feature\n* Clear cache\n* Show security Log\n* User search only for +10 users\n* For api translations should be done completely in backoffice\n* Change translation files so they are loaded in settings instead of adding them manually to settings-defaults.yaml","## Cleanups:","* DONE: Events\n* DONE: Error messages\n* DONE: Translations","## Info: Select userroles","* Userroles for file restriction: in vue-blox-components loaded via api\n* Userroles for userfields: in php model user getUserFields()\n* Userroles for meta: in php controller apiAuthorMeta getMeta()\n* Plugins and themes: in php model extension getThemeDefinitions()","## Info: License Check","* On activation in apiControllerExtension. It checks the license in yaml.\n* In plugin php code with setPremiumLicense\n* In static plugins, it checks manual premium list and method setPremiumLicense and more ","## Plugins","* MAKER: Rebuild search\n* MAKER: Rebuild contactform with shortcode\n* MAKER: SEO\n* REQUIRED DOING: Directory Plugin\n* REQUIRED: Directory Theme\n* REQUIRED: Download\n* REQUIRED DONE: Version\n* REQUIRED DONE: Mailerlite \n* DONE: Search\n* DO: Analytics\n* DO: Contactform\n* DO: ebookproducts\n* DO: ebooks\n* DO: mail\n* DO: math\n* DO: register\n* DO: rss","## Status codes","| Status code | Description | \n|---|---|\n| 200 ok | cell | \n| 400 bad request | The request was unacceptable due to missing or invalid parameter. | \n| 401 unauthorized | The request requires an authorization. | \n| (402 request failed) | The parameters where there but the request failed for other reasons. | \n| 403 forbidden | The user is authenticated but he has not enough rights. | \n| 404 not found | new | \n| 500 internal server error | new |","## Upgrade","* Switch server to php 8.0 at least\n* Delete content of system folders\n* Upload new content of system folder with folders typemill and vendor\n* Backup and delete settings file \n* upload new index.php file\n* Upload new htaccess file\n* Delete theme folder\n* Uplload new cyanine-theme\n* Deactivate and delete all plugins."]
\ No newline at end of file
diff --git a/content/00-welcome/05-todos.yaml b/content/00-welcome/05-todos.yaml
index 2cd3140..226f61f 100644
--- a/content/00-welcome/05-todos.yaml
+++ b/content/00-welcome/05-todos.yaml
@@ -2,7 +2,7 @@ meta:
navtitle: 'To Dos'
title: 'A list of open tasks'
description: ' Visual Editor with more stuff'
- heroimage: media/live/screenshot-2023-08-03-at-15-23-44-setup-3.png
+ heroimage: ''
heroimagealt: ''
owner: 'Sebastian, testauthor'
author: ''
diff --git a/data/navigation/navi-draft.txt b/data/navigation/navi-draft.txt
index b7f3496..1a9c613 100644
--- a/data/navigation/navi-draft.txt
+++ b/data/navigation/navi-draft.txt
@@ -1 +1 @@
-a:2:{i:0;O:8:"stdClass":22:{s:12:"originalName";s:10:"00-welcome";s:11:"elementType";s:6:"folder";s:8:"contains";s:5:"pages";s:6:"status";s:9:"published";s:8:"fileType";s:2:"md";s:5:"order";s:2:"00";s:4:"name";s:7:"welcome";s:4:"slug";s:7:"welcome";s:4:"path";s:11:"/00-welcome";s:15:"pathWithoutType";s:17:"/00-welcome/index";s:9:"urlRelWoF";s:8:"/welcome";s:6:"urlRel";s:17:"/typemill/welcome";s:6:"urlAbs";s:33:"http://localhost/typemill/welcome";s:3:"key";i:0;s:7:"keyPath";i:0;s:12:"keyPathArray";a:1:{i:0;s:1:"0";}s:7:"chapter";i:1;s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:0;s:13:"folderContent";a:6:{i:0;O:8:"stdClass":20:{s:12:"originalName";s:24:"00-setup-your-website.md";s:11:"elementType";s:4:"file";s:6:"status";s:9:"published";s:8:"fileType";s:2:"md";s:5:"order";s:2:"00";s:4:"name";s:18:"setup your website";s:4:"slug";s:18:"setup-your-website";s:4:"path";s:36:"/00-welcome/00-setup-your-website.md";s:15:"pathWithoutType";s:33:"/00-welcome/00-setup-your-website";s:3:"key";i:0;s:7:"keyPath";s:3:"0.0";s:12:"keyPathArray";a:2:{i:0;s:1:"0";i:1;s:1:"0";}s:7:"chapter";s:3:"1.1";s:9:"urlRelWoF";s:27:"/welcome/setup-your-website";s:6:"urlRel";s:36:"/typemill/welcome/setup-your-website";s:6:"urlAbs";s:52:"http://localhost/typemill/welcome/setup-your-website";s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:0;s:7:"noindex";b:0;}i:1;O:8:"stdClass":20:{s:12:"originalName";s:19:"01-manage-access.md";s:11:"elementType";s:4:"file";s:6:"status";s:9:"published";s:8:"fileType";s:2:"md";s:5:"order";s:2:"01";s:4:"name";s:13:"manage access";s:4:"slug";s:13:"manage-access";s:4:"path";s:31:"/00-welcome/01-manage-access.md";s:15:"pathWithoutType";s:28:"/00-welcome/01-manage-access";s:3:"key";i:1;s:7:"keyPath";s:3:"0.1";s:12:"keyPathArray";a:2:{i:0;s:1:"0";i:1;s:1:"1";}s:7:"chapter";s:3:"1.2";s:9:"urlRelWoF";s:22:"/welcome/manage-access";s:6:"urlRel";s:31:"/typemill/welcome/manage-access";s:6:"urlAbs";s:47:"http://localhost/typemill/welcome/manage-access";s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:0;s:7:"noindex";b:0;}i:2;O:8:"stdClass":20:{s:12:"originalName";s:19:"02-write-content.md";s:11:"elementType";s:4:"file";s:6:"status";s:9:"published";s:8:"fileType";s:2:"md";s:5:"order";s:2:"02";s:4:"name";s:13:"write content";s:4:"slug";s:13:"write-content";s:4:"path";s:31:"/00-welcome/02-write-content.md";s:15:"pathWithoutType";s:28:"/00-welcome/02-write-content";s:3:"key";i:2;s:7:"keyPath";s:3:"0.2";s:12:"keyPathArray";a:2:{i:0;s:1:"0";i:1;s:1:"2";}s:7:"chapter";s:3:"1.3";s:9:"urlRelWoF";s:22:"/welcome/write-content";s:6:"urlRel";s:31:"/typemill/welcome/write-content";s:6:"urlAbs";s:47:"http://localhost/typemill/welcome/write-content";s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:1;s:7:"noindex";b:0;}i:3;O:8:"stdClass":20:{s:12:"originalName";s:14:"03-get-help.md";s:11:"elementType";s:4:"file";s:6:"status";s:9:"published";s:8:"fileType";s:2:"md";s:5:"order";s:2:"03";s:4:"name";s:8:"get help";s:4:"slug";s:8:"get-help";s:4:"path";s:26:"/00-welcome/03-get-help.md";s:15:"pathWithoutType";s:23:"/00-welcome/03-get-help";s:3:"key";i:3;s:7:"keyPath";s:3:"0.3";s:12:"keyPathArray";a:2:{i:0;s:1:"0";i:1;s:1:"3";}s:7:"chapter";s:3:"1.4";s:9:"urlRelWoF";s:17:"/welcome/get-help";s:6:"urlRel";s:26:"/typemill/welcome/get-help";s:6:"urlAbs";s:42:"http://localhost/typemill/welcome/get-help";s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:0;s:7:"noindex";b:0;}i:4;O:8:"stdClass":20:{s:12:"originalName";s:19:"04-markdown-test.md";s:11:"elementType";s:4:"file";s:6:"status";s:9:"published";s:8:"fileType";s:2:"md";s:5:"order";s:2:"04";s:4:"name";s:13:"markdown test";s:4:"slug";s:13:"markdown-test";s:4:"path";s:31:"/00-welcome/04-markdown-test.md";s:15:"pathWithoutType";s:28:"/00-welcome/04-markdown-test";s:3:"key";i:4;s:7:"keyPath";s:3:"0.4";s:12:"keyPathArray";a:2:{i:0;s:1:"0";i:1;s:1:"4";}s:7:"chapter";s:3:"1.5";s:9:"urlRelWoF";s:22:"/welcome/markdown-test";s:6:"urlRel";s:31:"/typemill/welcome/markdown-test";s:6:"urlAbs";s:47:"http://localhost/typemill/welcome/markdown-test";s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:0;s:7:"noindex";b:0;}i:5;O:8:"stdClass":20:{s:12:"originalName";s:11:"05-todos.md";s:11:"elementType";s:4:"file";s:6:"status";s:9:"published";s:8:"fileType";s:2:"md";s:5:"order";s:2:"05";s:4:"name";s:6:"To Dos";s:4:"slug";s:5:"todos";s:4:"path";s:23:"/00-welcome/05-todos.md";s:15:"pathWithoutType";s:20:"/00-welcome/05-todos";s:3:"key";i:5;s:7:"keyPath";s:3:"0.5";s:12:"keyPathArray";a:2:{i:0;s:1:"0";i:1;s:1:"5";}s:7:"chapter";s:3:"1.6";s:9:"urlRelWoF";s:14:"/welcome/todos";s:6:"urlRel";s:23:"/typemill/welcome/todos";s:6:"urlAbs";s:39:"http://localhost/typemill/welcome/todos";s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:0;s:7:"noindex";b:0;}}s:7:"noindex";b:0;}i:1;O:8:"stdClass":22:{s:12:"originalName";s:16:"01-cyanine-theme";s:11:"elementType";s:6:"folder";s:8:"contains";s:5:"pages";s:6:"status";s:9:"published";s:8:"fileType";s:2:"md";s:5:"order";s:2:"01";s:4:"name";s:13:"cyanine theme";s:4:"slug";s:13:"cyanine-theme";s:4:"path";s:17:"/01-cyanine-theme";s:15:"pathWithoutType";s:23:"/01-cyanine-theme/index";s:9:"urlRelWoF";s:14:"/cyanine-theme";s:6:"urlRel";s:23:"/typemill/cyanine-theme";s:6:"urlAbs";s:39:"http://localhost/typemill/cyanine-theme";s:3:"key";i:1;s:7:"keyPath";i:1;s:12:"keyPathArray";a:1:{i:0;s:1:"1";}s:7:"chapter";i:2;s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:0;s:13:"folderContent";a:4:{i:0;O:8:"stdClass":20:{s:12:"originalName";s:17:"00-landingpage.md";s:11:"elementType";s:4:"file";s:6:"status";s:9:"published";s:8:"fileType";s:2:"md";s:5:"order";s:2:"00";s:4:"name";s:11:"landingpage";s:4:"slug";s:11:"landingpage";s:4:"path";s:35:"/01-cyanine-theme/00-landingpage.md";s:15:"pathWithoutType";s:32:"/01-cyanine-theme/00-landingpage";s:3:"key";i:0;s:7:"keyPath";s:3:"1.0";s:12:"keyPathArray";a:2:{i:0;s:1:"1";i:1;s:1:"0";}s:7:"chapter";s:3:"2.1";s:9:"urlRelWoF";s:26:"/cyanine-theme/landingpage";s:6:"urlRel";s:35:"/typemill/cyanine-theme/landingpage";s:6:"urlAbs";s:51:"http://localhost/typemill/cyanine-theme/landingpage";s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:0;s:7:"noindex";b:1;}i:1;O:8:"stdClass":20:{s:12:"originalName";s:22:"01-colors-and-fonts.md";s:11:"elementType";s:4:"file";s:6:"status";s:9:"published";s:8:"fileType";s:2:"md";s:5:"order";s:2:"01";s:4:"name";s:16:"colors and fonts";s:4:"slug";s:16:"colors-and-fonts";s:4:"path";s:40:"/01-cyanine-theme/01-colors-and-fonts.md";s:15:"pathWithoutType";s:37:"/01-cyanine-theme/01-colors-and-fonts";s:3:"key";i:1;s:7:"keyPath";s:3:"1.1";s:12:"keyPathArray";a:2:{i:0;s:1:"1";i:1;s:1:"1";}s:7:"chapter";s:3:"2.2";s:9:"urlRelWoF";s:31:"/cyanine-theme/colors-and-fonts";s:6:"urlRel";s:40:"/typemill/cyanine-theme/colors-and-fonts";s:6:"urlAbs";s:56:"http://localhost/typemill/cyanine-theme/colors-and-fonts";s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:0;s:7:"noindex";b:0;}i:2;O:8:"stdClass":20:{s:12:"originalName";s:12:"02-footer.md";s:11:"elementType";s:4:"file";s:6:"status";s:9:"published";s:8:"fileType";s:2:"md";s:5:"order";s:2:"02";s:4:"name";s:6:"footer";s:4:"slug";s:6:"footer";s:4:"path";s:30:"/01-cyanine-theme/02-footer.md";s:15:"pathWithoutType";s:27:"/01-cyanine-theme/02-footer";s:3:"key";i:2;s:7:"keyPath";s:3:"1.2";s:12:"keyPathArray";a:2:{i:0;s:1:"1";i:1;s:1:"2";}s:7:"chapter";s:3:"2.3";s:9:"urlRelWoF";s:21:"/cyanine-theme/footer";s:6:"urlRel";s:30:"/typemill/cyanine-theme/footer";s:6:"urlAbs";s:46:"http://localhost/typemill/cyanine-theme/footer";s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:0;s:7:"noindex";b:0;}i:3;O:8:"stdClass":20:{s:12:"originalName";s:22:"03-content-elements.md";s:11:"elementType";s:4:"file";s:6:"status";s:9:"published";s:8:"fileType";s:2:"md";s:5:"order";s:2:"03";s:4:"name";s:16:"content elements";s:4:"slug";s:16:"content-elements";s:4:"path";s:40:"/01-cyanine-theme/03-content-elements.md";s:15:"pathWithoutType";s:37:"/01-cyanine-theme/03-content-elements";s:3:"key";i:3;s:7:"keyPath";s:3:"1.3";s:12:"keyPathArray";a:2:{i:0;s:1:"1";i:1;s:1:"3";}s:7:"chapter";s:3:"2.4";s:9:"urlRelWoF";s:31:"/cyanine-theme/content-elements";s:6:"urlRel";s:40:"/typemill/cyanine-theme/content-elements";s:6:"urlAbs";s:56:"http://localhost/typemill/cyanine-theme/content-elements";s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:0;s:7:"noindex";b:0;}}s:7:"noindex";b:0;}}
\ No newline at end of file
+a:2:{i:0;O:8:"stdClass":22:{s:12:"originalName";s:10:"00-welcome";s:11:"elementType";s:6:"folder";s:8:"contains";s:5:"pages";s:6:"status";s:9:"published";s:8:"fileType";s:2:"md";s:5:"order";s:2:"00";s:4:"name";s:7:"welcome";s:4:"slug";s:7:"welcome";s:4:"path";s:11:"/00-welcome";s:15:"pathWithoutType";s:17:"/00-welcome/index";s:9:"urlRelWoF";s:8:"/welcome";s:6:"urlRel";s:17:"/typemill/welcome";s:6:"urlAbs";s:33:"http://localhost/typemill/welcome";s:3:"key";i:0;s:7:"keyPath";i:0;s:12:"keyPathArray";a:1:{i:0;s:1:"0";}s:7:"chapter";i:1;s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:0;s:13:"folderContent";a:6:{i:0;O:8:"stdClass":20:{s:12:"originalName";s:24:"00-setup-your-website.md";s:11:"elementType";s:4:"file";s:6:"status";s:9:"published";s:8:"fileType";s:2:"md";s:5:"order";s:2:"00";s:4:"name";s:18:"setup your website";s:4:"slug";s:18:"setup-your-website";s:4:"path";s:36:"/00-welcome/00-setup-your-website.md";s:15:"pathWithoutType";s:33:"/00-welcome/00-setup-your-website";s:3:"key";i:0;s:7:"keyPath";s:3:"0.0";s:12:"keyPathArray";a:2:{i:0;s:1:"0";i:1;s:1:"0";}s:7:"chapter";s:3:"1.1";s:9:"urlRelWoF";s:27:"/welcome/setup-your-website";s:6:"urlRel";s:36:"/typemill/welcome/setup-your-website";s:6:"urlAbs";s:52:"http://localhost/typemill/welcome/setup-your-website";s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:0;s:7:"noindex";b:0;}i:1;O:8:"stdClass":20:{s:12:"originalName";s:19:"01-manage-access.md";s:11:"elementType";s:4:"file";s:6:"status";s:9:"published";s:8:"fileType";s:2:"md";s:5:"order";s:2:"01";s:4:"name";s:13:"manage access";s:4:"slug";s:13:"manage-access";s:4:"path";s:31:"/00-welcome/01-manage-access.md";s:15:"pathWithoutType";s:28:"/00-welcome/01-manage-access";s:3:"key";i:1;s:7:"keyPath";s:3:"0.1";s:12:"keyPathArray";a:2:{i:0;s:1:"0";i:1;s:1:"1";}s:7:"chapter";s:3:"1.2";s:9:"urlRelWoF";s:22:"/welcome/manage-access";s:6:"urlRel";s:31:"/typemill/welcome/manage-access";s:6:"urlAbs";s:47:"http://localhost/typemill/welcome/manage-access";s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:0;s:7:"noindex";b:0;}i:2;O:8:"stdClass":20:{s:12:"originalName";s:19:"02-write-content.md";s:11:"elementType";s:4:"file";s:6:"status";s:9:"published";s:8:"fileType";s:2:"md";s:5:"order";s:2:"02";s:4:"name";s:13:"write content";s:4:"slug";s:13:"write-content";s:4:"path";s:31:"/00-welcome/02-write-content.md";s:15:"pathWithoutType";s:28:"/00-welcome/02-write-content";s:3:"key";i:2;s:7:"keyPath";s:3:"0.2";s:12:"keyPathArray";a:2:{i:0;s:1:"0";i:1;s:1:"2";}s:7:"chapter";s:3:"1.3";s:9:"urlRelWoF";s:22:"/welcome/write-content";s:6:"urlRel";s:31:"/typemill/welcome/write-content";s:6:"urlAbs";s:47:"http://localhost/typemill/welcome/write-content";s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:1;s:7:"noindex";b:0;}i:3;O:8:"stdClass":20:{s:12:"originalName";s:14:"03-get-help.md";s:11:"elementType";s:4:"file";s:6:"status";s:9:"published";s:8:"fileType";s:2:"md";s:5:"order";s:2:"03";s:4:"name";s:8:"get help";s:4:"slug";s:8:"get-help";s:4:"path";s:26:"/00-welcome/03-get-help.md";s:15:"pathWithoutType";s:23:"/00-welcome/03-get-help";s:3:"key";i:3;s:7:"keyPath";s:3:"0.3";s:12:"keyPathArray";a:2:{i:0;s:1:"0";i:1;s:1:"3";}s:7:"chapter";s:3:"1.4";s:9:"urlRelWoF";s:17:"/welcome/get-help";s:6:"urlRel";s:26:"/typemill/welcome/get-help";s:6:"urlAbs";s:42:"http://localhost/typemill/welcome/get-help";s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:0;s:7:"noindex";b:0;}i:4;O:8:"stdClass":20:{s:12:"originalName";s:19:"04-markdown-test.md";s:11:"elementType";s:4:"file";s:6:"status";s:9:"published";s:8:"fileType";s:2:"md";s:5:"order";s:2:"04";s:4:"name";s:13:"markdown test";s:4:"slug";s:13:"markdown-test";s:4:"path";s:31:"/00-welcome/04-markdown-test.md";s:15:"pathWithoutType";s:28:"/00-welcome/04-markdown-test";s:3:"key";i:4;s:7:"keyPath";s:3:"0.4";s:12:"keyPathArray";a:2:{i:0;s:1:"0";i:1;s:1:"4";}s:7:"chapter";s:3:"1.5";s:9:"urlRelWoF";s:22:"/welcome/markdown-test";s:6:"urlRel";s:31:"/typemill/welcome/markdown-test";s:6:"urlAbs";s:47:"http://localhost/typemill/welcome/markdown-test";s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:0;s:7:"noindex";b:0;}i:5;O:8:"stdClass":20:{s:12:"originalName";s:14:"05-todos.txtmd";s:11:"elementType";s:4:"file";s:6:"status";s:8:"modified";s:8:"fileType";s:3:"txt";s:5:"order";s:2:"05";s:4:"name";s:6:"To Dos";s:4:"slug";s:5:"todos";s:4:"path";s:26:"/00-welcome/05-todos.txtmd";s:15:"pathWithoutType";s:20:"/00-welcome/05-todos";s:3:"key";i:5;s:7:"keyPath";s:3:"0.5";s:12:"keyPathArray";a:2:{i:0;s:1:"0";i:1;s:1:"5";}s:7:"chapter";s:3:"1.6";s:9:"urlRelWoF";s:14:"/welcome/todos";s:6:"urlRel";s:23:"/typemill/welcome/todos";s:6:"urlAbs";s:39:"http://localhost/typemill/welcome/todos";s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:0;s:7:"noindex";b:0;}}s:7:"noindex";b:0;}i:1;O:8:"stdClass":22:{s:12:"originalName";s:16:"01-cyanine-theme";s:11:"elementType";s:6:"folder";s:8:"contains";s:5:"pages";s:6:"status";s:9:"published";s:8:"fileType";s:2:"md";s:5:"order";s:2:"01";s:4:"name";s:13:"cyanine theme";s:4:"slug";s:13:"cyanine-theme";s:4:"path";s:17:"/01-cyanine-theme";s:15:"pathWithoutType";s:23:"/01-cyanine-theme/index";s:9:"urlRelWoF";s:14:"/cyanine-theme";s:6:"urlRel";s:23:"/typemill/cyanine-theme";s:6:"urlAbs";s:39:"http://localhost/typemill/cyanine-theme";s:3:"key";i:1;s:7:"keyPath";i:1;s:12:"keyPathArray";a:1:{i:0;s:1:"1";}s:7:"chapter";i:2;s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:0;s:13:"folderContent";a:4:{i:0;O:8:"stdClass":20:{s:12:"originalName";s:17:"00-landingpage.md";s:11:"elementType";s:4:"file";s:6:"status";s:9:"published";s:8:"fileType";s:2:"md";s:5:"order";s:2:"00";s:4:"name";s:11:"landingpage";s:4:"slug";s:11:"landingpage";s:4:"path";s:35:"/01-cyanine-theme/00-landingpage.md";s:15:"pathWithoutType";s:32:"/01-cyanine-theme/00-landingpage";s:3:"key";i:0;s:7:"keyPath";s:3:"1.0";s:12:"keyPathArray";a:2:{i:0;s:1:"1";i:1;s:1:"0";}s:7:"chapter";s:3:"2.1";s:9:"urlRelWoF";s:26:"/cyanine-theme/landingpage";s:6:"urlRel";s:35:"/typemill/cyanine-theme/landingpage";s:6:"urlAbs";s:51:"http://localhost/typemill/cyanine-theme/landingpage";s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:0;s:7:"noindex";b:1;}i:1;O:8:"stdClass":20:{s:12:"originalName";s:22:"01-colors-and-fonts.md";s:11:"elementType";s:4:"file";s:6:"status";s:9:"published";s:8:"fileType";s:2:"md";s:5:"order";s:2:"01";s:4:"name";s:16:"colors and fonts";s:4:"slug";s:16:"colors-and-fonts";s:4:"path";s:40:"/01-cyanine-theme/01-colors-and-fonts.md";s:15:"pathWithoutType";s:37:"/01-cyanine-theme/01-colors-and-fonts";s:3:"key";i:1;s:7:"keyPath";s:3:"1.1";s:12:"keyPathArray";a:2:{i:0;s:1:"1";i:1;s:1:"1";}s:7:"chapter";s:3:"2.2";s:9:"urlRelWoF";s:31:"/cyanine-theme/colors-and-fonts";s:6:"urlRel";s:40:"/typemill/cyanine-theme/colors-and-fonts";s:6:"urlAbs";s:56:"http://localhost/typemill/cyanine-theme/colors-and-fonts";s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:0;s:7:"noindex";b:0;}i:2;O:8:"stdClass":20:{s:12:"originalName";s:12:"02-footer.md";s:11:"elementType";s:4:"file";s:6:"status";s:9:"published";s:8:"fileType";s:2:"md";s:5:"order";s:2:"02";s:4:"name";s:6:"footer";s:4:"slug";s:6:"footer";s:4:"path";s:30:"/01-cyanine-theme/02-footer.md";s:15:"pathWithoutType";s:27:"/01-cyanine-theme/02-footer";s:3:"key";i:2;s:7:"keyPath";s:3:"1.2";s:12:"keyPathArray";a:2:{i:0;s:1:"1";i:1;s:1:"2";}s:7:"chapter";s:3:"2.3";s:9:"urlRelWoF";s:21:"/cyanine-theme/footer";s:6:"urlRel";s:30:"/typemill/cyanine-theme/footer";s:6:"urlAbs";s:46:"http://localhost/typemill/cyanine-theme/footer";s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:0;s:7:"noindex";b:0;}i:3;O:8:"stdClass":20:{s:12:"originalName";s:22:"03-content-elements.md";s:11:"elementType";s:4:"file";s:6:"status";s:9:"published";s:8:"fileType";s:2:"md";s:5:"order";s:2:"03";s:4:"name";s:16:"content elements";s:4:"slug";s:16:"content-elements";s:4:"path";s:40:"/01-cyanine-theme/03-content-elements.md";s:15:"pathWithoutType";s:37:"/01-cyanine-theme/03-content-elements";s:3:"key";i:3;s:7:"keyPath";s:3:"1.3";s:12:"keyPathArray";a:2:{i:0;s:1:"1";i:1;s:1:"3";}s:7:"chapter";s:3:"2.4";s:9:"urlRelWoF";s:31:"/cyanine-theme/content-elements";s:6:"urlRel";s:40:"/typemill/cyanine-theme/content-elements";s:6:"urlAbs";s:56:"http://localhost/typemill/cyanine-theme/content-elements";s:6:"active";b:0;s:12:"activeParent";b:0;s:4:"hide";b:0;s:7:"noindex";b:0;}}s:7:"noindex";b:0;}}
\ No newline at end of file
diff --git a/data/navigation/navi-extended.txt b/data/navigation/navi-extended.txt
index 17de291..9096508 100644
--- a/data/navigation/navi-extended.txt
+++ b/data/navigation/navi-extended.txt
@@ -38,7 +38,7 @@
navtitle: 'To Dos'
hide: false
noindex: false
- path: /00-welcome/05-todos.md
+ path: /00-welcome/05-todos.txtmd
keyPath: '0.5'
/cyanine-theme:
navtitle: 'cyanine theme'
diff --git a/system/typemill/Assets.php b/system/typemill/Assets.php
index f2936fb..e3d5c59 100644
--- a/system/typemill/Assets.php
+++ b/system/typemill/Assets.php
@@ -10,7 +10,29 @@ use Typemill\Models\StorageWrapper;
class Assets
{
public $baseUrl;
-
+
+ public $JS;
+
+ public $CSS;
+
+ public $inlineJS;
+
+ public $inlineCSS;
+
+ public $editorJS;
+
+ public $editorCSS;
+
+ public $editorInlineJS;
+
+ public $svgSymbols;
+
+ public $meta;
+
+ public $imageUrl;
+
+ public $imageFolder;
+
public function __construct($baseUrl)
{
$this->baseUrl = $baseUrl;
@@ -69,7 +91,7 @@ class Assets
public function activateVue()
{
- $vueUrl = '';
+ $vueUrl = '';
if(!in_array($vueUrl, $this->JS))
{
$this->JS[] = $vueUrl;
@@ -90,6 +112,7 @@ class Assets
public function activateTachyons()
{
+ die('Hi from asset class, Tachyons not available in Typemill v2');
$tachyonsUrl = '';
if(!in_array($tachyonsUrl, $this->CSS))
{
diff --git a/system/typemill/Controllers/ControllerApiAuthorArticle.php b/system/typemill/Controllers/ControllerApiAuthorArticle.php
index b35d51b..42ab4cb 100644
--- a/system/typemill/Controllers/ControllerApiAuthorArticle.php
+++ b/system/typemill/Controllers/ControllerApiAuthorArticle.php
@@ -99,12 +99,16 @@ class ControllerApiAuthorArticle extends Controller
'item' => $item,
'metadata' => $metadata
];
- $this->c->get('dispatcher')->dispatch(new OnPagePublished($data), 'onPagePublished');
+
+ $message = $this->c->get('dispatcher')->dispatch(new OnPagePublished($data), 'onPagePublished')->getData();
+
+ # validate message
$response->getBody()->write(json_encode([
'navigation' => $draftNavigation,
'item' => $item,
- 'metadata' => $metadata
+ 'metadata' => $metadata,
+ 'message' => $message
]));
return $response->withHeader('Content-Type', 'application/json');
diff --git a/system/typemill/Controllers/ControllerApiSystemExtensions.php b/system/typemill/Controllers/ControllerApiSystemExtensions.php
index 21d31c4..b74ea12 100644
--- a/system/typemill/Controllers/ControllerApiSystemExtensions.php
+++ b/system/typemill/Controllers/ControllerApiSystemExtensions.php
@@ -30,19 +30,11 @@ class ControllerApiSystemExtensions extends Controller
return $response->withHeader('Content-Type', 'application/json')->withStatus(400);
}
- if(!isset($this->settings[$params['type']][$params['name']]))
- {
- $response->getBody()->write(json_encode([
- 'message' => Translations::translate('The plugin or themes was not found.'),
- ]));
-
- return $response->withHeader('Content-Type', 'application/json')->withStatus(404);
- }
-
if($params['checked'] == true)
{
$extension = new Extension();
+ $definitions = false;
if($params['type'] == 'plugins')
{
$definitions = $extension->getPluginDefinition($params['name']);
@@ -51,6 +43,14 @@ class ControllerApiSystemExtensions extends Controller
{
$definitions = $extension->getThemeDefinition($params['name']);
}
+ if(!$definitions)
+ {
+ $response->getBody()->write(json_encode([
+ 'message' => Translations::translate('The plugin or themes was not found.'),
+ ]));
+
+ return $response->withHeader('Content-Type', 'application/json')->withStatus(404);
+ }
if(isset($definitions['license']) && in_array($definitions['license'], ['MAKER', 'BUSINESS']))
{
diff --git a/system/typemill/Controllers/ControllerWebSystem.php b/system/typemill/Controllers/ControllerWebSystem.php
index d9d42e0..7ffd72e 100644
--- a/system/typemill/Controllers/ControllerWebSystem.php
+++ b/system/typemill/Controllers/ControllerWebSystem.php
@@ -72,7 +72,7 @@ class ControllerWebSystem extends Controller
);
$extension = new Extension();
- $themeDefinitions = $extension->getThemeDetails();
+ $themeDefinitions = $extension->getThemeDetails($this->settings['theme']);
# add userroles and other datasets
foreach($themeDefinitions as $name => $definitions)
@@ -126,7 +126,7 @@ class ControllerWebSystem extends Controller
);
$extension = new Extension();
- $pluginDefinitions = $extension->getPluginDetails();
+ $pluginDefinitions = $extension->getPluginDetails($this->settings['plugins']);
# add userroles and other datasets
foreach($pluginDefinitions as $name => $definitions)
@@ -137,7 +137,8 @@ class ControllerWebSystem extends Controller
}
}
- $pluginSettings = $extension->getPluginSettings($this->settings['plugins']);
+# $pluginSettings = $extension->getPluginSettings($this->settings['plugins']);
+ $pluginSettings = $this->settings['plugins'];
$license = [];
if(is_array($this->settings['license']))
@@ -150,7 +151,7 @@ class ControllerWebSystem extends Controller
'darkmode' => $request->getAttribute('c_darkmode'),
'mainnavi' => $mainNavigation,
'jsdata' => [
- 'systemnavi' => $systemNavigation,
+ 'systemnavi' => $systemNavigation,
'settings' => $pluginSettings,
'definitions' => $pluginDefinitions,
'license' => $license,
diff --git a/system/typemill/Extensions/ParsedownExtension.php b/system/typemill/Extensions/ParsedownExtension.php
index ffcd751..f64ee30 100644
--- a/system/typemill/Extensions/ParsedownExtension.php
+++ b/system/typemill/Extensions/ParsedownExtension.php
@@ -7,6 +7,17 @@ use Typemill\Events\OnShortcodeFound;
class ParsedownExtension extends \ParsedownExtra
{
+
+ private $settings;
+
+ private $dispatcher;
+
+ private $showAnchor;
+
+ private $visualMode;
+
+ private $baseUrl;
+
function __construct($baseUrl = '', $settings = NULL, $dispatcher = NULL)
{
parent::__construct();
diff --git a/system/typemill/Middleware/ApiAuthorization.php b/system/typemill/Middleware/ApiAuthorization.php
index 935511f..c21c940 100644
--- a/system/typemill/Middleware/ApiAuthorization.php
+++ b/system/typemill/Middleware/ApiAuthorization.php
@@ -11,6 +11,13 @@ use Typemill\Static\Translations;
class ApiAuthorization implements MiddlewareInterface
{
+
+ private $acl;
+
+ private $resource;
+
+ private $action;
+
public function __construct($acl, string $resource = NULL, string $action = NULL)
{
$this->acl = $acl;
diff --git a/system/typemill/Middleware/FlashMessages.php b/system/typemill/Middleware/FlashMessages.php
index 1a6ce28..9bcb7bc 100644
--- a/system/typemill/Middleware/FlashMessages.php
+++ b/system/typemill/Middleware/FlashMessages.php
@@ -7,7 +7,9 @@ use Psr\Http\Server\RequestHandlerInterface as RequestHandler;
use Slim\Flash\Messages;
class FlashMessages
-{
+{
+ private $container;
+
public function __construct($container)
{
$this->container = $container;
diff --git a/system/typemill/Middleware/WebAuthorization.php b/system/typemill/Middleware/WebAuthorization.php
index 573e40c..a065c1f 100644
--- a/system/typemill/Middleware/WebAuthorization.php
+++ b/system/typemill/Middleware/WebAuthorization.php
@@ -10,6 +10,15 @@ use Slim\Psr7\Response;
class WebAuthorization implements MiddlewareInterface
{
+
+ private $router;
+
+ private $acl;
+
+ private $resource;
+
+ private $action;
+
public function __construct(RouteParser $router, $acl, string $resource = NULL, string $action = NULL)
{
$this->router = $router;
diff --git a/system/typemill/Middleware/WebRedirectIfAuthenticated.php b/system/typemill/Middleware/WebRedirectIfAuthenticated.php
index 90abafb..500bc8f 100644
--- a/system/typemill/Middleware/WebRedirectIfAuthenticated.php
+++ b/system/typemill/Middleware/WebRedirectIfAuthenticated.php
@@ -9,7 +9,11 @@ use Psr\Http\Server\RequestHandlerInterface as RequestHandler;
use Slim\Psr7\Response;
class WebRedirectIfAuthenticated implements MiddlewareInterface
-{
+{
+ private $router;
+
+ private $settings;
+
public function __construct(RouteParser $router, $settings)
{
$this->router = $router;
diff --git a/system/typemill/Middleware/WebRedirectIfUnauthenticated.php b/system/typemill/Middleware/WebRedirectIfUnauthenticated.php
index ee2fdcd..6d089fc 100644
--- a/system/typemill/Middleware/WebRedirectIfUnauthenticated.php
+++ b/system/typemill/Middleware/WebRedirectIfUnauthenticated.php
@@ -11,6 +11,8 @@ use Typemill\Models\User;
class WebRedirectIfUnauthenticated implements MiddlewareInterface
{
+ private $router;
+
public function __construct(RouteParser $router)
{
$this->router = $router;
diff --git a/system/typemill/Models/Content.php b/system/typemill/Models/Content.php
index 0323a93..3eaadeb 100644
--- a/system/typemill/Models/Content.php
+++ b/system/typemill/Models/Content.php
@@ -9,6 +9,8 @@ class Content
{
private $storage;
+ private $parsedown;
+
public function __construct($baseurl = NULL, $settings = NULL, $dispatcher = NULL)
{
$this->storage = new StorageWrapper('\Typemill\Models\Storage');
diff --git a/system/typemill/Models/Extension.php b/system/typemill/Models/Extension.php
index bbec91e..46232d0 100644
--- a/system/typemill/Models/Extension.php
+++ b/system/typemill/Models/Extension.php
@@ -14,25 +14,46 @@ class Extension
$this->storage = new StorageWrapper('\Typemill\Models\Storage');
}
- public function getThemeDetails()
+ public function getThemeDetails($activeThemeName = NULL)
{
$themes = $this->getThemes();
$themeDetails = [];
foreach($themes as $themeName)
{
- $themeDetails[$themeName] = $this->getThemeDefinition($themeName);
+ $details = $this->getThemeDefinition($themeName);
+ if($details && isset($details['name']))
+ {
+ # add to first position if active
+ if($activeThemeName && ($activeThemeName == $themeName))
+ {
+ $themeDetails = array_merge(array($themeName => $details), $themeDetails);
+ }
+ else
+ {
+ $themeDetails[$themeName] = $details;
+ }
+ }
}
return $themeDetails;
}
- public function getThemeSettings($themes)
+ public function getThemeSettings($themesInSettings)
{
+ # WHAT ABOUT DEFAULT-SETTINGS FROM THEME YAMLs?
+
+ $themes = $this->getThemes();
+
$themeSettings = [];
- foreach($themes as $themename => $themeinputs)
+ foreach($themes as $themename)
{
- if(!is_array($themeinputs)){ $themeinputs = []; }
+ $themeinputs = [];
+ if(isset($themesInSettings[$themename]))
+ {
+ $themeinputs = $themesInSettings[$themename];
+ }
+
$themeSettings[$themename] = $themeinputs;
$themeSettings[$themename]['customcss'] = $this->storage->getFile('cacheFolder', '', $themename . '-custom.css');
}
@@ -40,6 +61,7 @@ class Extension
return $themeSettings;
}
+
public function getThemes()
{
$themeFolder = $this->storage->getFolderPath('themesFolder');
@@ -71,36 +93,39 @@ class Extension
'description' => Translations::translate('You can overwrite the theme-css with your own css here.')
];
-# add image preview file
$themeSettings['preview'] = '/themes/' . $themeName . '/' . $themeName . '.png';
return $themeSettings;
}
- public function getPluginDetails()
+ public function getPluginDetails($userSettings = NULL)
{
$plugins = $this->getPlugins();
$pluginDetails = [];
foreach($plugins as $pluginName)
{
- $pluginDetails[$pluginName] = $this->getPluginDefinition($pluginName);
+ $details = $this->getPluginDefinition($pluginName);
+ if($details && $details['name'])
+ {
+ # add active plugins first
+ if(
+ $userSettings
+ && isset($userSettings[$pluginName])
+ && ($userSettings[$pluginName]['active'] == true)
+ )
+ {
+ $pluginDetails = array_merge(array($pluginName => $details), $pluginDetails);
+ }
+ else
+ {
+ $pluginDetails[$pluginName] = $details;
+ }
+ }
}
-
return $pluginDetails;
}
- public function getPluginSettings($plugins)
- {
- $pluginSettings = [];
- foreach($plugins as $pluginname => $plugininputs)
- {
- $pluginSettings[$pluginname] = $plugininputs;
- }
-
- return $pluginSettings;
- }
-
public function getPlugins()
{
$pluginFolder = $this->storage->getFolderPath('pluginsFolder');
diff --git a/system/typemill/Models/Storage.php b/system/typemill/Models/Storage.php
index 9a70412..48c9f73 100644
--- a/system/typemill/Models/Storage.php
+++ b/system/typemill/Models/Storage.php
@@ -41,7 +41,7 @@ class Storage
protected $isReadable = [];
- protected $isWrtiable = [];
+ protected $isWritable = [];
public function __construct()
{
diff --git a/system/typemill/Models/User.php b/system/typemill/Models/User.php
index 5b09f23..33516ba 100644
--- a/system/typemill/Models/User.php
+++ b/system/typemill/Models/User.php
@@ -9,6 +9,8 @@ class User
{
private $userDir;
+ private $storage;
+
private $yaml;
private $user = false;
diff --git a/system/typemill/Plugin.php b/system/typemill/Plugin.php
index 125b846..a3920ee 100644
--- a/system/typemill/Plugin.php
+++ b/system/typemill/Plugin.php
@@ -16,6 +16,8 @@ abstract class Plugin implements EventSubscriberInterface
protected $route;
+ protected $urlinfo;
+
protected $adminroute = false;
protected $editorroute = false;
@@ -26,7 +28,11 @@ abstract class Plugin implements EventSubscriberInterface
$this->container = $container;
$this->urlinfo = $this->container->get('urlinfo');
$this->route = $this->urlinfo['route'];
- $this->route = ltrim($this->route, '/');
+
+ if($this->route != '/')
+ {
+ $this->route = ltrim($this->route, '/');
+ }
if(str_starts_with($this->route, 'tm/'))
{
diff --git a/system/typemill/system.php b/system/typemill/system.php
index 5218571..3e5e65f 100644
--- a/system/typemill/system.php
+++ b/system/typemill/system.php
@@ -241,7 +241,7 @@ $container->set('translations', $translations);
$container->set('dispatcher', function() use ($dispatcher){ return $dispatcher; });
# asset function for plugins
-$assets = new \Typemill\Assets($urlinfo['basepath']);
+$assets = new \Typemill\Assets($urlinfo['baseurl']);
$container->set('assets', function() use ($assets){ return $assets; });
/****************************
@@ -286,6 +286,16 @@ $container->set('view', function() use ($settings, $urlinfo, $translations) {
* MIDDLEWARE *
****************************/
+foreach($middleware as $pluginMiddleware)
+{
+ $middlewareClass = $pluginMiddleware['classname'];
+ $middlewareParams = $pluginMiddleware['params'];
+ if(class_exists($middlewareClass))
+ {
+ $app->add(new $middlewareClass($middlewareParams));
+ }
+}
+
$app->add(new AssetMiddleware($assets, $container->get('view')));
$app->add(new ValidationErrorsMiddleware($container->get('view')));
diff --git a/themes/cyanine/layout.twig b/themes/cyanine/layout.twig
index 868dc21..c1dd227 100644
--- a/themes/cyanine/layout.twig
+++ b/themes/cyanine/layout.twig
@@ -215,7 +215,7 @@
{% block javascripts %}
-
+
{% if settings.themes.cyanine.collapseNav %}