I have a question about how the “Resolve first asset” option works. It displays the first item in an asset list. It allows to display the thumbnail and/or the name of the image.
I personally use svg images and I think that the svg type is not considered a “valid” image for the PreviewMode because in preview in my content list, it only displays the name and not the image.
Do you think it’s possible to add the svg type as a valid image for the preview?
Maybe also the “type/svg” assets could have the “image” tag, I think that would make sense. But it might be complicated to generate the “image/small” “image/medium” etc tags.
Yes, I can make both I guess.
I saw that you had made a small update for the svg.
I don’t know exactly where in the code, but I think there is something missing related to the IsImage test for the svg. When I want to validate a field with an svg and the property “Must be Image” in the validation. The back considers that the svg is not an image.
For confirmation, in the httpPost of the asset (PostAsset), at the creation of the CreateAsset command and at the CheckAssetFileAsync, the mime type is image/svg+xml
Thats true, I have forgotten that.
Thanks a lot, I’ll test it tomorrow and I’ll tell you if I see another problem
Sorry, i forgot to confirm that all ok from my code for the svg in the list.
Thank you very much for your help.
This topic was automatically closed after 2 days. New replies are no longer allowed.