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
Support .scale-XYZ images on WASM #1780
Comments
I will try this |
@davidjohnoliver Is there already a built-in way to find out all available |
@MartinZikmund It's already implemented for the other platforms, you should be able to leverage the existing code: https://github.com/nventive/Uno/blob/5f7131f13b37a5a9809c5cac4b3208a13c549fd4/src/SourceGenerators/Uno.UI.Tasks/Assets/RetargetAssets.cs#L85
|
@davidjohnoliver I was thinking about this and need a confirmation :-) . In case of WASM, I cannot just list all the items in the This probably means I will have to create a build task (at the same level as |
@MartinZikmund Sure, it sounds like that approach should work. |
@davidjohnoliver I just thought about one thing - this could potentially be a breaking change if the user calls |
We're already using it for a bunch of stuff, specially css and script files... it shouldn't be a problem. |
@carldebilly Awesome, thanks! |
## PR Type What kind of change does this PR introduce? - Feature ## Description Add Cards samples ## PR Checklist Please check if your PR fulfills the following requirements: - [ ] Interface members are XML documented. - [ ] Existing XML documentation and comments have been updated. - [ ] Architecture documents have been updated. - [X] Tested on iOS. - [X] Tested on Wasm. (**See known issue below**) - [X] Tested on Android. - [X] Tested on UWP. - [X] Tested in both **Light** and **Dark** themes. **KNOWN ISSUE FOR WASM: unoplatform/uno#1780 Related work items: #190829
Implemented by #3694 |
What would you like to be added:
Currently images provided with multiple scales don't render on WASM at all:
For example with:
The rendered HTML contains just
Test.png
, although such image does not actually exist.This can be resolved using the
<img>
srcset
attribute, which allows us to specify multiple different scales for each image based on pixel density of the display.Why is this needed:
Scaling on all pixel densities.
For which Platform:
Anything else we need to know?
The text was updated successfully, but these errors were encountered: