]> BookStack Code Mirror - bookstack/log
bookstack
16 months agoMerge pull request #4850 from BookStackApp/table_improvements
Dan Brown [Sat, 17 Feb 2024 16:40:27 +0000 (16:40 +0000)]
Merge pull request #4850 from BookStackApp/table_improvements

Range of WYSIWYG Editor Table Handling Improvements

16 months agoTables: Added dynamic table header toggle 4850/head
Dan Brown [Sat, 17 Feb 2024 16:28:13 +0000 (16:28 +0000)]
Tables: Added dynamic table header toggle

Shows in table context toolbar when in the first row.

16 months agoTables: Added menu items to clear formatting and sizes
Dan Brown [Fri, 16 Feb 2024 14:38:30 +0000 (14:38 +0000)]
Tables: Added menu items to clear formatting and sizes

16 months agoTables: Added fix to ensure proper clear formatting on cell selections
Dan Brown [Thu, 15 Feb 2024 16:29:37 +0000 (16:29 +0000)]
Tables: Added fix to ensure proper clear formatting on cell selections

16 months agoTables: Updated selection style to avoid scroll overflow
Dan Brown [Thu, 15 Feb 2024 14:40:27 +0000 (14:40 +0000)]
Tables: Updated selection style to avoid scroll overflow

Fixes #4844

16 months agoUpdated tinymce from 6.7.2 to 6.8.3
Dan Brown [Thu, 15 Feb 2024 14:12:47 +0000 (14:12 +0000)]
Updated tinymce from 6.7.2 to 6.8.3

16 months agoMerge branch 'development' of github.com:BookStackApp/BookStack into development
Dan Brown [Wed, 14 Feb 2024 10:36:36 +0000 (10:36 +0000)]
Merge branch 'development' of github.com:BookStackApp/BookStack into development

16 months agoRTL: Fixed pagination not responding to RTL layout
Dan Brown [Wed, 14 Feb 2024 10:36:00 +0000 (10:36 +0000)]
RTL: Fixed pagination not responding to RTL layout

For #4808

16 months agoMerge pull request #4794 from BookStackApp/en_tweaks
Dan Brown [Tue, 13 Feb 2024 14:13:29 +0000 (14:13 +0000)]
Merge pull request #4794 from BookStackApp/en_tweaks

Text: Tweaks to EN text for consistency/readability

16 months agoHeader: Fixed mobile menu falling out of header
Dan Brown [Tue, 13 Feb 2024 14:00:34 +0000 (14:00 +0000)]
Header: Fixed mobile menu falling out of header

Changed button to be within-DOM rather than absolute positioned.
Also improves RTL handling by showing menu on the right side.

Fixes #4841

16 months agoMerge pull request #4827 from BookStackApp/query_revamp
Dan Brown [Sun, 11 Feb 2024 15:56:32 +0000 (15:56 +0000)]
Merge pull request #4827 from BookStackApp/query_revamp

Update of entity loading to be more efficient and avoid global addSelects

16 months agoQueries: Update API to align data with previous versions 4827/head
Dan Brown [Sun, 11 Feb 2024 15:42:37 +0000 (15:42 +0000)]
Queries: Update API to align data with previous versions

Ensures fields returned match API docs and previous versions of
BookStack where we were accidentally returning more fields than
expected.
Updates tests to cover many of these.
Also updated clockwork to ignore image requests for less noisy
debugging.
Also updated chapter page query to not be loading all page data, via new
query in PageQueries.

16 months agoQueries: Addressed failing test cases from recent changes
Dan Brown [Thu, 8 Feb 2024 17:18:03 +0000 (17:18 +0000)]
Queries: Addressed failing test cases from recent changes

16 months agoQueries: Updated old use-specific entity query classes
Dan Brown [Thu, 8 Feb 2024 16:39:59 +0000 (16:39 +0000)]
Queries: Updated old use-specific entity query classes

- Updated name to align, and differentate from new 'XQueries' clases.
- Removed old sketchy base class with app resolving workarounds, to a
  proper injection-based approach.
- Also fixed wrong translation text used in PageQueries.

16 months agoQueries: Moved out or removed some class-level items
Dan Brown [Wed, 7 Feb 2024 22:41:45 +0000 (22:41 +0000)]
Queries: Moved out or removed some class-level items

Also ran auto-removal of unused imports across app folder.

16 months agoQueries: Extracted static page,chapter,shelf queries to classes
Dan Brown [Wed, 7 Feb 2024 21:58:27 +0000 (21:58 +0000)]
Queries: Extracted static page,chapter,shelf queries to classes

16 months agoQueries: Updated all app book static query uses
Dan Brown [Wed, 7 Feb 2024 16:37:36 +0000 (16:37 +0000)]
Queries: Updated all app book static query uses

16 months agoQueries: Migrated revision repo queries to new class
Dan Brown [Wed, 7 Feb 2024 15:09:16 +0000 (15:09 +0000)]
Queries: Migrated revision repo queries to new class

16 months agoQueries: Extracted PageRepo queries to own class
Dan Brown [Mon, 5 Feb 2024 17:35:49 +0000 (17:35 +0000)]
Queries: Extracted PageRepo queries to own class

Started new class for PageRevisions too as part of these changes

16 months agoQueries: Extracted chapter repo queries to class
Dan Brown [Mon, 5 Feb 2024 15:59:20 +0000 (15:59 +0000)]
Queries: Extracted chapter repo queries to class

Updated query classes to align to interface for common aligned
operations.
Extracted repeated string-identifier-based finding from page/chapter
repos to shared higher-level entity queries.

16 months agoMerge pull request #4828 from shashinma/development
Dan Brown [Mon, 5 Feb 2024 11:54:32 +0000 (11:54 +0000)]
Merge pull request #4828 from shashinma/development

Update PWA manifest orientation from 'portrait' to 'any'

16 months agoUpdate PWA manifest orientation to any 4828/head
Mikhail Shashin [Mon, 5 Feb 2024 01:28:22 +0000 (04:28 +0300)]
Update PWA manifest orientation to any

Changed the orientation settings in PwaManifestBuilder.php from 'portrait' to 'any'. This allows the PWA to adjust to any screen orientation, enhancing user flexibility.

16 months agoQueries: Migrated bookshelf repo queries to new class
Dan Brown [Sun, 4 Feb 2024 19:32:19 +0000 (19:32 +0000)]
Queries: Migrated bookshelf repo queries to new class

16 months agoQueries: Migrated BookRepo queries to new query class
Dan Brown [Sun, 4 Feb 2024 17:35:16 +0000 (17:35 +0000)]
Queries: Migrated BookRepo queries to new query class

Also moved to a non-static approach, and added a high-level class to
allow easy access to all other entity queries, for use in mixed-entity
scenarios and easier/simpler injection.

16 months agoDB: Started update of entity loading to avoid global selects
Dan Brown [Sun, 4 Feb 2024 14:39:01 +0000 (14:39 +0000)]
DB: Started update of entity loading to avoid global selects

Removes page/chpater addSelect global query, to load book slug, and
instead extracts base queries to be managed in new static class, while
updating specific entitiy relation loading to use our more efficient
MixedEntityListLoader where appropriate.

Related to #4823

17 months agoPlonker Remediation: Removed dd line left in from debugging
Dan Brown [Thu, 1 Feb 2024 12:57:26 +0000 (12:57 +0000)]
Plonker Remediation: Removed dd line left in from debugging

17 months agoMerge branch 'chapter-templates' into development
Dan Brown [Thu, 1 Feb 2024 12:55:38 +0000 (12:55 +0000)]
Merge branch 'chapter-templates' into development

17 months agoDefault chapter templates: Added tests, extracted repo logic
Dan Brown [Thu, 1 Feb 2024 12:51:47 +0000 (12:51 +0000)]
Default chapter templates: Added tests, extracted repo logic

- Updated existing book tests to be generic to all default templates,
  and updated with chapter testing.
- Extracted repeated logic in the Book/Chapter repos to be shared in the
  BaseRepo.

Review of #4750

