Media Gallery
Available since Hyvä CMS 1.3.0
The Media Gallery is included with Hyvä CMS 1.3.0, including image references that follow asset IDs. The gallery package has its own version and is installed as a CMS dependency.
Use Magento's picker instead
To disable the Hyvä gallery picker, set Stores → Configuration → Hyvä Commerce → Hyvä CMS → Media Gallery → Enable Media Gallery Picker in Live View to No. The included package remains installed.
The new Media Gallery gives you one place to find, organise and select images. It uses Magento's media assets, so images stay available to the native gallery and other Magento features.
Installation and Upgrade
Upgrading to CMS 1.3.0 installs hyva-themes/commerce-module-media-gallery as a dependency. Complete Magento's normal schema, DI, cache and static-content deployment, including the CMS admin styles step. Projects using individual Git repositories must make the gallery repository available to Composer before upgrading.
The gallery requires Hyvä Commerce and CMS. Review the Hyva_MediaGallery::media role resource and its view, upload, save, delete, folder save and folder delete permissions. Keep cron running for Trash retention.
Requirements
The gallery requires Magento's enhanced Media Gallery and its database asset index. The legacy filesystem gallery alone is not sufficient: images need records in media_gallery_asset, with an asset ID that the picker and CMS can reference.
Under Stores → Configuration → Advanced → System → Media Gallery, set Enable Old Media Gallery to No, save and refresh the invalidated cache. Ensure the media.gallery.synchronization and media.content.synchronization queue consumers run for initial synchronization. See Adobe's Media Gallery setup instructions.
If files exist on disk but are absent from the gallery, check synchronization before uploading duplicates.
The Hyvä picker is controlled separately by Stores → Configuration → Hyvä Commerce → Hyvä CMS → Media Gallery → Enable Media Gallery Picker in Live View. Turning this off uses Magento's default picker; it does not configure or synchronize the enhanced gallery.
Open the Gallery
Select an image field in the Liveview Editor to open the gallery picker.
Find and Select Images
Use All images, Recents, Favourites or the folder tree to find an asset. Search by title, path or keywords, and switch between grid and list views. Filters narrow results by file type, dimensions and file size. The possible-duplicates filter finds matching sizes and dimensions; it does not prove that images are identical.
Open an image's details to inspect its metadata and usage, copy its URL or download it. Star frequently used assets for later. Favourites, recent assets, expanded folders and the view choice are saved for your admin user. Library preferences let you reopen the last folder or always start in a chosen folder.
For library multi-selection, use Ctrl-click or Cmd-click, Shift-click for a range, or drag across empty grid space. Ctrl+A or Cmd+A selects the loaded items, rather than every image in an unbounded result list.
Upload and Organise
Drag files from your desktop into the gallery to upload them to the current folder. Folder creation follows Magento's allowed media roots; uploads from Root go to wysiwyg.
Drag selected images onto a folder to move them. Right-click an image or folder for its available actions. The selection bar supports moving images, adding keywords and deleting a selection. Actions depend on your admin role.
Images selected through the gallery are referenced by their database asset ID. Moving or renaming an image, or reorganising its folders through the gallery, updates the stored path while preserving that ID. Hyvä CMS resolves the ID to the current path when rendering, so those references continue to work after the move.
Moving or renaming files still changes their URLs. Handwritten HTML, external links and other references that contain a literal URL may need updating. Move files through the gallery rather than directly on disk so the database stays in sync. Replace swaps the file at its existing path, keeping the URL; the replacement must have the same extension.
When Hyvä Image Editor is available, Edit opens it from the gallery. Saving uses the existing image-editor save and duplicate workflow.
Trash and Missing Images
Deleting from the gallery moves images to Trash after confirmation, with a warning when usage is found. Trashed images stop being available to content. Restore an image from Trash if it is still needed, or use Delete forever or Empty trash to remove it permanently.
The default retention is seven days, configured under Stores → Configuration → Hyvä Commerce → Hyvä CMS → Media Gallery. Magento cron performs the purge, so Trash is a temporary recovery option.
Picker Integration
A field can opt into multiple-image selection; the picker then collects images and applies an array when the user confirms. Ordinary image fields keep the single-image workflow. This does not make every image field accept an array automatically.
For extensions, toggle-image-select accepts isOpen, uid, fieldName, JSON fieldValue and optional multiple. The response remains editor-change, with a single image value or an image array according to that mode. Preserve the existing event contract when adding a custom picker caller.
The hyva.media.picker.extras layout container provides a neutral place for optional picker actions. AI image generation is supplied by the separate CMS AI integration and a configured image provider/worker; the gallery itself does not require AI. See AI tools and the admin style contract for companion integrations.