Explorar el Código

refactor getCurrentWebsite* methods, and remove now useless classes

Olivier Massot hace 4 años
padre
commit
5a5bb980cb

+ 10 - 0
ot_core/Classes/Controller/ActionController.php

@@ -3,6 +3,7 @@
 namespace Opentalent\OtCore\Controller;
 
 use Opentalent\OtCore\Website\OtPageRepository;
+use Opentalent\OtCore\Website\OtWebsiteRepository;
 
 /**
  * Base class for all controllers of backend modules
@@ -11,6 +12,15 @@ use Opentalent\OtCore\Website\OtPageRepository;
  */
 class ActionController extends \TYPO3\CMS\Extbase\Mvc\Controller\ActionController
 {
+    /**
+     * @var OtWebsiteRepository
+     */
+    protected OtWebsiteRepository $otWebsiteRepository;
+
+    public function injectOtWebsiteRepository(OtWebsiteRepository $otWebsiteRepository) {
+        $this->otWebsiteRepository = $otWebsiteRepository;
+    }
+
     /**
      * @var OtPageRepository
      */

+ 12 - 1
ot_core/Classes/Controller/SelectedSiteController.php

@@ -19,6 +19,13 @@ use TYPO3\CMS\Extbase\Object\ObjectManager;
  */
 class SelectedSiteController extends ActionController
 {
+    /**
+     * The current website
+     *
+     * @var array
+     */
+    protected $currentWebsite;
+
     /**
      * The current site root page uid
      *
@@ -49,12 +56,16 @@ class SelectedSiteController extends ActionController
                     $objectManager = new ObjectManager();
                     $this->otPageRepository = $objectManager->get(OtPageRepository::class);
                 }
-                $this->currentRootUid = $this->otPageRepository->getCurrentRootUid();
+                $this->currentRootUid = $this->otPageRepository->getCurrentBeRootUid();
             } catch (NoSiteSelected $e) {
                 $this->currentRootUid = null;
             }
         }
 
+        if ($this->currentRootUid) {
+            $this->currentWebsite = $this->otWebsiteRepository->getWebsiteByPageUid($this->currentRootUid);
+        }
+
         // [TESTS ONLY]
         if ($this->preventPropagation) { return; }
 

+ 15 - 91
ot_core/Classes/Website/OtPageRepository.php

@@ -3,7 +3,6 @@
 namespace Opentalent\OtCore\Website;
 
 use Opentalent\OtCore\Exception\NoSiteSelected;
-use TYPO3\CMS\Core\Site\Entity\Site;
 use TYPO3\CMS\Core\Utility\GeneralUtility;
 
 /**
@@ -20,41 +19,31 @@ class OtPageRepository
      */
     private \FluidTYPO3\Vhs\Service\PageService $pageService;
 
-    /**
-     * @var \TYPO3\CMS\Frontend\Page\PageRepository
-     */
-    private \TYPO3\CMS\Frontend\Page\PageRepository $pageRepository;
-
-    /**
-     * @var \TYPO3\CMS\Core\Database\ConnectionPool
-     */
-    private \TYPO3\CMS\Core\Database\ConnectionPool $connectionPool;
-
-    /**
-     * @var \TYPO3\CMS\Core\Site\SiteFinder
-     */
-    private \TYPO3\CMS\Core\Site\SiteFinder $siteFinder;
-
     public function injectPageService(\FluidTYPO3\Vhs\Service\PageService $pageService)
     {
         $this->pageService = $pageService;
     }
 
+    /**
+     * @var \TYPO3\CMS\Frontend\Page\PageRepository
+     */
+    private \TYPO3\CMS\Frontend\Page\PageRepository $pageRepository;
+
     public function injectPageRepository(\TYPO3\CMS\Frontend\Page\PageRepository $pageRepository)
     {
         $this->pageRepository = $pageRepository;
     }
 
+    /**
+     * @var \TYPO3\CMS\Core\Database\ConnectionPool
+     */
+    private \TYPO3\CMS\Core\Database\ConnectionPool $connectionPool;
+
     public function injectConnectionPool(\TYPO3\CMS\Core\Database\ConnectionPool $connectionPool)
     {
         $this->connectionPool = $connectionPool;
     }
 
-    public function injectSiteFinder(\TYPO3\CMS\Core\Site\SiteFinder $siteFinder)
-    {
-        $this->siteFinder = $siteFinder;
-    }
-
     /**
      * Returns all the subpages of the given page
      *
@@ -131,72 +120,7 @@ class OtPageRepository
      */
     public function getPageWithSubpages(int $pageUid, bool $withRestrictions=false): array
     {
-        return array_merge([$this->getPage($pageUid)], $this->getAllSubpagesForPage($pageUid));
-    }
-
-    /**
-     * Return the Site object for the given page
-     *
-     * @param int $pageUid
-     * @return Site
-     * @throws \TYPO3\CMS\Core\Exception\SiteNotFoundException
-     */
-    public function getSiteFor(int $pageUid): Site
-    {
-        $rootPage = $this->getRootPageFor($pageUid);
-        $rootUid = $rootPage['uid'];
-
-        return $this->siteFinder->getSiteByRootPageId($rootUid);
-    }
-
-    /**
-     * Returns the typo3 site matching the current request (FE only)
-     *
-     * @return Site
-     * @throws \TYPO3\CMS\Core\Exception\SiteNotFoundException
-     */
-    public function getCurrentSite(): Site
-    {
-        $request = $GLOBALS['TYPO3_REQUEST'];
-        $site = $request->getAttribute('site');
-        return $this->siteFinder->getSiteByIdentifier($site->getIdentifier());
-    }
-
-    /**
-     * Returns the current site's rootpage uid (FE only)
-     *
-     * @return int
-     * @throws \TYPO3\CMS\Core\Exception\SiteNotFoundException
-     */
-    public function getCurrentSiteRootPageUid(): int
-    {
-        $site = $this->getCurrentSite();
-        return $site->getRootPageId();
-    }
-
-    /**
-     * Returns the current site's rootpage URI (FE only)
-     *
-     * @return \Psr\Http\Message\UriInterface
-     * @throws \TYPO3\CMS\Core\Exception\SiteNotFoundException
-     */
-    public function getCurrentSiteRootPageUri(): \Psr\Http\Message\UriInterface
-    {
-        $site = $this->getCurrentSite();
-        return $site->getBase();
-    }
-
-    /**
-     * [Frontend Only]
-     * Returns the current site's rootpage array
-     *
-     * @return array
-     * @throws \TYPO3\CMS\Core\Exception\SiteNotFoundException
-     */
-    public function getCurrentSiteRootPage(): array
-    {
-        $uid = $this->getCurrentSiteRootPageUid();
-        return $this->pageRepository->getPage($uid);
+        return array_merge([$this->getPage($pageUid)], $this->getAllSubpagesForPage($pageUid, $withRestrictions));
     }
 
     /**
@@ -205,7 +129,7 @@ class OtPageRepository
      *
      * @return int|null
      */
-    public function getCurrentPageId(): ?int
+    public function getCurrentBePageId(): ?int
     {
         return (int)GeneralUtility::_GP('id');
     }
@@ -218,9 +142,9 @@ class OtPageRepository
      * @return int
      * @throws NoSiteSelected
      */
-    public function getCurrentRootUid(): int
+    public function getCurrentBeRootUid(): int
     {
-        $pageUid = $this->getCurrentPageId();
+        $pageUid = $this->getCurrentBePageId();
 
         $rootPage = $this->getRootPageFor($pageUid);
         $rootUid = $rootPage['uid'] ?? 0;
@@ -245,7 +169,7 @@ class OtPageRepository
         }
 
         $mountpoints = $be_user->returnWebmounts();
-        return array_filter($mountpoints, function($m) { return is_numeric($m) && (int)$m > 0; });;
+        return array_filter($mountpoints, function($m) { return is_numeric($m) && (int)$m > 0; });
     }
 
     public function getPage(int $uid): array

+ 39 - 0
ot_core/Classes/Website/OtWebsiteRepository.php

@@ -5,6 +5,7 @@ namespace Opentalent\OtCore\Website;
 use Opentalent\OtCore\Exception\InvalidWebsiteConfigurationException;
 use Opentalent\OtCore\Exception\NoSuchWebsiteException;
 use Symfony\Component\Yaml\Yaml;
+use TYPO3\CMS\Core\Http\Uri;
 use TYPO3\CMS\Core\Site\Entity\Site;
 
 /**
@@ -246,6 +247,44 @@ class OtWebsiteRepository
         );
     }
 
+    /**
+     * Returns the typo3 site matching the current request (FE only)
+     *
+     * @return array
+     * @throws NoSuchWebsiteException
+     */
+    public function getCurrentWebsiteFromFEGlobals(): array
+    {
+        $request = $GLOBALS['TYPO3_REQUEST'];
+        $site = $request->getAttribute('site');
+        return $this->getWebsiteByConfigIdentifier($site->getIdentifier());
+    }
+
+    /**
+     * Returns the typo3 site matching the current request (FE only)
+     *
+     * @return int
+     * @throws NoSuchWebsiteException
+     */
+    public function getCurrentRootpageUidFromFEGlobals(): int
+    {
+        $website = $this->getCurrentWebSiteFromFEGlobals();
+        return $this->getWebsiteRootUid($website['uid']);
+    }
+
+    /**
+     * Returns the current site's rootpage URI (FE only)
+     *
+     * @return string
+     * @throws InvalidWebsiteConfigurationException
+     * @throws NoSuchWebsiteException
+     */
+    public function getCurrentSiteRootUriFromFeGlobals(): string
+    {
+        $website = $this->getCurrentWebSiteFromFEGlobals();
+        return $this->resolveWebsiteBaseUri($website);
+    }
+
     /**
      * Try to retrieve the website matching the given Uri and return the given website
      *

+ 2 - 2
ot_core/Tests/Unit/Controller/SelectedSiteControllerTest.php

@@ -19,9 +19,9 @@ class SelectedSiteControllerTest extends UnitTestCase
         $otPageRepository = $this->prophesize(OtPageRepository::class);
 
         if ($selectedUid != null) {
-            $otPageRepository->getCurrentRootUid()->willReturn($selectedUid);
+            $otPageRepository->getCurrentBeRootUid()->willReturn($selectedUid);
         } else {
-            $otPageRepository->getCurrentRootUid()->willThrow(new NoSiteSelected());
+            $otPageRepository->getCurrentBeRootUid()->willThrow(new NoSiteSelected());
         }
         $otPageRepository->getCurrentBeUserMountpoints()->shouldBeCalled()->willReturn($mountpoints);
         $this->controller->injectOtPageRepository($otPageRepository->reveal());

+ 3 - 64
ot_core/Tests/Unit/Website/OtPageRepositoryTest.php

@@ -263,73 +263,12 @@ class OtPageRepositoryTest extends UnitTestCase
     }
 
     /**
-     * Calling getSiteByRootPageId() on a site's root page should return the site object
-     * as the typo3 SiteFinder class would do
-     *
-     * @test
-     */
-    public function getSiteForSiteRootPage() {
-
-        // Prepare prophecies
-        $root_uid = 200;
-        $root_page = $this->pageFixtures->getByUid($root_uid);
-
-        $root_line = $this->pageFixtures->getRootlineFor($root_uid);
-
-        $this->pageService->getRootLine($root_uid)->shouldBeCalled()->willReturn($root_line);
-        $this->pageRepository->getPage($root_uid)->shouldBeCalled()->willReturn($root_page);
-
-        $site = $this->prophesize(\TYPO3\CMS\Core\Site\Entity\Site::class);
-        $this->siteFinder->getSiteByRootPageId($root_uid)->shouldBeCalled()->willReturn($site->reveal());
-
-        $this->injectProphecies();
-
-        // Test
-        $expected = $site->reveal();
-        $actual = $this->otPageRepository->getSiteFor($root_uid);
-
-        $this->assertEquals($expected, $actual);
-    }
-
-    /**
-     * Calling getSiteByRootPageId() on a site's page should return the site object
-     *
-     * @test
-     */
-    public function getSiteForSiteSubPage() {
-
-        // Prepare prophecies
-        $page_uid = 211;
-
-        $root_uid = 200;
-        $root_page = $this->pageFixtures->getByUid($root_uid);
-
-        $root_line = $this->pageFixtures->getRootlineFor($page_uid);
-
-        $this->pageService->getRootLine($page_uid)->shouldBeCalled()->willReturn($root_line);
-        $this->pageRepository->getPage($root_uid)->shouldBeCalled()->willReturn($root_page);
-
-        $site = $this->prophesize(\TYPO3\CMS\Core\Site\Entity\Site::class);
-        $this->siteFinder->getSiteByRootPageId($root_uid)->shouldBeCalled()->willReturn($site->reveal());
-
-        $this->injectProphecies();
-
-        // Test
-        $expected = $site->reveal();
-        $actual = $this->otPageRepository->getSiteFor($page_uid);
-
-        $this->assertEquals($expected, $actual);
-    }
-
-
-
-    /**
-     * Calling getCurrentRootUid() when the current page is a site's page
+     * Calling getCurrentBeRootUid() when the current page is a site's page
      * should return the root page uid of the site
      *
      * @test
      */
-    public function getCurrentRootUidOnSitePage() {
+    public function getCurrentBeRootUidOnSitePage() {
 
         // Prepare prophecies
         $page_uid = 210;
@@ -347,7 +286,7 @@ class OtPageRepositoryTest extends UnitTestCase
 
         // Test
         $expected = $root_uid;
-        $actual = $this->otPageRepository->getCurrentRootUid();
+        $actual = $this->otPageRepository->getCurrentBeRootUid();
 
         $this->assertEquals($expected, $actual);
     }

+ 2 - 6
ot_stats/Classes/Controller/OtStatsController.php

@@ -5,7 +5,6 @@ namespace Opentalent\OtStats\Controller;
 use Opentalent\OtCore\Controller\SelectedSiteController;
 use Opentalent\OtCore\Logging\OtLogger;
 use Opentalent\OtStats\Domain\Repository\MatomoWebsiteRepository;
-use Opentalent\OtStats\Settings\StatsSettingsRepository;
 use TYPO3\CMS\Core\Messaging\AbstractMessage;
 use TYPO3\CMS\Core\Utility\GeneralUtility;
 use TYPO3\CMS\Extbase\Mvc\Exception\StopActionException;
@@ -28,10 +27,7 @@ class OtStatsController extends SelectedSiteController {
      * Displays the customizer page on the backend
      */
     public function indexAction() {
-        $this->view->assign('rootPage', $this->currentRootUid);
-        $statsSettingsRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(StatsSettingsRepository::class);
-        $matomoId = $statsSettingsRepository->getMatomoSiteId($this->currentRootUid);
-
+        $matomoId = $this->currentWebsite['matomo_site_id'];
         if ($matomoId == null) {
             $this->forward('askForActivationConfirmation');
         }
@@ -40,7 +36,7 @@ class OtStatsController extends SelectedSiteController {
         $args = $this->request->getArguments();
 
         // Default interval
-        $period = isset($args['period']) ? $args['period'] : 'month';
+        $period = $args['period'] ?? 'month';
         $this->view->assign('period', $period);
 
     }

+ 18 - 2
ot_stats/Classes/Domain/Repository/MatomoWebsiteRepository.php

@@ -117,6 +117,24 @@ class MatomoWebsiteRepository
         return $this->fromArray($data);
     }
 
+    /**
+     * Retrieve the MatomoWebsite object for the typo3 website with
+     * the given rootUid, otherwise, returns Null
+     *
+     * @param int $websiteUid
+     * @return MatomoWebsite|null
+     */
+    public function findByWebsiteUid(int $websiteUid): ?MatomoWebsite
+    {
+        $otWebsiteRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(OtWebsiteRepository::class);
+        $website = $otWebsiteRepository->getWebsiteByUid($websiteUid);
+
+        if ($website['matomo_site_id'] == null) {
+            return null;
+        }
+        return $this->findById($website['matomo_site_id']);
+    }
+
     /**
      * Retrieve the MatomoWebsite object for the typo3 website with
      * the given rootUid, otherwise, returns Null
@@ -127,8 +145,6 @@ class MatomoWebsiteRepository
     public function findByRootUid(int $rootUid): ?MatomoWebsite
     {
         $otWebsiteRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(OtWebsiteRepository::class);
-
-        // Just to make sure this page is actually the root page
         $website = $otWebsiteRepository->getWebsiteByPageUid($rootUid);
 
         if ($website['matomo_site_id'] == null) {

+ 4 - 7
ot_stats/Classes/Middleware/RequestHandler.php

@@ -1,8 +1,7 @@
 <?php
 namespace Opentalent\OtStats\Middleware;
 
-use Opentalent\OtCore\Website\OtPageRepository;
-use Opentalent\OtStats\Settings\StatsSettingsRepository;
+use Opentalent\OtCore\Website\OtWebsiteRepository;
 use Psr\Http\Message\ResponseInterface;
 use Psr\Http\Message\ServerRequestInterface;
 use Psr\Http\Server\MiddlewareInterface;
@@ -39,11 +38,9 @@ class RequestHandler implements MiddlewareInterface
     {
 
         // Retrieve the current matomo site's id if set
-        $otPageRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(OtPageRepository::class);
-        $rootPageUid = $otPageRepository->getCurrentSiteRootPageUid();
-
-        $statsSettingsRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(StatsSettingsRepository::class);
-        $matomoSiteId = $statsSettingsRepository->getMatomoSiteId($rootPageUid);
+        $otWebsiteRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(OtWebsiteRepository::class);
+        $website = $otWebsiteRepository->getCurrentWebsiteFromFEGlobals();
+        $matomoSiteId = $website['matomo_site_id'];
 
         if (!$matomoSiteId > 0) {
             // stats are not enabled, continue

+ 0 - 29
ot_stats/Classes/Settings/StatsSettingsRepository.php

@@ -1,29 +0,0 @@
-<?php
-
-namespace Opentalent\OtStats\Settings;
-
-use Opentalent\OtCore\Website\OtWebsiteRepository;
-use TYPO3\CMS\Core\Utility\GeneralUtility;
-use TYPO3\CMS\Extbase\Object\ObjectManager;
-
-/**
- * Class StatsRepository
- *
- * Give access to the website's settings for the stats module
- *
- * @package Opentalent\OtTemplating\Page
- */
-class StatsSettingsRepository
-{
-    /**
-     * Returns the website registered matomo site's id
-     * @param int $rootPageUid
-     * @return int|null
-     */
-    public function getMatomoSiteId(int $rootPageUid): ?int
-    {
-        $otWebsiteRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(OtWebsiteRepository::class);
-        $website = $otWebsiteRepository->getWebsiteByPageUid($rootPageUid);
-        return $website['matomo_site_id'];
-    }
-}

+ 4 - 7
ot_stats/Classes/ViewHelpers/MatomoSiteIdViewHelper.php

@@ -4,8 +4,7 @@ namespace Opentalent\OtStats\ViewHelpers;
 
 
 use Closure;
-use Opentalent\OtCore\Website\OtPageRepository;
-use Opentalent\OtStats\Settings\StatsSettingsRepository;
+use Opentalent\OtCore\Website\OtWebsiteRepository;
 use TYPO3\CMS\Core\Utility\GeneralUtility;
 use TYPO3\CMS\Extbase\Object\ObjectManager;
 use TYPO3Fluid\Fluid\Core\Rendering\RenderingContextInterface;
@@ -37,10 +36,8 @@ class MatomoSiteIdViewHelper extends AbstractViewHelper
         Closure $renderChildrenClosure,
         RenderingContextInterface $renderingContext
     ) {
-        $otPageRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(OtPageRepository::class);
-        $rootPageUid = $otPageRepository->getCurrentSiteRootPageUid();
-
-        $statsSettingsRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(StatsSettingsRepository::class);
-        return $statsSettingsRepository->getMatomoSiteId($rootPageUid);
+        $otWebsiteRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(OtWebsiteRepository::class);
+        $website = $otWebsiteRepository->getCurrentWebsiteFromFEGlobals();
+        return $website['matomo_site_id'];
     }
 }

+ 6 - 11
ot_templating/Classes/Controller/OtCustomizerController.php

@@ -34,11 +34,12 @@ class OtCustomizerController extends SelectedSiteController {
      */
     public function indexAction() {
         $this->view->assign('rootPage', $this->currentRootUid);
+        $this->view->assign('website', $this->currentWebsite);
         $this->view->assign('templates', TemplateRepository::templates);
 
         $templateRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(TemplateRepository::class);
-        $this->view->assign('currentTemplate', $templateRepository->getTemplate($this->currentRootUid));
-        $this->view->assign('preferences', $templateRepository->getTemplatePreferences($this->currentRootUid));
+        $this->view->assign('currentTemplate', $templateRepository->getTemplate($this->currentWebsite));
+        $this->view->assign('preferences', $templateRepository->getTemplatePreferences($this->currentWebsite));
     }
 
     /**
@@ -47,13 +48,10 @@ class OtCustomizerController extends SelectedSiteController {
     public function selectTemplateAction() {
         $templateKey = $this->request->getArgument('template_key');
 
-        $otWebsiteRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(OtWebsiteRepository::class);
-        $website = $otWebsiteRepository->getWebsiteByPageUid($this->currentRootUid);
-
         // applies the change in the database
-        $queryBuilder = $this->connectionPool->getQueryBuilderForTable('pages');
+        $queryBuilder = $this->connectionPool->getQueryBuilderForTable('ot_websites');
         $queryBuilder->update('ot_websites')
-            ->where($queryBuilder->expr()->eq('uid', $website['uid']))
+            ->where($queryBuilder->expr()->eq('uid', $this->currentWebsite['uid']))
             ->set('template', $templateKey)
             ->execute();
 
@@ -86,12 +84,9 @@ class OtCustomizerController extends SelectedSiteController {
         }
 
         // applies the change in the database
-        $otWebsiteRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(OtWebsiteRepository::class);
-        $website = $otWebsiteRepository->getWebsiteByPageUid($this->currentRootUid);
-
         $queryBuilder = $this->connectionPool->getQueryBuilderForTable('ot_websites');
         $queryBuilder->update('ot_websites')
-            ->where($queryBuilder->expr()->eq('uid', $website['uid']))
+            ->where($queryBuilder->expr()->eq('uid', $this->currentWebsite['uid']))
             ->set('template_preferences', json_encode($prefs))
             ->execute();
 

+ 3 - 7
ot_templating/Classes/Templating/TemplateRepository.php

@@ -43,14 +43,12 @@ class TemplateRepository
      * @param int $rootUid
      * @return string
      */
-    public function getTemplate(int $rootUid): string
+    public function getTemplate(array $website): string
     {
-        if (!($rootUid >= 0)) {
+        if (!($website['uid'] >= 0)) {
             return self::defaultTemplate;
         }
 
-        $otWebsiteRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(OtWebsiteRepository::class);
-        $website = $otWebsiteRepository->getWebsiteByPageUid($rootUid);
         $templateName = $website['template'];
 
         if ($templateName==='' || $templateName==null) {
@@ -64,10 +62,8 @@ class TemplateRepository
      * @param int $rootUid
      * @return array
      */
-    public function getTemplatePreferences(int $rootUid): array
+    public function getTemplatePreferences(array $website): array
     {
-        $otWebsiteRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(OtWebsiteRepository::class);
-        $website = $otWebsiteRepository->getWebsiteByPageUid($rootUid);
         $templatePreferences = $website['template_preferences'] ?? '';
 
         if ($templatePreferences !== '') {

+ 3 - 3
ot_templating/Classes/ViewHelpers/RootPage/GetIdViewHelper.php

@@ -3,8 +3,8 @@
 namespace Opentalent\OtTemplating\ViewHelpers\RootPage;
 
 use Closure;
-use Opentalent\OtCore\Website\OtPageRepository;
 use Opentalent\OtCore\ViewHelpers\OtAbstractViewHelper;
+use Opentalent\OtCore\Website\OtWebsiteRepository;
 use TYPO3\CMS\Core\Utility\GeneralUtility;
 use TYPO3\CMS\Extbase\Object\ObjectManager;
 use TYPO3Fluid\Fluid\Core\Rendering\RenderingContextInterface;
@@ -35,7 +35,7 @@ class GetIdViewHelper extends OtAbstractViewHelper
         Closure $renderChildrenClosure,
         RenderingContextInterface $renderingContext
     ) {
-        $pageRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(OtPageRepository::class);
-        return $pageRepository->getCurrentSiteRootPageUid();
+        $pageRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(OtWebsiteRepository::class);
+        return $pageRepository->getCurrentRootpageUidFromFEGlobals();
     }
 }

+ 3 - 3
ot_templating/Classes/ViewHelpers/RootPage/GetUriViewHelper.php

@@ -4,7 +4,7 @@ namespace Opentalent\OtTemplating\ViewHelpers\RootPage;
 
 use Closure;
 use Opentalent\OtCore\ViewHelpers\OtAbstractViewHelper;
-use Opentalent\OtCore\Website\OtPageRepository;
+use Opentalent\OtCore\Website\OtWebsiteRepository;
 use TYPO3\CMS\Core\Utility\GeneralUtility;
 use TYPO3\CMS\Extbase\Object\ObjectManager;
 use TYPO3Fluid\Fluid\Core\Rendering\RenderingContextInterface;
@@ -35,7 +35,7 @@ class GetUriViewHelper extends OtAbstractViewHelper
         Closure $renderChildrenClosure,
         RenderingContextInterface $renderingContext
     ) {
-        $pageRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(OtPageRepository::class);
-        return $pageRepository->getCurrentSiteRootPageUri();
+        $pageRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(OtWebsiteRepository::class);
+        return $pageRepository->getCurrentSiteRootUriFromFeGlobals();
     }
 }

+ 4 - 4
ot_templating/Classes/ViewHelpers/Template/CurrentViewHelper.php

@@ -4,8 +4,8 @@ namespace Opentalent\OtTemplating\ViewHelpers\Template;
 
 
 use Closure;
-use Opentalent\OtCore\Website\OtPageRepository;
 use Opentalent\OtCore\ViewHelpers\OtAbstractViewHelper;
+use Opentalent\OtCore\Website\OtWebsiteRepository;
 use Opentalent\OtTemplating\Templating\TemplateRepository;
 use TYPO3\CMS\Core\Utility\GeneralUtility;
 use TYPO3\CMS\Extbase\Object\ObjectManager;
@@ -36,10 +36,10 @@ class CurrentViewHelper extends OtAbstractViewHelper
         Closure $renderChildrenClosure,
         RenderingContextInterface $renderingContext
     ) {
-        $pageRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(OtPageRepository::class);
-        $rootUid = $pageRepository->getCurrentSiteRootPageUid();
+        $pageRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(OtWebsiteRepository::class);
+        $website = $pageRepository->getCurrentWebsiteFromFEGlobals();
 
         $templateRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(TemplateRepository::class);
-        return $templateRepository->getTemplate($rootUid);
+        return $templateRepository->getTemplate($website);
     }
 }

+ 4 - 4
ot_templating/Classes/ViewHelpers/Template/GetPreferenceViewHelper.php

@@ -4,8 +4,8 @@ namespace Opentalent\OtTemplating\ViewHelpers\Template;
 
 
 use Closure;
-use Opentalent\OtCore\Website\OtPageRepository;
 use Opentalent\OtCore\ViewHelpers\OtAbstractViewHelper;
+use Opentalent\OtCore\Website\OtWebsiteRepository;
 use Opentalent\OtTemplating\Templating\TemplateRepository;
 use TYPO3\CMS\Core\Utility\GeneralUtility;
 use TYPO3\CMS\Extbase\Object\ObjectManager;
@@ -50,11 +50,11 @@ class GetPreferenceViewHelper extends OtAbstractViewHelper
         Closure $renderChildrenClosure,
         RenderingContextInterface $renderingContext
     ) {
-        $pageRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(OtPageRepository::class);
-        $rootUid = $pageRepository->getCurrentSiteRootPageUid();
+        $pageRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(OtWebsiteRepository::class);
+        $website = $pageRepository->getCurrentWebsiteFromFEGlobals();
 
         $templateRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(TemplateRepository::class);
-        $preferences = $templateRepository->getTemplatePreferences($rootUid);
+        $preferences = $templateRepository->getTemplatePreferences($website);
 
         $key = $arguments['key'];
         return $preferences[$key];

+ 2 - 2
ot_templating/Classes/ViewHelpers/Template/GetPreferencesViewHelper.php

@@ -36,10 +36,10 @@ class PreferencesViewHelper extends OtAbstractViewHelper
         RenderingContextInterface $renderingContext
     ) {
         $pageRepository = GeneralUtility::makeInstance(ObjectManager::class)->get(OtPageRepository::class);
-        $rootUid = $pageRepository->getCurrentSiteRootPageUid();
+        $website = $pageRepository->getCurrentWebsiteFromFEGlobals();
 
         $templateRepository = GeneralUtility::makeInstance(TemplateRepository::class);
-        return $templateRepository->getTemplatePreferences($rootUid);
+        return $templateRepository->getTemplatePreferences($website);
     }
 
 }

+ 53 - 53
ot_templating/Resources/Public/assets/Modern/fonts/revicons.svg

@@ -1,54 +1,54 @@
-<?xml version="1.0" standalone="no"?>


-<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">


-<svg xmlns="http://www.w3.org/2000/svg">


-<metadata>Copyright (C) 2013 by original authors @ fontello.com</metadata>


-<defs>


-<font id="revicons" horiz-adv-x="1000" >


-<font-face font-family="revicons" font-weight="400" font-stretch="normal" units-per-em="1000" ascent="850" descent="-150" />


-<missing-glyph horiz-adv-x="1000" />


-<glyph glyph-name="search" unicode="&#xe802;" d="m643 386q0 103-74 176t-176 74t-177-74t-73-176t73-177t177-73t176 73t74 177z m286-465q0-29-22-50t-50-21q-30 0-50 21l-191 191q-100-69-223-69q-80 0-153 31t-125 84t-84 125t-31 153t31 152t84 126t125 84t153 31t152-31t126-84t84-126t31-152q0-123-69-223l191-191q21-21 21-51z" horiz-adv-x="928.6" />


-<glyph glyph-name="pencil-1" unicode="&#xe831;" d="m795 731c50-46 44-118-4-165l-46-46s35 53-37 123c-64 64-124 37-124 37l49 48c43 45 120 45 162 3z m-89-250l-492-493l-210-51l-4 4l55 210l493 490c8 2 30 9 60 2l-523-522l-15-55l60-60l56 15l25 24l3 56l-40 40l479 479c7-7 7-7 15-15c71-70 38-124 38-124z" horiz-adv-x="830" />


