diff --git a/plugins/Cover/Cover.php b/plugins/Cover/Cover.php index b18c1ee152..d923140b19 100644 --- a/plugins/Cover/Cover.php +++ b/plugins/Cover/Cover.php @@ -37,8 +37,7 @@ class Cover extends Module */ public function onAddRoute(RouteLoader $r): bool { - $r->connect('settings_cover', 'settings/cover', [Controller\Cover::class, 'coversettings']); - + $r->connect('settings_profile_cover', 'settings/cover', [Controller\Cover::class, 'coversettings']); $r->connect('cover', '/cover', [Controller\Cover::class, 'cover']); return Event::next; } @@ -53,7 +52,7 @@ class Cover extends Module public function onStartTwigPopulateVars(array &$vars): bool { $vars['profile_tabs'] = [['title' => 'Cover', - 'href' => 'settings_cover', + 'route' => 'settings_profile_cover', ]]; if (Common::user() != null) { @@ -80,7 +79,7 @@ class Cover extends Module */ public function onStartShowStyles(array &$styles): bool { - //$styles[] = 'voer/poll.css'; + $styles[] = 'cover/cover.css'; return Event::next; } } diff --git a/public/assets/css/cover/cover.css b/public/assets/css/cover/cover.css new file mode 100644 index 0000000000..97cb9b1d8b --- /dev/null +++ b/public/assets/css/cover/cover.css @@ -0,0 +1,26 @@ + +.cover{ + width: 100%; + height: 100%; + position: absolute; + top:0; + left: 0; + z-index: -1; +} + +.cover-img{ + width: 100%; + height: 100%; + object-fit: cover; +} + +.no-cover{ + width: 100%; + height: 100%; + background-color: var(--bg2); +} + +.profile{ + position:relative; + background-color: transparent !important; +} diff --git a/public/assets/css/left/left.css b/public/assets/css/left/left.css index fc6139ca22..9d9b6bc8e1 100644 --- a/public/assets/css/left/left.css +++ b/public/assets/css/left/left.css @@ -77,35 +77,6 @@ margin-bottom: var(--unit-size); vertical-align: middle; } -/*teisitn*/ -.cover{ - width: 100%; - height: 100%; - position: absolute; - top:0; - left: 0; - z-index: -1; -} - -.cover-img{ - width: 100%; - height: 100%; - object-fit: cover; -} - -.no-cover{ - width: 100%; - height: 100%; - background-color: var(--bg2); -} - -.profile{ - position:relative; - background-color: transparent !important; -} - - -/**/ .icon-avatar { order: 1; diff --git a/templates/settings/base.html.twig b/templates/settings/base.html.twig index b154e21253..75e23b2052 100644 --- a/templates/settings/base.html.twig +++ b/templates/settings/base.html.twig @@ -28,7 +28,7 @@