Repository navigation
nmc/7006-incorrect-audio-file-icon-in-search-result - #534
Open
suet-kei-chan wants to merge 1 commit into
Open
suet-kei-chan wants to merge 1 commit into
suet-kei-chan wants to merge 1 commit into
Conversation
In the unified search modal, audio files (e.g. .mp3) were displayed with the folder icon on dev/pre/prod instead of their mimetype icon. Core adds the `result-item__icon--no-preview` class to every result that has no thumbnail. The theme applied the blue folder icon with `!important` to both `.icon-folder` and `--no-preview`, which overrode the inline mimetype icon set by core for any file without a preview. Locally this was hidden because `OC\Preview\MP3` was enabled in `enabledPreviewProviders`, so MP3 files had a thumbnail. On environments without that provider, MP3s (and any other file type without preview support) fell back to `--no-preview` and showed the folder icon. Restrict the folder background image to `.icon-folder` only, while keeping the shared 42px sizing and positioning for `--no-preview` items so files without previews render their correct mimetype icon. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
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.
In the unified search modal, audio files (e.g. .mp3) were displayed with the folder icon on dev/pre/prod instead of their mimetype icon.
Core adds the
result-item__icon--no-previewclass to every result that has no thumbnail. The theme applied the blue folder icon with!importantto both.icon-folderand--no-preview, which overrode the inline mimetype icon set by core for any file without a preview.Locally this was hidden because
OC\Preview\MP3was enabled inenabledPreviewProviders, so MP3 files had a thumbnail. On environments without that provider, MP3s (and any other file type without preview support) fell back to--no-previewand showed the folder icon.Restrict the folder background image to
.icon-folderonly, while keeping the shared 42px sizing and positioning for--no-previewitems so files without previews render their correct mimetype icon.