mirror of
https://github.com/BookStackApp/BookStack.git
synced 2025-06-06 02:24:33 +08:00
Added page HTML export
This commit is contained in:
96
resources/assets/sass/_fonts.scss
Normal file
96
resources/assets/sass/_fonts.scss
Normal file
@ -0,0 +1,96 @@
|
||||
/* Generated by Font Squirrel (http://www.fontsquirrel.com) on December 30, 2015 */
|
||||
@font-face {
|
||||
font-family: 'Roboto';
|
||||
src: url('/fonts/roboto-bold-webfont.eot');
|
||||
src: url('/fonts/roboto-bold-webfont.eot?#iefix') format('embedded-opentype'),
|
||||
url('/fonts/roboto-bold-webfont.woff2') format('woff2'),
|
||||
url('/fonts/roboto-bold-webfont.woff') format('woff'),
|
||||
url('/fonts/roboto-bold-webfont.ttf') format('truetype'),
|
||||
url('/fonts/roboto-bold-webfont.svg#robotobold') format('svg');
|
||||
font-weight: bold;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Roboto';
|
||||
src: url('/fonts/roboto-bolditalic-webfont.eot');
|
||||
src: url('/fonts/roboto-bolditalic-webfont.eot?#iefix') format('embedded-opentype'),
|
||||
url('/fonts/roboto-bolditalic-webfont.woff2') format('woff2'),
|
||||
url('/fonts/roboto-bolditalic-webfont.woff') format('woff'),
|
||||
url('/fonts/roboto-bolditalic-webfont.ttf') format('truetype'),
|
||||
url('/fonts/roboto-bolditalic-webfont.svg#robotobold_italic') format('svg');
|
||||
font-weight: bold;
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Roboto';
|
||||
src: url('/fonts/roboto-italic-webfont.eot');
|
||||
src: url('/fonts/roboto-italic-webfont.eot?#iefix') format('embedded-opentype'),
|
||||
url('/fonts/roboto-italic-webfont.woff2') format('woff2'),
|
||||
url('/fonts/roboto-italic-webfont.woff') format('woff'),
|
||||
url('/fonts/roboto-italic-webfont.ttf') format('truetype'),
|
||||
url('/fonts/roboto-italic-webfont.svg#robotoitalic') format('svg');
|
||||
font-weight: normal;
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Roboto';
|
||||
src: url('/fonts/roboto-light-webfont.eot');
|
||||
src: url('/fonts/roboto-light-webfont.eot?#iefix') format('embedded-opentype'),
|
||||
url('/fonts/roboto-light-webfont.woff2') format('woff2'),
|
||||
url('/fonts/roboto-light-webfont.woff') format('woff'),
|
||||
url('/fonts/roboto-light-webfont.ttf') format('truetype'),
|
||||
url('/fonts/roboto-light-webfont.svg#robotolight') format('svg');
|
||||
font-weight: 300;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Roboto';
|
||||
src: url('/fonts/roboto-lightitalic-webfont.eot');
|
||||
src: url('/fonts/roboto-lightitalic-webfont.eot?#iefix') format('embedded-opentype'),
|
||||
url('/fonts/roboto-lightitalic-webfont.woff2') format('woff2'),
|
||||
url('/fonts/roboto-lightitalic-webfont.woff') format('woff'),
|
||||
url('/fonts/roboto-lightitalic-webfont.ttf') format('truetype'),
|
||||
url('/fonts/roboto-lightitalic-webfont.svg#robotolight_italic') format('svg');
|
||||
font-weight: 300;
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Roboto';
|
||||
src: url('/fonts/roboto-medium-webfont.eot');
|
||||
src: url('/fonts/roboto-medium-webfont.eot?#iefix') format('embedded-opentype'),
|
||||
url('/fonts/roboto-medium-webfont.woff2') format('woff2'),
|
||||
url('/fonts/roboto-medium-webfont.woff') format('woff'),
|
||||
url('/fonts/roboto-medium-webfont.ttf') format('truetype'),
|
||||
url('/fonts/roboto-medium-webfont.svg#robotomedium') format('svg');
|
||||
font-weight: 500;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Roboto';
|
||||
src: url('/fonts/roboto-mediumitalic-webfont.eot');
|
||||
src: url('/fonts/roboto-mediumitalic-webfont.eot?#iefix') format('embedded-opentype'),
|
||||
url('/fonts/roboto-mediumitalic-webfont.woff2') format('woff2'),
|
||||
url('/fonts/roboto-mediumitalic-webfont.woff') format('woff'),
|
||||
url('/fonts/roboto-mediumitalic-webfont.ttf') format('truetype'),
|
||||
url('/fonts/roboto-mediumitalic-webfont.svg#robotomedium_italic') format('svg');
|
||||
font-weight: 500;
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Roboto';
|
||||
src: url('/fonts/roboto-regular-webfont.eot');
|
||||
src: url('/fonts/roboto-regular-webfont.eot?#iefix') format('embedded-opentype'),
|
||||
url('/fonts/roboto-regular-webfont.woff2') format('woff2'),
|
||||
url('/fonts/roboto-regular-webfont.woff') format('woff'),
|
||||
url('/fonts/roboto-regular-webfont.ttf') format('truetype'),
|
||||
url('/fonts/roboto-regular-webfont.svg#robotoregular') format('svg');
|
||||
font-weight: normal;
|
||||
font-style: normal;
|
||||
}
|
@ -187,7 +187,7 @@ form.search-box {
|
||||
}
|
||||
|
||||
.faded {
|
||||
a, button, span {
|
||||
a, button, span, span > div {
|
||||
color: #666;
|
||||
}
|
||||
.text-button {
|
||||
|
@ -52,101 +52,3 @@ $text-light: #EEE;
|
||||
$bs-light: 0 0 4px 1px #CCC;
|
||||
$bs-med: 0 1px 3px 1px rgba(76, 76, 76, 0.26);
|
||||
$bs-hover: 0 2px 2px 1px rgba(0,0,0,.13);
|
||||
|
||||
|
||||
/* Generated by Font Squirrel (http://www.fontsquirrel.com) on December 30, 2015 */
|
||||
@font-face {
|
||||
font-family: 'Roboto';
|
||||
src: url('/fonts/roboto-bold-webfont.eot');
|
||||
src: url('/fonts/roboto-bold-webfont.eot?#iefix') format('embedded-opentype'),
|
||||
url('/fonts/roboto-bold-webfont.woff2') format('woff2'),
|
||||
url('/fonts/roboto-bold-webfont.woff') format('woff'),
|
||||
url('/fonts/roboto-bold-webfont.ttf') format('truetype'),
|
||||
url('/fonts/roboto-bold-webfont.svg#robotobold') format('svg');
|
||||
font-weight: bold;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Roboto';
|
||||
src: url('/fonts/roboto-bolditalic-webfont.eot');
|
||||
src: url('/fonts/roboto-bolditalic-webfont.eot?#iefix') format('embedded-opentype'),
|
||||
url('/fonts/roboto-bolditalic-webfont.woff2') format('woff2'),
|
||||
url('/fonts/roboto-bolditalic-webfont.woff') format('woff'),
|
||||
url('/fonts/roboto-bolditalic-webfont.ttf') format('truetype'),
|
||||
url('/fonts/roboto-bolditalic-webfont.svg#robotobold_italic') format('svg');
|
||||
font-weight: bold;
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Roboto';
|
||||
src: url('/fonts/roboto-italic-webfont.eot');
|
||||
src: url('/fonts/roboto-italic-webfont.eot?#iefix') format('embedded-opentype'),
|
||||
url('/fonts/roboto-italic-webfont.woff2') format('woff2'),
|
||||
url('/fonts/roboto-italic-webfont.woff') format('woff'),
|
||||
url('/fonts/roboto-italic-webfont.ttf') format('truetype'),
|
||||
url('/fonts/roboto-italic-webfont.svg#robotoitalic') format('svg');
|
||||
font-weight: normal;
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Roboto';
|
||||
src: url('/fonts/roboto-light-webfont.eot');
|
||||
src: url('/fonts/roboto-light-webfont.eot?#iefix') format('embedded-opentype'),
|
||||
url('/fonts/roboto-light-webfont.woff2') format('woff2'),
|
||||
url('/fonts/roboto-light-webfont.woff') format('woff'),
|
||||
url('/fonts/roboto-light-webfont.ttf') format('truetype'),
|
||||
url('/fonts/roboto-light-webfont.svg#robotolight') format('svg');
|
||||
font-weight: 300;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Roboto';
|
||||
src: url('/fonts/roboto-lightitalic-webfont.eot');
|
||||
src: url('/fonts/roboto-lightitalic-webfont.eot?#iefix') format('embedded-opentype'),
|
||||
url('/fonts/roboto-lightitalic-webfont.woff2') format('woff2'),
|
||||
url('/fonts/roboto-lightitalic-webfont.woff') format('woff'),
|
||||
url('/fonts/roboto-lightitalic-webfont.ttf') format('truetype'),
|
||||
url('/fonts/roboto-lightitalic-webfont.svg#robotolight_italic') format('svg');
|
||||
font-weight: 300;
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Roboto';
|
||||
src: url('/fonts/roboto-medium-webfont.eot');
|
||||
src: url('/fonts/roboto-medium-webfont.eot?#iefix') format('embedded-opentype'),
|
||||
url('/fonts/roboto-medium-webfont.woff2') format('woff2'),
|
||||
url('/fonts/roboto-medium-webfont.woff') format('woff'),
|
||||
url('/fonts/roboto-medium-webfont.ttf') format('truetype'),
|
||||
url('/fonts/roboto-medium-webfont.svg#robotomedium') format('svg');
|
||||
font-weight: 500;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Roboto';
|
||||
src: url('/fonts/roboto-mediumitalic-webfont.eot');
|
||||
src: url('/fonts/roboto-mediumitalic-webfont.eot?#iefix') format('embedded-opentype'),
|
||||
url('/fonts/roboto-mediumitalic-webfont.woff2') format('woff2'),
|
||||
url('/fonts/roboto-mediumitalic-webfont.woff') format('woff'),
|
||||
url('/fonts/roboto-mediumitalic-webfont.ttf') format('truetype'),
|
||||
url('/fonts/roboto-mediumitalic-webfont.svg#robotomedium_italic') format('svg');
|
||||
font-weight: 500;
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Roboto';
|
||||
src: url('/fonts/roboto-regular-webfont.eot');
|
||||
src: url('/fonts/roboto-regular-webfont.eot?#iefix') format('embedded-opentype'),
|
||||
url('/fonts/roboto-regular-webfont.woff2') format('woff2'),
|
||||
url('/fonts/roboto-regular-webfont.woff') format('woff'),
|
||||
url('/fonts/roboto-regular-webfont.ttf') format('truetype'),
|
||||
url('/fonts/roboto-regular-webfont.svg#robotoregular') format('svg');
|
||||
font-weight: normal;
|
||||
font-style: normal;
|
||||
}
|
||||
|
12
resources/assets/sass/export-styles.scss
Normal file
12
resources/assets/sass/export-styles.scss
Normal file
@ -0,0 +1,12 @@
|
||||
@import "reset";
|
||||
@import "variables";
|
||||
@import "mixins";
|
||||
@import "html";
|
||||
@import "text";
|
||||
@import "grid";
|
||||
@import "blocks";
|
||||
@import "forms";
|
||||
@import "tables";
|
||||
@import "header";
|
||||
@import "lists";
|
||||
@import "pages";
|
@ -1,5 +1,6 @@
|
||||
@import "reset";
|
||||
@import "variables";
|
||||
@import "fonts";
|
||||
@import "mixins";
|
||||
@import "html";
|
||||
@import "text";
|
||||
|
32
resources/views/pages/pdf.blade.php
Normal file
32
resources/views/pages/pdf.blade.php
Normal file
@ -0,0 +1,32 @@
|
||||
<!doctype html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>{{ $page->name }}</title>
|
||||
|
||||
<style>
|
||||
{!! $css !!}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="container" id="page-show" ng-non-bindable>
|
||||
<div class="row">
|
||||
<div class="col-md-8 col-md-offset-2">
|
||||
<div class="page-content">
|
||||
|
||||
@include('pages/page-display')
|
||||
|
||||
<hr>
|
||||
|
||||
<p class="text-muted small">
|
||||
Created {{$page->created_at->diffForHumans()}} @if($page->createdBy) by {{$page->createdBy->name}} @endif
|
||||
<br>
|
||||
Last Updated {{$page->updated_at->diffForHumans()}} @if($page->updatedBy) by {{$page->updatedBy->name}} @endif
|
||||
</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
@ -19,6 +19,12 @@
|
||||
</div>
|
||||
<div class="col-sm-6 faded">
|
||||
<div class="action-buttons">
|
||||
<span dropdown class="dropdown-container">
|
||||
<div dropdown-toggle class="text-button text-primary"><i class="zmdi zmdi-open-in-new"></i>Export Page</div>
|
||||
<ul>
|
||||
<li><a href="{{$page->getUrl() . '/export/html'}}" target="_blank">Contained HTML File</a></li>
|
||||
</ul>
|
||||
</span>
|
||||
@if($currentUser->can('page-update'))
|
||||
<a href="{{$page->getUrl() . '/revisions'}}" class="text-primary text-button"><i class="zmdi zmdi-replay"></i>Revisions</a>
|
||||
<a href="{{$page->getUrl() . '/edit'}}" class="text-primary text-button" ><i class="zmdi zmdi-edit"></i>Edit</a>
|
||||
|
Reference in New Issue
Block a user