]> BookStack Code Mirror - website/commitdiff
Got site ready for v0.14
authorDan Brown <redacted>
Sun, 22 Jan 2017 11:42:14 +0000 (11:42 +0000)
committerDan Brown <redacted>
Sun, 22 Jan 2017 11:42:14 +0000 (11:42 +0000)
15 files changed:
.gitattributes
content/blog/beta-release-v0-14-0.md
content/docs/admin/cache-session-config.md
content/docs/admin/pdf-rendering.mdown [new file with mode: 0644]
content/docs/user/reusing-content.md
static/images/2017/01/bookstack-includes-popover.mp4 [new file with mode: 0644]
static/images/2017/01/language-selection.png [new file with mode: 0644]
static/images/blog-cover-images/logs-sean-tan.jpg [new file with mode: 0644]
static/images/docs/user/forcing-wysiwyg-ids.png [new file with mode: 0644]
themes/bookstack/layouts/_default/single.html
themes/bookstack/layouts/partials/menu_admin_docs.html
themes/bookstack/layouts/partials/menu_user_docs.html
themes/bookstack/sass/_text.scss
themes/bookstack/sass/styles.scss
themes/bookstack/static/js/script.js

index 18a14d2e876db90e94ed63098822b276d05c1ec0..3d6411025a8a86280986bf76ecb75b2211502209 100644 (file)
@@ -3,3 +3,4 @@
 *.gif filter=lfs diff=lfs merge=lfs -text
 *.woff filter=lfs diff=lfs merge=lfs -text
 *.woff2 filter=lfs diff=lfs merge=lfs -text
+*.mp4 filter=lfs diff=lfs merge=lfs -text
index ab8095a8e98d68447247ed2c47f8b8bfdff00dcf..b5dd27ec57b812dec8c692c019c9f2143d6f8d95 100644 (file)
@@ -4,7 +4,7 @@ tags = ["Releases"]
 title = "Beta Release v0.14.0"
 date = 2017-01-22T17:00:00Z
 author = "Dan Brown"
-image = "https://unsplash.com/photos/ivQeBMYXaTY"
+image = "/images/blog-cover-images/logs-sean-tan.jpg"
 description = "BookStack v0.14 released with multi language support, Page includes and many bugfixes"
 slug = "beta-release-v0-14-0"
 draft = false
@@ -17,22 +17,26 @@ The first release of 2017 is upon us with v0.14. Since the last release, back in
 
 ### Language Support
 
-All of the text used in BookStack has been moved into language-specific text files so different languages can be easily added. Thanks to some awesome members of the community much of BookStack has been translated to Franch and Brazillian Portuguese. There is also partial support for German. A default language can be set at an instance level by setting a `APP_LANG` variable to a specific language code. For example:
+All of the text used in BookStack has been moved into language-specific text files so different languages can be easily added. Thanks to some awesome members of the community much of BookStack has been translated to French and Brazillian Portuguese. There is also partial support for German. A default language can be set at an instance level by setting a `APP_LANG` variable to a specific language code. For example:
 
 ```
 APP_LANG=FR
+# OR
+APP_LANG=PT_BR
 ```
 
 In addition to the global language setting, Users can set their own language preference by changing the option found in the 'Edit Profile' screen:
 
-**INSERT IMAGE OF CHANGING LANGUAGE**
+![Changing BookStack user language](/images/2017/01/language-selection.png)
 
 
 Obviously this will not translate the content you write in BookStack but it goes a long way to opening up BookStack to non-english speakers. If you're interested in adding a language the [readme.md file](https://github.com/BookStackApp/BookStack#translations) has been updated with some details on how to do this.
 
+Please note that adding language support was quite a large effort so there is likely to be a few areas missing translations. Where there are no language translations english is used as a backup so you may see a mix of english and other languages until this stabilises.
+
 ### Page Include Tags
 
-A commonly request feature was being able to include pages and page content within other pages. This is now possible through the use of page include tags. **INSERT LINK TO DOCS ABOUT INCLUDE TAGS**
+A commonly request feature was being able to include pages and page content within other pages. This is now possible through the use of page include tags. Details of this can be [found in the docs here](/docs/user/reusing-page-content/).
 
 ### Full List of Features, Changes & Fixes
 