-<glyph glyph-name="picture-1" unicode="&#xe803;" d="m357 529q0-45-31-76t-76-32t-76 32t-31 76t31 75t76 32t76-32t31-75z m572-215v-250h-786v107l178 179l90-89l285 285z m53 393h-893q-7 0-12-5t-6-13v-678q0-8 6-13t12-5h893q7 0 13 5t5 13v678q0 7-5 13t-13 5z m89-18v-678q0-37-26-63t-63-27h-893q-36 0-63 27t-26 63v678q0 37 26 63t63 27h893q37 0 63-27t26-63z" horiz-adv-x="1071.4" />


-<glyph glyph-name="cancel" unicode="&#xe80a;" d="m724 112q0-22-15-38l-76-76q-16-15-38-15t-38 15l-164 165l-164-165q-16-15-38-15t-38 15l-76 76q-16 16-16 38t16 38l164 164l-164 164q-16 16-16 38t16 38l76 76q16 16 38 16t38-16l164-164l164 164q16 16 38 16t38-16l76-76q15-15 15-38t-15-38l-164-164l164-164q15-15 15-38z" horiz-adv-x="785.7" />


-<glyph glyph-name="info-circled" unicode="&#xe80f;" d="m571 82v89q0 8-5 13t-12 5h-54v286q0 8-5 13t-13 5h-178q-8 0-13-5t-5-13v-89q0-8 5-13t13-5h53v-179h-53q-8 0-13-5t-5-13v-89q0-8 5-13t13-5h250q7 0 12 5t5 13z m-71 500v89q0 8-5 13t-13 5h-107q-8 0-13-5t-5-13v-89q0-8 5-13t13-5h107q8 0 13 5t5 13z m357-232q0-117-57-215t-156-156t-215-58t-216 58t-155 156t-58 215t58 215t155 156t216 58t215-58t156-156t57-215z" horiz-adv-x="857.1" />


