Skip to content

Commit

Permalink
WIP Security page
Browse files Browse the repository at this point in the history
  • Loading branch information
spaze committed Nov 23, 2024
1 parent 2e3aae2 commit 1b725c9
Show file tree
Hide file tree
Showing 4 changed files with 37 additions and 2 deletions.
4 changes: 4 additions & 0 deletions app/config/routes.neon
Original file line number Diff line number Diff line change
Expand Up @@ -104,3 +104,7 @@ parameters:
mask:
cs_CZ: cookies
en_US: cookies
Security:
mask:
cs_CZ: bezpecnost
en_US: security
24 changes: 24 additions & 0 deletions app/src/Www/Presenters/SecurityPresenter.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
<?php
declare(strict_types = 1);

namespace MichalSpacekCz\Www\Presenters;

use Contributte\Translation\Translator;

class SecurityPresenter extends BasePresenter
{

public function __construct(
private readonly Translator $translator,
) {
parent::__construct();
}


public function renderDefault(): void
{
$this->template->pageTitle = $this->translator->translate('messages.title.who');
$this->template->pageHeader = $this->translator->translate('messages.header.who');
}

}
4 changes: 2 additions & 2 deletions app/src/Www/Presenters/templates/@layout.latte
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@
<title>{if isset($pageTitle)}{$pageTitle} | {/if}Michal Špaček</title>
{control criticalCss}
{if $darkMode === null}
{styleSheet screen-main + '@media (prefers-color-scheme: dark) {' + screen-main-dark + '}'}
{styleSheet screen-main + '@media (prefers-color-scheme: dark) {' + screen-main-dark + '}' + rating}
{elseif $darkMode}
{styleSheet screen-main + screen-main-dark}
{styleSheet screen-main + screen-main-dark + rating}
{else}
{styleSheet screen-main}
{/if}
Expand Down
7 changes: 7 additions & 0 deletions app/src/Www/Presenters/templates/Security/default.latte
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{define #menu}
&raquo; <a n:href="Homepage:">Michal Špaček</a>
{/define}

{define #content}
<div class="rating"><strong class="left rating-a">A<sup>+</sup></strong> ayyyy</div>
{/define}

0 comments on commit 1b725c9

Please sign in to comment.