mirror of
https://github.com/BookStackApp/BookStack.git
synced 2024-10-01 01:36:00 -04:00
Made another mass of accessibility improvements
- Set proper semantic tags for main parts of content. - Removed focus-trap from tag manager/autosuggest. - Set better accessibility labelling on tag manager. - Updated collapsible sections to be keyboard navigatable. - Improved input focus styling to better fit theme. - Updated custom styled file picker to be accessible via keyboard. Related to #1320
This commit is contained in:
parent
ae93a6ed07
commit
cf5d51e7b8
@ -18,11 +18,13 @@ class Collapsible {
|
||||
|
||||
open() {
|
||||
this.elem.classList.add('open');
|
||||
this.trigger.setAttribute('aria-expanded', 'true');
|
||||
slideDown(this.content, 300);
|
||||
}
|
||||
|
||||
close() {
|
||||
this.elem.classList.remove('open');
|
||||
this.trigger.setAttribute('aria-expanded', 'false');
|
||||
slideUp(this.content, 300);
|
||||
}
|
||||
|
||||
|
@ -6,6 +6,7 @@ const template = `
|
||||
@input="inputUpdate($event.target.value)" @focus="inputUpdate($event.target.value)"
|
||||
@blur="inputBlur"
|
||||
@keydown="inputKeydown"
|
||||
:aria-label="placeholder"
|
||||
/>
|
||||
<ul class="suggestion-box" v-if="showSuggestions">
|
||||
<li v-for="(suggestion, i) in suggestions"
|
||||
@ -66,23 +67,23 @@ const methods = {
|
||||
},
|
||||
|
||||
inputKeydown(event) {
|
||||
if (event.keyCode === 13) event.preventDefault();
|
||||
if (event.key === 'Enter') event.preventDefault();
|
||||
if (!this.showSuggestions) return;
|
||||
|
||||
// Down arrow
|
||||
if (event.keyCode === 40) {
|
||||
if (event.key === 'ArrowDown') {
|
||||
this.active = (this.active === this.suggestions.length - 1) ? 0 : this.active+1;
|
||||
}
|
||||
// Up Arrow
|
||||
else if (event.keyCode === 38) {
|
||||
else if (event.key === 'ArrowUp') {
|
||||
this.active = (this.active === 0) ? this.suggestions.length - 1 : this.active-1;
|
||||
}
|
||||
// Enter or tab keys
|
||||
else if ((event.keyCode === 13 || event.keyCode === 9) && !event.shiftKey) {
|
||||
// Enter key
|
||||
else if ((event.key === 'Enter') && !event.shiftKey) {
|
||||
this.selectSuggestion(this.suggestions[this.active]);
|
||||
}
|
||||
// Escape key
|
||||
else if (event.keyCode === 27) {
|
||||
else if (event.key === 'Escape') {
|
||||
this.showSuggestions = false;
|
||||
}
|
||||
},
|
||||
|
@ -1,7 +1,7 @@
|
||||
import draggable from 'vuedraggable';
|
||||
import autosuggest from './components/autosuggest';
|
||||
|
||||
let data = {
|
||||
const data = {
|
||||
entityId: false,
|
||||
entityType: null,
|
||||
tags: [],
|
||||
@ -10,7 +10,7 @@ let data = {
|
||||
const components = {draggable, autosuggest};
|
||||
const directives = {};
|
||||
|
||||
let methods = {
|
||||
const methods = {
|
||||
|
||||
addEmptyTag() {
|
||||
this.tags.push({name: '', value: '', key: Math.random().toString(36).substring(7)});
|
||||
|
@ -19,6 +19,10 @@
|
||||
&.disabled, &[disabled] {
|
||||
background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAcAAAAHCAYAAADEUlfTAAAAMUlEQVQIW2NkwAGuXbv2nxGbHEhCS0uLEUMSJgHShCKJLIEiiS4Bl8QmAZbEJQGSBAC62BuJ+tt7zgAAAABJRU5ErkJggg==);
|
||||
}
|
||||
&:focus {
|
||||
border-color: var(--color-primary);
|
||||
outline: 1px solid var(--color-primary);
|
||||
}
|
||||
}
|
||||
|
||||
.fake-input {
|
||||
@ -266,6 +270,9 @@ input[type=color] {
|
||||
margin-left: -$-m;
|
||||
margin-right: -$-m;
|
||||
padding: $-s $-m;
|
||||
display: block;
|
||||
width: calc(100% + 32px);
|
||||
text-align: left;
|
||||
}
|
||||
.collapse-title, .collapse-title label {
|
||||
cursor: pointer;
|
||||
@ -377,3 +384,18 @@ div[editor-type="markdown"] .title-input.page-title input[type="text"] {
|
||||
background-color: #BBB;
|
||||
max-width: 100%;
|
||||
}
|
||||
|
||||
.custom-file-input {
|
||||
overflow: hidden;
|
||||
padding: 0;
|
||||
position: absolute;
|
||||
white-space: nowrap;
|
||||
width: 1px;
|
||||
height: 1px;
|
||||
border: 0;
|
||||
clip: rect(0, 0, 0, 0);
|
||||
}
|
||||
.custom-file-input:focus + label {
|
||||
border-color: var(--color-primary);
|
||||
outline: 1px solid var(--color-primary);
|
||||
}
|
@ -301,7 +301,7 @@ body.flexbox {
|
||||
.tri-layout-mobile-tabs {
|
||||
display: none;
|
||||
}
|
||||
.tri-layout-left-contents > div, .tri-layout-right-contents > div {
|
||||
.tri-layout-left-contents > *, .tri-layout-right-contents > * {
|
||||
opacity: 0.6;
|
||||
transition: opacity ease-in-out 120ms;
|
||||
&:hover {
|
||||
|
@ -59,6 +59,7 @@ return [
|
||||
'grid_view' => 'Grid View',
|
||||
'list_view' => 'List View',
|
||||
'default' => 'Default',
|
||||
'breadcrumb' => 'Breadcrumb',
|
||||
|
||||
// Header
|
||||
'profile_menu' => 'Profile Menu',
|
||||
|
@ -243,9 +243,11 @@ return [
|
||||
'shelf_tags' => 'Shelf Tags',
|
||||
'tag' => 'Tag',
|
||||
'tags' => 'Tags',
|
||||
'tag_name' => 'Tag Name',
|
||||
'tag_value' => 'Tag Value (Optional)',
|
||||
'tags_explain' => "Add some tags to better categorise your content. \n You can assign a value to a tag for more in-depth organisation.",
|
||||
'tags_add' => 'Add another tag',
|
||||
'tags_remove' => 'Remove this tag',
|
||||
'attachments' => 'Attachments',
|
||||
'attachments_explain' => 'Upload some files or attach some links to display on your page. These are visible in the page sidebar.',
|
||||
'attachments_explain_instant_save' => 'Changes here are saved instantly.',
|
||||
|
@ -30,9 +30,9 @@
|
||||
@include('partials.notifications')
|
||||
@include('common.header')
|
||||
|
||||
<section id="content" class="block">
|
||||
<div id="content" class="block">
|
||||
@yield('content')
|
||||
</section>
|
||||
</div>
|
||||
|
||||
<div back-to-top class="primary-background print-hidden">
|
||||
<div class="inner">
|
||||
|
@ -25,12 +25,12 @@
|
||||
@endif
|
||||
</div>
|
||||
|
||||
<div class="content-wrap card">
|
||||
<main class="content-wrap card">
|
||||
<h1 class="list-heading">{{ trans('entities.books_create') }}</h1>
|
||||
<form action="{{ isset($bookshelf) ? $bookshelf->getUrl('/create-book') : url('/books') }}" method="POST" enctype="multipart/form-data">
|
||||
@include('books.form')
|
||||
</form>
|
||||
</div>
|
||||
</main>
|
||||
</div>
|
||||
|
||||
@stop
|
@ -14,12 +14,12 @@
|
||||
]])
|
||||
</div>
|
||||
|
||||
<div class="content-wrap card">
|
||||
<main class="content-wrap card">
|
||||
<h1 class="list-heading">{{ trans('entities.books_edit') }}</h1>
|
||||
<form action="{{ $book->getUrl() }}" method="POST" enctype="multipart/form-data">
|
||||
<input type="hidden" name="_method" value="PUT">
|
||||
@include('books.form', ['model' => $book])
|
||||
</form>
|
||||
</div>
|
||||
</main>
|
||||
</div>
|
||||
@stop
|
@ -11,9 +11,9 @@
|
||||
</div>
|
||||
|
||||
<div class="form-group" collapsible id="logo-control">
|
||||
<div class="collapse-title text-primary" collapsible-trigger>
|
||||
<label for="user-avatar">{{ trans('common.cover_image') }}</label>
|
||||
</div>
|
||||
<button type="button" class="collapse-title text-primary" collapsible-trigger aria-expanded="false">
|
||||
<label>{{ trans('common.cover_image') }}</label>
|
||||
</button>
|
||||
<div class="collapse-content" collapsible-content>
|
||||
<p class="small">{{ trans('common.cover_image_description') }}</p>
|
||||
|
||||
@ -27,9 +27,9 @@
|
||||
</div>
|
||||
|
||||
<div class="form-group" collapsible id="tags-control">
|
||||
<div class="collapse-title text-primary" collapsible-trigger>
|
||||
<button type="button" class="collapse-title text-primary" collapsible-trigger aria-expanded="false">
|
||||
<label for="tag-manager">{{ trans('entities.book_tags') }}</label>
|
||||
</div>
|
||||
</button>
|
||||
<div class="collapse-content" collapsible-content>
|
||||
@include('components.tag-manager', ['entity' => isset($book)?$book:null, 'entityType' => 'chapter'])
|
||||
</div>
|
||||
|
@ -1,5 +1,5 @@
|
||||
|
||||
<div class="content-wrap mt-m card">
|
||||
<main class="content-wrap mt-m card">
|
||||
<div class="grid half v-center no-row-gap">
|
||||
<h1 class="list-heading">{{ trans('entities.books') }}</h1>
|
||||
<div class="text-m-right my-m">
|
||||
@ -31,4 +31,4 @@
|
||||
<a href="{{ url("/create-book") }}" class="text-pos">@icon('edit'){{ trans('entities.create_now') }}</a>
|
||||
@endif
|
||||
@endif
|
||||
</div>
|
||||
</main>
|
@ -14,10 +14,10 @@
|
||||
]])
|
||||
</div>
|
||||
|
||||
<div class="card content-wrap">
|
||||
<main class="card content-wrap">
|
||||
<h1 class="list-heading">{{ trans('entities.books_permissions') }}</h1>
|
||||
@include('form.entity-permissions', ['model' => $book])
|
||||
</div>
|
||||
</main>
|
||||
</div>
|
||||
|
||||
@stop
|
||||
|
@ -14,7 +14,7 @@
|
||||
]])
|
||||
</div>
|
||||
|
||||
<div class="content-wrap card">
|
||||
<main class="content-wrap card">
|
||||
<h1 class="break-text" v-pre>{{$book->name}}</h1>
|
||||
<div class="book-content" v-show="!searching">
|
||||
<p class="text-muted" v-pre>{!! nl2br(e($book->description)) !!}</p>
|
||||
@ -53,7 +53,7 @@
|
||||
</div>
|
||||
|
||||
@include('partials.entity-dashboard-search-results')
|
||||
</div>
|
||||
</main>
|
||||
|
||||
@stop
|
||||
|
||||
|
@ -35,12 +35,12 @@
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<div class="card content-wrap">
|
||||
<main class="card content-wrap">
|
||||
<h2 class="list-heading mb-m">{{ trans('entities.books_sort_show_other') }}</h2>
|
||||
|
||||
@include('components.entity-selector', ['name' => 'books_list', 'selectorSize' => 'compact', 'entityTypes' => 'book', 'entityPermission' => 'update', 'showAdd' => true])
|
||||
|
||||
</div>
|
||||
</main>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
@ -13,12 +13,12 @@
|
||||
]])
|
||||
</div>
|
||||
|
||||
<div class="content-wrap card">
|
||||
<main class="content-wrap card">
|
||||
<h1 class="list-heading">{{ trans('entities.chapters_create') }}</h1>
|
||||
<form action="{{ $book->getUrl('/create-chapter') }}" method="POST">
|
||||
@include('chapters.form')
|
||||
</form>
|
||||
</div>
|
||||
</main>
|
||||
|
||||
</div>
|
||||
@stop
|
@ -15,13 +15,13 @@
|
||||
]])
|
||||
</div>
|
||||
|
||||
<div class="content-wrap card">
|
||||
<main class="content-wrap card">
|
||||
<h1 class="list-heading">{{ trans('entities.chapters_edit') }}</h1>
|
||||
<form action="{{ $chapter->getUrl() }}" method="POST">
|
||||
<input type="hidden" name="_method" value="PUT">
|
||||
@include('chapters.form', ['model' => $chapter])
|
||||
</form>
|
||||
</div>
|
||||
</main>
|
||||
|
||||
</div>
|
||||
|
||||
|
@ -12,9 +12,9 @@
|
||||
</div>
|
||||
|
||||
<div class="form-group" collapsible id="logo-control">
|
||||
<div class="collapse-title text-primary" collapsible-trigger>
|
||||
<label for="user-avatar">{{ trans('entities.chapter_tags') }}</label>
|
||||
</div>
|
||||
<button type="button" class="collapse-title text-primary" collapsible-trigger aria-expanded="false">
|
||||
<label for="tags">{{ trans('entities.chapter_tags') }}</label>
|
||||
</button>
|
||||
<div class="collapse-content" collapsible-content>
|
||||
@include('components.tag-manager', ['entity' => isset($chapter)?$chapter:null, 'entityType' => 'chapter'])
|
||||
</div>
|
||||
|
@ -15,7 +15,7 @@
|
||||
]])
|
||||
</div>
|
||||
|
||||
<div class="card content-wrap">
|
||||
<main class="card content-wrap">
|
||||
<h1 class="list-heading">{{ trans('entities.chapters_move') }}</h1>
|
||||
|
||||
<form action="{{ $chapter->getUrl('/move') }}" method="POST">
|
||||
@ -31,7 +31,7 @@
|
||||
</div>
|
||||
</form>
|
||||
|
||||
</div>
|
||||
</main>
|
||||
|
||||
|
||||
|
||||
|
@ -15,10 +15,10 @@
|
||||
]])
|
||||
</div>
|
||||
|
||||
<div class="card content-wrap">
|
||||
<main class="card content-wrap">
|
||||
<h1 class="list-heading">{{ trans('entities.chapters_permissions') }}</h1>
|
||||
@include('form.entity-permissions', ['model' => $chapter])
|
||||
</div>
|
||||
</main>
|
||||
</div>
|
||||
|
||||
@stop
|
||||
|
@ -15,7 +15,7 @@
|
||||
]])
|
||||
</div>
|
||||
|
||||
<div class="content-wrap card">
|
||||
<main class="content-wrap card">
|
||||
<h1 class="break-text" v-pre>{{ $chapter->name }}</h1>
|
||||
<div class="chapter-content" v-show="!searching">
|
||||
<p v-pre class="text-muted break-text">{!! nl2br(e($chapter->description)) !!}</p>
|
||||
@ -50,7 +50,7 @@
|
||||
</div>
|
||||
|
||||
@include('partials.entity-dashboard-search-results')
|
||||
</div>
|
||||
</main>
|
||||
|
||||
@stop
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
<div page-comments page-id="{{ $page->id }}" class="comments-list">
|
||||
<section page-comments page-id="{{ $page->id }}" class="comments-list" aria-label="{{ trans('entities.comments') }}">
|
||||
|
||||
@exposeTranslations([
|
||||
'entities.comment_updated_success',
|
||||
@ -34,4 +34,4 @@
|
||||
@endif
|
||||
@endif
|
||||
|
||||
</div>
|
||||
</section>
|
@ -15,7 +15,7 @@
|
||||
|
||||
<div class="header-search hide-under-l">
|
||||
@if (hasAppAccess())
|
||||
<form action="{{ url('/search') }}" method="GET" class="search-box">
|
||||
<form action="{{ url('/search') }}" method="GET" class="search-box" role="search">
|
||||
<button id="header-search-box-button" type="submit" aria-label="{{ trans('common.search') }}" tabindex="-1">@icon('search') </button>
|
||||
<input id="header-search-box-input" type="text" name="term"
|
||||
aria-label="{{ trans('common.search') }}" placeholder="{{ trans('common.search') }}"
|
||||
@ -25,7 +25,7 @@
|
||||
</div>
|
||||
|
||||
<div class="text-right">
|
||||
<div class="header-links">
|
||||
<nav class="header-links" >
|
||||
<div class="links text-center">
|
||||
@if (hasAppAccess())
|
||||
<a class="hide-over-l" href="{{ url('/search') }}">@icon('search'){{ trans('common.search') }}</a>
|
||||
@ -69,7 +69,7 @@
|
||||
</ul>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
</nav>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
@ -2,11 +2,11 @@
|
||||
|
||||
@section('body')
|
||||
<div class="mt-m">
|
||||
<div class="content-wrap card">
|
||||
<main class="content-wrap card">
|
||||
<div class="page-content" page-display="{{ $customHomepage->id }}">
|
||||
@include('pages.page-display', ['page' => $customHomepage])
|
||||
</div>
|
||||
</div>
|
||||
</main>
|
||||
</div>
|
||||
@stop
|
||||
|
||||
|
@ -8,8 +8,8 @@
|
||||
</div>
|
||||
<div class="text-center">
|
||||
|
||||
<input type="file" class="custom-file-input" accept="image/*" name="{{ $name }}" id="{{ $name }}">
|
||||
<label for="{{ $name }}" class="button outline">{{ trans('components.image_select_image') }}</label>
|
||||
<input type="file" class="hidden" accept="image/*" name="{{ $name }}" id="{{ $name }}">
|
||||
<input type="hidden" data-reset-input name="{{ $name }}_reset" value="true" disabled="disabled">
|
||||
@if(isset($removeName))
|
||||
<input type="hidden" data-remove-input name="{{ $removeName }}" value="{{ $removeValue }}" disabled="disabled">
|
||||
|
@ -2,19 +2,18 @@
|
||||
<div class="tags">
|
||||
<p class="text-muted small">{!! nl2br(e(trans('entities.tags_explain'))) !!}</p>
|
||||
|
||||
|
||||
<draggable :options="{handle: '.handle'}" :list="tags" element="div">
|
||||
<div v-for="(tag, i) in tags" :key="tag.key" class="card drag-card">
|
||||
<div class="handle" >@icon('grip')</div>
|
||||
<div>
|
||||
<autosuggest url="{{ url('/ajax/tags/suggest/names') }}" type="name" class="outline" :name="getTagFieldName(i, 'name')"
|
||||
v-model="tag.name" @input="tagChange(tag)" @blur="tagBlur(tag)" placeholder="{{ trans('entities.tag') }}"/>
|
||||
v-model="tag.name" @input="tagChange(tag)" @blur="tagBlur(tag)" placeholder="{{ trans('entities.tag_name') }}"/>
|
||||
</div>
|
||||
<div>
|
||||
<autosuggest url="{{ url('/ajax/tags/suggest/values') }}" type="value" class="outline" :name="getTagFieldName(i, 'value')"
|
||||
v-model="tag.value" @change="tagChange(tag)" @blur="tagBlur(tag)" placeholder="{{ trans('entities.tag_value') }}"/>
|
||||
</div>
|
||||
<div v-show="tags.length !== 1" class="text-center drag-card-action text-neg" @click="removeTag(tag)">@icon('close')</div>
|
||||
<button type="button" aria-label="{{ trans('entities.tags_remove') }}" v-show="tags.length !== 1" class="text-center drag-card-action text-neg" @click="removeTag(tag)">@icon('close')</button>
|
||||
</div>
|
||||
</draggable>
|
||||
|
||||
|
@ -29,9 +29,9 @@
|
||||
</div>
|
||||
|
||||
<div class="form-group" collapsible>
|
||||
<div class="collapse-title text-primary" collapsible-trigger>
|
||||
<button type="button" class="collapse-title text-primary" collapsible-trigger aria-expanded="false">
|
||||
<label for="entity_selection">{{ trans('entities.pages_copy_desination') }}</label>
|
||||
</div>
|
||||
</button>
|
||||
<div class="collapse-content" collapsible-content>
|
||||
@include('components.entity-selector', ['name' => 'entity_selection', 'selectorSize' => 'large', 'entityTypes' => 'book,chapter', 'entityPermission' => 'page-create'])
|
||||
</div>
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
@section('body')
|
||||
<div class="container small pt-xl">
|
||||
<div class="card content-wrap">
|
||||
<main class="card content-wrap">
|
||||
<h1 class="list-heading">{{ $title }}</h1>
|
||||
|
||||
<div class="book-contents">
|
||||
@ -12,6 +12,6 @@
|
||||
<div class="text-center">
|
||||
{!! $pages->links() !!}
|
||||
</div>
|
||||
</div>
|
||||
</main>
|
||||
</div>
|
||||
@stop
|
@ -15,7 +15,7 @@
|
||||
]])
|
||||
</div>
|
||||
|
||||
<div class="card content-wrap">
|
||||
<main class="card content-wrap">
|
||||
<h1 class="list-heading">{{ trans('entities.pages_new') }}</h1>
|
||||
<form action="{{ $parent->getUrl('/create-guest-page') }}" method="POST">
|
||||
{!! csrf_field() !!}
|
||||
@ -31,7 +31,7 @@
|
||||
</div>
|
||||
|
||||
</form>
|
||||
</div>
|
||||
</main>
|
||||
</div>
|
||||
|
||||
@stop
|
@ -16,7 +16,7 @@
|
||||
]])
|
||||
</div>
|
||||
|
||||
<div class="card content-wrap">
|
||||
<main class="card content-wrap">
|
||||
<h1 class="list-heading">{{ trans('entities.pages_move') }}</h1>
|
||||
|
||||
<form action="{{ $page->getUrl('/move') }}" method="POST">
|
||||
@ -31,7 +31,7 @@
|
||||
</div>
|
||||
</form>
|
||||
|
||||
</div>
|
||||
</main>
|
||||
</div>
|
||||
|
||||
@stop
|
||||
|
@ -16,10 +16,10 @@
|
||||
]])
|
||||
</div>
|
||||
|
||||
<div class="card content-wrap">
|
||||
<main class="card content-wrap">
|
||||
<h1 class="list-heading">{{ trans('entities.pages_permissions') }}</h1>
|
||||
@include('form.entity-permissions', ['model' => $page])
|
||||
</div>
|
||||
</main>
|
||||
</div>
|
||||
|
||||
@stop
|
||||
|
@ -25,10 +25,10 @@
|
||||
]])
|
||||
</div>
|
||||
|
||||
<div class="card content-wrap">
|
||||
<main class="card content-wrap">
|
||||
<div class="page-content page-revision">
|
||||
@include('pages.page-display')
|
||||
</div>
|
||||
</div>
|
||||
</main>
|
||||
|
||||
@stop
|
@ -15,7 +15,7 @@
|
||||
]])
|
||||
</div>
|
||||
|
||||
<div class="card content-wrap">
|
||||
<main class="card content-wrap">
|
||||
<h1 class="list-heading">{{ trans('entities.pages_revisions') }}</h1>
|
||||
@if(count($page->revisions) > 0)
|
||||
|
||||
@ -86,7 +86,7 @@
|
||||
@else
|
||||
<p>{{ trans('entities.pages_revisions_none') }}</p>
|
||||
@endif
|
||||
</div>
|
||||
</main>
|
||||
|
||||
</div>
|
||||
|
||||
|
@ -10,12 +10,12 @@
|
||||
]])
|
||||
</div>
|
||||
|
||||
<div class="content-wrap card">
|
||||
<main class="content-wrap card">
|
||||
<div class="page-content" page-display="{{ $page->id }}">
|
||||
@include('pages.pointer', ['page' => $page])
|
||||
@include('pages.page-display')
|
||||
</div>
|
||||
</div>
|
||||
</main>
|
||||
|
||||
@if ($commentsEnabled)
|
||||
<div class="container small p-none comments-container mb-l print-hidden">
|
||||
@ -50,7 +50,7 @@
|
||||
@endif
|
||||
|
||||
@if (isset($pageNav) && count($pageNav))
|
||||
<div id="page-navigation" class="mb-xl">
|
||||
<nav id="page-navigation" class="mb-xl" aria-label="{{ trans('entities.pages_navigation') }}">
|
||||
<h5>{{ trans('entities.pages_navigation') }}</h5>
|
||||
<div class="body">
|
||||
<div class="sidebar-page-nav menu">
|
||||
@ -62,7 +62,7 @@
|
||||
@endforeach
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</nav>
|
||||
@endif
|
||||
|
||||
@include('partials.book-tree', ['book' => $book, 'sidebarTree' => $sidebarTree])
|
||||
|
@ -1,4 +1,4 @@
|
||||
<div id="book-tree" class="book-tree mb-xl" v-pre>
|
||||
<nav id="book-tree" class="book-tree mb-xl" v-pre aria-label="{{ trans('entities.books_navigation') }}">
|
||||
<h5>{{ trans('entities.books_navigation') }}</h5>
|
||||
|
||||
<ul class="sidebar-page-list mt-xs menu entity-list">
|
||||
@ -29,4 +29,4 @@
|
||||
</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
</div>
|
||||
</nav>
|
@ -1,4 +1,4 @@
|
||||
<div class="breadcrumbs text-center">
|
||||
<nav class="breadcrumbs text-center" aria-label="{{ trans('common.breadcrumb') }}">
|
||||
<?php $breadcrumbCount = 0; ?>
|
||||
|
||||
{{-- Show top level books item --}}
|
||||
@ -51,4 +51,4 @@
|
||||
@endif
|
||||
<?php $breadcrumbCount++; ?>
|
||||
@endforeach
|
||||
</div>
|
||||
</nav>
|
@ -1,5 +1,5 @@
|
||||
<div class="mb-xl">
|
||||
<form v-on:submit.prevent="searchBook" class="search-box flexible">
|
||||
<form v-on:submit.prevent="searchBook" class="search-box flexible" role="search">
|
||||
<input v-model="searchTerm" v-on:change="checkSearchForm" type="text" aria-label="{{ trans('entities.books_search_this') }}" name="term" placeholder="{{ trans('entities.books_search_this') }}">
|
||||
<button type="submit" aria-label="{{ trans('common.search') }}">@icon('search')</button>
|
||||
<button v-if="searching" v-cloak class="search-box-cancel text-neg" v-on:click="clearSearch"
|
||||
|
@ -1,5 +1,5 @@
|
||||
|
||||
<div class="active-link-list">
|
||||
<nav class="active-link-list">
|
||||
@if($currentUser->can('settings-manage'))
|
||||
<a href="{{ url('/settings') }}" @if($selected == 'settings') class="active" @endif>@icon('settings'){{ trans('settings.settings') }}</a>
|
||||
<a href="{{ url('/settings/maintenance') }}" @if($selected == 'maintenance') class="active" @endif>@icon('spanner'){{ trans('settings.maint') }}</a>
|
||||
@ -10,4 +10,4 @@
|
||||
@if($currentUser->can('user-roles-manage'))
|
||||
<a href="{{ url('/settings/roles') }}" @if($selected == 'roles') class="active" @endif>@icon('lock-open'){{ trans('settings.roles') }}</a>
|
||||
@endif
|
||||
</div>
|
||||
</nav>
|
@ -17,12 +17,12 @@
|
||||
]])
|
||||
</div>
|
||||
|
||||
<div class="card content-wrap">
|
||||
<main class="card content-wrap">
|
||||
<h1 class="list-heading">{{ trans('entities.shelves_create') }}</h1>
|
||||
<form action="{{ url("/shelves") }}" method="POST" enctype="multipart/form-data">
|
||||
@include('shelves.form', ['shelf' => null, 'books' => $books])
|
||||
</form>
|
||||
</div>
|
||||
</main>
|
||||
|
||||
</div>
|
||||
|
||||
|
@ -14,13 +14,13 @@
|
||||
]])
|
||||
</div>
|
||||
|
||||
<div class="card content-wrap">
|
||||
<main class="card content-wrap">
|
||||
<h1 class="list-heading">{{ trans('entities.shelves_edit') }}</h1>
|
||||
<form action="{{ $shelf->getUrl() }}" method="POST" enctype="multipart/form-data">
|
||||
<input type="hidden" name="_method" value="PUT">
|
||||
@include('shelves.form', ['model' => $shelf])
|
||||
</form>
|
||||
</div>
|
||||
</main>
|
||||
</div>
|
||||
|
||||
@stop
|
@ -40,9 +40,9 @@
|
||||
|
||||
|
||||
<div class="form-group" collapsible id="logo-control">
|
||||
<div class="collapse-title text-primary" collapsible-trigger>
|
||||
<label for="user-avatar">{{ trans('common.cover_image') }}</label>
|
||||
</div>
|
||||
<button type="button" class="collapse-title text-primary" collapsible-trigger aria-expanded="false">
|
||||
<label>{{ trans('common.cover_image') }}</label>
|
||||
</button>
|
||||
<div class="collapse-content" collapsible-content>
|
||||
<p class="small">{{ trans('common.cover_image_description') }}</p>
|
||||
|
||||
@ -56,9 +56,9 @@
|
||||
</div>
|
||||
|
||||
<div class="form-group" collapsible id="tags-control">
|
||||
<div class="collapse-title text-primary" collapsible-trigger>
|
||||
<button type="button" class="collapse-title text-primary" collapsible-trigger aria-expanded="false">
|
||||
<label for="tag-manager">{{ trans('entities.shelf_tags') }}</label>
|
||||
</div>
|
||||
</button>
|
||||
<div class="collapse-content" collapsible-content>
|
||||
@include('components.tag-manager', ['entity' => $shelf ?? null, 'entityType' => 'bookshelf'])
|
||||
</div>
|
||||
|
@ -1,5 +1,5 @@
|
||||
|
||||
<div class="content-wrap mt-m card">
|
||||
<main class="content-wrap mt-m card">
|
||||
|
||||
<div class="grid half v-center">
|
||||
<h1 class="list-heading">{{ trans('entities.shelves') }}</h1>
|
||||
@ -35,4 +35,4 @@
|
||||
@endif
|
||||
@endif
|
||||
|
||||
</div>
|
||||
</main>
|
||||
|
@ -8,7 +8,7 @@
|
||||
]])
|
||||
</div>
|
||||
|
||||
<div class="card content-wrap">
|
||||
<main class="card content-wrap">
|
||||
<h1 class="break-text">{{$shelf->name}}</h1>
|
||||
<div class="book-content">
|
||||
<p class="text-muted">{!! nl2br(e($shelf->description)) !!}</p>
|
||||
@ -39,7 +39,7 @@
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
</main>
|
||||
|
||||
@stop
|
||||
|
||||
|
@ -18,9 +18,9 @@
|
||||
<div class="tri-layout-container" tri-layout @yield('container-attrs') >
|
||||
|
||||
<div class="tri-layout-left print-hidden pt-m" id="sidebar">
|
||||
<div class="tri-layout-left-contents">
|
||||
<aside class="tri-layout-left-contents">
|
||||
@yield('left')
|
||||
</div>
|
||||
</aside>
|
||||
</div>
|
||||
|
||||
<div class="@yield('body-wrap-classes') tri-layout-middle">
|
||||
@ -30,9 +30,9 @@
|
||||
</div>
|
||||
|
||||
<div class="tri-layout-right print-hidden pt-m">
|
||||
<div class="tri-layout-right-contents">
|
||||
<aside class="tri-layout-right-contents">
|
||||
@yield('right')
|
||||
</div>
|
||||
</aside>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
@ -8,7 +8,7 @@
|
||||
@include('settings.navbar', ['selected' => 'users'])
|
||||
</div>
|
||||
|
||||
<div class="card content-wrap">
|
||||
<main class="card content-wrap">
|
||||
<h1 class="list-heading">{{ trans('settings.users_add_new') }}</h1>
|
||||
|
||||
<form action="{{ url("/settings/users/create") }}" method="post">
|
||||
@ -25,7 +25,7 @@
|
||||
|
||||
</form>
|
||||
|
||||
</div>
|
||||
</main>
|
||||
</div>
|
||||
|
||||
@stop
|
||||
|
@ -7,7 +7,7 @@
|
||||
@include('settings.navbar', ['selected' => 'users'])
|
||||
</div>
|
||||
|
||||
<div class="card content-wrap">
|
||||
<section class="card content-wrap">
|
||||
<h1 class="list-heading">{{ $user->id === $currentUser->id ? trans('settings.users_edit_profile') : trans('settings.users_edit') }}</h1>
|
||||
<form action="{{ url("/settings/users/{$user->id}") }}" method="post" enctype="multipart/form-data">
|
||||
{!! csrf_field() !!}
|
||||
@ -61,29 +61,31 @@
|
||||
<button class="button" type="submit">{{ trans('common.save') }}</button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
@if($currentUser->id === $user->id && count($activeSocialDrivers) > 0)
|
||||
<div class="card content-wrap auto-height">
|
||||
<section class="card content-wrap auto-height">
|
||||
<h2 class="list-heading">{{ trans('settings.users_social_accounts') }}</h2>
|
||||
<p class="text-muted">{{ trans('settings.users_social_accounts_info') }}</p>
|
||||
<div class="container">
|
||||
<div class="grid third">
|
||||
@foreach($activeSocialDrivers as $driver => $enabled)
|
||||
<div class="text-center mb-m">
|
||||
<div>@icon('auth/'. $driver, ['style' => 'width: 56px;height: 56px;'])</div>
|
||||
<div role="presentation">@icon('auth/'. $driver, ['style' => 'width: 56px;height: 56px;'])</div>
|
||||
<div>
|
||||
@if($user->hasSocialAccount($driver))
|
||||
<a href="{{ url("/login/service/{$driver}/detach") }}" class="button small outline">{{ trans('settings.users_social_disconnect') }}</a>
|
||||
<a href="{{ url("/login/service/{$driver}/detach") }}" aria-label="{{ trans('settings.users_social_disconnect') }} - {{ $driver }}"
|
||||
class="button small outline">{{ trans('settings.users_social_disconnect') }}</a>
|
||||
@else
|
||||
<a href="{{ url("/login/service/{$driver}") }}" class="button small outline">{{ trans('settings.users_social_connect') }}</a>
|
||||
<a href="{{ url("/login/service/{$driver}") }}" aria-label="{{ trans('settings.users_social_connect') }} - {{ $driver }}"
|
||||
class="button small outline">{{ trans('settings.users_social_connect') }}</a>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
@endforeach
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
@endif
|
||||
</div>
|
||||
|
||||
|
@ -7,7 +7,7 @@
|
||||
@include('settings.navbar', ['selected' => 'users'])
|
||||
</div>
|
||||
|
||||
<div class="card content-wrap">
|
||||
<main class="card content-wrap">
|
||||
|
||||
<div class="grid right-focus v-center">
|
||||
<h1 class="list-heading">{{ trans('settings.users') }}</h1>
|
||||
@ -62,7 +62,7 @@
|
||||
<div>
|
||||
{{ $users->links() }}
|
||||
</div>
|
||||
</div>
|
||||
</main>
|
||||
|
||||
</div>
|
||||
|
||||
|
@ -7,14 +7,14 @@
|
||||
<div class="grid right-focus reverse-collapse">
|
||||
|
||||
<div>
|
||||
<div id="recent-user-activity" class="mb-xl">
|
||||
<section id="recent-user-activity" class="mb-xl">
|
||||
<h5>{{ trans('entities.recent_activity') }}</h5>
|
||||
@include('partials.activity-list', ['activity' => $activity])
|
||||
</div>
|
||||
</section>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<div class="card content-wrap auto-height">
|
||||
<section class="card content-wrap auto-height">
|
||||
<div class="grid half v-center">
|
||||
<div>
|
||||
<div class="mr-m float left">
|
||||
@ -54,9 +54,9 @@
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<div class="card content-wrap auto-height book-contents">
|
||||
<section class="card content-wrap auto-height book-contents">
|
||||
<h2 id="recent-pages" class="list-heading">
|
||||
{{ trans('entities.recently_created_pages') }}
|
||||
@if (count($recentlyCreated['pages']) > 0)
|
||||
@ -68,9 +68,9 @@
|
||||
@else
|
||||
<p class="text-muted">{{ trans('entities.profile_not_created_pages', ['userName' => $user->name]) }}</p>
|
||||
@endif
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<div class="card content-wrap auto-height book-contents">
|
||||
<section class="card content-wrap auto-height book-contents">
|
||||
<h2 id="recent-chapters" class="list-heading">
|
||||
{{ trans('entities.recently_created_chapters') }}
|
||||
@if (count($recentlyCreated['chapters']) > 0)
|
||||
@ -82,9 +82,9 @@
|
||||
@else
|
||||
<p class="text-muted">{{ trans('entities.profile_not_created_chapters', ['userName' => $user->name]) }}</p>
|
||||
@endif
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<div class="card content-wrap auto-height book-contents">
|
||||
<section class="card content-wrap auto-height book-contents">
|
||||
<h2 id="recent-books" class="list-heading">
|
||||
{{ trans('entities.recently_created_books') }}
|
||||
@if (count($recentlyCreated['books']) > 0)
|
||||
@ -96,9 +96,9 @@
|
||||
@else
|
||||
<p class="text-muted">{{ trans('entities.profile_not_created_books', ['userName' => $user->name]) }}</p>
|
||||
@endif
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<div class="card content-wrap auto-height book-contents">
|
||||
<section class="card content-wrap auto-height book-contents">
|
||||
<h2 id="recent-shelves" class="list-heading">
|
||||
{{ trans('entities.recently_created_shelves') }}
|
||||
@if (count($recentlyCreated['shelves']) > 0)
|
||||
@ -110,13 +110,11 @@
|
||||
@else
|
||||
<p class="text-muted">{{ trans('entities.profile_not_created_shelves', ['userName' => $user->name]) }}</p>
|
||||
@endif
|
||||
</div>
|
||||
</section>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
@stop
|
Loading…
Reference in New Issue
Block a user