🚧 Make Button usable outside of the button.rs file

This commit is contained in:
2024-04-26 19:23:34 +02:00
parent dfe2761a3a
commit 3afed02aa8
2 changed files with 10 additions and 4 deletions

View File

@@ -77,7 +77,7 @@ pub struct ButtonProps {
children: Element, children: Element,
} }
fn Button(props: ButtonProps) -> Element { pub fn Button(props: ButtonProps) -> Element {
rsx! { rsx! {
style { {STYLE_SHEET} }, style { {STYLE_SHEET} },

View File

@@ -5,16 +5,22 @@
aspect-ratio: 3.5; aspect-ratio: 3.5;
border: $border-normal; border: $border-normal;
border-radius: $border-radius; border-radius: 5%;
color: get-color(greyscale, 0); color: get-color(greyscale, 0);
font-family: "Geist"; font-family: "Geist";
font-weight: bold; font-weight: bold;
// To center the inner svg
// TODO: Find a more efficient way to center
display: flex;
align-items: center;
justify-content: center;
svg { svg {
height: 100%; height: 85%;
width: 100%; width: 85%;
text { text {
font-size: 50; font-size: 50;