@@ -40,7 +44,7 @@ A commonly request feature was being able to include pages and page content with
 * French & Brazillian Portuguese languages added (Thanks to [sirgix](https://github.com/BookStackApp/BookStack/pull/274) and [NakaharaL](https://github.com/BookStackApp/BookStack/pull/279)).
 * Added support for page/page-content includes within other pages.
 * Added support for using the database to store the cache and session.
-* Added option to use WKHTMLtoPDF for improved PDF rendering.
+* Added option to use WKHTMLtoPDF for improved PDF rendering. [Details here](/docs/admin/pdf-rendering/).
 * Added auto-linking in the WYSIWYG editor.
 * Updated page nav to scale if only smaller headers are used.
 * Fixed bug causing offset first lines in code blocks when using the markdown editor.
@@ -51,7 +55,7 @@ A commonly request feature was being able to include pages and page content with
 * Increased testing coverage of social authentication methods.
 * Standardised breadcrumbs across BookStack views.
 * Refactored entity code and permissions code to be more efficient.
-* Updated LDAP config to allow a protocol to be defined which allows use of ldaps connections.
+* Updated LDAP config to allow a protocol to be defined which allows use of ldaps connections (Thanks to [fredericmohr](https://github.com/BookStackApp/BookStack/pull/236)).
 
 ### Next Steps
 
@@ -59,14 +63,12 @@ For the next release I want to focus some time on making sure BookStack is effic
 
 In terms of new features some additional import/export options are much needed so I hope to tackle a few of the outstanding requests for those.
 
-As a longer term idea I've been thinking about making BookStack JavaScript driven to be a VueJS single page application. To voice your opinion on this or to see the advantages/disadvantages you can [view the issue on GtHub here](https://github.com/BookStackApp/BookStack/issues/249).
+As a longer term idea I've been thinking about making BookStack JavaScript driven to be a VueJS single page application. To voice your opinion on this or to see the advantages/disadvantages you can [view the issue on GitHub here](https://github.com/BookStackApp/BookStack/issues/249).
 
 ### Other Updates
 
 As you may have noticed, The BookStack blog, website and docs have recently been updated and are now all stored in the single [BookStackApp/website](https://github.com/BookStackApp/website) repository and it's now generated using the [Hugo](https://gohugo.io/) static site generator. Additionally search has been added to the docs courtesy of [Algolia Docsearch](https://community.algolia.com/docsearch/).
 
-Once again, You can use the form below to sign up to recieve emails when the blog is updated with releases or news.
-
 ----
 
 <span style="font-size: 0.8em;opacity:0.8;">Header Image Credits: <a href="https://unsplash.com/@darkroomsg" target="_blank">Sean Tan</a></span>
index 12a088486f32f3c0e6afab029a2a8882f5999186..846d257c681a43be28ca401c0b853f01dd41c2e0 100644 (file)
@@ -7,6 +7,15 @@ type = "admin-docs"
 
 By default BookStack will use a file system cache that's storage in the `storage/framework` folder. This is also used to store user session data. Below are some alternative systems that can be used for caching & sessions.
 
+### Database
+
+As an easy alternative to using the filesystem, you can use the database to store the cache and session. The database setup for this is done when installing/updating BookStack so you simply need to set the following in your `.env` file:
+
+```
+CACHE_DRIVER=database
+SESSION_DRIVER=database
+```
+
 ### Memcached
 
 To use memcached for caching and/or sessions open up your `.env` file and find the `CACHE_DRIVER` & `SESSION_DRIVER` variables. By default these are both set to `file`. Change these variables to `memcached`. You will also need to add a variable to specify the memcached servers you are using. To do this add a variable named `MEMCACHED_SERVERS` to the `.env` file and set the value to be your memcached servers in the following format: `HOST:PORT:WEIGHT,HOST2:PORT:WEIGHT`. You can specify as many servers as you want. Their usage split will be determined by the weight given to them. Here are some examples of what the `.env` file should look like:
diff --git a/content/docs/admin/pdf-rendering.mdown b/content/docs/admin/pdf-rendering.mdown
new file mode 100644 (file)
index 0000000..18755f4
--- /dev/null
@@ -0,0 +1,21 @@
++++
+title = "PDF Rendering"
+description = "Using WKHTMLtoPDF to generate PDF's for better rendering"
+date = "2017-01-22"
+type = "admin-docs"
++++
+
+By default BookStack uses [Dompdf](https://github.com/dompdf/dompdf) to export pages as PDF documents. The benefit of using DomPDF is that it doesn't require any additional installation or setup but the rendering capabilities are somewhat limited.
+
+As an alternative you can use [wkhtmltopdf](http://wkhtmltopdf.org/) to generate PDF documents instead. wkhtmltopdf uses the Qt WebKit rendering engine to provide a more accurate overall result.
+
+### Using wkhtmltopdf
+
+Pre-compiled binaries for wkhtmltopdf can be found on the downloads page of [their website](http://wkhtmltopdf.org/downloads.html). BookStack will check for a file named `wkhtmltopdf` at the base folder of a BookStack install. If found it will use that to render PDF's. If that does not exist it will check for a `WKHTMLTOPDF` variable in the `.env` file. You can use this variable to set an alternate location to wkhtmltopdf:
+
+```
+# In .env file
+WKHTMLTOPDF=/home/user/bins/wkhtmltopdf
+```
+
+If neither of those exist Dompdf will be used instead.
\ No newline at end of file
index 3c0cd2bb35c4e6a904a0283db32ca239d1c84409..9f1ddb3210bcae7555641ed71956e85a7193bea0 100644 (file)
@@ -3,20 +3,23 @@ title = "Reusing Page Content"
 description = "How to use include tags to reuse pages and page content within other pages"
 date = "2017-01-22"
 type = "user-docs"
+slug = "reusing-page-content"
 +++
 
-Within BookStack you may find that you want to include the same block of content in multiple places. You could copy and paste that content into multiple pages but then, if that content need to be changed, you'd have to update it multiple times across different pages. Introduced in BookStack v0.14 is the ability to include other pages and to also include single blocks of content from other pages.
+Within BookStack you may find that you want to include the same block of content in multiple places. You could copy and paste that content into multiple pages but then, if that content needs to be changed, you'd have to update it multiple times across different pages. Introduced in BookStack v0.14 is the ability to include other pages and to also include single blocks of content from other pages.
+
+Note that the include behaviour is non-recursive so including will only work to a single level. This ensures performance and prevents users from breaking pages by creating include loops.
 
 ## Include Tags
 
 To include the content of a page within another you can used the following syntax:
 
-`{{@<page_id>}}` or `@{{<page_id>#<content_id>}}`
+`{{@page_id}}` or `@{{page_id#content_id}}`
 
 Here are some examples of this in use:
 
 * `{{@5}}` - Include all content from the page with and id of '5'.
-* `{{@10#bkmrk-copyright-year}}` - Include the content within the element with an id of `bkmrk-copyright-year` in the page with an id of '10'.
+* `{{@10#bkmrk-copyright-year}}` - Include the content within the element of id `bkmrk-copyright-year` in the page with an id of '10'.
 
 You simply enter that in the page editor and then, When the page is viewed, the content will be dynamically be fetched. This means you can update the referenced content and it will show the same changes on any page the content is included within.
 
@@ -26,9 +29,7 @@ Finding the id of a page can be difficult so a quick and easy way to find includ
 View a page with some content you want to re-use. Use your mouse to select some content and you will see a popup appear.
 By default this contains a direct link to that content. If you click the link icon on the left it will switch to show you the include tag for that content. Simply copy that and place it in another page. Remove the `#` and content id to include the whole content of the page instead of just a single block.
 
-SHOW IMAGE OF POPUP
-
-TODO: CHECK WHAT HAPPENS WHEN YOU INCLUDE THE CONTENT OF THE SAME PAGE.
+<video controls src="/images/2017/01/bookstack-includes-popover.mp4"></video>
 
 ## Forcing Content Id's
 
@@ -40,7 +41,7 @@ Due to the fact ID's can change it's recommended to force ID's on you content:
 
 In the WYSIWYG editor you can force an ID by going into the source code view and adding it manually:
 
-TODO: INSERT IMAGE
+![Forcing WYSIWYG Ids](/images/docs/user/forcing-wysiwyg-ids.png)
 
 #### Markdown Editor
 
@@ -48,9 +49,9 @@ In the markdown editor you can simply insert HTML with an ID to ensure it does n
 
 ```
 # Old Content
-Copyright BookStack enterprises 2017
+Copyright BookStack Enterprises 2017
 
 # Revised with ID
-<p id="include-copyright-text">Copytight BookStack enterprises 2017</p>
+<p id="include-copyright-text">Copyright BookStack Enterprises 2017</p>
 
 ```
diff --git a/static/images/2017/01/bookstack-includes-popover.mp4 b/static/images/2017/01/bookstack-includes-popover.mp4
new file mode 100644 (file)
index 0000000..d3cfaa9
--- /dev/null
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:31eb02a7666edcca4243eadf07bdd0227a1d5a7e5184119a21196f3e9174fc6b
+size 176893
diff --git a/static/images/2017/01/language-selection.png b/static/images/2017/01/language-selection.png
new file mode 100644 (file)
index 0000000..5158a49
--- /dev/null
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:bbcef13746cf6b4f50ad1d9613d178f93a98c46c446b89c5857b7da58655274c
+size 15319
diff --git a/static/images/blog-cover-images/logs-sean-tan.jpg b/static/images/blog-cover-images/logs-sean-tan.jpg
new file mode 100644 (file)
index 0000000..e7db593
--- /dev/null
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:8d70381c1a9000319b9102301ac98d7967b7ea2aa2b351b40ab398d553345d3a
+size 300157
diff --git a/static/images/docs/user/forcing-wysiwyg-ids.png b/static/images/docs/user/forcing-wysiwyg-ids.png
new file mode 100644 (file)
index 0000000..200f450
--- /dev/null
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:1f34cb586affe03ef6b6edb7e23b9487aa44095ad498826d28105e39cc3c588a
+size 81388
index 18f507fb3779a6adfef92a8a439576c3f14d92e7..fb4b963795de6117d640b2a550e0e154509a4b47 100644 (file)
@@ -5,7 +5,12 @@
   <div class="container">
     <div class="row">
       <div class="col-sm-6">
-        <h2 class="thin-margin">User Documentation</h2>
+        {{ if eq .Type "admin-docs" }}
+          <h2 class="thin-margin">Admin Documentation</h2>
+        {{end}}
+        {{ if eq .Type "user-docs" }}
+          <h2 class="thin-margin">User Documentation</h2>
+        {{end}}
       </div>
       <div class="col-sm-6">
         <div class="float right float-none-sm">
index 5d2378195fbad5f0fb666aead109039bcfd343f7..1dd5f361e66f4e6d2e6e487c0f0c81486ca4ca4f 100644 (file)
@@ -19,4 +19,5 @@
        <li><a href="/docs/admin/cache-session-config">Caching &amp; Sessions</a></li>
        <li><a href="/docs/admin/social-auth">Social Authentication</a></li>
        <li><a href="/docs/admin/ldap-auth">LDAP Authentication</a></li>
+       <li><a href="/docs/admin/pdf-rendering">PDF Rendering</a></li>
 </ul>
\ No newline at end of file
index c0095307102020a92aabc9858f4f8e462d2431a3..c7d9cc19618ad90f727344ff7e04e21ab1df4d7f 100644 (file)
@@ -4,3 +4,7 @@
        <li><a href="/docs/user/content-overview">Content Overview</a></li>
        <li><a href="/docs/user/organising-content">Organising Content</a></li>
 </ul>
+<h4>Advanced Features</h4>
+<ul>
+       <li><a href="/docs/user/reusing-page-content">Reusing Page Content</a></li>
+</ul>
\ No newline at end of file
index 75a0539b5c14345a3a855754f186b089fafbabb1..448056a8d880d9f9ea8a35b34c72cf8f01a1c382 100644 (file)
@@ -69,8 +69,7 @@ h1, h2, h3, h4 {
   position: relative;
   display: block;
   color: #555;
-  .subheader {
-    display: block;
+  .subheader, small {
     font-size: 0.5em;
     line-height: 1em;
     color: lighten($text-dark, 16%);
index 0b3cd7233ae77551a024b6681a1d9d6914d47f4b..5ee314d6a66ecc0bb46394c00c9b5759f04b9c5b 100644 (file)
@@ -91,7 +91,7 @@ header #menu-button {
 
 @include smaller-than($xl) {
   body header {
-    padding-top: $-xxl*2.2;
+    padding-top: $-xxl*1.7;
   }
   header .row.fix-mobile {
     top: 0;
@@ -239,10 +239,16 @@ input[type=text] {
       fill: $primary;
     }
   }
-  img {
+  img, video {
     border: 1px solid $primary;
     border-radius: 3px;
   }
+  video {
+    cursor: pointer;
+    margin: $-l auto;
+    display: block;
+    max-width: 100%;
+  }
 }
 
 .sidebar, .docs-index {
index 41f365f9f6a5ee1963b5dba06260a6b348e56db7..e5c7d2f588b65d039364518c25898ee2dc385c11 100644 (file)
@@ -18,4 +18,16 @@ menuButton.onclick = function(event) {
 document.body.onclick = function(event) {
     menuDropDown.className = menuDropDown.className.replace('showing', '');
     event.stopPropagation();
-};
\ No newline at end of file
+};
+
+
+// Handle video click to play
+let videos = document.querySelectorAll('video');
+for (var i = 0; i < videos.length; i++) {
+    videos[i].addEventListener('click', videoClick)
+}
+
+function videoClick() {
+    if (typeof InstallTrigger !== 'undefined') return;
+    this.paused ? this.play() : this.pause();
+}
\ No newline at end of file