17 months agoDefault chapter templates: Updated api docs and tests
Dan Brown [Thu, 1 Feb 2024 12:22:16 +0000 (12:22 +0000)]
Default chapter templates: Updated api docs and tests

Also applied minor tweaks to some wording and logic.

During review of #4750

17 months agoMerge pull request #4815 from BookStackApp/comment_wysiwyg
Dan Brown [Wed, 31 Jan 2024 16:57:36 +0000 (16:57 +0000)]
Merge pull request #4815 from BookStackApp/comment_wysiwyg

Comment WYSIWYG Inputs

17 months agoComments: Added HTML filter test, fixed placeholder in dark mode 4815/head
Dan Brown [Wed, 31 Jan 2024 16:47:58 +0000 (16:47 +0000)]
Comments: Added HTML filter test, fixed placeholder in dark mode

17 months agoComments: Removed remaining uses of redundant 'text' field
Dan Brown [Wed, 31 Jan 2024 16:35:58 +0000 (16:35 +0000)]
Comments: Removed remaining uses of redundant 'text' field

Opened #4821 to remove the DB field in a few releases time.

17 months agoComments: Added HTML filter on load, tinymce elem filtering
Dan Brown [Wed, 31 Jan 2024 16:20:22 +0000 (16:20 +0000)]
Comments: Added HTML filter on load, tinymce elem filtering

- Added filter on load to help prevent potentially dangerous comment
  HTML in DB at load time (if it gets passed input filtering, or is
  existing).
- Added TinyMCE valid_elements for input wysiwygs, to gracefully degrade
  content at point of user-view, rather than surprising the user by
  stripping content, which TinyMCE would show, post-save.

17 months agoComments: Added wysiwyg link selector, updated tests, removed command
Dan Brown [Wed, 31 Jan 2024 14:22:04 +0000 (14:22 +0000)]
Comments: Added wysiwyg link selector, updated tests, removed command

- Updated existing tests with recent back-end changes, mainly to use
  HTML data.
- Removed old comment regen command that's no longer required.

17 months agoComments: Added back-end HTML support, fixed editor focus
Dan Brown [Tue, 30 Jan 2024 15:16:58 +0000 (15:16 +0000)]
Comments: Added back-end HTML support, fixed editor focus

Also fixed handling of editors when moved in DOM, to properly remove
then re-init before & after move to avoid issues.

17 months agoComments: Added input wysiwyg for creating/updating comments
Dan Brown [Tue, 30 Jan 2024 14:27:09 +0000 (14:27 +0000)]
Comments: Added input wysiwyg for creating/updating comments

Not supporting old content, existing HTML or updating yet.

17 months agoWYSIWYG: Altered how custom head added to editors
Dan Brown [Tue, 30 Jan 2024 11:38:47 +0000 (11:38 +0000)]
WYSIWYG: Altered how custom head added to editors

Updated to parse and add as DOM nodes instead of innerHTML to avoid
triggering an update of all head content, which would throw warnings in
chromium in regard to setting the base URI.

For #4814

17 months agoadded template to chapter API controller 4750/head
Sascha [Mon, 29 Jan 2024 18:59:03 +0000 (19:59 +0100)]
added template to chapter API controller

17 months agoextraded template form to own file and changed translations
Sascha [Mon, 29 Jan 2024 18:55:39 +0000 (19:55 +0100)]
extraded template form to own file and changed translations

17 months agoUpdate entities.php
Sascha [Mon, 29 Jan 2024 18:37:59 +0000 (19:37 +0100)]
Update entities.php

changed text of `pages_delete_warning_template` to include chapters

17 months agoMerge pull request #4804 from BookStackApp/oidc_pkce
Dan Brown [Sat, 27 Jan 2024 18:11:19 +0000 (18:11 +0000)]
Merge pull request #4804 from BookStackApp/oidc_pkce

Add OIDC PKCE functionality

17 months agoOIDC: Added testing of PKCE flow 4804/head
Dan Brown [Sat, 27 Jan 2024 16:41:15 +0000 (16:41 +0000)]
OIDC: Added testing of PKCE flow

Also compared full flow to RFC spec during this process

