feat: Add optional gallery header image #3491
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request introduces a new feature for configurable header images in the gallery view, along with related UI and backend changes. The most important updates include adding new configuration options, updating the
RootConfig
class to handle these options, and modifying theAlbumsHeader.vue
component to reflect the new functionality.Backend Changes
gallery_header.php
migration file to enable or disable the header image, set its URL, and configure transparency and gradient options for the header bar. These changes allow for more customization of the gallery header.RootConfig
Class: Introduced new properties (header_image_url
,is_header_bar_transparent
, andis_header_bar_gradient
) and a private methodsetHeaderImageurl("")
to initialize these properties based on the new configuration settings. [1] [2]Frontend Changes
AlbumsHeader.vue
:Toolbar
component to dynamically apply styles based on the new transparency and gradient settings.<img>
element to display the header image if a URL is provided in the configuration.props
definition to include the new properties for header configuration.