1
0
mirror of https://github.com/BookStackApp/BookStack.git synced 2026-01-03 23:42:28 +03:00

Reviewed and refactored next/previous navigation button implementation

- Updated styling to include item name.
- Extracted used text to translations.
- Updated the design to better suit the surrounding blocks.
- Removed newly added model/repo methods.
- Moved core logic out of controller and instead into a "NextPreviousContentLocator"
helper with re-uses the output from the book-tree generation.
- Also added the system to chapters.

For #2511
This commit is contained in:
Dan Brown
2021-05-29 12:39:41 +01:00
parent 7ca66c5d5e
commit 0cfff6ab6f
13 changed files with 158 additions and 101 deletions

View File

@@ -62,9 +62,6 @@
}
@include smaller-than($m) {
.grid.third.prev-next:not(.no-break) {
grid-template-columns: 1fr 1fr 1fr;
}
.grid.third:not(.no-break) {
grid-template-columns: 1fr 1fr;
}
@@ -84,24 +81,12 @@
.grid.right-focus.reverse-collapse > *:nth-child(1) {
order: 1;
}
.grid.third:not(.no-break) .text-m-left {
margin-left: 20%;
}
.grid.third:not(.no-break) .text-m-right {
margin-left: 45%;
}
}
@include smaller-than($s) {
.grid.third:not(.no-break) {
grid-template-columns: 1fr;
}
.grid.third:not(.no-break) .text-m-left {
margin-left: 18%;
}
.grid.third:not(.no-break) .text-m-right {
margin-left: 20%;
}
}
@include smaller-than($xs) {
@@ -227,6 +212,13 @@ body.flexbox {
}
}
/**
* Border radiuses
*/
.rounded {
border-radius: 4px;
}
/**
* Inline content columns
*/
@@ -381,8 +373,4 @@ body.flexbox {
margin-inline-start: 0;
margin-inline-end: 0;
}
}
.prev-next-btn {
height: 50px;
}
}