1
Fork 0

Ditch this component

This commit is contained in:
Korbs 2024-06-23 22:32:00 -04:00
parent 0e52338b1f
commit 8e12514f94
No known key found for this signature in database

View file

@ -1,58 +0,0 @@
---
const {
// Primary Options
Icon,
Link,
// Style
Color = "white",
Background = "#222222",
BorderColor = "#222222",
BorderWidth = "1px",
BorderRadius = "4px",
BackDrop,
// Optionals Options
Target = "_self",
Onclick = "null",
} = Astro.props
---
<a
href={Link}
target={Target}
onclick={Onclick}
class="generic-button"
style={
' color: ' + Color
+ '; background: ' + Background
+ '; border-color: ' + BorderColor
+ '; border-width: ' + BorderWidth
+ '; border-radius: ' + BorderRadius
+ '; backdrop-filter: ' + BackDrop
}
>
<slot/>
</a>
<style lang="scss" is:global define:vars={{ BorderRadius }}>
.generic-button {
display: flex;
align-items: center;
gap: 6px;
padding-right: 12px;
border-style: solid;
text-decoration: none;
max-width: max-content;
&:hover {
filter: brightness(0.75);
}
svg {
// background: rgba(255,255,255,0.1);
border-radius: var(--BorderRadius) 0px 0px var(--BorderRadius);
padding: 6px;
margin: -1px;
margin-left: 6px;
}
}
</style>