2 categories = ["Releases"]
4 title = "BookStack Release v22.09"
5 date = 2022-09-08T11:30:00Z
7 image = "/images/blog-cover-images/sheep-mountain-luke-ellis-craven.jpg"
8 slug = "bookstack-release-v22-09"
12 The BookStack September release is here with a variety of desired features that build upon,
13 and enhance, existing BookStack systems. As usual, it also includes language updates
14 and a bunch of tweaks & fixes.
16 * [Release video overview](https://youtu.be/nK2FqQCP-Ms)
17 * [Update instructions](https://www.bookstackapp.com/docs/admin/updates)
18 * [GitHub release page](https://github.com/BookStackApp/BookStack/releases/tag/v22.09)
23 - **Security** - This release cycle contained a security release that added detail that's important to consider when BookStack content is used externally. See the [v22.07.3 post](/blog/bookstack-release-v22-07-3/) for more detail.
24 - **Revision Visibility** - This update fixes a permission disparity with revisions. Revision content has always been accessible to those with page-view permissions, but the links to the revisions list previously required page-edit permission to show. This has been aligned, which may mean page revision links may now show to those that did not previously see them.
25 - **Revision Limit Change** - The default, per-page, revision limit has been doubled from 50 to 100, to account for new system-content updates that may occur. If desired, you can [configure this to a custom value](/docs/admin/other-config/#revision-limit).
26 - **Reference Index** - New features have been added to track links between content in BookStack, which uses an internal reference index. Upon upgrade from an older BookStack version, this index will need to be rebuilt. This can be done with the ["Regenerate References" command](/docs/admin/commands/#regenerate-reference-index) or via the "Regenerate References" maintenance action within BookStack.
28 ### Page Content References
30 When you edit and save pages within the system, BookStack will now attempt to identify links
31 to other pages, chapters, books and shelves in the system.
32 A new element will show when viewing one of those items, reflecting a count of pages that link
33 to the currently viewed item:
35 
37 When clicked, this will take you to a new "References" view which lists the all pages
38 leading to the this current item:
40 
42 This new feature should help provide some insight to how content is interlinked within the system,
43 while also providing an index that we can use within BookStack's systems to make some operations more efficient.
45 When upgrading an existing BookStack instance, no references will be indexed until you start saving content.
46 To index and detect existing cross-content links, you can use the new "Regenerate References"
47 admin maintenance action:
49 
51 Alternatively, this action has also been added as a terminal command which
52 you can [find in our documentation here](/docs/admin/commands/#regenerate-reference-index).
54 ### Auto Link Updating
56 Making use of our new reference indexing system, as detailed above, BookStack will now
57 auto-update internal page links to shelves, books, chapters and other pages when those
58 items experience a change in URL.
60 BookStack already had a system to handle some changes, it would attempt to find pages using
61 their old URLs by looking up against page revisions, but this would not work for books, chapters & shelves
62 or for pages if revisions were deleted.
63 Now, upon changes to an item's URL, BookStack will lookup pages referencing that item and auto-update
64 such links to be current. This will be done in a fully transparent manner, with a revision
65 being logged for the change with a "System auto-update of internal links" changelog message.
66 To support this addition, the default per-page revision limit has increased from 50 to 100 entries.
68 There may still be some logical gaps that will produce old links, such as restoring an old page revision,
69 but this should handle most cases to ensure internal links stay current.
71 ### OIDC Group Sync Support
73 OIDC authentication was added to BookStack almost a year ago, as part of v21.10.
74 Since then I've been [taking feedback](https://github.com/BookStackApp/BookStack/issues/3004)
75 to understand how group syncing would operate. Within v22.09 we're putting that feedback
76 into action with the addition of OIDC group sync support.
78 To work with BookStack, your OIDC system will need to provide groups within the OIDC ID token
79 it provides back to BookStack. To support this in BookStack, we've added options to
80 define custom authentication request scopes (Needed for groups in some scenarios)
81 while also supporting accessing nested properties in the ID token JSON data.
83 Read the new ["Group Sync" section](/docs/admin/oidc-auth/#group-sync) of our OIDC documentation for more details.
85 ### New "Local (Secure - Restricted)" Image Storage Option
87 A long while ago we added a `local_secure` storage option for images which required user login
88 before serving an image, as a layer of access control.
89 This release takes this further with a `local_secure_restricted` storage option which
90 will check the user's permissions to access the item that an image was uploaded to.
91 This means that image file access for page images can be controlled by the page they're uploaded to, providing
92 a whole new layer of control for environments that need it.
94 This new option does have some caveats, mainly that it can introduce various logical scenarios
95 that cause image visibility anomalies, in cases where images are re-used across different permissions contexts.
97 [Find full details of this option in our docs](/docs/admin/upload-config/#local-secure---restricted).
99 ### "Page Include Parse" Logical Theme Event
101 Our [logical theme system](https://github.com/BookStackApp/BookStack/blob/development/dev/docs/logical-theme-system.md)
102 has received a new event to customise handling of the [page include system](/docs/user/reusing-page-content).
103 The page include system allows dynamic import of page content into the body of a page.
104 Using this event, you can now extensively customize the handling of page includes.
106 As an example, the below `functions.php` code would replace "dog" with "cat" in included content:
111 use BookStack\Entities\Models\Page;
112 use BookStack\Facades\Theme;
113 use BookStack\Theming\ThemeEvents;
115 Theme::listen(ThemeEvents::PAGE_INCLUDE_PARSE, function(string $tagReference, string $replacementHTML, Page $currentPage, ?Page $referencedPage) {
116 return str_replace('dog', 'cat', $replacementHTML);
120 Of course there are much more practical examples for this, such as defining fallback content or adding extra permission control.
122 Find the details of the event [in the source code here](https://github.com/BookStackApp/BookStack/blob/98aed794cc7272687720c4f4c42a4f540390c0af/app/Theming/ThemeEvents.php#L73-L86).
124 ### Visual Theme System - Export Template Partials
126 As part of v22.07.2 we added a couple of export-specific template files
127 that could be used with the [visual theme system](https://github.com/BookStackApp/BookStack/blob/development/dev/docs/visual-theme-system.md), found at:
129 - `layouts/parts/export-body-start.blade.php`
130 - `layouts/parts/export-body-end.blade.php`
132 These can be used to add custom HTML code to the start & end of the HTML content used for
133 HTML and PDF exports within BookStack.
135 As a usage example I published a video on the BookStack YouTube channel showing
136 how to leverage these new templates to add a custom header and footer
139 {{< yt 5bZ7zlNEphc >}}
143 This release of BookStack adds Romanian as an available language.
144 A massive thanks to Mihai Ochian (soulstorm19) on Crowdin for their amazing effort
145 of translating over 6k words in this release cycle to add this language.
147 As usual, a range of our existing languages have received updates from our terrific translators
148 since v22.07, so a big thanks to all listed below:
150 - Mihai Ochian (soulstorm19) - *Romanian*
151 - 10935336 - *Chinese Simplified*
152 - HeartCore - *German Informal; German*
153 - Ji-Hyeon Gim (PotatoGim) - *Korean*
154 - SmokingCrop - *Dutch*
156 - scureza - *Italian*
157 - pedromcsousa - *Portuguese*
158 - Statium - *Russian*
159 - Maciej Lebiest (Szwendacz) - *Polish*
160 - Alex Navarro (alex.n.navarro) - *Portuguese, Brazilian*
161 - Douradinho - *Portuguese*
162 - na3shkw - *Japanese*
163 - Éric Gaspar (erga) - *French*
164 - mcgong (GongMingCai) - *Chinese Simplified; Chinese Traditional*
169 For the next release cycle I'll probably re-focus back on the permission system, to start
170 development of the features intended on the related road-map item, such as an overhaul of
171 item-level permission management to be more intuitive.
173 We're approaching a milestone of 10k GitHub stars so there may be a minor detour to
174 celebrate that little achievement.
176 ### Full List of Changes
178 **Released in v22.09**
180 * Added cross-item link reference tracking & updating. ([#3656](https://github.com/BookStackApp/BookStack/pull/3656), [#3683](https://github.com/BookStackApp/BookStack/issues/3683), [#1969](https://github.com/BookStackApp/BookStack/issues/1969))
181 * Added OIDC group sync functionality. ([#3616](https://github.com/BookStackApp/BookStack/pull/3616), [#3004](https://github.com/BookStackApp/BookStack/issues/3004))
182 * Added reference view to shelves, chapters, books & pages. ([#2864](https://github.com/BookStackApp/BookStack/issues/2864))
183 * Added new `local_secure_restricted` image storage option. ([#3693](https://github.com/BookStackApp/BookStack/pull/3693))
184 * Added "page_include_parse" theme event. ([#3698](https://github.com/BookStackApp/BookStack/pull/3698))
185 * Updated API docs to add detail for the request format. ([#3652](https://github.com/BookStackApp/BookStack/issues/3652))
186 * Updated revision link visibility to show to users. ([#2946](https://github.com/BookStackApp/BookStack/issues/2946))
187 * Updated shelf naming to be consistent across system. ([#3553](https://github.com/BookStackApp/BookStack/issues/3553))
188 * Updated translations with latest Crowdin changes. ([#3643](https://github.com/BookStackApp/BookStack/pull/3643), [#3701](https://github.com/BookStackApp/BookStack/pull/3701))
189 * Updated role edit/create form with clarification upon image access permissions. ([#3688](https://github.com/BookStackApp/BookStack/issues/3688))
190 * Fixed dates not using the correct encoding on some systems. ([#3590](https://github.com/BookStackApp/BookStack/issues/3590))
191 * Fixed image delete button showing to those without permission to delete. ([#3697](https://github.com/BookStackApp/BookStack/issues/3697))
192 * Fixed incorrect comment counts on Chinese language options. ([#3554](https://github.com/BookStackApp/BookStack/issues/3554))
193 * Fixed list indentation when next to floated images. ([#3672](https://github.com/BookStackApp/BookStack/issues/3672))
194 * Fixed various RTL text interface issues. ([#3702](https://github.com/BookStackApp/BookStack/issues/3702))
195 * Fixed WYSIWYG drawing update not triggering draft save. ([#3682](https://github.com/BookStackApp/BookStack/issues/3682))
196 * Fixed some additional SVG-based script cases not being filtered. ([#3705](https://github.com/BookStackApp/BookStack/issues/3705))
198 **Released in v22.07.3**
200 * Added API documentation section to advise of content security. ([#3636](https://github.com/BookStackApp/BookStack/issues/3636))
201 * Updated Persian translations. Thanks to [@samadha56](https://github.com/BookStackApp/BookStack/pull/3639). ([#3639](https://github.com/BookStackApp/BookStack/pull/3639))
202 * Updated code block rendering to help prevent blank blocks on fresh cache. ([#3637](https://github.com/BookStackApp/BookStack/issues/3637))
203 * Updated HTML filtering to prevent SVG animate case. ([#3636](https://github.com/BookStackApp/BookStack/issues/3636))
204 * Updated translations with latest changes from Crowdin. ([#3635](https://github.com/BookStackApp/BookStack/pull/3635))
205 * Updated revision list view to help prevent system memory exhaustion. ([#3633](https://github.com/BookStackApp/BookStack/issues/3633))
206 * Fixed issue with permission checking prevent certain actions where permission should have allowed. ([#3632](https://github.com/BookStackApp/BookStack/pull/3632))
208 **Released in v22.07.2**
210 * Added body-start/end partials to export template, for easier export customization via the visual theme system. ([#3630](https://github.com/BookStackApp/BookStack/pull/3630))
211 * Added activity recording for revision delete/restore. ([#3628](https://github.com/BookStackApp/BookStack/issues/3628))
212 * Updated translations with latest changes from Crowdin. ([#3625](https://github.com/BookStackApp/BookStack/pull/3625))
213 * Updated user validation with sensible limit to name input. ([#3614](https://github.com/BookStackApp/BookStack/issues/3614))
214 * Fixed issue where activity type could not be selected in the audit log. ([#3623](https://github.com/BookStackApp/BookStack/issues/3623))
215 * Fixed possibility of breaking page load due to bad user language input. ([#3615](https://github.com/BookStackApp/BookStack/issues/3615))
217 **Released in v22.07.1**
219 * Fixed issue where old WYSIWYG editor code would be cached, preventing the editor from showing. ([#3611](https://github.com/BookStackApp/BookStack/issues/3611))
220 * Updated translations with latest Crowdin changes. ([#3605](https://github.com/BookStackApp/BookStack/pull/3605))
224 <span style="font-size: 0.8em;opacity:0.9;">Header Image Credits: <span>Photo by <a href="https://unsplash.com/@lukeelliscraven?utm_source=unsplash&utm_medium=referral&utm_content=creditCopyText">Luke Ellis-Craven</a> on <a href="https://unsplash.com/s/photos/sheep?utm_source=unsplash&utm_medium=referral&utm_content=creditCopyText">Unsplash</a></span></span>