17 months agoOIDC: Added PKCE functionality
Dan Brown [Thu, 25 Jan 2024 14:24:46 +0000 (14:24 +0000)]
OIDC: Added PKCE functionality

Related to #4734.
Uses core logic from League AbstractProvider.

17 months agoMerge pull request #4796 from BookStackApp/v23-12
Dan Brown [Wed, 24 Jan 2024 10:38:14 +0000 (10:38 +0000)]
Merge pull request #4796 from BookStackApp/v23-12

Merge in v23.12.2 changes

17 months agoDependancies: Updated PHP deps via composer 4796/head
Dan Brown [Wed, 24 Jan 2024 10:27:09 +0000 (10:27 +0000)]
Dependancies: Updated PHP deps via composer

17 months agoUpdated translator attribution before v23.12.2 release
Dan Brown [Wed, 24 Jan 2024 10:25:24 +0000 (10:25 +0000)]
Updated translator attribution before v23.12.2 release

17 months agoMerged l10n_development into v23-12
Dan Brown [Wed, 24 Jan 2024 10:22:13 +0000 (10:22 +0000)]
Merged l10n_development into v23-12

Squash merge
Closes #4779

17 months agofixed error from phpcs
Sascha [Tue, 23 Jan 2024 21:37:15 +0000 (22:37 +0100)]
fixed error from phpcs

17 months agoUpdate TrashCan.php
Sascha [Tue, 23 Jan 2024 20:37:00 +0000 (21:37 +0100)]
Update TrashCan.php

remove duplicate call of $page->forceDelete();

17 months agoEntity selector: Fixed initial load overwriting initial search
Dan Brown [Tue, 23 Jan 2024 15:39:09 +0000 (15:39 +0000)]
Entity selector: Fixed initial load overwriting initial search

This changes how initial searches can be handled via config rather than
specific action so they can be considered in how the initial data load
is done, to prevent the default empty state loading and overwriting the
search data if it lands later (which was commonly likely).

For #4778

17 months agoAttachment List: Fixed broken ctrl-click functionality
Dan Brown [Tue, 23 Jan 2024 15:01:07 +0000 (15:01 +0000)]
Attachment List: Fixed broken ctrl-click functionality

Fixes #4782

17 months agoText: Tweaks to EN text for consistency/readability 4794/head
Dan Brown [Tue, 23 Jan 2024 12:31:44 +0000 (12:31 +0000)]
Text: Tweaks to EN text for consistency/readability

As suggested by Tim in discord chat.

17 months agoMerge pull request #4758 from BookStackApp/range_request_support
Dan Brown [Wed, 17 Jan 2024 11:10:38 +0000 (11:10 +0000)]
Merge pull request #4758 from BookStackApp/range_request_support

Range request support

17 months agoMerge branch 'development' of github.com:BookStackApp/BookStack into development
Dan Brown [Tue, 16 Jan 2024 12:14:44 +0000 (12:14 +0000)]
Merge branch 'development' of github.com:BookStackApp/BookStack into development

17 months agoUpdated translator attribution
Dan Brown [Tue, 16 Jan 2024 12:14:25 +0000 (12:14 +0000)]
Updated translator attribution

