New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Dataverse Theme + Widgets - Support SVG upload for Logo Image #2843
Comments
I confirmed this issue in the 4.2.3 branch (I'm on f641fe4). It says "The image could not be uploaded. Please try again with a jpeg, tiff, or png file.logo.svg"
Here's where it's controlled:
https://github.com/IQSS/dataverse/blob/v4.2.2/src/main/webapp/themeAndWidgetsFragment.xhtml#L50 |
By adding "svg" to the list (twice, on lines 50 and 54, which should be refactored), I'm able to upload an SVG file from http://wiki.greptilian.com/greptilian.com/logo.svg @mheppler @eaquigley @scolapasta is there any reason why we shouldn't allow SVG images in logos? |
From what I understand svg is a much more web-friendly format that tff, which Dataverse supports for logo uploads. |
@pdurbin I have nothing against SVG as a file type for logo. Might have been an oversight or something that by default wasn't part of the primefaces component. |
I just realized that while the SVG logo looks fine in the header the default logo appears in the cards: Header (SVG logo appears):Cards (no SVG logo, generic dataverse logo instead):Maybe this is why we don't support SVG? Not sure. @landreev might know what's going on with the cards. |
@bmckinney I don't think this issue is particularly high priority but maybe play around with the |
@bmckinney @pameyer and I discussed this today. It's an issue but not at all a high priority. Unassigning @bmckinney . |
To re-iterate, this isn't a blocker for us and is low priority. |
This relates to #3559. |
@pameyer heh. Since you removed the SBGrid label, can we close this? 😄 |
I realize this isn't a high priority but adding svg would be nice - from a web graphics standpoint. |
I took a quick pass at this last night to see if I could figure anything out and to try and understand more. It looks like imageio, which we use for converting these images to thumbnails in imagethumbconverter.java, does not support svg and that could be where it's falling over. :( https://github.com/jai-imageio/jai-imageio-core From our pom.xml: com.github.jai-imageio jai-imageio-core 1.3.1Note for us in the future if we ever decide to take this on is that we could investigate one that supports svg such as https://github.com/haraldk/TwelveMonkeys or take some completely different approach. Not sure of the tradeoffs for this. We'll leave this be for now. |
Minor suggestion - allow for SVG (in addition to PNG, JPEG) or another vector graphics format for logo image uploads.
The text was updated successfully, but these errors were encountered: