38 lines
759 B
Svelte
38 lines
759 B
Svelte
<style lang="scss">
|
|
.badge {
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
min-height: 16px;
|
|
margin: 0 auto;
|
|
padding: 0 6px;
|
|
text-align: center;
|
|
background: $color-secondary-light;
|
|
font-weight: 500;
|
|
text-transform: uppercase;
|
|
letter-spacing: 1px;
|
|
line-height: 1;
|
|
color: $color-primary-darker;
|
|
border-radius: 100vh;
|
|
|
|
// Small size
|
|
&--small {
|
|
font-size: rem(7px);
|
|
}
|
|
}
|
|
</style>
|
|
|
|
<script lang="ts">
|
|
let {
|
|
text,
|
|
size = 'small',
|
|
}: {
|
|
text: string
|
|
size?: string
|
|
} = $props()
|
|
</script>
|
|
|
|
<div class="badge badge--{size}">
|
|
<span>{text}</span>
|
|
</div>
|