nx: base layout
parent
3c1d6cffdd
commit
9903885862
|
@ -55,7 +55,6 @@ class PageController extends Controller
|
||||||
|
|
||||||
// Scripts
|
// Scripts
|
||||||
OCPUtil::addScript($this->appName, 'memories-main');
|
OCPUtil::addScript($this->appName, 'memories-main');
|
||||||
$this->eventDispatcher->dispatchTyped(new LoadSidebar());
|
|
||||||
|
|
||||||
// Extra translations
|
// Extra translations
|
||||||
if (Util::recognizeIsEnabled()) {
|
if (Util::recognizeIsEnabled()) {
|
||||||
|
@ -67,6 +66,14 @@ class PageController extends Controller
|
||||||
$response->setContentSecurityPolicy(self::getCSP());
|
$response->setContentSecurityPolicy(self::getCSP());
|
||||||
$response->cacheFor(0);
|
$response->cacheFor(0);
|
||||||
|
|
||||||
|
// Check if requested from native app
|
||||||
|
$userAgent = $this->request->getHeader('User-Agent');
|
||||||
|
if (strpos($userAgent, 'memories-native') !== false) {
|
||||||
|
$response->renderAs(TemplateResponse::RENDER_AS_BASE);
|
||||||
|
} else {
|
||||||
|
$this->eventDispatcher->dispatchTyped(new LoadSidebar());
|
||||||
|
}
|
||||||
|
|
||||||
return $response;
|
return $response;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -25,6 +25,12 @@ body {
|
||||||
border-top-left-radius: var(--body-container-radius);
|
border-top-left-radius: var(--body-container-radius);
|
||||||
border-bottom-left-radius: var(--body-container-radius);
|
border-bottom-left-radius: var(--body-container-radius);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Nothing on top
|
||||||
|
body.layout-base & {
|
||||||
|
margin-top: 0 !important;
|
||||||
|
height: 100vh !important;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Top bar is above everything else on mobile
|
// Top bar is above everything else on mobile
|
||||||
|
|
Loading…
Reference in New Issue