-<glyph glyph-name="trash" unicode="&#xe801;" d="m286 439v-321q0-8-5-13t-13-5h-36q-8 0-13 5t-5 13v321q0 8 5 13t13 5h36q8 0 13-5t5-13z m143 0v-321q0-8-5-13t-13-5h-36q-8 0-13 5t-5 13v321q0 8 5 13t13 5h36q8 0 13-5t5-13z m142 0v-321q0-8-5-13t-12-5h-36q-8 0-13 5t-5 13v321q0 8 5 13t13 5h36q7 0 12-5t5-13z m72-404v529h-500v-529q0-12 4-22t8-15t6-5h464q2 0 6 5t8 15t4 22z m-375 601h250l-27 65q-4 5-9 6h-177q-6-1-10-6z m518-18v-36q0-8-5-13t-13-5h-54v-529q0-46-26-80t-63-34h-464q-37 0-63 33t-27 79v531h-53q-8 0-13 5t-5 13v36q0 8 5 13t13 5h172l39 93q9 21 31 35t44 15h178q22 0 44-15t30-35l39-93h173q8 0 13-5t5-13z" horiz-adv-x="785.7" />


-<glyph glyph-name="left-dir" unicode="&#xe817;" d="m357 600v-500q0-14-10-25t-26-11t-25 11l-250 250q-10 11-10 25t10 25l250 250q11 11 25 11t26-11t10-25z" horiz-adv-x="357.1" />


-<glyph glyph-name="right-dir" unicode="&#xe818;" d="m321 350q0-14-10-25l-250-250q-11-11-25-11t-25 11t-11 25v500q0 15 11 25t25 11t25-11l250-250q10-10 10-25z" horiz-adv-x="357.1" />


-<glyph glyph-name="down-open" unicode="&#xe83b;" d="m899 457q0-29-21-50l-363-363q-21-22-51-22q-30 0-50 22l-363 363q-21 20-21 50q0 30 21 51l41 42q22 20 51 20q29 0 50-20l271-271l271 271q21 20 51 20q29 0 50-20l42-42q21-22 21-51z" horiz-adv-x="928.6" />


-<glyph glyph-name="left-open" unicode="&#xe819;" d="m414-28l-364 364q-20 20-20 50t20 51l364 363q21 20 51 20t50-20l42-42q21-21 21-51t-21-50l-271-271l271-271q21-21 21-51t-21-50l-42-42q-21-20-50-20t-51 20z" horiz-adv-x="642.9" />


-<glyph glyph-name="right-open" unicode="&#xe81a;" d="m613 386q0-29-20-51l-364-363q-21-21-50-21t-51 21l-42 42q-21 21-21 50q0 30 21 51l271 271l-271 270q-21 22-21 51q0 30 21 50l42 42q20 21 51 21t50-21l364-363q20-21 20-50z" horiz-adv-x="642.9" />


-<glyph glyph-name="angle-left" unicode="&#xe820;" d="m350 546q0-7-6-12l-219-220l219-219q6-6 6-13t-6-13l-28-28q-5-5-12-5t-13 5l-260 260q-6 6-6 13t6 13l260 260q5 6 13 6t12-6l28-28q6-5 6-13z" horiz-adv-x="357.1" />


