Checkpoint

This commit is contained in:
Antonio Scandurra 2023-10-05 15:34:57 +02:00
parent 2e056e9b0b
commit f3560caf93
3 changed files with 4 additions and 4 deletions

View file

@ -72,7 +72,7 @@ impl<S: Send + Sync + 'static> Element for Img<S> {
.now_or_never()
.and_then(ResultExt::log_err)
{
let corner_radii = style.corner_radii.to_pixels(bounds, cx.rem_size());
let corner_radii = style.corner_radii.to_pixels(bounds.size, cx.rem_size());
cx.paint_image(bounds, corner_radii, order, data, self.grayscale)?;
} else {
cx.spawn(|_, mut cx| async move {

View file

@ -138,7 +138,7 @@ vertex ShadowVertexOutput shadow_vertex(
bounds.size.width += 2. * margin;
bounds.size.height += 2. * margin;
float4 device_position = to_device_position(unit_vertex, bounds, bounds, viewport_size);
float4 device_position = to_device_position(unit_vertex, bounds, shadow.content_mask.bounds, viewport_size);
float4 color = hsla_to_rgba(shadow.color);
return ShadowVertexOutput {

View file

@ -227,8 +227,8 @@ pub trait StyleHelpers: Styled<Style = Style> {
{
self.declared_style().box_shadow = Some(BoxShadow {
color: hsla(0., 0., 0., 1.),
offset: point(px(0.), px(0.)),
blur_radius: px(1.),
offset: point(px(0.), px(1.)),
blur_radius: px(2.),
spread_radius: px(0.),
});
self