mirror of
https://github.com/nextcloud/server.git
synced 2026-06-10 17:23:59 -04:00
Merge pull request #51753 from nextcloud/backport/50121/stable31
[stable31] fix(theming): enforce theme also for login
This commit is contained in:
commit
fa2b03d759
2 changed files with 5 additions and 1 deletions
|
|
@ -35,7 +35,9 @@ p($theme->getTitle());
|
|||
<?php emit_script_loading_tags($_); ?>
|
||||
<?php print_unescaped($_['headers']); ?>
|
||||
</head>
|
||||
<body id="<?php p($_['bodyid']);?>">
|
||||
<body id="<?php p($_['bodyid']);?>" <?php foreach ($_['enabledThemes'] as $themeId) {
|
||||
p("data-theme-$themeId ");
|
||||
}?> data-themes="<?php p(join(',', $_['enabledThemes'])) ?>">
|
||||
<?php include 'layout.noscript.warning.php'; ?>
|
||||
<?php include 'layout.initial-state.php'; ?>
|
||||
<div class="wrapper">
|
||||
|
|
|
|||
|
|
@ -151,6 +151,8 @@ class TemplateLayout extends \OC_Template {
|
|||
if ($user) {
|
||||
$userDisplayName = $user->getDisplayName();
|
||||
}
|
||||
$theme = $this->config->getSystemValueString('enforce_theme', '');
|
||||
$this->assign('enabledThemes', $theme === '' ? [] : [$theme]);
|
||||
$this->assign('user_displayname', $userDisplayName);
|
||||
$this->assign('user_uid', \OC_User::getUser());
|
||||
} elseif ($renderAs === TemplateResponse::RENDER_AS_PUBLIC) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue