[Asset Preview] Persist folder preview image size per user (#3745)#1953
Open
xIrusux wants to merge 7 commits into
Open
[Asset Preview] Persist folder preview image size per user (#3745)#1953xIrusux wants to merge 7 commits into
xIrusux wants to merge 7 commits into
Conversation
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
… (#3745) The schema-diff API introspects the full DB and fails with "Unknown database type bit" on MariaDB; use addSql CREATE TABLE like the other Studio migrations. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Up to standards ✅🟢 Issues
|
| Category | Results |
|---|---|
| UnusedCode | 2 medium |
| BestPractice | 3 medium 1 minor |
| CodeStyle | 57 minor |
🟢 Metrics 27 complexity
Metric Results Complexity 27
NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.
…(#3745) Expected::once() returned null, violating the non-nullable FolderPreviewSettingRepositoryInterface::save() return type. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
Contributor
|
TBH, I’m not sure whether creating a separate database entity just for this setting is the best approach. Could we instead extend the user entity with something like uiSettings? This would give us more flexibility and allow us to store additional UI-related settings in the future. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.



What
Backend for pimcore/studio-ui-bundle#3745 — persist the asset folder Preview tab image-display size (small/large) per user + folder, so it survives logout/login instead of only living in the browser session.
Changes
Entity/Asset/FolderPreviewSetting(composite PKuser+assetFolderId,imageSize), created inInstaller+ migrationVersion20260715120000(rawCREATE TABLEto avoid the MariaDBbit-type schema-diff error).Asset/Repository/FolderPreviewSettingRepository(get by user+folder, upsert).Asset/Service/FolderPreviewSettingService— returns defaultsmallwhen unset, upserts on save; dispatches a pre-response event.Asset/Schema/FolderPreviewSettingDTO +Asset/Hydrator/...+Asset/Event/PreResponse/FolderPreviewSettingEvent.Asset/Controller/FolderPreviewSetting/:GET/PUT /assets/{folderId}/preview-setting, guarded with#[IsGranted(ASSETS)], fully OpenAPI-documented (+6 translation keys).Tests
Companion PR
feature/3745-persist-asset-preview-image-size-2026x).Notes
🤖 Generated with Claude Code