-<glyph glyph-name="angle-right" unicode="&#xe81d;" d="m332 314q0-7-6-13l-260-260q-5-5-12-5t-13 5l-28 28q-6 6-6 13t6 13l219 219l-219 220q-6 5-6 12t6 13l28 28q5 6 13 6t12-6l260-260q6-5 6-13z" horiz-adv-x="357.1" />


-<glyph glyph-name="left-big" unicode="&#xe81f;" d="m857 350v-71q0-30-18-51t-47-21h-393l164-164q21-20 21-50t-21-50l-42-43q-21-20-51-20q-29 0-50 20l-364 364q-20 21-20 50q0 29 20 51l364 363q21 21 50 21q29 0 51-21l42-42q21-21 21-50t-21-51l-164-164h393q29 0 47-20t18-51z" horiz-adv-x="857.1" />


-<glyph glyph-name="right-big" unicode="&#xe81e;" d="m821 314q0-30-20-50l-363-364q-22-20-51-20q-29 0-50 20l-42 42q-22 21-22 51t22 51l163 163h-393q-29 0-47 21t-18 51v71q0 30 18 51t47 20h393l-163 164q-22 21-22 51t22 50l42 42q21 21 50 21q29 0 51-21l363-363q20-20 20-51z" horiz-adv-x="857.1" />


-<glyph glyph-name="magic" unicode="&#xe807;" d="m664 526l164 163l-60 60l-164-164z m249 163q0-15-10-25l-717-718q-10-10-25-10t-25 10l-111 111q-10 10-10 25t10 25l718 718q10 10 25 10t25-10l110-111q10-10 10-25z m-753 106l54-16l-54-17l-17-55l-17 55l-55 17l55 16l17 55z m195-90l109-34l-109-33l-34-109l-33 109l-109 33l109 34l33 109z m519-267l55-17l-55-16l-17-55l-17 55l-54 16l54 17l17 55z m-357 357l54-16l-54-17l-17-55l-17 55l-54 17l54 16l17 55z" horiz-adv-x="928.6" />


-<glyph glyph-name="picture" unicode="&#xe800;" d="m856 518l-100 0l-124 150l-214-150l-180 0q-52 0-90-39t-38-91l0-160l-108 296q-10 38 22 52l680 248q36 10 50-24z m106-90q16 0 27-12t11-28l0-472q0-16-11-28t-27-12l-724 0q-16 0-27 12t-11 28l0 472q0 16 11 28t27 12l724 0z m-56-452l0 162l-72 160l-166-60l-130-132l-138 170l-92-214l0-86l598 0z" horiz-adv-x="1000" />


-<glyph glyph-name="export" unicode="&#xe80b;" d="m750 60l0 56l100 82l0-188q0-20-15-35t-35-15l-750 0q-20 0-35 15t-15 35l0 550q0 22 14 36t36 14l288 0q-32-24-59-49t-39-39l-10-12l-130 0l0-450l650 0z m-82 348q-166 0-242-41t-160-181q0 8 1 22t9 56t22 79t44 83t70 79t107 56t149 23l0 156l332-250l-332-260l0 178z" horiz-adv-x="1000" />


-<glyph glyph-name="cog" unicode="&#xe832;" d="m760 350q0-72 80-122q-12-40-34-82q-70 18-136-44q-54-58-34-136q-40-20-84-36q-46 82-132 82t-132-82q-44 16-84 36q20 80-34 136q-54 54-136 34q-14 26-34 82q82 52 82 132q0 72-82 124q20 56 34 82q74-18 136 44q54 56 34 136q42 22 84 34q46-80 132-80t132 80q42-12 84-34q-20-78 34-136q66-62 136-44q22-42 34-82q-80-50-80-124z m-340-182q76 0 129 53t53 129t-53 130t-129 54t-129-54t-53-130t53-129t129-53z" horiz-adv-x="840" />


-<glyph glyph-name="login" unicode="&#xe833;" d="m800 800q42 0 71-29t29-71l0-700q0-40-29-70t-71-30l-450 0q-40 0-69 30t-29 70l0 100l98 0l0-100l450 0l0 700l-450 0l0-150l-98 0l0 150q0 42 29 71t69 29l450 0z m-350-670l0 120l-450 0l0 150l450 0l0 120l200-194z" horiz-adv-x="900" />


-<glyph glyph-name="logout" unicode="&#xe834;" d="m502 0l0 100l98 0l0-100q0-40-29-70t-71-30l-400 0q-40 0-70 30t-30 70l0 700q0 42 30 71t70 29l400 0q42 0 71-29t29-71l0-150l-98 0l0 150l-402 0l0-700l402 0z m398 326l-198-196l0 120l-450 0l0 150l450 0l0 120z" horiz-adv-x="900" />


-<glyph glyph-name="video" unicode="&#xe805;" d="m214-43v72q0 14-10 25t-25 10h-72q-14 0-25-10t-11-25v-72q0-14 11-25t25-11h72q14 0 25 11t10 25z m0 214v72q0 14-10 25t-25 11h-72q-14 0-25-11t-11-25v-72q0-14 11-25t25-10h72q14 0 25 10t10 25z m0 215v71q0 15-10 25t-25 11h-72q-14 0-25-11t-11-25v-71q0-15 11-25t25-11h72q14 0 25 11t10 25z m572-429v286q0 14-11 25t-25 11h-429q-14 0-25-11t-10-25v-286q0-14 10-25t25-11h429q15 0 25 11t11 25z m-572 643v71q0 15-10 26t-25 10h-72q-14 0-25-10t-11-26v-71q0-15 11-25t25-11h72q14 0 25 11t10 25z m786-643v72q0 14-11 25t-25 10h-71q-15 0-25-10t-11-25v-72q0-14 11-25t25-11h71q15 0 25 11t11 25z m-214 429v285q0 15-11 26t-25 10h-429q-14 0-25-10t-10-26v-285q0-15 10-25t25-11h429q15 0 25 11t11 25z m214-215v72q0 14-11 25t-25 11h-71q-15 0-25-11t-11-25v-72q0-14 11-25t25-10h71q15 0 25 10t11 25z m0 215v71q0 15-11 25t-25 11h-71q-15 0-25-11t-11-25v-71q0-15 11-25t25-11h71q15 0 25 11t11 25z m0 214v71q0 15-11 26t-25 10h-71q-15 0-25-10t-11-26v-71q0-15 11-25t25-11h71q15 0 25 11t11 25z m71 89v-750q0-37-26-63t-63-26h-893q-36 0-63 26t-26 63v750q0 37 26 63t63 27h893q37 0 63-27t26-63z" horiz-adv-x="1071.4" />


-<glyph glyph-name="arrow-combo" unicode="&#xe827;" d="m230 850l230-364l-460 0z m0-1000l-230 366l460 0z" horiz-adv-x="460" />


-<glyph glyph-name="left-open-1" unicode="&#xe82a;" d="m242 626q14 16 39 16t41-16q38-36 0-80l-186-196l186-194q38-44 0-80q-16-16-40-16t-40 16l-226 236q-16 16-16 38q0 24 16 40q206 214 226 236z" horiz-adv-x="341" />


-<glyph glyph-name="right-open-1" unicode="&#xe82b;" d="m98 626l226-236q16-16 16-40q0-22-16-38l-226-236q-16-16-40-16t-40 16q-36 36 0 80l186 194l-186 196q-36 44 0 80q16 16 41 16t39-16z" horiz-adv-x="340" />


-<glyph glyph-name="left-open-mini" unicode="&#xe822;" d="m252 180q26-26 0-48q-26-26-48 0l-192 194q-24 24 0 50l192 194q22 26 48 0q26-22 0-48l-156-172z" horiz-adv-x="265" />


-<glyph glyph-name="right-open-mini" unicode="&#xe823;" d="m13 180l158 170l-158 172q-26 26 0 48q26 26 48 0l192-194q24-26 0-50l-192-194q-22-26-48 0q-26 22 0 48z" horiz-adv-x="265" />


-<glyph glyph-name="left-open-big" unicode="&#xe824;" d="m452-20q26-26 0-48q-26-26-48 0l-392 394q-24 24 0 50l392 394q22 26 48 0q26-22 0-48l-358-372z" horiz-adv-x="465" />


-<glyph glyph-name="right-open-big" unicode="&#xe825;" d="m13-20l358 370l-358 372q-26 26 0 48q26 26 48 0l392-394q24-26 0-50l-392-394q-22-26-48 0q-26 22 0 48z" horiz-adv-x="465" />


-<glyph glyph-name="left" unicode="&#xe836;" d="m378 20l-378 330l378 330l0-190l352 0l0-278l-352 0l0-192z" horiz-adv-x="730" />


-<glyph glyph-name="right" unicode="&#xe826;" d="m350 680l380-330l-380-330l0 192l-350 0l0 278l350 0l0 190z" horiz-adv-x="730" />


