From 7f89c4bcbb7cc160f49f9fb5b9c1cc8fd046c1da Mon Sep 17 00:00:00 2001 From: trendschau Date: Thu, 12 Oct 2023 19:17:59 +0200 Subject: [PATCH] RC2: Fix frontend navigation, darkmode, and more --- composer.lock | 10 +- content/00-welcome/02-write-content.yaml | 2 +- content/00-welcome/03-get-help.md | 4 - content/00-welcome/05-todos.md | 166 +++++++++++++++ content/00-welcome/05-todos.txt | 2 +- data/css/cyanine-custom.css | 30 +++ data/navigation/navi-draft.txt | 2 +- data/navigation/navi-extended.txt | 4 +- data/navigation/navi-live.txt | 2 +- .../Controllers/ControllerApiSystemThemes.php | 21 ++ .../Controllers/ControllerWebFrontend.php | 42 +++- system/typemill/Models/Folder.php | 69 +++++- system/typemill/Models/Navigation.php | 196 ++++++------------ system/typemill/Models/Settings.php | 10 + system/typemill/author/auth/setup.twig | 4 +- system/typemill/author/css/output.css | 140 ++++++++++--- system/typemill/author/js/vue-forms.js | 24 +-- system/typemill/author/js/vue-license.js | 4 +- system/typemill/author/js/vue-plugins.js | 28 ++- system/typemill/author/js/vue-system.js | 4 +- system/typemill/author/js/vue-systemnavi.js | 4 +- system/typemill/author/js/vue-themes.js | 58 ++++-- .../typemill/author/layouts/layoutAuth.twig | 2 +- .../author/layouts/layoutContent.twig | 2 +- .../typemill/author/layouts/layoutSystem.twig | 8 +- .../author/layouts/layoutSystemBlank.twig | 2 +- system/typemill/author/partials/mainNavi.twig | 16 +- system/typemill/routes/api.php | 1 + system/typemill/settings/system.yaml | 15 +- system/typemill/system.php | 4 +- tailwind.config.js | 1 + 31 files changed, 616 insertions(+), 261 deletions(-) create mode 100644 content/00-welcome/05-todos.md create mode 100644 data/css/cyanine-custom.css diff --git a/composer.lock b/composer.lock index 51249cc..ad19ab2 100644 --- a/composer.lock +++ b/composer.lock @@ -227,12 +227,12 @@ "source": { "type": "git", "url": "https://github.com/Gregwar/Captcha.git", - "reference": "5b8323637b502d3dbcbe28a74633dad8aed63452" + "reference": "229d3cdfe33d6f1349e0aec94a26e9205a6db08e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Gregwar/Captcha/zipball/5b8323637b502d3dbcbe28a74633dad8aed63452", - "reference": "5b8323637b502d3dbcbe28a74633dad8aed63452", + "url": "https://api.github.com/repos/Gregwar/Captcha/zipball/229d3cdfe33d6f1349e0aec94a26e9205a6db08e", + "reference": "229d3cdfe33d6f1349e0aec94a26e9205a6db08e", "shasum": "" }, "require": { @@ -275,9 +275,9 @@ ], "support": { "issues": "https://github.com/Gregwar/Captcha/issues", - "source": "https://github.com/Gregwar/Captcha/tree/master" + "source": "https://github.com/Gregwar/Captcha/tree/v1.2.1" }, - "time": "2023-05-08T15:17:31+00:00" + "time": "2023-09-26T13:45:37+00:00" }, { "name": "jbroadway/urlify", diff --git a/content/00-welcome/02-write-content.yaml b/content/00-welcome/02-write-content.yaml index d9d1033..6db7724 100644 --- a/content/00-welcome/02-write-content.yaml +++ b/content/00-welcome/02-write-content.yaml @@ -14,5 +14,5 @@ meta: time: 22-09-48 reference: null referencetype: null - hide: false + hide: true noindex: false diff --git a/content/00-welcome/03-get-help.md b/content/00-welcome/03-get-help.md index f909e83..85cc588 100644 --- a/content/00-welcome/03-get-help.md +++ b/content/00-welcome/03-get-help.md @@ -6,9 +6,5 @@ If you found a bug or if you have a question, then please open a new issue on [G Do you need professional help, an individual theme or a special plugin? You can hire us at [Trendschau Digital](https://trendschau.net/typemill-development). -[recording 2023 05 11 at 235818 (GIF, 1.30 MB)](media/files/recording-2023-05-11-at-235818.gif){.tm-download file-gif} - -[Contributions](https://github.com/typemill/typemill#contributors--supporters), [donations](https://www.paypal.me/typemill) and [feedback](https://github.com/typemill/typemill/issues) for this open source project are always welcome. - ![alt](media/live/youtube-6i2-uv88gke.jpeg){.center loading="lazy"} diff --git a/content/00-welcome/05-todos.md b/content/00-welcome/05-todos.md new file mode 100644 index 0000000..49b7cc9 --- /dev/null +++ b/content/00-welcome/05-todos.md @@ -0,0 +1,166 @@ +# ToDos Version 2 + +[TOC] + +## System settings + +* DONE: Migrate from backend to frontend with vue and api +* DONE: Redesign +* DONE: License feature +* DONE: Enhance with plugins + +## Visual Editor + +* DONE: Refactor and redesign +* DONE: Fix toc component in new block +* DONE: Fix hr component in new block +* DONE: finish shortcode component +* DONE: Fix inline formats +* DONE: fix lenght of page +* DONE: Fix design of new block at the end (background color) +* DONE: Move Block +* DONE: Fix headline design +* DONE: Fix save on two enter +* DONE: fix quote design +* DONE: Fix toc preview +* DONE: disable enable +* DONE: Add load sign (from navigation) +* DONE: File is not published from tmp to media/files if you save the block. + +## Raw Editor + +* DONE: Refactor and redesign +* DONE: Integrate highlighting + +## Navigation + +* DONE: Refactor and redesign +* DONE: fix status in navigation +* DONE: refresh navigation after changes + +## Publish Controller + +* DONE: Refactor and redesign +* DONE: Create +* DONE: publish +* DONE: unpublish +* DONE: discard +* DONE: delete +* DONE: save draft +* DONE: switch to raw + +## Meta Tabs + +* DONE: Refactor and redesign +* DONE: Enhance with plugins + +## Medialib + +* DONE: Refactor and redesign + +## Posts + +* DONE: Refactor and redesign + +## Plugins + +* Asset Class in progress + +## Frontend + +* DONE: Refactor +* DONE: Test restrictions + +## Other big tasks + +* DONE: System setup +* DONE: Recover Password + +## Medium tasks + +* DONE: Merge processAssets modell +* DONE: Table of content duplicated for published pages +* DONE: Session handling: csrf fail and session start error if restrictions are active +* DONE: Image and files for meta + +## Open tasks + +* DONE: Sitemap and ping +* DONE: Version check +* DONE: Proxy support +* DONE: SVG checker: https://github.com/TribalSystems/SVG-Sanitizer +* DONE: Backend form builder +* DONE: Image generation on the fly +* DONE: Delete folder in base level +* DONE: Make folder delete easier with glob or scandir +* DONE: fix error messages (check models) +* DONE: error status codes (check middleware) +* DONE: Warn if open another block +* DONE: Customfields not styled yet +* DOING: Fix error api systemnavi + validate +* FIXED: System stores html or sends wrong error messsages +* FIXED: Wrong frontend navigation if unpublished pages +* DONE: Icon for hidden pages +* DOING: Responsive design +* DONE: Captcha integration +* DONE: Solution for logo and favicon +* FIXED: Raw editor jumps if you edit long text at the end +* Reference feature +* Typemill Utilities +* Markdown secure rendering +* finish youtube component +* Handle formdata centrally ??? +* BUG: Error fields in account form not styled correctly + +## later + +* Clear cache +* Show security Log +* User search only for +10 users +* For api translations should be done completely in backoffice +* Change translation files so they are loaded in settings instead of adding them manually to settings-defaults.yaml + +## Cleanups: + +* DONE: Events +* DONE: Error messages +* DONE: Translations + +## Info: Select userroles + +* Userroles for file restriction: in vue-blox-components loaded via api +* Userroles for userfields: in php model user getUserFields() +* Userroles for meta: in php controller apiAuthorMeta getMeta() +* Plugins and themes: in php model extension getThemeDefinitions() + +## Info: License Check + +* On activation in apiControllerExtension. It checks the license in yaml. +* In plugin php code with setPremiumLicense +* In static plugins, it checks manual premium list and method setPremiumLicense and more + +## Plugins + +* MAKER: Rebuild search +* MAKER: Rebuild contactform with shortcode + +## Status codes + +| Status code | Description | +|---|---| +| 200 ok | cell | +| 400 bad request | The request was unacceptable due to missing or invalid parameter. | +| 401 unauthorized | The request requires an authorization. | +| (402 request failed) | The parameters where there but the request failed for other reasons. | +| 403 forbidden | The user is authenticated but he has not enough rights. | +| 404 not found | new | +| 500 internal server error | new | + +## Upgrade + +* Delete content of system folder +* Upload new content of system folder with folders typemill and vendor +* Delete settings file +* upload new index.php file +* Upload new htaccess file + diff --git a/content/00-welcome/05-todos.txt b/content/00-welcome/05-todos.txt index 7a6f6e6..f74898e 100644 --- a/content/00-welcome/05-todos.txt +++ b/content/00-welcome/05-todos.txt @@ -1 +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* Reference feature\n* Typemill Utilities\n* Markdown secure rendering\n* finish youtube component\n* Handle formdata centrally ???\n* BUG: Raw editor jumps if you edit long text at the end\n* BUG: Error fields in account form not styled correctly","## later","* 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","## 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 |"] \ No newline at end of file +["# 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* Reference feature\n* Typemill Utilities\n* Markdown secure rendering\n* finish youtube component\n* Handle formdata centrally ???\n* BUG: Error fields in account form not styled correctly\n* DONE: Update CSS for themes\n* BUG: Codefield jumps on editing","## later","* 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","## 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","* Delete content of system folder\n* Upload new content of system folder with folders typemill and vendor\n* Delete settings file \n* upload new index.php file\n* Upload new htaccess file"] \ No newline at end of file diff --git a/data/css/cyanine-custom.css b/data/css/cyanine-custom.css new file mode 100644 index 0000000..c4ab8ec --- /dev/null +++ b/data/css/cyanine-custom.css @@ -0,0 +1,30 @@ +.landingpageintro h1{ +display: inline-block; +background: white; +padding: 4px 10px; +margin: 5px; +} + +.landingpageintro p{ +display: inline; +background: white; +line-height: 2.1rem; +padding: 6px 4px 4px; +} +article a[href^="http"]::after, +article a[href^="https://"]::after +{ + content: ""; + width: 11px; + height: 11px; + margin-left: 4px; + background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='currentColor' viewBox='0 0 16 16'%3E%3Cpath fill-rule='evenodd' d='M8.636 3.5a.5.5 0 0 0-.5-.5H1.5A1.5 1.5 0 0 0 0 4.5v10A1.5 1.5 0 0 0 1.5 16h10a1.5 1.5 0 0 0 1.5-1.5V7.864a.5.5 0 0 0-1 0V14.5a.5.5 0 0 1-.5.5h-10a.5.5 0 0 1-.5-.5v-10a.5.5 0 0 1 .5-.5h6.636a.5.5 0 0 0 .5-.5z'/%3E%3Cpath fill-rule='evenodd' d='M16 .5a.5.5 0 0 0-.5-.5h-5a.5.5 0 0 0 0 1h3.793L6.146 9.146a.5.5 0 1 0 .708.708L15 1.707V5.5a.5.5 0 0 0 1 0v-5z'/%3E%3C/svg%3E"); + background-position: center; + background-repeat: no-repeat; + background-size: contain; + display: inline-block; +} +a[href^="https://www.electrictoolbox.com"] { + background: none; + padding-right: 0; +} \ No newline at end of file diff --git a/data/navigation/navi-draft.txt b/data/navigation/navi-draft.txt index 153c732..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:0;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:12:"05-todos.txt";s:11:"elementType";s:4:"file";s:6:"status";s:11:"unpublished";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:24:"/00-welcome/05-todos.txt";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 1f081bf..9096508 100644 --- a/data/navigation/navi-extended.txt +++ b/data/navigation/navi-extended.txt @@ -18,7 +18,7 @@ keyPath: '0.1' /welcome/write-content: navtitle: 'write content' - hide: false + hide: true noindex: false path: /00-welcome/02-write-content.md keyPath: '0.2' @@ -38,7 +38,7 @@ navtitle: 'To Dos' hide: false noindex: false - path: /00-welcome/05-todos.txt + path: /00-welcome/05-todos.txtmd keyPath: '0.5' /cyanine-theme: navtitle: 'cyanine theme' diff --git a/data/navigation/navi-live.txt b/data/navigation/navi-live.txt index 82a3b37..b7f3496 100644 --- a/data/navigation/navi-live.txt +++ b/data/navigation/navi-live.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:5:{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:0;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;}}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: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 diff --git a/system/typemill/Controllers/ControllerApiSystemThemes.php b/system/typemill/Controllers/ControllerApiSystemThemes.php index c997d13..e118214 100644 --- a/system/typemill/Controllers/ControllerApiSystemThemes.php +++ b/system/typemill/Controllers/ControllerApiSystemThemes.php @@ -47,4 +47,25 @@ class ControllerApiSystemThemes extends Controller return $response->withHeader('Content-Type', 'application/json')->withStatus(200); } + + public function updateThemeCss(Request $request, Response $response) + { + $params = $request->getParsedBody(); + $themename = $params['theme']; + $themecss = $params['css']; + + # validate css input + $themecss = strip_tags($themecss); + + # store updated css + $settings = new Settings(); + $updatedSettings = $settings->updateThemeCss($themename, $themecss); + + $response->getBody()->write(json_encode([ + 'message' => Translations::translate('settings have been saved'), + 'code' => $updatedSettings + ])); + + return $response->withHeader('Content-Type', 'application/json')->withStatus(200); + } } \ No newline at end of file diff --git a/system/typemill/Controllers/ControllerWebFrontend.php b/system/typemill/Controllers/ControllerWebFrontend.php index 6f2c001..716fbfb 100644 --- a/system/typemill/Controllers/ControllerWebFrontend.php +++ b/system/typemill/Controllers/ControllerWebFrontend.php @@ -29,13 +29,11 @@ class ControllerWebFrontend extends Controller $userrole = $request->getAttribute('c_userrole'); $username = $request->getAttribute('c_username'); - # GET THE NAVIGATION $navigation = new Navigation(); - $liveNavigation = $navigation->getLiveNavigation($urlinfo, $langattr); + $draftNavigation = $navigation->getDraftNavigation($urlinfo, $langattr); $home = false; - # GET THE PAGINATION $currentpage = $navigation->getCurrentPage($args); if($currentpage) @@ -56,6 +54,7 @@ class ControllerWebFrontend extends Controller $extendedNavigation = $navigation->getExtendedNavigation($urlinfo, $langattr); $pageinfo = $extendedNavigation[$url] ?? false; + if(!$pageinfo) { return $this->c->get('view')->render($response->withStatus(404), '404.twig', [ @@ -66,23 +65,46 @@ class ControllerWebFrontend extends Controller $keyPathArray = explode(".", $pageinfo['keyPath']); - $liveNavigation = $navigation->setActiveNaviItems($liveNavigation, $keyPathArray); +# + $item = $navigation->getItemWithKeyPath($draftNavigation, $keyPathArray); - $item = $navigation->getItemWithKeyPath($liveNavigation, $keyPathArray); + # but what if parent is unpublished ?? + if(!$item) + { + return $this->c->get('view')->render($response->withStatus(404), '404.twig', [ + 'title' => 'Page not found', + 'description' => 'We did not find the page you where looking for.' + ]); + } } - $liveNavigation = $this->c->get('dispatcher')->dispatch(new OnPagetreeLoaded($liveNavigation), 'onPagetreeLoaded')->getData(); - - # CREATE THE BREADCRUMB - $breadcrumb = $navigation->getBreadcrumb($liveNavigation, $item->keyPathArray); + $breadcrumb = $navigation->getBreadcrumb($draftNavigation, $item->keyPathArray); $breadcrumb = $this->c->get('dispatcher')->dispatch(new OnBreadcrumbLoaded($breadcrumb), 'onBreadcrumbLoaded')->getData(); + # CHECK IF WHOLE TREE IS PUBLISHED + foreach($breadcrumb as $page) + { + if($page->status == 'unpublished') + { + return $this->c->get('view')->render($response->withStatus(404), '404.twig', [ + 'title' => 'Page not found', + 'description' => 'We did not find the page you where looking for.' + ]); + } + } + + # GET THE LIVE NAVIGATION (keyPathArray does not match here!!!) + $liveNavigation = $navigation->getLiveNavigation($urlinfo, $langattr); # STRIP OUT HIDDEN PAGES $liveNavigation = $navigation->removeHiddenPages($liveNavigation); - # we could cache navigation without hidden pages?? + # SET PAGEs ACTIVE + $liveNavigation = $navigation->setActiveNaviItems($liveNavigation, $breadcrumb); + + # DISPATCH LIVE NAVIGATION + $liveNavigation = $this->c->get('dispatcher')->dispatch(new OnPagetreeLoaded($liveNavigation), 'onPagetreeLoaded')->getData(); # ADD BACKWARD-/FORWARD PAGINATION $item = $navigation->getPagingForItem($liveNavigation, $item); diff --git a/system/typemill/Models/Folder.php b/system/typemill/Models/Folder.php index 06b6a04..7697565 100644 --- a/system/typemill/Models/Folder.php +++ b/system/typemill/Models/Folder.php @@ -82,14 +82,79 @@ class Folder $folderContent[] = $item; } - /* store the name of the last file */ + # store the name of the last file $last = implode($nameParts); } } } return $folderContent; } - + + /* + * scans content of a folder recursively and keeps the index order + * vars: folder path as string + * returns: multi-dimensional array with names of folders and files + */ + public function scanFolderCheckIndex($folderPath, $draft = false) + { + $folderItems = scandir($folderPath); + $folderContent = array(); + + # if it is the live version and if it is a folder that is not published, then do not show the folder and its content. + if(!$draft && !in_array('index.md', $folderItems)){ return false; } + + foreach ($folderItems as $key => $item) + { + if (!in_array($item, array(".","..")) && substr($item, 0, 1) != '.') + { + if (is_dir($folderPath . DIRECTORY_SEPARATOR . $item)) + { + + $subFolder = $item; + $folderPublished = file_exists($folderPath . DIRECTORY_SEPARATOR . $item . DIRECTORY_SEPARATOR . 'index.md'); + + # scan that folder only if it is a draft or if the folder is published (contains index.md) + if($draft OR $folderPublished) + { + # we need s countable index here + $folderContent[$subFolder] = $this->scanFolder($folderPath . DIRECTORY_SEPARATOR . $subFolder, $draft); + } + } + else + { + $nameParts = $this->getStringParts($item); + $fileType = array_pop($nameParts); + + if($fileType == 'md') + { + $folderContent[] = $item; + } + + if($fileType == 'txt') + { + if(isset($last) && ($last == implode($nameParts)) ) + { + array_pop($folderContent); + $item = $item . 'md'; + } + $folderContent[] = $item; + + if(!$draft) + { + $index = count($folderContent)-1; + unset($folderContent[$index]); + } + } + + # store the name of the last file + $last = implode($nameParts); + + } + } + } + return $folderContent; + } + /* * Transforms array of folder item into an array of item-objects with additional information for each item diff --git a/system/typemill/Models/Navigation.php b/system/typemill/Models/Navigation.php index 40d82ab..0e0f66e 100644 --- a/system/typemill/Models/Navigation.php +++ b/system/typemill/Models/Navigation.php @@ -80,15 +80,19 @@ class Navigation extends Folder $allowedmainnavi = []; + $activeitem = false; + foreach($mainnavi as $name => $naviitem) { if($acl->isAllowed($userrole, $naviitem['aclresource'], $naviitem['aclprivilege'])) { # set the navi of current route active $thisRoute = '/tm/' . $name; + if(strpos($urlinfo['route'], $thisRoute) !== false) { $naviitem['active'] = true; + $activeitem = true; } $allowedmainnavi[$name] = $naviitem; @@ -99,6 +103,12 @@ class Navigation extends Folder if(isset($allowedmainnavi['system'])) { unset($allowedmainnavi['account']); + + # if no active item has been found, then it is submenu under system + if(!$activeitem) + { + $allowedmainnavi['system']['active'] = true; + } } # set correct editor mode according to user settings @@ -112,16 +122,19 @@ class Navigation extends Folder public function getSystemNavigation($userrole, $acl, $urlinfo, $dispatcher, $routeparser) { - $systemnavi = $this->storage->getYaml('systemSettings', '', 'systemnavi.yaml'); - $systemnavi = $dispatcher->dispatch(new OnSystemnaviLoaded($systemnavi), 'onSystemnaviLoaded')->getData(); + $systemnavi = $this->storage->getYaml('systemSettings', '', 'systemnavi.yaml'); + $systemnavi = $dispatcher->dispatch(new OnSystemnaviLoaded($systemnavi), 'onSystemnaviLoaded')->getData(); - $allowedsystemnavi = []; + $allowedsystemnavi = []; + + $route = trim($urlinfo['route'], '/'); foreach($systemnavi as $name => $naviitem) { - $naviitem['url'] = $routeparser->urlFor($naviitem['routename']); + $naviitem['url'] = $routeparser->urlFor($naviitem['routename']); + $itemurl = trim($naviitem['url'], '/'); - if(strpos( trim($naviitem['url'], '/'), trim($urlinfo['route'], '/'))) + if(strpos( $itemurl, $route ) !== false) { $naviitem['active'] = true; } @@ -224,7 +237,6 @@ class Navigation extends Folder return $this->basicLiveNavigation; } - # creates a fresh structure with published and non-published pages for the author public function createBasicLiveNavigation($urlinfo, $language) { # scan the content of the folder @@ -330,6 +342,7 @@ class Navigation extends Folder public function getItemWithKeyPath($navigation, array $searchArray, $baseUrl = null) { + $item = false; # if it is the homepage @@ -352,7 +365,37 @@ class Navigation extends Folder return $item; } - public function setActiveNaviItems($navigation, array $searchArray) + # used with scan folder that generates own indexes for live version + public function setActiveNaviItems($navigation, $breadcrumb) + { + foreach($breadcrumb as $crumbkey => $page) + { + foreach($navigation as $itemkey => $item) + { + if($page->urlRelWoF == $item->urlRelWoF) + { + unset($breadcrumb[$crumbkey]); + + if(empty($breadcrumb)) + { + $navigation[$itemkey]->active = true; + } + elseif(isset($navigation[$itemkey]->folderContent)) + { + $navigation[$itemkey]->activeParent = true; + $navigation[$itemkey]->folderContent = $this->setActiveNaviItems($navigation[$itemkey]->folderContent, $breadcrumb); + } + + break; + } + } + } + + return $navigation; + } + + # used with scan folder that keeps index from draft version + public function setActiveNaviItemsWithKeyPath($navigation, array $searchArray) { foreach($searchArray as $key => $itemKey) { @@ -491,6 +534,7 @@ class Navigation extends Folder if(!isset($navigation[$searchArray[$i]])){ return false; } $item = $navigation[$searchArray[$i]]; + if($i == count($searchArray)-1) { $item->active = true; @@ -536,9 +580,16 @@ class Navigation extends Folder $item->thisChapter = $this->getItemWithKeyPath($navigation, $thisChapArray); } - $flat = $this->flatten($navigation, $item->keyPath); + $flat = $this->flatten($navigation, $item->urlRel); $itemkey = $flat[0]; + + # if no previous or next is found (e.g. hidden page) + if(!is_int($itemkey)) + { + return $item; + } + if($itemkey > 1) { $item->prevItem = $flat[$itemkey-1]; @@ -551,13 +602,13 @@ class Navigation extends Folder return $item; } - public function flatten($navigation, $keyPath, $flat = []) - { + public function flatten($navigation, $urlRel, $flat = []) + { foreach($navigation as $key => $item) { $flat[] = clone($item); - if($keyPath === $item->keyPath) + if($item->urlRel == $urlRel) { array_unshift($flat, count($flat)); } @@ -566,134 +617,13 @@ class Navigation extends Folder { $last = array_key_last($flat); unset($flat[$last]->folderContent); - $flat = $this->flatten($item->folderContent, $keyPath, $flat); + $flat = $this->flatten($item->folderContent, $urlRel, $flat); } } return $flat; } - public function getPagingForItemOld($navigation, $item) - { - # if page is home - if(trim($item->pathWithoutType, DIRECTORY_SEPARATOR) == 'index') - { - return $item; - } - - $keyPos = count($item->keyPathArray)-1; - $thisChapArray = $item->keyPathArray; - $nextItemArray = $item->keyPathArray; - $prevItemArray = $item->keyPathArray; - - $item->thisChapter = false; - $item->prevItem = false; - $item->nextItem = false; - - - /************************ - * ADD THIS CHAPTER * - ************************/ - - if($keyPos > 0) - { - array_pop($thisChapArray); - $item->thisChapter = $this->getItemWithKeyPath($navigation, $thisChapArray); - } - - /************************ - * ADD NEXT ITEM * - ************************/ - - if($item->elementType == 'folder') - { - # get the first element in the folder - $item->nextItem = isset($item->folderContent[0]) ? clone($item->folderContent[0]) : false; - } - - # the item is a file or an empty folder - if(!$item->nextItem) - { - # walk to the next file in the same hierarchy - $nextItemArray[$keyPos]++; - - # get the key of the last element in this hierarchy level - # if there is no chapter, then it is probably an empty first-level-folder. Count content to get the number of first level items - $lastKey = $item->thisChapter ? array_key_last($item->thisChapter->folderContent) : count($navigation); - - # as long as the nextItemArray is smaller than the last key in this hierarchy level, search for the next item - # this ensures that it does not stop if key is missing (e.g. if the next page is hidden) - while( ($nextItemArray[$keyPos] <= $lastKey) && !$item->nextItem = $this->getItemWithKeyPath($navigation, $nextItemArray) ) - { - $nextItemArray[$keyPos]++; - } - } - - # there is no next file or folder in this level, so walk up the hierarchy to the next folder or file - while(!$item->nextItem) - { - # delete the array level with the current item, so you are in the parent folder - array_pop($nextItemArray); - - # if the array is empty now, then you where in the base level already, so break - if(empty($nextItemArray)) break; - - # define the key position where you are right now - $newKeyPos = count($nextItemArray)-1; - - # go to the next position - $nextItemArray[$newKeyPos]++; - - # search for 5 items in case there are some hidden elements - $maxlength = $nextItemArray[$newKeyPos]+5; - while( ($nextItemArray[$newKeyPos] <= $maxlength) && !$item->nextItem = $this->getItemWithKeyPath($navigation, $nextItemArray) ) - { - $nextItemArray[$newKeyPos]++; - } - } - - /************************ - * ADD PREVIOUS ITEM * - ************************/ - - # check if element is the first in the array - $first = ($prevItemArray[$keyPos] == 0) ? true : false; - - if(!$first) - { - $prevItemArray[$keyPos]--; - - while($prevItemArray[$keyPos] >= 0 && !$item->prevItem = $this->getItemWithKeyPath($navigation, $prevItemArray)) - { - $prevItemArray[$keyPos]--; - } - - # if no item is found, then all previous items are hidden, so set first item to true and it will walk up the array later - if(!$item->prevItem) - { - $first = true; - } - elseif($item->prevItem && $item->prevItem->elementType == 'folder' && !empty($item->prevItem->folderContent)) - { - # if the previous item is a folder, the get the last item of that folder - $item->prevItem = $this->getLastItemOfFolder($item->prevItem); - } - } - - # if it is the first item in the folder (or all other files are hidden) - if($first) - { - # then the previous item is the containing chapter - $item->prevItem = $item->thisChapter; - } - - if($item->prevItem && $item->prevItem->elementType == 'folder'){ unset($item->prevItem->folderContent); } - if($item->nextItem && $item->nextItem->elementType == 'folder'){ unset($item->nextItem->folderContent); } - if($item->thisChapter){unset($item->thisChapter->folderContent); } - - return $item; - } - public function getLastItemOfFolder($folder) { $lastItem = end($folder->folderContent); diff --git a/system/typemill/Models/Settings.php b/system/typemill/Models/Settings.php index 2829dc5..641ff40 100644 --- a/system/typemill/Models/Settings.php +++ b/system/typemill/Models/Settings.php @@ -156,6 +156,16 @@ class Settings return false; } + public function updateThemeCss(string $name, string $css) + { + if($this->storage->writeFile('cacheFolder', '', $name . '-custom.css', $css)) + { + return true; + } + + return false; + } + private function array_is_list(array $arr) { if ($arr === []) diff --git a/system/typemill/author/auth/setup.twig b/system/typemill/author/auth/setup.twig index a7949d8..3ee1525 100644 --- a/system/typemill/author/auth/setup.twig +++ b/system/typemill/author/auth/setup.twig @@ -1,6 +1,6 @@ {% extends 'layouts/layoutAuth.twig' %} -{% block title %}{{ 'Setup'|translate }}{% endblock %} +{% block title %}{{ translate('Setup') }}{% endblock %} {% block content %} @@ -83,7 +83,7 @@ {% else %}

{{ translate('Welcome to Typemill') }}

-

{{ translate('Hey writer, author, editor, content-guru, or website-manager.') }} {{ translate(' We hope you like Typemill, because we coded it just for you.'}}

+

{{ translate('Hey writer, author, editor, content-guru, or website-manager.') }} {{ translate(' We hope you like Typemill, because we coded it just for you.') }}

{{ translate('Get inspired and enjoy your writing') }}!

{% endif %} diff --git a/system/typemill/author/css/output.css b/system/typemill/author/css/output.css index e16fa2e..6b2513d 100644 --- a/system/typemill/author/css/output.css +++ b/system/typemill/author/css/output.css @@ -1022,10 +1022,6 @@ video { width: 33.333333%; } -.w-half { - width: 48%; -} - .w-80 { width: 20rem; } @@ -1046,6 +1042,10 @@ video { width: 60%; } +.w-half { + width: 48%; +} + .w-3\/4 { width: 75%; } @@ -1144,10 +1144,6 @@ video { list-style-type: disc; } -.flex-row { - flex-direction: row; -} - .flex-col { flex-direction: column; } @@ -2113,21 +2109,109 @@ video { visibility: visible; } -@media (prefers-color-scheme: dark) { - .dark\:text-gray-400 { - --tw-text-opacity: 1; - color: rgb(156 163 175 / var(--tw-text-opacity)); - } +.dark .dark\:border-stone-900 { + --tw-border-opacity: 1; + border-color: rgb(28 25 23 / var(--tw-border-opacity)); } -@media (min-width: 640px) { - .sm\:table-row { - display: table-row; - } +.dark .dark\:border-stone-200 { + --tw-border-opacity: 1; + border-color: rgb(231 229 228 / var(--tw-border-opacity)); +} - .sm\:flex-none { - flex: none; - } +.dark .dark\:border-stone-600 { + --tw-border-opacity: 1; + border-color: rgb(87 83 78 / var(--tw-border-opacity)); +} + +.dark .dark\:bg-stone-600 { + --tw-bg-opacity: 1; + background-color: rgb(87 83 78 / var(--tw-bg-opacity)); +} + +.dark .dark\:bg-stone-700 { + --tw-bg-opacity: 1; + background-color: rgb(68 64 60 / var(--tw-bg-opacity)); +} + +.dark .dark\:bg-stone-900 { + --tw-bg-opacity: 1; + background-color: rgb(28 25 23 / var(--tw-bg-opacity)); +} + +.dark .dark\:bg-stone-200 { + --tw-bg-opacity: 1; + background-color: rgb(231 229 228 / var(--tw-bg-opacity)); +} + +.dark .dark\:text-gray-400 { + --tw-text-opacity: 1; + color: rgb(156 163 175 / var(--tw-text-opacity)); +} + +.dark .dark\:text-stone-50 { + --tw-text-opacity: 1; + color: rgb(250 250 249 / var(--tw-text-opacity)); +} + +.dark .dark\:text-stone-200 { + --tw-text-opacity: 1; + color: rgb(231 229 228 / var(--tw-text-opacity)); +} + +.dark .dark\:text-stone-900 { + --tw-text-opacity: 1; + color: rgb(28 25 23 / var(--tw-text-opacity)); +} + +.dark .hover\:dark\:border-stone-600:hover { + --tw-border-opacity: 1; + border-color: rgb(87 83 78 / var(--tw-border-opacity)); +} + +.dark .hover\:dark\:border-teal-500:hover { + --tw-border-opacity: 1; + border-color: rgb(20 184 166 / var(--tw-border-opacity)); +} + +.dark .hover\:dark\:border-stone-200:hover { + --tw-border-opacity: 1; + border-color: rgb(231 229 228 / var(--tw-border-opacity)); +} + +.dark .hover\:dark\:bg-stone-900:hover { + --tw-bg-opacity: 1; + background-color: rgb(28 25 23 / var(--tw-bg-opacity)); +} + +.dark .hover\:dark\:bg-stone-200:hover { + --tw-bg-opacity: 1; + background-color: rgb(231 229 228 / var(--tw-bg-opacity)); +} + +.dark .hover\:dark\:text-stone-900:hover { + --tw-text-opacity: 1; + color: rgb(28 25 23 / var(--tw-text-opacity)); +} + +.dark .focus\:dark\:border-stone-600:focus { + --tw-border-opacity: 1; + border-color: rgb(87 83 78 / var(--tw-border-opacity)); +} + +.dark .focus\:dark\:text-stone-900:focus { + --tw-text-opacity: 1; + color: rgb(28 25 23 / var(--tw-text-opacity)); +} + +.dark .active\:dark\:border-stone-600:active { + --tw-border-opacity: 1; + border-color: rgb(87 83 78 / var(--tw-border-opacity)); +} + +.dark .active\:dark\:text-stone-900:active { + --tw-text-opacity: 1; + color: rgb(28 25 23 / var(--tw-text-opacity)); } @media (min-width: 768px) { @@ -2141,10 +2225,6 @@ video { margin-right: 0.5rem; } - .lg\:mt-4 { - margin-top: 1rem; - } - .lg\:mt-0 { margin-top: 0px; } @@ -2165,24 +2245,20 @@ video { display: none; } - .lg\:h-12 { - height: 3rem; - } - .lg\:w-1\/2 { width: 50%; } - .lg\:w-1\/4 { - width: 25%; + .lg\:w-half { + width: 48%; } .lg\:w-3\/4 { width: 75%; } - .lg\:w-half { - width: 48%; + .lg\:w-1\/4 { + width: 25%; } .lg\:flex-row { diff --git a/system/typemill/author/js/vue-forms.js b/system/typemill/author/js/vue-forms.js index 8e77ebf..6aa7fc1 100644 --- a/system/typemill/author/js/vue-forms.js +++ b/system/typemill/author/js/vue-forms.js @@ -2,7 +2,7 @@ app.component('component-text', { props: ['id', 'description', 'maxlength', 'hidden', 'readonly', 'required', 'disabled', 'placeholder', 'label', 'name', 'type', 'value', 'css', 'errors'], template: `
- - @@ -751,7 +751,7 @@ app.component('component-image', {
-

Maker License

Use all maker-prodcuts (plugins and themes) for one year. The subscription will automatically refresh after a year until you cancel it.

- Buy on Typemill + Buy on Typemill

Business License

Use all business- and maker-products (plugins, themes, services) for one year. The subscription will automatically refresh after a year until you cancel it.

- Buy on Typemill + Buy on Typemill
diff --git a/system/typemill/author/js/vue-plugins.js b/system/typemill/author/js/vue-plugins.js index 2632741..0c10ac1 100644 --- a/system/typemill/author/js/vue-plugins.js +++ b/system/typemill/author/js/vue-plugins.js @@ -2,7 +2,7 @@ const app = Vue.createApp({ template: `
    -
  • +
  • Please update to version {{ versions[pluginname].version }}

    License: {{ plugin.license }}

    @@ -21,7 +21,7 @@ const app = Vue.createApp({

    {{plugin.description}}

    - @@ -133,18 +133,18 @@ const app = Vue.createApp({ }, methods: { - getActiveClass: function(pluginname) + getActiveClass(pluginname) { if(this.formData[pluginname]['active']) { return 'bg-stone-200'; } }, - getLinkToLicense: function() + getLinkToLicense() { return tmaxios.defaults.baseURL + "/tm/license"; }, - checkLicense: function(haystack, needle) + checkLicense(haystack, needle) { if(needle == 'MAKER' || needle == 'BUSINESS') { @@ -155,7 +155,7 @@ const app = Vue.createApp({ } return true; }, - activate: function(pluginname) + activate(pluginname) { var self = this; @@ -178,7 +178,15 @@ const app = Vue.createApp({ } }); }, - setCurrent: function(name) + hasSettings(pluginname) + { + if(this.formDefinitions[pluginname].forms !== undefined) + { + return true; + } + return false; + }, + setCurrent(name) { if(this.current == name) { @@ -189,11 +197,11 @@ const app = Vue.createApp({ this.current = name; } }, - selectComponent: function(type) + selectComponent(type) { return 'component-'+type; }, - save: function() + save() { this.reset(); var self = this; @@ -220,7 +228,7 @@ const app = Vue.createApp({ } }); }, - reset: function() + reset() { this.errors = {}; this.message = ''; diff --git a/system/typemill/author/js/vue-system.js b/system/typemill/author/js/vue-system.js index a7b2c8d..8678d05 100644 --- a/system/typemill/author/js/vue-system.js +++ b/system/typemill/author/js/vue-system.js @@ -4,7 +4,7 @@ const app = Vue.createApp({

    Please update typemill to version {{ version.system }}

    • - +
    @@ -22,7 +22,7 @@ const app = Vue.createApp({
    {{ $filters.translate(message) }}
    - +
    `, diff --git a/system/typemill/author/js/vue-systemnavi.js b/system/typemill/author/js/vue-systemnavi.js index 4b31d3e..4181825 100644 --- a/system/typemill/author/js/vue-systemnavi.js +++ b/system/typemill/author/js/vue-systemnavi.js @@ -1,13 +1,13 @@ const systemnavi = Vue.createApp({ template: ` -
      +
      • - + {{ $filters.translate(navitem.title) }}
      • diff --git a/system/typemill/author/js/vue-themes.js b/system/typemill/author/js/vue-themes.js index 5cda873..19f88c0 100644 --- a/system/typemill/author/js/vue-themes.js +++ b/system/typemill/author/js/vue-themes.js @@ -2,7 +2,7 @@ const app = Vue.createApp({ template: `
        @@ -140,24 +140,28 @@ const app = Vue.createApp({ }); }, methods: { - deactivateThemes: function() + deactivateThemes() { for (const theme in this.formData) { delete this.formData[theme].active; } }, - getActiveClass: function(themename) + getActiveClass(themename) { if(this.formData[themename]['active']) { - return 'bg-stone-200'; + return 'bg-stone-200 dark:bg-stone-900'; } }, - getLinkToLicense: function() + getSrc(preview) + { + return data.urlinfo.baseurl + preview; + }, + getLinkToLicense() { return tmaxios.defaults.baseURL + "/tm/license"; }, - checkLicense: function(haystack, needle) + checkLicense(haystack, needle) { if(needle == 'MAKER' || needle == 'BUSINESS') { @@ -168,7 +172,7 @@ const app = Vue.createApp({ } return true; }, - activate: function(themename) + activate(themename) { var self = this; @@ -193,7 +197,7 @@ const app = Vue.createApp({ } }); }, - setCurrent: function(name) + setCurrent(name) { if(this.current == name) { @@ -204,13 +208,14 @@ const app = Vue.createApp({ this.current = name; } }, - selectComponent: function(type) + selectComponent(type) { return 'component-'+type; }, - save: function() + save() { this.reset(); + var self = this; tmaxios.post('/api/v1/theme',{ @@ -235,14 +240,35 @@ const app = Vue.createApp({ self.errors = error.response.data.errors; } } - }); + }); }, - updateCSS: function() + updateCSS() { - /* check if css has been modified */ - /* if so, send to api endpoint */ + var selfcss = this; + + tmaxios.post('/api/v1/themecss',{ + 'theme': this.current, + 'css': this.formData[this.current].customcss + }) + .then(function (response) + { + self.messageClass = 'bg-teal-500'; + self.message = response.data.message; + }) + .catch(function (error) + { + if(error.response) + { + self.message = handleErrorMessage(error); + self.messageClass = 'bg-rose-500'; + if(error.response.data.errors !== undefined) + { + self.errors = error.response.data.errors; + } + } + }); }, - reset: function() + reset() { this.errors = {}; this.message = ''; diff --git a/system/typemill/author/layouts/layoutAuth.twig b/system/typemill/author/layouts/layoutAuth.twig index 27e27c7..ed20702 100644 --- a/system/typemill/author/layouts/layoutAuth.twig +++ b/system/typemill/author/layouts/layoutAuth.twig @@ -1,5 +1,5 @@ - + {% block title %}{% endblock %} diff --git a/system/typemill/author/layouts/layoutContent.twig b/system/typemill/author/layouts/layoutContent.twig index bd7e8b7..6fc7e04 100644 --- a/system/typemill/author/layouts/layoutContent.twig +++ b/system/typemill/author/layouts/layoutContent.twig @@ -1,5 +1,5 @@ - + {% block title %}{% endblock %} diff --git a/system/typemill/author/layouts/layoutSystem.twig b/system/typemill/author/layouts/layoutSystem.twig index 508a0e8..bc16b6c 100644 --- a/system/typemill/author/layouts/layoutSystem.twig +++ b/system/typemill/author/layouts/layoutSystem.twig @@ -1,5 +1,5 @@ - + {% block title %}{% endblock %} @@ -24,11 +24,11 @@ {{ assets.renderCSS() }} - + {% include 'partials/symbols.twig' %} -
        +
        {% include 'partials/mainNavi.twig' %}
        @@ -38,7 +38,7 @@ -
        +
        {% block content %}{% endblock %}
        diff --git a/system/typemill/author/layouts/layoutSystemBlank.twig b/system/typemill/author/layouts/layoutSystemBlank.twig index 7bd9aea..c9c0ee8 100644 --- a/system/typemill/author/layouts/layoutSystemBlank.twig +++ b/system/typemill/author/layouts/layoutSystemBlank.twig @@ -1,5 +1,5 @@ - + {% block title %}{% endblock %} diff --git a/system/typemill/author/partials/mainNavi.twig b/system/typemill/author/partials/mainNavi.twig index 90213dd..01e27f7 100644 --- a/system/typemill/author/partials/mainNavi.twig +++ b/system/typemill/author/partials/mainNavi.twig @@ -1,13 +1,19 @@ \ No newline at end of file diff --git a/system/typemill/routes/api.php b/system/typemill/routes/api.php index 2033331..17d8ba3 100644 --- a/system/typemill/routes/api.php +++ b/system/typemill/routes/api.php @@ -29,6 +29,7 @@ $app->group('/api/v1', function (RouteCollectorProxy $group) use ($acl) { $group->get('/settings', ControllerApiSystemSettings::class . ':getSettings')->setName('api.settings.get')->add(new ApiAuthorization($acl, 'system', 'view')); # admin $group->post('/settings', ControllerApiSystemSettings::class . ':updateSettings')->setName('api.settings.set')->add(new ApiAuthorization($acl, 'system', 'update')); # admin $group->post('/license', ControllerApiSystemLicense::class . ':createLicense')->setName('api.license.create')->add(new ApiAuthorization($acl, 'system', 'update')); # admin + $group->post('/themecss', ControllerApiSystemThemes::class . ':updateThemeCss')->setName('api.themecss.set')->add(new ApiAuthorization($acl, 'system', 'update')); # admin $group->post('/theme', ControllerApiSystemThemes::class . ':updateTheme')->setName('api.theme.set')->add(new ApiAuthorization($acl, 'system', 'update')); # admin $group->post('/plugin', ControllerApiSystemPlugins::class . ':updatePlugin')->setName('api.plugin.set')->add(new ApiAuthorization($acl, 'system', 'update')); # admin $group->post('/extensions', ControllerApiSystemExtensions::class . ':activateExtension')->setName('api.extension.activate')->add(new ApiAuthorization($acl, 'system', 'update')); # admin diff --git a/system/typemill/settings/system.yaml b/system/typemill/settings/system.yaml index 4ba5a0d..b68a64d 100644 --- a/system/typemill/settings/system.yaml +++ b/system/typemill/settings/system.yaml @@ -53,6 +53,11 @@ fieldsetsystem: label: Google sitemap (readonly) css: lg:w-half disabled: true +# darkmode: +# type: checkbox +# label: Darkmode +# checkboxlabel: Switch to darkmode for the authoring area +# css: lg:w-half fieldsetmedia: type: fieldset legend: Media @@ -200,18 +205,10 @@ fieldsetdeveloper: type: checkbox label: Twig cache checkboxlabel: Activate the cache for twig templates - refreshcache: - type: checkbox - label: Refresh cache - checkboxlabel: Refresh the cache every 10 minutes. Use this option if you change content-files via FTP. proxy: type: checkbox label: Proxy checkboxlabel: Use x-forwarded-header. trustedproxies: type: text - label: Trusted IPs for proxies (comma separated) - headersoff: - type: checkbox - label: Disable headers - checkboxlabel: Disable the typemill headers and send your owwn \ No newline at end of file + label: Trusted IPs for proxies (comma separated) \ No newline at end of file diff --git a/system/typemill/system.php b/system/typemill/system.php index 94d5008..5218571 100644 --- a/system/typemill/system.php +++ b/system/typemill/system.php @@ -43,8 +43,8 @@ $timer['start'] = microtime(true); * HIDE ERRORS BY DEFAULT * ****************************/ -ini_set('display_errors', 1); -ini_set('display_startup_errors', 1); +ini_set('display_errors', 0); +ini_set('display_startup_errors', 0); error_reporting(E_ALL); /**************************** diff --git a/tailwind.config.js b/tailwind.config.js index 5b82721..27231ad 100644 --- a/tailwind.config.js +++ b/tailwind.config.js @@ -1,6 +1,7 @@ /** @type {import('tailwindcss').Config} */ module.exports = { content: ["./system/typemill/author/**/*.{html,js,twig}"], + darkMode: 'class', theme: { extend: { screens: {