Open alexander-nitsche opened 1 year ago
This issue is related to Flow Framework's https://github.com/neos/flow-development-collection/issues/3073.
Added a second desired mapping .opus
=> audio/ogg
or audio/ogg; codecs=opus
.
Added the desired mapping update for file extension .flac
.
Is there an existing issue for this topic?
Description
1. File extension
.vtt
=>text/vtt
WebVTT seems to be on the way to become a web standard in HTML video subtitles [1]. Its mime type is "text/vtt", its file extension ".vtt". It is already included in other public mime type libraries like the node package "mime" [2].
[1] https://developer.mozilla.org/en-US/docs/Web/API/WebVTT_API [2] https://github.com/broofa/mime/blob/main/types/standard.js#L315
2. File extension
.opus
=>audio/ogg
oraudio/ogg; codecs=opus
The Opus audio codec was approved by the IETF in 2012 and seems to be a successor of MP3 and Vorbis and even AAC. Mostly included in the OGG container, its file extension is ".opus" and its mime type is generally "audio/ogg" and specifically "audio/ogg; codecs=opus" [1], both of which are approved via the native Javascript HTMLMediaElement.canPlayType method [2] of Chromium, Firefox and Vivaldi (at least the ones I checked). My first contact with this format was via the Debian 10 "Bullseye" Gnome app "Sound Recorder", which offered four audio formats: OGG Vorbis, OGG Opus, MP3 and FLAC.
[1] https://datatracker.ietf.org/doc/html/rfc7845#section-9 [2] https://developer.mozilla.org/en-US/docs/Web/API/HTMLMediaElement/canPlayType
3. File extension
.flac
=>audio/flac
instead of deprecatedaudio/x-flac
The FLAC codec is a lossless audio codec, widely supported by OSs, browsers [1] and listed by Mozilla as one of the common web audio codecs [2], including being free to use without any licensing fees. Its file extension is ".flac" and its mime type is "audio/flac" [3]. It was previously "audio/x-flac" which is considered deprecated now, and which does not work with the browsers HTMLMediaElement.canPlayType method, for example.
[1] https://caniuse.com/flac [2] https://developer.mozilla.org/en-US/docs/Web/Media/Formats/Audio_codecs#common_codecs [3] https://en.wikipedia.org/wiki/FLAC
Possible Solution
I suggest to add or update the mime types to the corresponding places [1][2], create related mime type icons [3][4] and database migrations similar to former icon migrations [5][6] in all maintained Neos CMS branches.
[1] https://github.com/neos/neos-development-collection/blob/8.3/Neos.Media/Resources/Public/IconSets/classic/catalog.json [2] https://github.com/neos/neos-development-collection/blob/8.3/Neos.Media/Resources/Public/IconSets/vivid/catalog.json [3] Neos.Media/Resources/Public/IconSets/classic/vtt.svg [4] Neos.Media/Resources/Public/IconSets/vivid/vtt.svg [5] https://github.com/neos/neos-development-collection/blob/8.3/Neos.Media/Migrations/Mysql/Version20200823164700.php [6] https://github.com/neos/neos-development-collection/blob/8.3/Neos.Media/Migrations/Postgresql/Version20200823164701.php