-<glyph glyph-name="ccw" unicode="&#xe808;" d="m532 736q170 0 289-120t119-290t-119-290t-289-120q-142 0-252 88l70 74q84-60 182-60q126 0 216 90t90 218t-90 218t-216 90q-124 0-214-87t-92-211l142 0l-184-204l-184 204l124 0q2 166 122 283t286 117z" horiz-adv-x="940" />


-<glyph glyph-name="arrows-ccw" unicode="&#xe806;" d="m186 140l116 116l0-292l-276 16l88 86q-116 122-114 290t120 288q100 100 240 116l4-102q-100-16-172-88q-88-88-90-213t84-217z m332 598l276-16l-88-86q116-122 114-290t-120-288q-96-98-240-118l-2 104q98 16 170 88q88 88 90 213t-84 217l-114-116z" horiz-adv-x="820" />


-<glyph glyph-name="palette" unicode="&#xe829;" d="m857 622q72-48 101-110t20-104t-35-48q-16-4-54 10t-80 10t-80-46q-30-46-21-75t34-65t23-50q-2-26-36-63t-126-74t-216-37q-186 0-291 101t-95 245q8 118 104 235t216 151q290 84 536-80z m-318-466q30 0 52 22t22 54t-22 53t-52 21q-32 0-54-21t-22-53t22-54t54-22z" horiz-adv-x="980" />


-<glyph glyph-name="list-add" unicode="&#xe80c;" d="m350 400q22 0 36-15t14-35t-15-35t-35-15l-300 0q-20 0-35 15t-15 35t14 35t36 15l300 0z m0-200q22 0 36-15t14-35t-15-35t-35-15l-300 0q-20 0-35 15t-15 35t14 35t36 15l300 0z m620 200q30 0 30-50t-30-50l-170 0l0-170q0-30-50-30t-50 30l0 170l-164 0q-30 0-30 50t30 50l164 0l0 170q0 30 50 30t50-30l0-170l170 0z m-620 200q22 0 36-15t14-35t-15-35t-35-15l-300 0q-20 0-35 15t-15 35t14 35t36 15l300 0z" horiz-adv-x="1000" />


-<glyph glyph-name="doc" unicode="&#xe809;" d="m818 595q16-16 16-36l0-521q0-65-46-111t-110-46l-522 0q-65 0-110 46t-46 111l0 625q0 65 46 110t110 46l417 0q22 0 37-15z m-110-36l-135 134l0-56q0-32 23-55t55-23l57 0z m-30-574q21 0 36 16t15 37l0 469l-78 0q-53 0-92 38t-38 92l0 78l-365 0q-21 0-37-15t-15-37l0-625q0-21 15-37t37-16l522 0z" horiz-adv-x="834" />


-<glyph glyph-name="left-open-outline" unicode="&#xe82e;" d="m638 91q0-64-47-111t-110-46q-65 0-110 45l-371 372l371 371q44 44 111 44t111-44q45-45 45-111q0-65-45-110l-150-150l150-150q45-45 45-110z m-490 260l297-298q15-15 37-15t37 15t15 38q0 21-15 36l-224 224l224 223q15 15 15 37q0 22-15 37t-37 15t-37-15z" horiz-adv-x="638" />


-<glyph glyph-name="left-open-2" unicode="&#xe82c;" d="m481 684q32-31 32-74t-32-74l-186-186l186-186q32-31 32-74t-32-74t-73-31t-74 31l-334 334l334 334q30 31 74 31t73-31z" horiz-adv-x="513" />


-<glyph glyph-name="right-open-outline" unicode="&#xe82f;" d="m156-66q-63 0-110 46t-46 111t46 110l150 150l-150 150q-46 46-46 110q0 65 46 111q44 44 110 44t110-44l372-371l-372-372q-45-45-110-45z m0 729q-21 0-37-16t-15-36q0-20 16-37l223-223l-223-224q-16-16-16-36q0-22 16-38q15-15 36-15t37 15l297 298l-297 297q-15 15-37 15z" horiz-adv-x="638" />


-<glyph glyph-name="right-open-2" unicode="&#xe82d;" d="m31 684q30 31 74 31t74-31l335-334l-335-334q-31-31-74-31t-74 31t-31 74t31 74l188 186l-188 186q-31 32-31 74t31 74z" horiz-adv-x="514" />


-<glyph glyph-name="equalizer" unicode="&#xe83a;" d="m576 239l0-112l-55 0l0-167q0-23-17-40t-39-17t-39 17t-17 40l0 167l-56 0l0 112l56 0l0 503q0 24 17 39t38 16q24 0 41-16t16-39l0-503l55 0z m335 335l0-112l-55 0l0-502q0-23-16-40t-41-17q-23 0-39 17t-16 40l0 502l-56 0l0 112l56 0l0 168q0 24 16 39t39 16t41-16t16-39l0-168l55 0z m-670-112l0-111l-55 0l0-391q0-23-16-40t-40-17q-23 0-39 17t-17 40l0 391l-56 0l0 111l56 0l0 280q0 24 16 39t40 16t40-16t16-39l0-280l55 0z" horiz-adv-x="928" />


-<glyph glyph-name="layers-alt" unicode="&#xe804;" d="m18 127l446-111l447 111l0-111l-447-113l-446 113l0 111z m0 224l446-112l447 112l0-112l-447-112l-446 112l0 112z m0 223l446-112l447 112l0-112l-447-111l-446 111l0 112z m0 223l446-112l447 112l0-112l-447-111l-446 111l0 112z" horiz-adv-x="928" />


-<glyph glyph-name="popup" unicode="&#xe828;" d="m700 750q42 0 71-29t29-71l0-400q0-40-29-70t-71-30l-400 0q-40 0-70 30t-30 70l0 402q0 40 29 69t71 29l400 0z m0-500l0 400l-400 0l0-400l400 0z m-600 100l0-300l300 0l0-100l-300 0q-40 0-70 30t-30 70l0 300l100 0z" horiz-adv-x="800" />


-</font>


-</defs>


+<?xml version="1.0" standalone="no"?>

+<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">

+<svg xmlns="http://www.w3.org/2000/svg">

+<metadata>Copyright (C) 2013 by original authors @ fontello.com</metadata>

+<defs>

+<font id="revicons" horiz-adv-x="1000" >

+<font-face font-family="revicons" font-weight="400" font-stretch="normal" units-per-em="1000" ascent="850" descent="-150" />

+<missing-glyph horiz-adv-x="1000" />

+<glyph glyph-name="search" unicode="&#xe802;" d="m643 386q0 103-74 176t-176 74t-177-74t-73-176t73-177t177-73t176 73t74 177z m286-465q0-29-22-50t-50-21q-30 0-50 21l-191 191q-100-69-223-69q-80 0-153 31t-125 84t-84 125t-31 153t31 152t84 126t125 84t153 31t152-31t126-84t84-126t31-152q0-123-69-223l191-191q21-21 21-51z" horiz-adv-x="928.6" />

+<glyph glyph-name="pencil-1" unicode="&#xe831;" d="m795 731c50-46 44-118-4-165l-46-46s35 53-37 123c-64 64-124 37-124 37l49 48c43 45 120 45 162 3z m-89-250l-492-493l-210-51l-4 4l55 210l493 490c8 2 30 9 60 2l-523-522l-15-55l60-60l56 15l25 24l3 56l-40 40l479 479c7-7 7-7 15-15c71-70 38-124 38-124z" horiz-adv-x="830" />

+<glyph glyph-name="picture-1" unicode="&#xe803;" d="m357 529q0-45-31-76t-76-32t-76 32t-31 76t31 75t76 32t76-32t31-75z m572-215v-250h-786v107l178 179l90-89l285 285z m53 393h-893q-7 0-12-5t-6-13v-678q0-8 6-13t12-5h893q7 0 13 5t5 13v678q0 7-5 13t-13 5z m89-18v-678q0-37-26-63t-63-27h-893q-36 0-63 27t-26 63v678q0 37 26 63t63 27h893q37 0 63-27t26-63z" horiz-adv-x="1071.4" />

+<glyph glyph-name="cancel" unicode="&#xe80a;" d="m724 112q0-22-15-38l-76-76q-16-15-38-15t-38 15l-164 165l-164-165q-16-15-38-15t-38 15l-76 76q-16 16-16 38t16 38l164 164l-164 164q-16 16-16 38t16 38l76 76q16 16 38 16t38-16l164-164l164 164q16 16 38 16t38-16l76-76q15-15 15-38t-15-38l-164-164l164-164q15-15 15-38z" horiz-adv-x="785.7" />

+<glyph glyph-name="info-circled" unicode="&#xe80f;" d="m571 82v89q0 8-5 13t-12 5h-54v286q0 8-5 13t-13 5h-178q-8 0-13-5t-5-13v-89q0-8 5-13t13-5h53v-179h-53q-8 0-13-5t-5-13v-89q0-8 5-13t13-5h250q7 0 12 5t5 13z m-71 500v89q0 8-5 13t-13 5h-107q-8 0-13-5t-5-13v-89q0-8 5-13t13-5h107q8 0 13 5t5 13z m357-232q0-117-57-215t-156-156t-215-58t-216 58t-155 156t-58 215t58 215t155 156t216 58t215-58t156-156t57-215z" horiz-adv-x="857.1" />

