🐛 Fix not-centered AvatarSelector rendering issue
This commit is contained in:
@@ -35,21 +35,15 @@ pub fn AvatarSelector(cx: Scope) -> Element {
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
rect {
|
rect {
|
||||||
width: "90",
|
x: "10",
|
||||||
height: "90",
|
y: "10",
|
||||||
|
width: "80",
|
||||||
|
height: "80",
|
||||||
rx: "12",
|
rx: "12",
|
||||||
fill: "url('#avatar-gradient')",
|
fill: "url('#avatar-gradient')",
|
||||||
filter: "url('#avatar-shadow')",
|
filter: "url('#avatar-shadow')",
|
||||||
stroke: "grey",
|
stroke: "grey",
|
||||||
},
|
},
|
||||||
// rect {
|
|
||||||
// x: "7.5",
|
|
||||||
// y: "7.5",
|
|
||||||
// width: "75",
|
|
||||||
// height: "75",
|
|
||||||
// fill: "transparent",
|
|
||||||
// stroke: "grey",
|
|
||||||
// },
|
|
||||||
},
|
},
|
||||||
img {
|
img {
|
||||||
class: ClassName::PICTURE,
|
class: ClassName::PICTURE,
|
||||||
|
@@ -4,11 +4,14 @@
|
|||||||
aspect-ratio: 1;
|
aspect-ratio: 1;
|
||||||
|
|
||||||
.picture {
|
.picture {
|
||||||
|
$height: 65%;
|
||||||
|
$margin: calc(100% - $height) / 2;
|
||||||
|
|
||||||
position: absolute;
|
position: absolute;
|
||||||
height: 75%;
|
height: $height;
|
||||||
aspect-ratio: 1;
|
aspect-ratio: 1;
|
||||||
|
|
||||||
bottom: 17.5%;
|
top: $margin;
|
||||||
right: 18%;
|
right: $margin;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user