17 months agoUpdated translations with latest Crowdin changes (#4747)
Dan Brown [Tue, 16 Jan 2024 12:10:22 +0000 (12:10 +0000)]
Updated translations with latest Crowdin changes (#4747)

17 months agoChapters API: Added missing book_slug field
Dan Brown [Tue, 16 Jan 2024 12:06:13 +0000 (12:06 +0000)]
Chapters API: Added missing book_slug field

Was removed during previous changes, but reflected in response examples.
This adds into all standard single chapter responses.
For #4765

17 months agoUploads: Explicitly disabled s3 streaming in config 4758/head
Dan Brown [Mon, 15 Jan 2024 13:36:04 +0000 (13:36 +0000)]
Uploads: Explicitly disabled s3 streaming in config

This was the default option anyway, just adding here for
better visibility of this being set.
Can't enable without issues as the app will attempt to seek which does
not work for these streams. Also have not tested on non-s3, s3-like
systems.

17 months agoAttachments: Drag and drop video support
Dan Brown [Mon, 15 Jan 2024 11:50:05 +0000 (11:50 +0000)]
Attachments: Drag and drop video support

Supports dragging and dropping video attahchments to embed them in the
editor as HTML video tags.

17 months agoRange requests: Added test cases to cover functionality
Dan Brown [Sun, 14 Jan 2024 15:50:00 +0000 (15:50 +0000)]
Range requests: Added test cases to cover functionality

Fixed some found issues in the process.

17 months agoReadme: Updates sponsor list
Dan Brown [Wed, 10 Jan 2024 14:33:49 +0000 (14:33 +0000)]
Readme: Updates sponsor list

17 months agoRange requests: Added basic HTTP range support
Dan Brown [Sun, 7 Jan 2024 20:34:03 +0000 (20:34 +0000)]
Range requests: Added basic HTTP range support

17 months agoRange requests: Extracted stream output handling to new class
Dan Brown [Sun, 7 Jan 2024 14:03:13 +0000 (14:03 +0000)]
Range requests: Extracted stream output handling to new class

18 months agoAdded Default Templates for Chapters
Sascha [Mon, 1 Jan 2024 20:58:49 +0000 (21:58 +0100)]
Added Default Templates for Chapters

18 months agoUpdated translator attribution before release v23.12
Dan Brown [Fri, 29 Dec 2023 12:08:39 +0000 (12:08 +0000)]
Updated translator attribution before release v23.12

18 months agoUpdated translations with latest Crowdin changes (#4658)
Dan Brown [Thu, 28 Dec 2023 17:49:38 +0000 (17:49 +0000)]
Updated translations with latest Crowdin changes (#4658)

18 months agoLanguages: Added Finnish to language list
Dan Brown [Thu, 28 Dec 2023 15:24:51 +0000 (15:24 +0000)]
Languages: Added Finnish to language list

18 months agoPermissions: Updated generation querying to be more efficient
Dan Brown [Sat, 23 Dec 2023 13:35:57 +0000 (13:35 +0000)]
Permissions: Updated generation querying to be more efficient

Query of existing entity permissions during view permission generation
could cause timeouts or SQL placeholder limits due to massive whereOr
query generation, where an "or where" clause would be created for each
entity type/id combo involved, which could be all within 20 books.

This updates the query handling to use a query per type involved, with
no "or where"s, and to be chunked at large entity counts.

Also tweaked role-specific permission regen to chunk books at
half-previous rate to prevent such a large scope being involved on each
chunk.

For #4695

18 months agoDeps: Updated php depenencies via composer
Dan Brown [Fri, 22 Dec 2023 15:48:46 +0000 (15:48 +0000)]
Deps: Updated php depenencies via composer

18 months agoMerge pull request #4729 from BookStackApp/description_wysiwyg
Dan Brown [Fri, 22 Dec 2023 15:28:13 +0000 (15:28 +0000)]
Merge pull request #4729 from BookStackApp/description_wysiwyg

Simple WYSIWYG for description fields and comments

18 months agoInput WYSIWYG: Fixed up some dark mode elements 4729/head
Dan Brown [Fri, 22 Dec 2023 15:16:06 +0000 (15:16 +0000)]
Input WYSIWYG: Fixed up some dark mode elements

18 months agoInput WYSIWYG: Updated exports to handle HTML descriptions
Dan Brown [Fri, 22 Dec 2023 14:57:20 +0000 (14:57 +0000)]
Input WYSIWYG: Updated exports to handle HTML descriptions

18 months agoInput WYSIWYG: Updated API examples to align with changes
Dan Brown [Fri, 22 Dec 2023 14:37:48 +0000 (14:37 +0000)]
Input WYSIWYG: Updated API examples to align with changes

18 months agoInput WYSIWYG: Updated API testing, fixed description set issue
Dan Brown [Fri, 22 Dec 2023 13:17:23 +0000 (13:17 +0000)]
Input WYSIWYG: Updated API testing, fixed description set issue

Fixed issue where an existing description_html field would not be
updated via 'description' input.

18 months agoInput WYSIWYG: Updated API to show/accept html descriptions
Dan Brown [Thu, 21 Dec 2023 13:23:52 +0000 (13:23 +0000)]
Input WYSIWYG: Updated API to show/accept html descriptions

Also aligned books, shelves and chapters to return description content
and some relations (where not breaking API) in create/update responses
also so that information can be seen direct from that input in a
request.

API docs and tests not yet updated to match.

18 months agoInput WYSIWYG: Aligned newline handling with old descriptions
Dan Brown [Wed, 20 Dec 2023 17:40:58 +0000 (17:40 +0000)]
Input WYSIWYG: Aligned newline handling with old descriptions

To ensure consistenent behaviour before/after changes.
Added tests to cover.

18 months agoInput WYSIWYG: Fixed existing tests, fixed empty description handling
Dan Brown [Wed, 20 Dec 2023 17:21:09 +0000 (17:21 +0000)]
Input WYSIWYG: Fixed existing tests, fixed empty description handling

18 months agoInput WYSIWYG: Updated tests, Added simple html limiting
Dan Brown [Tue, 19 Dec 2023 15:10:29 +0000 (15:10 +0000)]
Input WYSIWYG: Updated tests, Added simple html limiting

18 months agoInput WYSIWYG: Added testing for description references
Dan Brown [Tue, 19 Dec 2023 12:55:51 +0000 (12:55 +0000)]
Input WYSIWYG: Added testing for description references

18 months agoInput WYSIWYG: Added dynamic options for entity selector popups
Dan Brown [Tue, 19 Dec 2023 12:09:57 +0000 (12:09 +0000)]
Input WYSIWYG: Added dynamic options for entity selector popups

So that multiple elements on the page can share the same popup, with
different search options.

18 months agoInput WYSIWYG: Updated UpdateUrlCommand, Added chapter HTML display
Dan Brown [Mon, 18 Dec 2023 18:31:16 +0000 (18:31 +0000)]
Input WYSIWYG: Updated UpdateUrlCommand, Added chapter HTML display

18 months agoInput WYSIWYG: Updated reference link updating for descriptions
Dan Brown [Mon, 18 Dec 2023 18:12:36 +0000 (18:12 +0000)]
Input WYSIWYG: Updated reference link updating for descriptions

18 months agoInput WYSIWYG: Added reference store & fetch handling
Dan Brown [Mon, 18 Dec 2023 16:23:40 +0000 (16:23 +0000)]
Input WYSIWYG: Added reference store & fetch handling

For book, shelves and chapters.
Made much of the existing handling generic to entity types.
Added new MixedEntityListLoader to help load lists somewhat efficiently.
Only manually tested so far.

18 months agoInput WYSIWYG: Added description_html field, added store logic
Dan Brown [Sun, 17 Dec 2023 15:02:15 +0000 (15:02 +0000)]
Input WYSIWYG: Added description_html field, added store logic

Rolled out HTML editor field and store logic across all target entity
types. Cleaned up WYSIWYG input logic and design.
Cleaned up some injected classes while there.

18 months agoInput WYSIWYG: Added compontent and rough logic to book form
Dan Brown [Sat, 16 Dec 2023 14:48:35 +0000 (14:48 +0000)]
Input WYSIWYG: Added compontent and rough logic to book form

Just as a draft for prototyping and playing around to get things
started.

18 months agoMerge pull request #4728 from BookStackApp/friendlier_buttons
Dan Brown [Sat, 16 Dec 2023 14:04:57 +0000 (14:04 +0000)]
Merge pull request #4728 from BookStackApp/friendlier_buttons

Design: Updated buttons to be a bit friendlier

18 months agoDesign: Updated buttons to be a bit friendlier 4728/head
Dan Brown [Sat, 16 Dec 2023 14:03:12 +0000 (14:03 +0000)]
Design: Updated buttons to be a bit friendlier

Old all-caps button design made them a bit angry, and kinda odd and
outdated. This updates them to use their original source text casing
(which may help for translation variations) while being a bit rounder
with a better defined shadow for outline buttons.

18 months agoMerge pull request #4727 from BookStackApp/editor_video_alignment
Dan Brown [Sat, 16 Dec 2023 12:32:52 +0000 (12:32 +0000)]
Merge pull request #4727 from BookStackApp/editor_video_alignment

WYSWIYG: Allowed video/embed alignment controls

18 months agoWYSWIYG: Allowed video/embed alignment controls 4727/head
Dan Brown [Sat, 16 Dec 2023 12:22:40 +0000 (12:22 +0000)]
WYSWIYG: Allowed video/embed alignment controls

Required a lot of working around TinyMCE since it added a
preview/wrapper element in the editor which complicates things.
Added view new "fixes.js" file so large hacks to default TinyMCe
functionality are kept in one place.

18 months agoUsers API: Fixed sending invite when using form requests
Dan Brown [Wed, 13 Dec 2023 15:11:42 +0000 (15:11 +0000)]
Users API: Fixed sending invite when using form requests

- Cast send_invite value in cases where it might not have been a boolean,
  which occurs on non-JSON requests.
- Added test to cover.
- Updated API docs to mention and shown boolean usage.

18 months agoMerge pull request #4721 from BookStackApp/default-templates
Dan Brown [Tue, 12 Dec 2023 16:06:35 +0000 (16:06 +0000)]
Merge pull request #4721 from BookStackApp/default-templates

Continued: Default book templates

18 months agoDefault templates: Fixed syntax for php8.0, added test 4721/head
Dan Brown [Tue, 12 Dec 2023 15:59:12 +0000 (15:59 +0000)]
Default templates: Fixed syntax for php8.0, added test

Null accessor is akward in php8.0 and throws warnings, so removed.
Added test to check template assingment handling on page delete.

18 months agoDefault templates: Added permission checks to selector test
Dan Brown [Tue, 12 Dec 2023 15:41:56 +0000 (15:41 +0000)]
Default templates: Added permission checks to selector test

18 months agoDefault templates: Cleaned up ux, added case for added endpoint
Dan Brown [Tue, 12 Dec 2023 15:38:09 +0000 (15:38 +0000)]
Default templates: Cleaned up ux, added case for added endpoint

Cleaned up and updated page picker a bit, allowing longer names to show,
clicking through to item without triggering popup, and updated to use
hidden attributes instead of styles.

Added phpunit tests to cover supporting entity-selector-templates
endpoint.

18 months agoDefault templates: Added tests to cover functionality
Dan Brown [Tue, 12 Dec 2023 15:04:40 +0000 (15:04 +0000)]
Default templates: Added tests to cover functionality

Included new helper in Test PermissionProvider to set app to public,
since that's a common test scenario.

18 months agoPage Templates: Changed template field name, added API support
Dan Brown [Tue, 12 Dec 2023 12:14:00 +0000 (12:14 +0000)]
Page Templates: Changed template field name, added API support

18 months agoDefault templates: Added page picker and working forms
Dan Brown [Mon, 11 Dec 2023 15:55:43 +0000 (15:55 +0000)]
Default templates: Added page picker and working forms

- Adapted existing page picker to be usable elsewhere.
- Added endpoint for getting templates for entity picker.
- Added search template filter to support above.
- Updated book save handling to check/validate submitted template.
  - Allows non-visible pages to flow through the save process, if not
    being changed.
- Updated page deletes to handle removal of default usage on books.
- Tweaked wording and form styles to suit.
- Updated migration to explicity reflect default value.

18 months agoDefault Templates: Started review and updates from PR code
Dan Brown [Mon, 11 Dec 2023 12:33:20 +0000 (12:33 +0000)]
Default Templates: Started review and updates from PR code

18 months agoMerge branch 'development' into default-templates
Dan Brown [Mon, 11 Dec 2023 11:41:43 +0000 (11:41 +0000)]
Merge branch 'development' into default-templates

18 months agoPHPStan: Fixed larastan loading and address some level2 issues
Dan Brown [Sun, 10 Dec 2023 14:58:05 +0000 (14:58 +0000)]
PHPStan: Fixed larastan loading and address some level2 issues