framework/views/app.blade.php

54 lines
1.5 KiB
PHP
Raw Normal View History

<!doctype html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>{{ $title }}</title>
<meta name="description" content="{{ $forum->attributes->description }}">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, minimum-scale=1">
<meta name="theme-color" content="{{ $forum->attributes->themePrimaryColor }}">
@foreach ($styles as $file)
2015-08-13 09:14:16 +08:00
<link rel="stylesheet" href="{{ $forum->attributes->baseUrl . str_replace(public_path(), '', $file) }}">
@endforeach
{!! $head !!}
</head>
<body>
{!! $layout !!}
<div id="modal"></div>
<div id="alerts"></div>
@if (! $noJs)
@foreach ($scripts as $file)
2015-08-13 09:14:16 +08:00
<script src="{{ $forum->attributes->baseUrl . str_replace(public_path(), '', $file) }}"></script>
@endforeach
<script>
2015-09-23 09:21:49 +08:00
@if (! $forum->attributes->debug)
try {
2015-09-23 09:21:49 +08:00
@endif
var app = System.get('flarum/app').default;
babelHelpers._extends(app, {!! json_encode($app) !!});
@foreach ($bootstrappers as $bootstrapper)
System.get('{{ $bootstrapper }}');
@endforeach
app.boot();
2015-09-23 09:21:49 +08:00
@if (! $forum->attributes->debug)
} catch (e) {
var nojs = window.location.indexOf('?') === -1 ? '?nojs=1' : ':nojs=1';
window.location = window.location + nojs;
}
2015-09-23 09:21:49 +08:00
@endif
</script>
@endif
{!! $foot !!}
</body>
</html>