mirror of
https://github.com/BookStackApp/BookStack.git
synced 2024-08-26 04:05:57 +00:00
Actioned some todo items, Cleaned old grid css
This commit is contained in:
parent
d9cde4123d
commit
0a06e2bce3
@ -59,11 +59,11 @@ class ViewService
|
|||||||
* @param string $action - used for permission checking
|
* @param string $action - used for permission checking
|
||||||
* @return Collection
|
* @return Collection
|
||||||
*/
|
*/
|
||||||
public function getPopular(int $count = 10, int $page = 0, $filterModels = null, $action = 'view')
|
public function getPopular(int $count = 10, int $page = 0, $filterModels = null, string $action = 'view')
|
||||||
{
|
{
|
||||||
// TODO - Standardise input filter
|
|
||||||
$skipCount = $count * $page;
|
$skipCount = $count * $page;
|
||||||
$query = $this->permissionService->filterRestrictedEntityRelations($this->view, 'views', 'viewable_id', 'viewable_type', $action)
|
$query = $this->permissionService
|
||||||
|
->filterRestrictedEntityRelations($this->view, 'views', 'viewable_id', 'viewable_type', $action)
|
||||||
->select('*', 'viewable_id', 'viewable_type', \DB::raw('SUM(views) as view_count'))
|
->select('*', 'viewable_id', 'viewable_type', \DB::raw('SUM(views) as view_count'))
|
||||||
->groupBy('viewable_id', 'viewable_type')
|
->groupBy('viewable_id', 'viewable_type')
|
||||||
->orderBy('view_count', 'desc');
|
->orderBy('view_count', 'desc');
|
||||||
|
@ -4,7 +4,6 @@ use Activity;
|
|||||||
use BookStack\Auth\UserRepo;
|
use BookStack\Auth\UserRepo;
|
||||||
use BookStack\Entities\Bookshelf;
|
use BookStack\Entities\Bookshelf;
|
||||||
use BookStack\Entities\Repos\EntityRepo;
|
use BookStack\Entities\Repos\EntityRepo;
|
||||||
use BookStack\Entities\ExportService;
|
|
||||||
use Illuminate\Http\Request;
|
use Illuminate\Http\Request;
|
||||||
use Illuminate\Http\Response;
|
use Illuminate\Http\Response;
|
||||||
use Views;
|
use Views;
|
||||||
@ -14,19 +13,16 @@ class BookshelfController extends Controller
|
|||||||
|
|
||||||
protected $entityRepo;
|
protected $entityRepo;
|
||||||
protected $userRepo;
|
protected $userRepo;
|
||||||
protected $exportService;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* BookController constructor.
|
* BookController constructor.
|
||||||
* @param \BookStack\Entities\Repos\EntityRepo $entityRepo
|
* @param EntityRepo $entityRepo
|
||||||
* @param UserRepo $userRepo
|
* @param UserRepo $userRepo
|
||||||
* @param \BookStack\Entities\ExportService $exportService
|
|
||||||
*/
|
*/
|
||||||
public function __construct(EntityRepo $entityRepo, UserRepo $userRepo, ExportService $exportService)
|
public function __construct(EntityRepo $entityRepo, UserRepo $userRepo)
|
||||||
{
|
{
|
||||||
$this->entityRepo = $entityRepo;
|
$this->entityRepo = $entityRepo;
|
||||||
$this->userRepo = $userRepo;
|
$this->userRepo = $userRepo;
|
||||||
$this->exportService = $exportService;
|
|
||||||
parent::__construct();
|
parent::__construct();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,121 +1,8 @@
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
* This file container all block styling including margins, paddings & borders.
|
* This file contains styling for custom block formats.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Padding
|
|
||||||
* TODO - Remove these older styles
|
|
||||||
*/
|
|
||||||
.nopadding {
|
|
||||||
padding: 0;
|
|
||||||
}
|
|
||||||
.padded {
|
|
||||||
padding: $-l;
|
|
||||||
&.large {
|
|
||||||
padding: $-xl;
|
|
||||||
}
|
|
||||||
>h1, >h2, >h3, >h4 {
|
|
||||||
&:first-child {
|
|
||||||
margin-top: 0.1em;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
.padded-vertical, .padded-top {
|
|
||||||
padding-top: $-m;
|
|
||||||
&.large {
|
|
||||||
padding-top: $-xl;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.padded-vertical, .padded-bottom {
|
|
||||||
padding-bottom: $-m;
|
|
||||||
&.large {
|
|
||||||
padding-bottom: $-xl;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
.padded-horizontal, .padded-left {
|
|
||||||
padding-left: $-m;
|
|
||||||
&.large {
|
|
||||||
padding-left: $-xl;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
.padded-horizontal, .padded-right {
|
|
||||||
padding-right: $-m;
|
|
||||||
&.large {
|
|
||||||
padding-right: $-xl;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Margins
|
|
||||||
* TODO - Remove these older styles
|
|
||||||
*/
|
|
||||||
.margins {
|
|
||||||
margin: $-l;
|
|
||||||
&.large {
|
|
||||||
margin: $-xl;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
.margins-vertical, .margin-top {
|
|
||||||
margin-top: $-m;
|
|
||||||
&.large {
|
|
||||||
margin-top: $-xl;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
.margins-vertical, .margin-bottom {
|
|
||||||
margin-bottom: $-m;
|
|
||||||
&.large {
|
|
||||||
margin-bottom: $-xl;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
.margins-horizontal, .margin-left {
|
|
||||||
margin-left: $-m;
|
|
||||||
&.large {
|
|
||||||
margin-left: $-xl;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
.margins-horizontal, .margin-right {
|
|
||||||
margin-right: $-m;
|
|
||||||
&.large {
|
|
||||||
margin-right: $-xl;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@mixin spacing($prop, $propLetter) {
|
|
||||||
@each $sizeLetter, $size in $spacing {
|
|
||||||
.#{$propLetter}-#{$sizeLetter} {
|
|
||||||
#{$prop}: $size !important;
|
|
||||||
}
|
|
||||||
.#{$propLetter}x-#{$sizeLetter} {
|
|
||||||
#{$prop}-left: $size !important;
|
|
||||||
#{$prop}-right: $size !important;
|
|
||||||
}
|
|
||||||
.#{$propLetter}y-#{$sizeLetter} {
|
|
||||||
#{$prop}-top: $size !important;
|
|
||||||
#{$prop}-bottom: $size !important;
|
|
||||||
}
|
|
||||||
.#{$propLetter}t-#{$sizeLetter} {
|
|
||||||
#{$prop}-top: $size !important;
|
|
||||||
}
|
|
||||||
.#{$propLetter}r-#{$sizeLetter} {
|
|
||||||
#{$prop}-right: $size !important;
|
|
||||||
}
|
|
||||||
.#{$propLetter}b-#{$sizeLetter} {
|
|
||||||
#{$prop}-bottom: $size !important;
|
|
||||||
}
|
|
||||||
.#{$propLetter}l-#{$sizeLetter} {
|
|
||||||
#{$prop}-left: $size !important;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
@include spacing('margin', 'm')
|
|
||||||
@include spacing('padding', 'p')
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Callouts
|
* Callouts
|
||||||
*/
|
*/
|
||||||
@ -238,9 +125,6 @@
|
|||||||
margin: $-s 0;
|
margin: $-s 0;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
> div.padded {
|
|
||||||
padding: $-s 0 !important;
|
|
||||||
}
|
|
||||||
.handle {
|
.handle {
|
||||||
background-color: #EEE;
|
background-color: #EEE;
|
||||||
left: 0;
|
left: 0;
|
||||||
@ -289,4 +173,74 @@
|
|||||||
|
|
||||||
.tag-list div:last-child .tag-item {
|
.tag-list div:last-child .tag-item {
|
||||||
margin-bottom: 0;
|
margin-bottom: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.grid-card {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
border: 1px solid #ddd;
|
||||||
|
margin-bottom: $-l;
|
||||||
|
border-radius: 4px;
|
||||||
|
overflow: hidden;
|
||||||
|
min-width: 100px;
|
||||||
|
color: $text-dark;
|
||||||
|
transition: border-color ease-in-out 120ms, box-shadow ease-in-out 120ms;
|
||||||
|
&:hover {
|
||||||
|
color: $text-dark;
|
||||||
|
text-decoration: none;
|
||||||
|
box-shadow: $bs-card;
|
||||||
|
}
|
||||||
|
h2 {
|
||||||
|
width: 100%;
|
||||||
|
font-size: 1.5em;
|
||||||
|
margin: 0 0 10px;
|
||||||
|
}
|
||||||
|
p {
|
||||||
|
font-size: .7rem;
|
||||||
|
margin: 0;
|
||||||
|
line-height: 1.6em;
|
||||||
|
}
|
||||||
|
.grid-card-content {
|
||||||
|
flex: 1;
|
||||||
|
border-top: 0;
|
||||||
|
border-bottom-width: 2px;
|
||||||
|
}
|
||||||
|
.grid-card-content, .grid-card-footer {
|
||||||
|
padding: $-l;
|
||||||
|
}
|
||||||
|
.grid-card-content + .grid-card-footer {
|
||||||
|
padding-top: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.bookshelf-grid-item .grid-card-content h2 a {
|
||||||
|
color: $color-bookshelf;
|
||||||
|
fill: $color-bookshelf;
|
||||||
|
}
|
||||||
|
|
||||||
|
.book-grid-item .grid-card-footer {
|
||||||
|
p.small {
|
||||||
|
font-size: .8em;
|
||||||
|
margin: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.content-wrap.card {
|
||||||
|
padding: $-l $-xxl;
|
||||||
|
margin-left: auto;
|
||||||
|
margin-right: auto;
|
||||||
|
margin-bottom: $-xl;
|
||||||
|
overflow: auto;
|
||||||
|
min-height: 60vh;
|
||||||
|
&.auto-height {
|
||||||
|
min-height: 0;
|
||||||
|
}
|
||||||
|
&.fill-width {
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
@include smaller-than($m) {
|
||||||
|
.content-wrap.card {
|
||||||
|
padding: $-m $-l;
|
||||||
|
}
|
||||||
}
|
}
|
@ -142,6 +142,9 @@ body.flexbox-support #entity-selector-wrap .popup-body .form-group {
|
|||||||
#entity-selector-wrap .popup-body .form-group {
|
#entity-selector-wrap .popup-body .form-group {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
}
|
}
|
||||||
|
.popup-body .entity-selector-container {
|
||||||
|
flex: 1;
|
||||||
|
}
|
||||||
|
|
||||||
.image-manager-body {
|
.image-manager-body {
|
||||||
min-height: 70vh;
|
min-height: 70vh;
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -6,6 +6,12 @@ header .grid {
|
|||||||
grid-template-columns: auto min-content auto;
|
grid-template-columns: auto min-content auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@include smaller-than($l) {
|
||||||
|
header .grid {
|
||||||
|
grid-template-columns: 1fr;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
header {
|
header {
|
||||||
position: relative;
|
position: relative;
|
||||||
display: block;
|
display: block;
|
||||||
@ -336,9 +342,6 @@ header .search-box {
|
|||||||
.action-buttons .dropdown-container:last-child a {
|
.action-buttons .dropdown-container:last-child a {
|
||||||
padding-left: $-xs;
|
padding-left: $-xs;
|
||||||
}
|
}
|
||||||
.toolbar .col-xs-1:first-child {
|
|
||||||
padding-right: 0;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.nav-tabs {
|
.nav-tabs {
|
||||||
|
286
resources/assets/sass/_layout.scss
Normal file
286
resources/assets/sass/_layout.scss
Normal file
@ -0,0 +1,286 @@
|
|||||||
|
|
||||||
|
/**
|
||||||
|
* Generic content container
|
||||||
|
*/
|
||||||
|
.container {
|
||||||
|
max-width: $xxl;
|
||||||
|
margin-left: auto;
|
||||||
|
margin-right: auto;
|
||||||
|
padding-left: $-m;
|
||||||
|
padding-right: $-m;
|
||||||
|
&.small {
|
||||||
|
max-width: 840px;
|
||||||
|
}
|
||||||
|
&.very-small {
|
||||||
|
max-width: 480px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Core grid layout system
|
||||||
|
*/
|
||||||
|
.grid {
|
||||||
|
display: grid;
|
||||||
|
grid-column-gap: $-l;
|
||||||
|
grid-row-gap: $-l;
|
||||||
|
&.half {
|
||||||
|
grid-template-columns: 1fr 1fr;
|
||||||
|
}
|
||||||
|
&.third {
|
||||||
|
grid-template-columns: 1fr 1fr 1fr;
|
||||||
|
}
|
||||||
|
&.left-focus {
|
||||||
|
grid-template-columns: 2fr 1fr;
|
||||||
|
}
|
||||||
|
&.right-focus {
|
||||||
|
grid-template-columns: 1fr 3fr;
|
||||||
|
}
|
||||||
|
&.gap-xl {
|
||||||
|
grid-column-gap: $-xl;
|
||||||
|
grid-row-gap: $-xl;
|
||||||
|
}
|
||||||
|
&.gap-xxl {
|
||||||
|
grid-column-gap: $-xxl;
|
||||||
|
grid-row-gap: $-xxl;
|
||||||
|
}
|
||||||
|
&.v-center {
|
||||||
|
align-items: center;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@include smaller-than($m) {
|
||||||
|
.grid.third {
|
||||||
|
grid-template-columns: 1fr 1fr;
|
||||||
|
}
|
||||||
|
.grid.half, .grid.left-focus, .grid.right-focus {
|
||||||
|
grid-template-columns: 1fr;
|
||||||
|
}
|
||||||
|
.grid.half.collapse-xs {
|
||||||
|
grid-template-columns: 1fr 1fr;
|
||||||
|
}
|
||||||
|
.grid.gap-xl {
|
||||||
|
grid-column-gap: $-m;
|
||||||
|
grid-row-gap: $-m;
|
||||||
|
}
|
||||||
|
.grid.right-focus.reverse-collapse > *:nth-child(2) {
|
||||||
|
order: 0;
|
||||||
|
}
|
||||||
|
.grid.right-focus.reverse-collapse > *:nth-child(1) {
|
||||||
|
order: 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@include smaller-than($s) {
|
||||||
|
.grid.third {
|
||||||
|
grid-template-columns: 1fr;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@include smaller-than($xs) {
|
||||||
|
.grid.half.collapse-xs {
|
||||||
|
grid-template-columns: 1fr;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Flexbox layout system
|
||||||
|
*/
|
||||||
|
body.flexbox {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
align-items: stretch;
|
||||||
|
height: 100%;
|
||||||
|
min-height: 100%;
|
||||||
|
max-height: 100%;
|
||||||
|
overflow: hidden;
|
||||||
|
#content {
|
||||||
|
flex: 1;
|
||||||
|
display: flex;
|
||||||
|
min-height: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.flex-fill {
|
||||||
|
display: flex;
|
||||||
|
align-items: stretch;
|
||||||
|
min-height: 0;
|
||||||
|
max-width: 100%;
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
.flex {
|
||||||
|
min-height: 0;
|
||||||
|
flex: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Display and float utilities
|
||||||
|
*/
|
||||||
|
.block {
|
||||||
|
display: block;
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
.inline {
|
||||||
|
display: inline;
|
||||||
|
}
|
||||||
|
|
||||||
|
.block.inline {
|
||||||
|
display: inline-block;
|
||||||
|
}
|
||||||
|
|
||||||
|
.float {
|
||||||
|
float: left;
|
||||||
|
&.right {
|
||||||
|
float: right;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Visibility
|
||||||
|
*/
|
||||||
|
@each $sizeLetter, $size in $screen-sizes {
|
||||||
|
@include smaller-than($size) {
|
||||||
|
.hide-under-#{$sizeLetter} {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
@include larger-than($size) {
|
||||||
|
.hide-over-#{$sizeLetter} {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Inline content columns
|
||||||
|
*/
|
||||||
|
.dual-column-content {
|
||||||
|
columns: 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
@include smaller-than($m) {
|
||||||
|
.dual-column-content {
|
||||||
|
columns: 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Fixes
|
||||||
|
*/
|
||||||
|
.clearfix:before,
|
||||||
|
.clearfix:after {
|
||||||
|
content: " ";
|
||||||
|
display: table;
|
||||||
|
}
|
||||||
|
.clearfix:after {
|
||||||
|
clear: both;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* View Layouts
|
||||||
|
*/
|
||||||
|
.tri-layout-container {
|
||||||
|
display: grid;
|
||||||
|
margin-left: $-xl;
|
||||||
|
margin-right: $-xl;
|
||||||
|
grid-template-columns: 1fr 4fr 1fr;
|
||||||
|
grid-template-areas: "a b c";
|
||||||
|
grid-column-gap: $-xxl;
|
||||||
|
.tri-layout-right {
|
||||||
|
grid-area: c;
|
||||||
|
min-width: 0;
|
||||||
|
}
|
||||||
|
.tri-layout-left {
|
||||||
|
grid-area: a;
|
||||||
|
min-width: 0;
|
||||||
|
}
|
||||||
|
.tri-layout-middle {
|
||||||
|
grid-area: b;
|
||||||
|
padding-top: $-m;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
@include smaller-than($xxl) {
|
||||||
|
.tri-layout-container {
|
||||||
|
grid-template-areas: "c b b"
|
||||||
|
"a b b";
|
||||||
|
grid-template-columns: 1fr 3fr;
|
||||||
|
grid-template-rows: max-content min-content;
|
||||||
|
padding-right: $-l;
|
||||||
|
.content-wrap.card {
|
||||||
|
padding: $-l $-xl;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
@include larger-than($xxl) {
|
||||||
|
.tri-layout-left-contents, .tri-layout-right-contents {
|
||||||
|
padding: $-m;
|
||||||
|
position: sticky;
|
||||||
|
top: $-m;
|
||||||
|
max-height: 100vh;
|
||||||
|
min-height: 50vh;
|
||||||
|
overflow-y: scroll;
|
||||||
|
overflow-x: hidden;
|
||||||
|
scrollbar-width: none;
|
||||||
|
-ms-overflow-style: none;
|
||||||
|
&::-webkit-scrollbar {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.tri-layout-middle-contents {
|
||||||
|
max-width: 940px;
|
||||||
|
margin: 0 auto;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@include smaller-than($l) {
|
||||||
|
.tri-layout-container {
|
||||||
|
grid-template-areas: none;
|
||||||
|
grid-template-columns: 10% 90%;
|
||||||
|
grid-column-gap: 0;
|
||||||
|
.tri-layout-left-contents, .tri-layout-right-contents {
|
||||||
|
padding-left: $-m;
|
||||||
|
padding-right: $-m;
|
||||||
|
}
|
||||||
|
.tri-layout-right-contents > div, .tri-layout-left-contents > div {
|
||||||
|
opacity: 0.6;
|
||||||
|
z-index: 0;
|
||||||
|
}
|
||||||
|
.tri-layout-left > *, .tri-layout-right > * {
|
||||||
|
pointer-events: none;
|
||||||
|
}
|
||||||
|
.tri-layout-right, .tri-layout-left, .tri-layout-middle {
|
||||||
|
grid-area: none;
|
||||||
|
grid-column: 1/3;
|
||||||
|
grid-row: 1;
|
||||||
|
}
|
||||||
|
.tri-layout-middle {
|
||||||
|
grid-row: 1/3;
|
||||||
|
grid-column: 2/3;
|
||||||
|
z-index: 1;
|
||||||
|
transition: transform ease-in-out 240ms;
|
||||||
|
}
|
||||||
|
.tri-layout-left {
|
||||||
|
grid-row: 2;
|
||||||
|
}
|
||||||
|
&.mobile-open {
|
||||||
|
overflow: hidden;
|
||||||
|
.tri-layout-middle {
|
||||||
|
transform: translateX(90%);
|
||||||
|
}
|
||||||
|
.tri-layout-right > *, .tri-layout-left > * {
|
||||||
|
pointer-events: auto;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.tri-layout-left-contents > div, .tri-layout-right-contents > div {
|
||||||
|
opacity: 0.6;
|
||||||
|
transition: opacity ease-in-out 120ms;
|
||||||
|
&:hover {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
}
|
@ -523,10 +523,6 @@ ul.pagination {
|
|||||||
color: #999;
|
color: #999;
|
||||||
fill: #999;
|
fill: #999;
|
||||||
}
|
}
|
||||||
li.padded {
|
|
||||||
padding: $-xs $-m;
|
|
||||||
line-height: 1.2;
|
|
||||||
}
|
|
||||||
li.active a {
|
li.active a {
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
}
|
}
|
||||||
|
@ -243,13 +243,6 @@
|
|||||||
min-height: 0px;
|
min-height: 0px;
|
||||||
overflow-y: scroll;
|
overflow-y: scroll;
|
||||||
}
|
}
|
||||||
div[toolbox-tab-content] .padded {
|
|
||||||
flex: 1;
|
|
||||||
padding-top: 0;
|
|
||||||
}
|
|
||||||
div[toolbox-tab-content] .padded.files {
|
|
||||||
overflow-x: hidden;
|
|
||||||
}
|
|
||||||
h4 {
|
h4 {
|
||||||
font-size: 24px;
|
font-size: 24px;
|
||||||
margin: $-m 0 0 0;
|
margin: $-m 0 0 0;
|
||||||
|
32
resources/assets/sass/_spacing.scss
Normal file
32
resources/assets/sass/_spacing.scss
Normal file
@ -0,0 +1,32 @@
|
|||||||
|
// Here we generate spacing utility classes for our sizes for all box sides and axis.
|
||||||
|
// These will output to classes like .px-m (Padding on x-axis, medium size) or .mr-l (Margin right, large size)
|
||||||
|
|
||||||
|
@mixin spacing($prop, $propLetter) {
|
||||||
|
@each $sizeLetter, $size in $spacing {
|
||||||
|
.#{$propLetter}-#{$sizeLetter} {
|
||||||
|
#{$prop}: $size !important;
|
||||||
|
}
|
||||||
|
.#{$propLetter}x-#{$sizeLetter} {
|
||||||
|
#{$prop}-left: $size !important;
|
||||||
|
#{$prop}-right: $size !important;
|
||||||
|
}
|
||||||
|
.#{$propLetter}y-#{$sizeLetter} {
|
||||||
|
#{$prop}-top: $size !important;
|
||||||
|
#{$prop}-bottom: $size !important;
|
||||||
|
}
|
||||||
|
.#{$propLetter}t-#{$sizeLetter} {
|
||||||
|
#{$prop}-top: $size !important;
|
||||||
|
}
|
||||||
|
.#{$propLetter}r-#{$sizeLetter} {
|
||||||
|
#{$prop}-right: $size !important;
|
||||||
|
}
|
||||||
|
.#{$propLetter}b-#{$sizeLetter} {
|
||||||
|
#{$prop}-bottom: $size !important;
|
||||||
|
}
|
||||||
|
.#{$propLetter}l-#{$sizeLetter} {
|
||||||
|
#{$prop}-left: $size !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
@include spacing('margin', 'm')
|
||||||
|
@include spacing('padding', 'p')
|
@ -14,6 +14,7 @@ $screen-lg: 1200px;
|
|||||||
$screen-md: 992px;
|
$screen-md: 992px;
|
||||||
$screen-sm: 768px;
|
$screen-sm: 768px;
|
||||||
|
|
||||||
|
// List of screen sizes
|
||||||
$screen-sizes: (('xxs', $xxs), ('xs', $xs), ('s', $s), ('m', $m), ('l', $l), ('xl', $xl));
|
$screen-sizes: (('xxs', $xxs), ('xs', $xs), ('s', $s), ('m', $m), ('l', $l), ('xl', $xl));
|
||||||
|
|
||||||
// Spacing (Margins+Padding)
|
// Spacing (Margins+Padding)
|
||||||
@ -26,6 +27,7 @@ $-s: 12px;
|
|||||||
$-xs: 6px;
|
$-xs: 6px;
|
||||||
$-xxs: 3px;
|
$-xxs: 3px;
|
||||||
|
|
||||||
|
// List of our spacing sizes
|
||||||
$spacing: (('none', 0), ('xxs', $-xxs), ('xs', $-xs), ('s', $-s), ('m', $-m), ('l', $-l), ('xl', $-xl), ('xxl', $-xxl));
|
$spacing: (('none', 0), ('xxs', $-xxs), ('xs', $-xs), ('s', $-s), ('m', $-m), ('l', $-l), ('xl', $-xl), ('xxl', $-xxl));
|
||||||
|
|
||||||
// Fonts
|
// Fonts
|
||||||
|
@ -1,8 +1,9 @@
|
|||||||
@import "variables";
|
@import "variables";
|
||||||
@import "mixins";
|
@import "mixins";
|
||||||
|
@import "spacing";
|
||||||
@import "html";
|
@import "html";
|
||||||
@import "text";
|
@import "text";
|
||||||
@import "grid";
|
@import "layout";
|
||||||
@import "blocks";
|
@import "blocks";
|
||||||
@import "forms";
|
@import "forms";
|
||||||
@import "tables";
|
@import "tables";
|
||||||
@ -12,6 +13,9 @@
|
|||||||
|
|
||||||
body {
|
body {
|
||||||
font-family: 'DejaVu Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", "Oxygen", "Ubuntu", "Roboto", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif;
|
font-family: 'DejaVu Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", "Oxygen", "Ubuntu", "Roboto", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif;
|
||||||
|
background-color: #FFF;
|
||||||
|
margin: 0;
|
||||||
|
padding: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
table {
|
table {
|
||||||
@ -19,6 +23,10 @@ table {
|
|||||||
border-collapse: collapse;
|
border-collapse: collapse;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.page-content {
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
// Prevent code block overflow on export
|
// Prevent code block overflow on export
|
||||||
pre {
|
pre {
|
||||||
padding-left: 12px;
|
padding-left: 12px;
|
||||||
|
@ -1,10 +1,11 @@
|
|||||||
@import "reset";
|
@import "reset";
|
||||||
@import "variables";
|
@import "variables";
|
||||||
@import "mixins";
|
@import "mixins";
|
||||||
|
@import "spacing";
|
||||||
@import "html";
|
@import "html";
|
||||||
@import "text";
|
@import "text";
|
||||||
@import "colors";
|
@import "colors";
|
||||||
@import "grid";
|
@import "layout";
|
||||||
@import "blocks";
|
@import "blocks";
|
||||||
@import "buttons";
|
@import "buttons";
|
||||||
@import "tables";
|
@import "tables";
|
||||||
|
@ -31,51 +31,51 @@
|
|||||||
@include('partials.custom-head')
|
@include('partials.custom-head')
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<div class="container">
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-md-8 col-md-offset-2">
|
|
||||||
<div class="page-content">
|
|
||||||
|
|
||||||
<h1 style="font-size: 4.8em">{{$book->name}}</h1>
|
<div class="page-content">
|
||||||
|
|
||||||
<p>{{ $book->description }}</p>
|
<h1 style="font-size: 4.8em">{{$book->name}}</h1>
|
||||||
|
|
||||||
@if(count($bookChildren) > 0)
|
<p>{{ $book->description }}</p>
|
||||||
<ul class="contents">
|
|
||||||
@foreach($bookChildren as $bookChild)
|
@if(count($bookChildren) > 0)
|
||||||
<li><a href="#{{$bookChild->getType()}}-{{$bookChild->id}}">{{ $bookChild->name }}</a></li>
|
<ul class="contents">
|
||||||
@if($bookChild->isA('chapter') && count($bookChild->pages) > 0)
|
@foreach($bookChildren as $bookChild)
|
||||||
<ul>
|
<li><a href="#{{$bookChild->getType()}}-{{$bookChild->id}}">{{ $bookChild->name }}</a></li>
|
||||||
@foreach($bookChild->pages as $page)
|
@if($bookChild->isA('chapter') && count($bookChild->pages) > 0)
|
||||||
<li><a href="#page-{{$page->id}}">{{ $page->name }}</a></li>
|
<ul>
|
||||||
@endforeach
|
@foreach($bookChild->pages as $page)
|
||||||
</ul>
|
<li><a href="#page-{{$page->id}}">{{ $page->name }}</a></li>
|
||||||
@endif
|
@endforeach
|
||||||
@endforeach
|
</ul>
|
||||||
</ul>
|
|
||||||
@endif
|
@endif
|
||||||
|
@endforeach
|
||||||
|
</ul>
|
||||||
|
@endif
|
||||||
|
|
||||||
@foreach($bookChildren as $bookChild)
|
@foreach($bookChildren as $bookChild)
|
||||||
|
<div class="page-break"></div>
|
||||||
|
<h1 id="{{$bookChild->getType()}}-{{$bookChild->id}}">{{ $bookChild->name }}</h1>
|
||||||
|
|
||||||
|
@if($bookChild->isA('chapter'))
|
||||||
|
<p>{{ $bookChild->description }}</p>
|
||||||
|
|
||||||
|
@if(count($bookChild->pages) > 0)
|
||||||
|
@foreach($bookChild->pages as $page)
|
||||||
<div class="page-break"></div>
|
<div class="page-break"></div>
|
||||||
<h1 id="{{$bookChild->getType()}}-{{$bookChild->id}}">{{ $bookChild->name }}</h1>
|
<div class="chapter-hint">{{$bookChild->name}}</div>
|
||||||
@if($bookChild->isA('chapter'))
|
<h1 id="page-{{$page->id}}">{{ $page->name }}</h1>
|
||||||
<p>{{ $bookChild->description }}</p>
|
{!! $page->html !!}
|
||||||
@if(count($bookChild->pages) > 0)
|
|
||||||
@foreach($bookChild->pages as $page)
|
|
||||||
<div class="page-break"></div>
|
|
||||||
<div class="chapter-hint">{{$bookChild->name}}</div>
|
|
||||||
<h1 id="page-{{$page->id}}">{{ $page->name }}</h1>
|
|
||||||
{!! $page->html !!}
|
|
||||||
@endforeach
|
|
||||||
@endif
|
|
||||||
@else
|
|
||||||
{!! $bookChild->html !!}
|
|
||||||
@endif
|
|
||||||
@endforeach
|
@endforeach
|
||||||
|
@endif
|
||||||
|
|
||||||
|
@else
|
||||||
|
{!! $bookChild->html !!}
|
||||||
|
@endif
|
||||||
|
|
||||||
|
@endforeach
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
@ -24,32 +24,28 @@
|
|||||||
@include('partials.custom-head')
|
@include('partials.custom-head')
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<div class="container">
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-md-8 col-md-offset-2">
|
|
||||||
<div class="page-content">
|
|
||||||
|
|
||||||
<h1 style="font-size: 4.8em">{{$chapter->name}}</h1>
|
<div class="page-content">
|
||||||
|
|
||||||
<p>{{ $chapter->description }}</p>
|
<h1 style="font-size: 4.8em">{{$chapter->name}}</h1>
|
||||||
|
|
||||||
@if(count($pages) > 0)
|
<p>{{ $chapter->description }}</p>
|
||||||
<ul class="contents">
|
|
||||||
@foreach($pages as $page)
|
|
||||||
<li><a href="#page-{{$page->id}}">{{ $page->name }}</a></li>
|
|
||||||
@endforeach
|
|
||||||
</ul>
|
|
||||||
@endif
|
|
||||||
|
|
||||||
@foreach($pages as $page)
|
@if(count($pages) > 0)
|
||||||
<div class="page-break"></div>
|
<ul class="contents">
|
||||||
<h1 id="page-{{$page->id}}">{{ $page->name }}</h1>
|
@foreach($pages as $page)
|
||||||
{!! $page->html !!}
|
<li><a href="#page-{{$page->id}}">{{ $page->name }}</a></li>
|
||||||
@endforeach
|
@endforeach
|
||||||
|
</ul>
|
||||||
|
@endif
|
||||||
|
|
||||||
|
@foreach($pages as $page)
|
||||||
|
<div class="page-break"></div>
|
||||||
|
<h1 id="page-{{$page->id}}">{{ $page->name }}</h1>
|
||||||
|
{!! $page->html !!}
|
||||||
|
@endforeach
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
@ -131,25 +131,10 @@
|
|||||||
<span>{{ trans('common.delete') }}</span>
|
<span>{{ trans('common.delete') }}</span>
|
||||||
</a>
|
</a>
|
||||||
@endif
|
@endif
|
||||||
|
|
||||||
{{--@if(userCan('page-create', $book))--}}
|
|
||||||
{{--<a href="{{ $book->getUrl('/create-page') }}" class="icon-list-item">--}}
|
|
||||||
{{--<span>@icon('add')</span>--}}
|
|
||||||
{{--<span>{{ trans('entities.pages_new') }}</span>--}}
|
|
||||||
{{--</a>--}}
|
|
||||||
{{--@endif--}}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="col-sm-6 col-xs-9 faded">
|
|
||||||
<div class="action-buttons">
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@stop
|
@stop
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@section('left')
|
@section('left')
|
||||||
|
|
||||||
@if($chapter->tags->count() > 0)
|
@if($chapter->tags->count() > 0)
|
||||||
|
@ -13,7 +13,7 @@
|
|||||||
<div dropdown class="dropdown-container">
|
<div dropdown class="dropdown-container">
|
||||||
<button type="button" dropdown-toggle class="text-button" title="{{ trans('common.delete') }}">@icon('delete')</button>
|
<button type="button" dropdown-toggle class="text-button" title="{{ trans('common.delete') }}">@icon('delete')</button>
|
||||||
<ul>
|
<ul>
|
||||||
<li class="padded"><small class="text-muted">{{trans('entities.comment_delete_confirm')}}</small></li>
|
<li class="px-l"><small class="text-muted">{{trans('entities.comment_delete_confirm')}}</small></li>
|
||||||
<li><a action="delete" class="text-button neg" >@icon('delete'){{ trans('common.delete') }}</a></li>
|
<li><a action="delete" class="text-button neg" >@icon('delete'){{ trans('common.delete') }}</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
<header id="header" header-mobile-toggle>
|
<header id="header" header-mobile-toggle>
|
||||||
<div class="grid break-l mx-l">
|
<div class="grid mx-l">
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<a href="{{ baseUrl('/') }}" class="logo">
|
<a href="{{ baseUrl('/') }}" class="logo">
|
||||||
|
@ -7,52 +7,55 @@
|
|||||||
<a expand-toggle=".entity-list.compact .entity-item-snippet" class="text-muted">@icon('expand-text'){{ trans('common.toggle_details') }}</a>
|
<a expand-toggle=".entity-list.compact .entity-item-snippet" class="text-muted">@icon('expand-text'){{ trans('common.toggle_details') }}</a>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="grid contained third gap-xxl" id="home-default">
|
<div class="container" id="home-default">
|
||||||
<div>
|
<div class="grid third gap-xxl" >
|
||||||
@if(count($draftPages) > 0)
|
<div>
|
||||||
<div id="recent-drafts" class="card mb-xl">
|
@if(count($draftPages) > 0)
|
||||||
<h3>{{ trans('entities.my_recent_drafts') }}</h3>
|
<div id="recent-drafts" class="card mb-xl">
|
||||||
|
<h3>{{ trans('entities.my_recent_drafts') }}</h3>
|
||||||
|
<div class="px-m">
|
||||||
|
@include('partials/entity-list', ['entities' => $draftPages, 'style' => 'compact'])
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
@endif
|
||||||
|
|
||||||
|
<div id="{{ $signedIn ? 'recently-viewed' : 'recent-books' }}" class="card mb-xl">
|
||||||
|
<h3>{{ trans('entities.' . ($signedIn ? 'my_recently_viewed' : 'books_recent')) }}</h3>
|
||||||
<div class="px-m">
|
<div class="px-m">
|
||||||
@include('partials/entity-list', ['entities' => $draftPages, 'style' => 'compact'])
|
@include('partials/entity-list', [
|
||||||
|
'entities' => $recents,
|
||||||
|
'style' => 'compact',
|
||||||
|
'emptyText' => $signedIn ? trans('entities.no_pages_viewed') : trans('entities.books_empty')
|
||||||
|
])
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@endif
|
</div>
|
||||||
|
|
||||||
<div id="{{ $signedIn ? 'recently-viewed' : 'recent-books' }}" class="card mb-xl">
|
<div>
|
||||||
<h3>{{ trans('entities.' . ($signedIn ? 'my_recently_viewed' : 'books_recent')) }}</h3>
|
<div id="recent-pages" class="card mb-xl">
|
||||||
<div class="px-m">
|
<h3><a class="no-color" href="{{ baseUrl("/pages/recently-updated") }}">{{ trans('entities.recently_updated_pages') }}</a></h3>
|
||||||
@include('partials/entity-list', [
|
<div id="recently-updated-pages" class="px-m">
|
||||||
'entities' => $recents,
|
@include('partials/entity-list', [
|
||||||
'style' => 'compact',
|
'entities' => $recentlyUpdatedPages,
|
||||||
'emptyText' => $signedIn ? trans('entities.no_pages_viewed') : trans('entities.books_empty')
|
'style' => 'compact',
|
||||||
])
|
'emptyText' => trans('entities.no_pages_recently_updated')
|
||||||
|
])
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<div id="recent-pages" class="card mb-xl">
|
<div id="recent-activity">
|
||||||
<h3><a class="no-color" href="{{ baseUrl("/pages/recently-updated") }}">{{ trans('entities.recently_updated_pages') }}</a></h3>
|
<div class="card mb-xl">
|
||||||
<div id="recently-updated-pages" class="px-m">
|
<h3>{{ trans('entities.recent_activity') }}</h3>
|
||||||
@include('partials/entity-list', [
|
@include('partials/activity-list', ['activity' => $activity])
|
||||||
'entities' => $recentlyUpdatedPages,
|
</div>
|
||||||
'style' => 'compact',
|
|
||||||
'emptyText' => trans('entities.no_pages_recently_updated')
|
|
||||||
])
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
|
|
||||||
<div>
|
|
||||||
<div id="recent-activity">
|
|
||||||
<div class="card mb-xl">
|
|
||||||
<h3>{{ trans('entities.recent_activity') }}</h3>
|
|
||||||
@include('partials/activity-list', ['activity' => $activity])
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@stop
|
@stop
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
<button class="overlay-close neg corner-button button" @click="hide()">x</button>
|
<button class="overlay-close neg corner-button button" @click="hide()">x</button>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="padded popup-content">
|
<div class="p-l popup-content">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label for="code-editor-language">{{ trans('components.code_language') }}</label>
|
<label for="code-editor-language">{{ trans('components.code_language') }}</label>
|
||||||
<div class="lang-options">
|
<div class="lang-options">
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
<div id="entity-selector-wrap">
|
<div id="entity-selector-wrap">
|
||||||
<div overlay entity-selector-popup>
|
<div overlay entity-selector-popup>
|
||||||
<div class="popup-body small flex-child">
|
<div class="popup-body small">
|
||||||
<div class="popup-header primary-background">
|
<div class="popup-header primary-background">
|
||||||
<div class="popup-title">{{ trans('entities.entity_select') }}</div>
|
<div class="popup-title">{{ trans('entities.entity_select') }}</div>
|
||||||
<button type="button" class="corner-button neg button overlay-close">x</button>
|
<button type="button" class="corner-button neg button overlay-close">x</button>
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
<div class="form-group">
|
<div class="form-group entity-selector-container">
|
||||||
<div entity-selector class="entity-selector {{$selectorSize ?? ''}}" entity-types="{{ $entityTypes ?? 'book,chapter,page' }}" entity-permission="{{ $entityPermission ?? 'view' }}">
|
<div entity-selector class="entity-selector {{$selectorSize ?? ''}}" entity-types="{{ $entityTypes ?? 'book,chapter,page' }}" entity-permission="{{ $entityPermission ?? 'view' }}">
|
||||||
<input type="hidden" entity-selector-input name="{{$name}}" value="">
|
<input type="hidden" entity-selector-input name="{{$name}}" value="">
|
||||||
<input type="text" placeholder="{{ trans('common.search') }}" entity-selector-search>
|
<input type="text" placeholder="{{ trans('common.search') }}" entity-selector-search>
|
||||||
|
@ -10,12 +10,10 @@
|
|||||||
<div class="flex-fill image-manager-body">
|
<div class="flex-fill image-manager-body">
|
||||||
|
|
||||||
<div class="image-manager-content">
|
<div class="image-manager-content">
|
||||||
<div v-if="imageType === 'gallery'" class="container">
|
<div v-if="imageType === 'gallery'" class="image-manager-header primary-background-light nav-tabs grid third">
|
||||||
<div class="image-manager-header primary-background-light row nav-tabs">
|
<div class="tab-item" title="{{ trans('components.image_all_title') }}" :class="{selected: (view=='all')}" @click="setView('all')">@icon('images') {{ trans('components.image_all') }}</div>
|
||||||
<div class="col-xs-4 tab-item" title="{{ trans('components.image_all_title') }}" :class="{selected: (view=='all')}" @click="setView('all')">@icon('images') {{ trans('components.image_all') }}</div>
|
<div class="tab-item" title="{{ trans('components.image_book_title') }}" :class="{selected: (view=='book')}" @click="setView('book')">@icon('book', ['class' => 'text-book svg-icon']) {{ trans('entities.book') }}</div>
|
||||||
<div class="col-xs-4 tab-item" title="{{ trans('components.image_book_title') }}" :class="{selected: (view=='book')}" @click="setView('book')">@icon('book', ['class' => 'text-book svg-icon']) {{ trans('entities.book') }}</div>
|
<div class="tab-item" title="{{ trans('components.image_page_title') }}" :class="{selected: (view=='page')}" @click="setView('page')">@icon('page', ['class' => 'text-page svg-icon']) {{ trans('entities.page') }}</div>
|
||||||
<div class="col-xs-4 tab-item" title="{{ trans('components.image_page_title') }}" :class="{selected: (view=='page')}" @click="setView('page')">@icon('page', ['class' => 'text-page svg-icon']) {{ trans('entities.page') }}</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
<div v-show="view === 'all'" >
|
<div v-show="view === 'all'" >
|
||||||
<form @submit.prevent="searchImages" class="contained-search-box">
|
<form @submit.prevent="searchImages" class="contained-search-box">
|
||||||
|
@ -13,22 +13,20 @@
|
|||||||
@include('partials.custom-head')
|
@include('partials.custom-head')
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<div class="container" id="page-show">
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-md-8 col-md-offset-2">
|
|
||||||
<div class="page-content">
|
|
||||||
|
|
||||||
@include('pages.page-display')
|
<div id="page-show">
|
||||||
|
<div class="page-content">
|
||||||
|
|
||||||
<hr>
|
@include('pages.page-display')
|
||||||
|
|
||||||
<div class="text-muted text-small">
|
<hr>
|
||||||
@include('partials.entity-export-meta', ['entity' => $page])
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</div>
|
<div class="text-muted text-small">
|
||||||
|
@include('partials.entity-export-meta', ['entity' => $page])
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
@ -11,7 +11,7 @@
|
|||||||
|
|
||||||
<div toolbox-tab-content="tags">
|
<div toolbox-tab-content="tags">
|
||||||
<h4>{{ trans('entities.page_tags') }}</h4>
|
<h4>{{ trans('entities.page_tags') }}</h4>
|
||||||
<div class="padded">
|
<div class="px-l">
|
||||||
@include('components.tag-manager', ['entity' => $page, 'entityType' => 'page'])
|
@include('components.tag-manager', ['entity' => $page, 'entityType' => 'page'])
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -19,7 +19,7 @@
|
|||||||
@if(userCan('attachment-create-all'))
|
@if(userCan('attachment-create-all'))
|
||||||
<div toolbox-tab-content="files" id="attachment-manager" page-id="{{ $page->id ?? 0 }}">
|
<div toolbox-tab-content="files" id="attachment-manager" page-id="{{ $page->id ?? 0 }}">
|
||||||
<h4>{{ trans('entities.attachments') }}</h4>
|
<h4>{{ trans('entities.attachments') }}</h4>
|
||||||
<div class="padded files">
|
<div class="px-l files">
|
||||||
|
|
||||||
<div id="file-list" v-show="!fileToEdit">
|
<div id="file-list" v-show="!fileToEdit">
|
||||||
<p class="muted small">{{ trans('entities.attachments_explain') }} <span class="secondary">{{ trans('entities.attachments_explain_instant_save') }}</span></p>
|
<p class="muted small">{{ trans('entities.attachments_explain') }} <span class="secondary">{{ trans('entities.attachments_explain_instant_save') }}</span></p>
|
||||||
@ -34,7 +34,7 @@
|
|||||||
<draggable style="width: 100%;" :options="{handle: '.handle'}" @change="fileSortUpdate" :list="files" element="div">
|
<draggable style="width: 100%;" :options="{handle: '.handle'}" @change="fileSortUpdate" :list="files" element="div">
|
||||||
<div v-for="(file, index) in files" :key="file.id" class="card drag-card">
|
<div v-for="(file, index) in files" :key="file.id" class="card drag-card">
|
||||||
<div class="handle">@icon('grip')</div>
|
<div class="handle">@icon('grip')</div>
|
||||||
<div class="padded">
|
<div class="py-s">
|
||||||
<a :href="getFileUrl(file)" target="_blank" v-text="file.name"></a>
|
<a :href="getFileUrl(file)" target="_blank" v-text="file.name"></a>
|
||||||
<div v-if="file.deleting">
|
<div v-if="file.deleting">
|
||||||
<span class="neg small">{{ trans('entities.attachments_delete_confirm') }}</span>
|
<span class="neg small">{{ trans('entities.attachments_delete_confirm') }}</span>
|
||||||
|
@ -41,7 +41,7 @@
|
|||||||
<div dropdown class="dropdown-container">
|
<div dropdown class="dropdown-container">
|
||||||
<a dropdown-toggle class="text-primary text-button">@icon('edit') <span v-text="changeSummaryShort"></span></a>
|
<a dropdown-toggle class="text-primary text-button">@icon('edit') <span v-text="changeSummaryShort"></span></a>
|
||||||
<ul class="wide">
|
<ul class="wide">
|
||||||
<li class="padded">
|
<li class="px-l py-m">
|
||||||
<p class="text-muted pb-s">{{ trans('entities.pages_edit_enter_changelog_desc') }}</p>
|
<p class="text-muted pb-s">{{ trans('entities.pages_edit_enter_changelog_desc') }}</p>
|
||||||
<input name="summary" id="summary-input" type="text" placeholder="{{ trans('entities.pages_edit_enter_changelog') }}" v-model="changeSummary" />
|
<input name="summary" id="summary-input" type="text" placeholder="{{ trans('entities.pages_edit_enter_changelog') }}" v-model="changeSummary" />
|
||||||
</li>
|
</li>
|
||||||
|
@ -55,7 +55,7 @@
|
|||||||
<div dropdown class="dropdown-container">
|
<div dropdown class="dropdown-container">
|
||||||
<a dropdown-toggle>{{ trans('common.delete') }}</a>
|
<a dropdown-toggle>{{ trans('common.delete') }}</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li class="padded"><small class="text-muted">{{trans('entities.revision_delete_confirm')}}</small></li>
|
<li class="px-m py-s"><small class="text-muted">{{trans('entities.revision_delete_confirm')}}</small></li>
|
||||||
<li>
|
<li>
|
||||||
<form action="{{ $revision->getUrl('/delete/') }}" method="POST">
|
<form action="{{ $revision->getUrl('/delete/') }}" method="POST">
|
||||||
{!! csrf_field() !!}
|
{!! csrf_field() !!}
|
||||||
|
@ -32,7 +32,7 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
@if ($commentsEnabled)
|
@if ($commentsEnabled)
|
||||||
<div class="container small nopad comments-container mb-l">
|
<div class="container small p-none comments-container mb-l">
|
||||||
@include('comments.comments', ['page' => $page])
|
@include('comments.comments', ['page' => $page])
|
||||||
<div class="clearfix"></div>
|
<div class="clearfix"></div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -1,80 +0,0 @@
|
|||||||
<!doctype html>
|
|
||||||
<html lang="en">
|
|
||||||
<head>
|
|
||||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
|
|
||||||
<title>{{ $book->name }}</title>
|
|
||||||
|
|
||||||
<style>
|
|
||||||
@if (!app()->environment('testing'))
|
|
||||||
{!! file_get_contents(public_path('/dist/export-styles.css')) !!}
|
|
||||||
@endif
|
|
||||||
.page-break {
|
|
||||||
page-break-after: always;
|
|
||||||
}
|
|
||||||
.chapter-hint {
|
|
||||||
color: #888;
|
|
||||||
margin-top: 32px;
|
|
||||||
}
|
|
||||||
.chapter-hint + h1 {
|
|
||||||
margin-top: 0;
|
|
||||||
}
|
|
||||||
ul.contents ul li {
|
|
||||||
list-style: circle;
|
|
||||||
}
|
|
||||||
@media screen {
|
|
||||||
.page-break {
|
|
||||||
border-top: 1px solid #DDD;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
@yield('head')
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div class="container">
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-md-8 col-md-offset-2">
|
|
||||||
<div class="page-content">
|
|
||||||
|
|
||||||
<h1 style="font-size: 4.8em">{{$book->name}}</h1>
|
|
||||||
|
|
||||||
<p>{{ $book->description }}</p>
|
|
||||||
|
|
||||||
@if(count($bookChildren) > 0)
|
|
||||||
<ul class="contents">
|
|
||||||
@foreach($bookChildren as $bookChild)
|
|
||||||
<li><a href="#{{$bookChild->getType()}}-{{$bookChild->id}}">{{ $bookChild->name }}</a></li>
|
|
||||||
@if($bookChild->isA('chapter') && count($bookChild->pages) > 0)
|
|
||||||
<ul>
|
|
||||||
@foreach($bookChild->pages as $page)
|
|
||||||
<li><a href="#page-{{$page->id}}">{{ $page->name }}</a></li>
|
|
||||||
@endforeach
|
|
||||||
</ul>
|
|
||||||
@endif
|
|
||||||
@endforeach
|
|
||||||
</ul>
|
|
||||||
@endif
|
|
||||||
|
|
||||||
@foreach($bookChildren as $bookChild)
|
|
||||||
<div class="page-break"></div>
|
|
||||||
<h1 id="{{$bookChild->getType()}}-{{$bookChild->id}}">{{ $bookChild->name }}</h1>
|
|
||||||
@if($bookChild->isA('chapter'))
|
|
||||||
<p>{{ $bookChild->description }}</p>
|
|
||||||
@if(count($bookChild->pages) > 0)
|
|
||||||
@foreach($bookChild->pages as $page)
|
|
||||||
<div class="page-break"></div>
|
|
||||||
<div class="chapter-hint">{{$bookChild->name}}</div>
|
|
||||||
<h1 id="page-{{$page->id}}">{{ $page->name }}</h1>
|
|
||||||
{!! $page->html !!}
|
|
||||||
@endforeach
|
|
||||||
@endif
|
|
||||||
@else
|
|
||||||
{!! $bookChild->html !!}
|
|
||||||
@endif
|
|
||||||
@endforeach
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
@ -10,39 +10,35 @@
|
|||||||
@include('form/textarea', ['name' => 'description'])
|
@include('form/textarea', ['name' => 'description'])
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div shelf-sort class="row">
|
<div shelf-sort class="grid half gap-xl">
|
||||||
<div class="col-md-6">
|
<div class="form-group">
|
||||||
<div class="form-group">
|
<label for="books">{{ trans('entities.shelves_books') }}</label>
|
||||||
<label for="books">{{ trans('entities.shelves_books') }}</label>
|
<input type="hidden" id="books-input" name="books"
|
||||||
<input type="hidden" id="books-input" name="books"
|
value="{{ isset($shelf) ? $shelf->books->implode('id', ',') : '' }}">
|
||||||
value="{{ isset($shelf) ? $shelf->books->implode('id', ',') : '' }}">
|
<div class="scroll-box">
|
||||||
<div class="scroll-box">
|
<div class="scroll-box-item text-small text-muted instruction">
|
||||||
<div class="scroll-box-item text-small text-muted instruction">
|
{{ trans('entities.shelves_drag_books') }}
|
||||||
{{ trans('entities.shelves_drag_books') }}
|
|
||||||
</div>
|
|
||||||
<div class="scroll-box-item scroll-box-placeholder" style="display: none;">
|
|
||||||
<a href="#" class="text-muted">@icon('book') ...</a>
|
|
||||||
</div>
|
|
||||||
@if (isset($shelfBooks) && count($shelfBooks) > 0)
|
|
||||||
@foreach ($shelfBooks as $book)
|
|
||||||
<div data-id="{{ $book->id }}" class="scroll-box-item">
|
|
||||||
<a href="{{ $book->getUrl() }}" class="text-book">@icon('book'){{ $book->name }}</a>
|
|
||||||
</div>
|
|
||||||
@endforeach
|
|
||||||
@endif
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
<div class="scroll-box-item scroll-box-placeholder" style="display: none;">
|
||||||
</div>
|
<a href="#" class="text-muted">@icon('book') ...</a>
|
||||||
<div class="col-md-6">
|
</div>
|
||||||
<div class="form-group">
|
@if (isset($shelfBooks) && count($shelfBooks) > 0)
|
||||||
<label for="books">{{ trans('entities.shelves_add_books') }}</label>
|
@foreach ($shelfBooks as $book)
|
||||||
<div class="scroll-box">
|
|
||||||
@foreach ($books as $book)
|
|
||||||
<div data-id="{{ $book->id }}" class="scroll-box-item">
|
<div data-id="{{ $book->id }}" class="scroll-box-item">
|
||||||
<a href="{{ $book->getUrl() }}" class="text-book">@icon('book'){{ $book->name }}</a>
|
<a href="{{ $book->getUrl() }}" class="text-book">@icon('book'){{ $book->name }}</a>
|
||||||
</div>
|
</div>
|
||||||
@endforeach
|
@endforeach
|
||||||
</div>
|
@endif
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label for="books">{{ trans('entities.shelves_add_books') }}</label>
|
||||||
|
<div class="scroll-box">
|
||||||
|
@foreach ($books as $book)
|
||||||
|
<div data-id="{{ $book->id }}" class="scroll-box-item">
|
||||||
|
<a href="{{ $book->getUrl() }}" class="text-book">@icon('book'){{ $book->name }}</a>
|
||||||
|
</div>
|
||||||
|
@endforeach
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
Loading…
Reference in New Issue
Block a user