+<glyph glyph-name="trash" unicode="&#xe801;" d="m286 439v-321q0-8-5-13t-13-5h-36q-8 0-13 5t-5 13v321q0 8 5 13t13 5h36q8 0 13-5t5-13z m143 0v-321q0-8-5-13t-13-5h-36q-8 0-13 5t-5 13v321q0 8 5 13t13 5h36q8 0 13-5t5-13z m142 0v-321q0-8-5-13t-12-5h-36q-8 0-13 5t-5 13v321q0 8 5 13t13 5h36q7 0 12-5t5-13z m72-404v529h-500v-529q0-12 4-22t8-15t6-5h464q2 0 6 5t8 15t4 22z m-375 601h250l-27 65q-4 5-9 6h-177q-6-1-10-6z m518-18v-36q0-8-5-13t-13-5h-54v-529q0-46-26-80t-63-34h-464q-37 0-63 33t-27 79v531h-53q-8 0-13 5t-5 13v36q0 8 5 13t13 5h172l39 93q9 21 31 35t44 15h178q22 0 44-15t30-35l39-93h173q8 0 13-5t5-13z" horiz-adv-x="785.7" />

+<glyph glyph-name="left-dir" unicode="&#xe817;" d="m357 600v-500q0-14-10-25t-26-11t-25 11l-250 250q-10 11-10 25t10 25l250 250q11 11 25 11t26-11t10-25z" horiz-adv-x="357.1" />

+<glyph glyph-name="right-dir" unicode="&#xe818;" d="m321 350q0-14-10-25l-250-250q-11-11-25-11t-25 11t-11 25v500q0 15 11 25t25 11t25-11l250-250q10-10 10-25z" horiz-adv-x="357.1" />

+<glyph glyph-name="down-open" unicode="&#xe83b;" d="m899 457q0-29-21-50l-363-363q-21-22-51-22q-30 0-50 22l-363 363q-21 20-21 50q0 30 21 51l41 42q22 20 51 20q29 0 50-20l271-271l271 271q21 20 51 20q29 0 50-20l42-42q21-22 21-51z" horiz-adv-x="928.6" />

+<glyph glyph-name="left-open" unicode="&#xe819;" d="m414-28l-364 364q-20 20-20 50t20 51l364 363q21 20 51 20t50-20l42-42q21-21 21-51t-21-50l-271-271l271-271q21-21 21-51t-21-50l-42-42q-21-20-50-20t-51 20z" horiz-adv-x="642.9" />

+<glyph glyph-name="right-open" unicode="&#xe81a;" d="m613 386q0-29-20-51l-364-363q-21-21-50-21t-51 21l-42 42q-21 21-21 50q0 30 21 51l271 271l-271 270q-21 22-21 51q0 30 21 50l42 42q20 21 51 21t50-21l364-363q20-21 20-50z" horiz-adv-x="642.9" />

+<glyph glyph-name="angle-left" unicode="&#xe820;" d="m350 546q0-7-6-12l-219-220l219-219q6-6 6-13t-6-13l-28-28q-5-5-12-5t-13 5l-260 260q-6 6-6 13t6 13l260 260q5 6 13 6t12-6l28-28q6-5 6-13z" horiz-adv-x="357.1" />

+<glyph glyph-name="angle-right" unicode="&#xe81d;" d="m332 314q0-7-6-13l-260-260q-5-5-12-5t-13 5l-28 28q-6 6-6 13t6 13l219 219l-219 220q-6 5-6 12t6 13l28 28q5 6 13 6t12-6l260-260q6-5 6-13z" horiz-adv-x="357.1" />

+<glyph glyph-name="left-big" unicode="&#xe81f;" d="m857 350v-71q0-30-18-51t-47-21h-393l164-164q21-20 21-50t-21-50l-42-43q-21-20-51-20q-29 0-50 20l-364 364q-20 21-20 50q0 29 20 51l364 363q21 21 50 21q29 0 51-21l42-42q21-21 21-50t-21-51l-164-164h393q29 0 47-20t18-51z" horiz-adv-x="857.1" />

+<glyph glyph-name="right-big" unicode="&#xe81e;" d="m821 314q0-30-20-50l-363-364q-22-20-51-20q-29 0-50 20l-42 42q-22 21-22 51t22 51l163 163h-393q-29 0-47 21t-18 51v71q0 30 18 51t47 20h393l-163 164q-22 21-22 51t22 50l42 42q21 21 50 21q29 0 51-21l363-363q20-20 20-51z" horiz-adv-x="857.1" />

+<glyph glyph-name="magic" unicode="&#xe807;" d="m664 526l164 163l-60 60l-164-164z m249 163q0-15-10-25l-717-718q-10-10-25-10t-25 10l-111 111q-10 10-10 25t10 25l718 718q10 10 25 10t25-10l110-111q10-10 10-25z m-753 106l54-16l-54-17l-17-55l-17 55l-55 17l55 16l17 55z m195-90l109-34l-109-33l-34-109l-33 109l-109 33l109 34l33 109z m519-267l55-17l-55-16l-17-55l-17 55l-54 16l54 17l17 55z m-357 357l54-16l-54-17l-17-55l-17 55l-54 17l54 16l17 55z" horiz-adv-x="928.6" />

+<glyph glyph-name="picture" unicode="&#xe800;" d="m856 518l-100 0l-124 150l-214-150l-180 0q-52 0-90-39t-38-91l0-160l-108 296q-10 38 22 52l680 248q36 10 50-24z m106-90q16 0 27-12t11-28l0-472q0-16-11-28t-27-12l-724 0q-16 0-27 12t-11 28l0 472q0 16 11 28t27 12l724 0z m-56-452l0 162l-72 160l-166-60l-130-132l-138 170l-92-214l0-86l598 0z" horiz-adv-x="1000" />

+<glyph glyph-name="export" unicode="&#xe80b;" d="m750 60l0 56l100 82l0-188q0-20-15-35t-35-15l-750 0q-20 0-35 15t-15 35l0 550q0 22 14 36t36 14l288 0q-32-24-59-49t-39-39l-10-12l-130 0l0-450l650 0z m-82 348q-166 0-242-41t-160-181q0 8 1 22t9 56t22 79t44 83t70 79t107 56t149 23l0 156l332-250l-332-260l0 178z" horiz-adv-x="1000" />

+<glyph glyph-name="cog" unicode="&#xe832;" d="m760 350q0-72 80-122q-12-40-34-82q-70 18-136-44q-54-58-34-136q-40-20-84-36q-46 82-132 82t-132-82q-44 16-84 36q20 80-34 136q-54 54-136 34q-14 26-34 82q82 52 82 132q0 72-82 124q20 56 34 82q74-18 136 44q54 56 34 136q42 22 84 34q46-80 132-80t132 80q42-12 84-34q-20-78 34-136q66-62 136-44q22-42 34-82q-80-50-80-124z m-340-182q76 0 129 53t53 129t-53 130t-129 54t-129-54t-53-130t53-129t129-53z" horiz-adv-x="840" />

+<glyph glyph-name="login" unicode="&#xe833;" d="m800 800q42 0 71-29t29-71l0-700q0-40-29-70t-71-30l-450 0q-40 0-69 30t-29 70l0 100l98 0l0-100l450 0l0 700l-450 0l0-150l-98 0l0 150q0 42 29 71t69 29l450 0z m-350-670l0 120l-450 0l0 150l450 0l0 120l200-194z" horiz-adv-x="900" />

+<glyph glyph-name="logout" unicode="&#xe834;" d="m502 0l0 100l98 0l0-100q0-40-29-70t-71-30l-400 0q-40 0-70 30t-30 70l0 700q0 42 30 71t70 29l400 0q42 0 71-29t29-71l0-150l-98 0l0 150l-402 0l0-700l402 0z m398 326l-198-196l0 120l-450 0l0 150l450 0l0 120z" horiz-adv-x="900" />

+<glyph glyph-name="video" unicode="&#xe805;" d="m214-43v72q0 14-10 25t-25 10h-72q-14 0-25-10t-11-25v-72q0-14 11-25t25-11h72q14 0 25 11t10 25z m0 214v72q0 14-10 25t-25 11h-72q-14 0-25-11t-11-25v-72q0-14 11-25t25-10h72q14 0 25 10t10 25z m0 215v71q0 15-10 25t-25 11h-72q-14 0-25-11t-11-25v-71q0-15 11-25t25-11h72q14 0 25 11t10 25z m572-429v286q0 14-11 25t-25 11h-429q-14 0-25-11t-10-25v-286q0-14 10-25t25-11h429q15 0 25 11t11 25z m-572 643v71q0 15-10 26t-25 10h-72q-14 0-25-10t-11-26v-71q0-15 11-25t25-11h72q14 0 25 11t10 25z m786-643v72q0 14-11 25t-25 10h-71q-15 0-25-10t-11-25v-72q0-14 11-25t25-11h71q15 0 25 11t11 25z m-214 429v285q0 15-11 26t-25 10h-429q-14 0-25-10t-10-26v-285q0-15 10-25t25-11h429q15 0 25 11t11 25z m214-215v72q0 14-11 25t-25 11h-71q-15 0-25-11t-11-25v-72q0-14 11-25t25-10h71q15 0 25 10t11 25z m0 215v71q0 15-11 25t-25 11h-71q-15 0-25-11t-11-25v-71q0-15 11-25t25-11h71q15 0 25 11t11 25z m0 214v71q0 15-11 26t-25 10h-71q-15 0-25-10t-11-26v-71q0-15 11-25t25-11h71q15 0 25 11t11 25z m71 89v-750q0-37-26-63t-63-26h-893q-36 0-63 26t-26 63v750q0 37 26 63t63 27h893q37 0 63-27t26-63z" horiz-adv-x="1071.4" />

