From 17d737b59010607e29e06fcc6fafa8ea8c4075b7 Mon Sep 17 00:00:00 2001 From: rainydaysavings Date: Sat, 13 Jun 2020 23:51:42 +0100 Subject: [PATCH] [UI][Mobile][FAQ][ROUTES] FAQ sub pages and routing added, small screen css work started. --- public/assets/css/faq/base.css | 132 -------------------------------- src/Controller/FaqHome.php | 41 ---------- src/Routes/Faq.php | 42 ---------- templates/faq/base.html.twig | 64 ++++++++++++++++ templates/faq/contact.html.twig | 2 +- templates/faq/home.html.twig | 47 +++++++++++- 6 files changed, 111 insertions(+), 217 deletions(-) delete mode 100644 public/assets/css/faq/base.css delete mode 100644 src/Controller/FaqHome.php delete mode 100644 src/Routes/Faq.php diff --git a/public/assets/css/faq/base.css b/public/assets/css/faq/base.css deleted file mode 100644 index 78daa2efd1..0000000000 --- a/public/assets/css/faq/base.css +++ /dev/null @@ -1,132 +0,0 @@ -/* GENERAL ----------------------------*/ - body, html - { - background-image: linear-gradient(to right bottom, #485563, #404c59, #38434f, #313a45, #29323c); - height: 100%; - background-position: center; - background-repeat: no-repeat; - background-size: cover; - color: #F6F6F6; - font-family: 'Open Sans', sans-serif; - } - - ul - { - text-decoration: none; - margin: 0; - padding: 0; - list-style: none; - } - - .drop-down ul li - { - position: relative; - } - - .drop-down ul li ul a - { - line-height: 1.8em; - } - - .drop-down ul li ul - { - display: none; - position: absolute; - background-color: rgba(0, 0, 0, 0.20); - padding: 0.8em 1.5em 1.5em 0.8em; - border-radius: 4px; - } - - .drop-down ul li:hover ul - { - display: block; - } - - .drop-down ul li ul a:hover - { - opacity: 0.6; - transition: all 0.5s ease; - } - - #hover-effect:hover - { - opacity: 0.6; - transition: all 0.5s ease; - } - - a:link - { - text-decoration: none; - outline: 0; - color: #F6F6F6; - } - a:visited - { - outline: 0; - color: #F6F6F6; - } -/*-------------------------------------*/ - -/* HEADER -----------------------------*/ - #header - { - margin-top: 2em; - margin-left: 20%; - margin-right: 20%; - display: flex; - justify-content: space-between; - } - - .flex-items - { - margin: 2em; - } - - /* MENU -------------------------------*/ - #menu - { - order: 1; - } - - #menu-png - { - height: 2em; - } - /*-------------------------------------*/ - - /* INSTANCE ---------------------------*/ - #instance - { - order: 2; - } - - #align-mid - { - - } - - #logo - { - height: 2em; - } - - #down-arrow - { - height: 1em; - } - /*-------------------------------------*/ - - /* SEARCH -----------------------------*/ - #search - { - order: 3; - } - - #search-png - { - height: 2em; - } - /*-------------------------------------*/ - -/*-------------------------------------*/ - diff --git a/src/Controller/FaqHome.php b/src/Controller/FaqHome.php deleted file mode 100644 index f347e30dca..0000000000 --- a/src/Controller/FaqHome.php +++ /dev/null @@ -1,41 +0,0 @@ -. -// }}} - -/** - * FAQ main page - * - * @package GNUsocial - * @category Controller - * - * @author Eliseu Amaro - * @copyright 2020 Free Software Foundation, Inc http://www.fsf.org - * @license https://www.gnu.org/licenses/agpl.html GNU AGPL v3 or later - */ - -namespace App\Controller; - -use Symfony\Bundle\FrameworkBundle\Controller\AbstractController; - -class FaqHome extends AbstractController -{ - public function __invoke() - { - return $this->render('faq/home.html.twig', []); - } -} \ No newline at end of file diff --git a/src/Routes/Faq.php b/src/Routes/Faq.php deleted file mode 100644 index ae8e8de092..0000000000 --- a/src/Routes/Faq.php +++ /dev/null @@ -1,42 +0,0 @@ -. -// }}} - -/** - * Define FAQ's main routes - * - * @package GNUsocial - * @category Router - * - * @author Eliseu Amaro - * @copyright 2020 Free Software Foundation, Inc http://www.fsf.org - * @license https://www.gnu.org/licenses/agpl.html GNU AGPL v3 or later - */ - -namespace App\Routes; - -use App\Controller\FaqHome; -use App\Core\RouteLoader; - -abstract class Faq -{ - public static function load(RouteLoader $r): void - { - $r->connect('doc_faq', '/doc/faq', FaqHome::class); - } -} diff --git a/templates/faq/base.html.twig b/templates/faq/base.html.twig index a2f4e0280b..42e81098fb 100644 --- a/templates/faq/base.html.twig +++ b/templates/faq/base.html.twig @@ -5,6 +5,7 @@ {% block title %}{% endblock %} {% block stylesheets %} +<<<<<<< HEAD {{ parent() }} @@ -12,5 +13,68 @@ {% endblock %} {% block header %}{{ parent() }}{% endblock %} +======= + + +{% endblock %} + +{% block body %} + +{% endblock %} +>>>>>>> 2ed0d2b706... [UI] FAQ sub pages and routing added, small screen css work started. {% block javascripts %}{% endblock %} diff --git a/templates/faq/contact.html.twig b/templates/faq/contact.html.twig index 9bcd914625..69c1e65563 100644 --- a/templates/faq/contact.html.twig +++ b/templates/faq/contact.html.twig @@ -1,4 +1,4 @@ -{% extends 'faq/faq.html.twig' %} +{% extends 'faq/base.html.twig' %} {% block title %}Help{% endblock %} diff --git a/templates/faq/home.html.twig b/templates/faq/home.html.twig index 6a1ee4c93b..ab3bfc3932 100644 --- a/templates/faq/home.html.twig +++ b/templates/faq/home.html.twig @@ -1 +1,46 @@ -{% extends 'faq/base.html.twig' %} \ No newline at end of file +{% extends 'faq/base.html.twig' %} + +{% block title %}FAQ{% endblock %} + +{% block body %} + {{ parent() }} + + +
+ {% apply markdown_to_html %} + ## What is this site? + This is a social network, running the GNU social software. + + You can use it to make connections between friends, family and colleagues -- writing short notices about yourself, where you are, and what you're doing, and those notices will be sent to all your contacts. + + In the future, we'll be adding support for photo, video and file sharing, as well as events, better contact management and mobile devices. + {% endapply %} +
+{% endblock %} \ No newline at end of file