aboutsummaryrefslogtreecommitdiff
path: root/app/layout/simple.phtml
diff options
context:
space:
mode:
Diffstat (limited to 'app/layout/simple.phtml')
-rw-r--r--app/layout/simple.phtml42
1 files changed, 32 insertions, 10 deletions
diff --git a/app/layout/simple.phtml b/app/layout/simple.phtml
index 065b69fb9..e460e283b 100644
--- a/app/layout/simple.phtml
+++ b/app/layout/simple.phtml
@@ -2,17 +2,27 @@
declare(strict_types=1);
/** @var FreshRSS_View $this */
FreshRSS::preLayout();
+ $class = '';
+ if (_t('gen.dir') === 'rtl') {
+ echo ' dir="rtl"';
+ $class = 'rtl ';
+ }
+ if (FreshRSS_Context::userConf()->darkMode !== 'no') {
+ $class .= 'darkMode_' . FreshRSS_Context::userConf()->darkMode;
+ }
?>
<!DOCTYPE html>
-<html lang="<?= FreshRSS_Context::userConf()->language ?>" xml:lang="<?= FreshRSS_Context::userConf()->language ?>">
+<html lang="<?= FreshRSS_Context::userConf()->language ?>" xml:lang="<?= FreshRSS_Context::userConf()->language ?>" class="<?= $class ?>">
<head>
<meta charset="UTF-8" />
- <meta name="viewport" content="initial-scale=1.0" />
+ <meta name="viewport" content="width=device-width, initial-scale=1.0, viewport-fit=cover" />
+ <?= FreshRSS_View::metaThemeColor() ?>
<?= FreshRSS_View::headStyle() ?>
<script id="jsonVars" type="application/json">
<?php $this->renderHelper('javascript_vars'); ?>
</script>
<?= FreshRSS_View::headScript() ?>
+ <link rel="manifest" href="<?= Minz_Url::display('/themes/manifest.json') ?>" />
<link rel="shortcut icon" id="favicon" type="image/x-icon" sizes="16x16 64x64" href="<?= Minz_Url::display('/favicon.ico') ?>" />
<link rel="icon msapplication-TileImage apple-touch-icon" type="image/png" sizes="256x256" href="<?= Minz_Url::display('/themes/icons/favicon-256.png') ?>" />
<link rel="apple-touch-icon" href="<?= Minz_Url::display('/themes/icons/apple-touch-icon.png') ?>" />
@@ -20,9 +30,15 @@
<meta name="apple-mobile-web-app-status-bar-style" content="black" />
<meta name="apple-mobile-web-app-title" content="<?= FreshRSS_Context::systemConf()->title ?>">
<meta name="msapplication-TileColor" content="#FFF" />
+ <meta name="theme-color" content="#FFF" />
+<?php if (!FreshRSS_Context::systemConf()->allow_referrer) { ?>
<meta name="referrer" content="never" />
- <meta name="robots" content="noindex,nofollow" />
+<?php } ?>
<?= FreshRSS_View::headTitle() ?>
+ <?php if ($this->rss_url != ''): ?>
+ <link rel="alternate" type="application/rss+xml" title="<?= $this->rss_title ?>" href="<?= $this->rss_url ?>" />
+ <?php endif; ?>
+ <meta name="robots" content="noindex,nofollow" />
</head>
<body>
@@ -30,7 +46,7 @@
<div class="app-layout app-layout-simple">
<div class="header">
<div class="item title">
- <a href="<?= _url('index', 'index') ?>">
+ <a href="<?= Minz_Url::display(['c' => 'index', 'a' => 'index'], 'html', 'root') ?>">
<?php if (FreshRSS_Context::systemConf()->logo_html == '') { ?>
<img class="logo" src="<?= _i('FreshRSS-logo', FreshRSS_Themes::ICON_URL) ?>" alt="FreshRSS" loading="lazy" />
<?php
@@ -43,14 +59,20 @@
<div class="item"></div>
- <div class="item">
- <?php if (FreshRSS_Auth::accessNeedsAction()) { ?>
- <a class="signout" href="<?= _url('auth', 'logout') ?>">
- <?= _i('logout') . _t('gen.auth.logout') ?>
+ <?php if (FreshRSS_Auth::accessNeedsAction()): ?>
+ <div class="item configure">
+ <?php if (FreshRSS_Auth::hasAccess()): ?>
+ <a class="signout" href="<?= Minz_Url::display(['c' => 'auth', 'a' => 'logout'], 'html', 'root') ?>">
+ <?= _i('logout') ?><?= _t('gen.auth.logout') ?>
(<?= htmlspecialchars(Minz_User::name() ?? '', ENT_NOQUOTES, 'UTF-8') ?>)
</a>
- <?php } ?>
- </div>
+ <?php else: ?>
+ <a class="signin" href="<?= Minz_Url::display(['c' => 'auth', 'a' => 'login'], 'html', 'root') ?>">
+ <?= _i('login') ?><?= _t('gen.auth.login') ?>
+ </a>
+ <?php endif; ?>
+ </div>
+ <?php endif; ?>
</div>
<?php $this->render(); ?>