💄 Center and uppercase the content of the Register and Login buttons

This commit is contained in:
2024-03-10 10:42:02 +01:00
parent f52733d9a6
commit 0a4969e079
2 changed files with 6 additions and 10 deletions

View File

@@ -53,13 +53,11 @@ impl IconShape for RegisterText {
fn child_elements(&self) -> LazyNodes { fn child_elements(&self) -> LazyNodes {
rsx! { rsx! {
text { text {
x: "50%",
y: "50%", y: "50%",
"dominant-baseline": "middle", "dominant-baseline": "central",
"text-anchor": "middle",
"font-size": "50", "font-size": "50",
style: "fill: #ffffff", style: "fill: #ffffff",
"Register" "REGISTER"
} }
} }
} }
@@ -103,7 +101,7 @@ pub fn RegisterButton<'a>(cx: Scope<'a, ButtonProps>) -> Element<'a> {
struct LoginText; struct LoginText;
impl IconShape for LoginText { impl IconShape for LoginText {
fn view_box(&self) -> String { fn view_box(&self) -> String {
String::from("0 0 250 50") String::from("0 0 150 50")
} }
fn xmlns(&self) -> String { fn xmlns(&self) -> String {
String::from("http://www.w3.org/2000/svg") String::from("http://www.w3.org/2000/svg")
@@ -111,13 +109,11 @@ impl IconShape for LoginText {
fn child_elements(&self) -> LazyNodes { fn child_elements(&self) -> LazyNodes {
rsx! { rsx! {
text { text {
x: "50%",
y: "50%", y: "50%",
"dominant-baseline": "middle", "dominant-baseline": "central",
"text-anchor": "middle",
"font-size": "50", "font-size": "50",
style: "fill: #ffffff", style: "fill: #ffffff",
"Login" "LOGIN"
} }
} }
} }

View File

@@ -13,7 +13,7 @@
font-weight: bold; font-weight: bold;
svg { svg {
height: 100%; height: 60%;
width: 100%; width: 100%;
} }
} }