+<glyph glyph-name="arrow-combo" unicode="&#xe827;" d="m230 850l230-364l-460 0z m0-1000l-230 366l460 0z" horiz-adv-x="460" />

+<glyph glyph-name="left-open-1" unicode="&#xe82a;" d="m242 626q14 16 39 16t41-16q38-36 0-80l-186-196l186-194q38-44 0-80q-16-16-40-16t-40 16l-226 236q-16 16-16 38q0 24 16 40q206 214 226 236z" horiz-adv-x="341" />

+<glyph glyph-name="right-open-1" unicode="&#xe82b;" d="m98 626l226-236q16-16 16-40q0-22-16-38l-226-236q-16-16-40-16t-40 16q-36 36 0 80l186 194l-186 196q-36 44 0 80q16 16 41 16t39-16z" horiz-adv-x="340" />

+<glyph glyph-name="left-open-mini" unicode="&#xe822;" d="m252 180q26-26 0-48q-26-26-48 0l-192 194q-24 24 0 50l192 194q22 26 48 0q26-22 0-48l-156-172z" horiz-adv-x="265" />

+<glyph glyph-name="right-open-mini" unicode="&#xe823;" d="m13 180l158 170l-158 172q-26 26 0 48q26 26 48 0l192-194q24-26 0-50l-192-194q-22-26-48 0q-26 22 0 48z" horiz-adv-x="265" />

+<glyph glyph-name="left-open-big" unicode="&#xe824;" d="m452-20q26-26 0-48q-26-26-48 0l-392 394q-24 24 0 50l392 394q22 26 48 0q26-22 0-48l-358-372z" horiz-adv-x="465" />

+<glyph glyph-name="right-open-big" unicode="&#xe825;" d="m13-20l358 370l-358 372q-26 26 0 48q26 26 48 0l392-394q24-26 0-50l-392-394q-22-26-48 0q-26 22 0 48z" horiz-adv-x="465" />

+<glyph glyph-name="left" unicode="&#xe836;" d="m378 20l-378 330l378 330l0-190l352 0l0-278l-352 0l0-192z" horiz-adv-x="730" />

+<glyph glyph-name="right" unicode="&#xe826;" d="m350 680l380-330l-380-330l0 192l-350 0l0 278l350 0l0 190z" horiz-adv-x="730" />

+<glyph glyph-name="ccw" unicode="&#xe808;" d="m532 736q170 0 289-120t119-290t-119-290t-289-120q-142 0-252 88l70 74q84-60 182-60q126 0 216 90t90 218t-90 218t-216 90q-124 0-214-87t-92-211l142 0l-184-204l-184 204l124 0q2 166 122 283t286 117z" horiz-adv-x="940" />

+<glyph glyph-name="arrows-ccw" unicode="&#xe806;" d="m186 140l116 116l0-292l-276 16l88 86q-116 122-114 290t120 288q100 100 240 116l4-102q-100-16-172-88q-88-88-90-213t84-217z m332 598l276-16l-88-86q116-122 114-290t-120-288q-96-98-240-118l-2 104q98 16 170 88q88 88 90 213t-84 217l-114-116z" horiz-adv-x="820" />

+<glyph glyph-name="palette" unicode="&#xe829;" d="m857 622q72-48 101-110t20-104t-35-48q-16-4-54 10t-80 10t-80-46q-30-46-21-75t34-65t23-50q-2-26-36-63t-126-74t-216-37q-186 0-291 101t-95 245q8 118 104 235t216 151q290 84 536-80z m-318-466q30 0 52 22t22 54t-22 53t-52 21q-32 0-54-21t-22-53t22-54t54-22z" horiz-adv-x="980" />

+<glyph glyph-name="list-add" unicode="&#xe80c;" d="m350 400q22 0 36-15t14-35t-15-35t-35-15l-300 0q-20 0-35 15t-15 35t14 35t36 15l300 0z m0-200q22 0 36-15t14-35t-15-35t-35-15l-300 0q-20 0-35 15t-15 35t14 35t36 15l300 0z m620 200q30 0 30-50t-30-50l-170 0l0-170q0-30-50-30t-50 30l0 170l-164 0q-30 0-30 50t30 50l164 0l0 170q0 30 50 30t50-30l0-170l170 0z m-620 200q22 0 36-15t14-35t-15-35t-35-15l-300 0q-20 0-35 15t-15 35t14 35t36 15l300 0z" horiz-adv-x="1000" />

+<glyph glyph-name="doc" unicode="&#xe809;" d="m818 595q16-16 16-36l0-521q0-65-46-111t-110-46l-522 0q-65 0-110 46t-46 111l0 625q0 65 46 110t110 46l417 0q22 0 37-15z m-110-36l-135 134l0-56q0-32 23-55t55-23l57 0z m-30-574q21 0 36 16t15 37l0 469l-78 0q-53 0-92 38t-38 92l0 78l-365 0q-21 0-37-15t-15-37l0-625q0-21 15-37t37-16l522 0z" horiz-adv-x="834" />

+<glyph glyph-name="left-open-outline" unicode="&#xe82e;" d="m638 91q0-64-47-111t-110-46q-65 0-110 45l-371 372l371 371q44 44 111 44t111-44q45-45 45-111q0-65-45-110l-150-150l150-150q45-45 45-110z m-490 260l297-298q15-15 37-15t37 15t15 38q0 21-15 36l-224 224l224 223q15 15 15 37q0 22-15 37t-37 15t-37-15z" horiz-adv-x="638" />

+<glyph glyph-name="left-open-2" unicode="&#xe82c;" d="m481 684q32-31 32-74t-32-74l-186-186l186-186q32-31 32-74t-32-74t-73-31t-74 31l-334 334l334 334q30 31 74 31t73-31z" horiz-adv-x="513" />

+<glyph glyph-name="right-open-outline" unicode="&#xe82f;" d="m156-66q-63 0-110 46t-46 111t46 110l150 150l-150 150q-46 46-46 110q0 65 46 111q44 44 110 44t110-44l372-371l-372-372q-45-45-110-45z m0 729q-21 0-37-16t-15-36q0-20 16-37l223-223l-223-224q-16-16-16-36q0-22 16-38q15-15 36-15t37 15l297 298l-297 297q-15 15-37 15z" horiz-adv-x="638" />

+<glyph glyph-name="right-open-2" unicode="&#xe82d;" d="m31 684q30 31 74 31t74-31l335-334l-335-334q-31-31-74-31t-74 31t-31 74t31 74l188 186l-188 186q-31 32-31 74t31 74z" horiz-adv-x="514" />

+<glyph glyph-name="equalizer" unicode="&#xe83a;" d="m576 239l0-112l-55 0l0-167q0-23-17-40t-39-17t-39 17t-17 40l0 167l-56 0l0 112l56 0l0 503q0 24 17 39t38 16q24 0 41-16t16-39l0-503l55 0z m335 335l0-112l-55 0l0-502q0-23-16-40t-41-17q-23 0-39 17t-16 40l0 502l-56 0l0 112l56 0l0 168q0 24 16 39t39 16t41-16t16-39l0-168l55 0z m-670-112l0-111l-55 0l0-391q0-23-16-40t-40-17q-23 0-39 17t-17 40l0 391l-56 0l0 111l56 0l0 280q0 24 16 39t40 16t40-16t16-39l0-280l55 0z" horiz-adv-x="928" />

+<glyph glyph-name="layers-alt" unicode="&#xe804;" d="m18 127l446-111l447 111l0-111l-447-113l-446 113l0 111z m0 224l446-112l447 112l0-112l-447-112l-446 112l0 112z m0 223l446-112l447 112l0-112l-447-111l-446 111l0 112z m0 223l446-112l447 112l0-112l-447-111l-446 111l0 112z" horiz-adv-x="928" />

+<glyph glyph-name="popup" unicode="&#xe828;" d="m700 750q42 0 71-29t29-71l0-400q0-40-29-70t-71-30l-400 0q-40 0-70 30t-30 70l0 402q0 40 29 69t71 29l400 0z m0-500l0 400l-400 0l0-400l400 0z m-600 100l0-300l300 0l0-100l-300 0q-40 0-70 30t-30 70l0 300l100 0z" horiz-adv-x="800" />

+</font>

+</defs>

 </svg>