Initial commit
This commit is contained in:
63
frontend/src/lib/components/widgets/TopRightCrinkle.svelte
Normal file
63
frontend/src/lib/components/widgets/TopRightCrinkle.svelte
Normal file
@@ -0,0 +1,63 @@
|
||||
<script lang="ts">
|
||||
export let brightColor = true
|
||||
export let edges = true,
|
||||
bigVersion = false,
|
||||
icon: string
|
||||
console.log("ICON WTFDOFJSIKDJ?", icon)
|
||||
//
|
||||
</script>
|
||||
|
||||
<div
|
||||
id="crinkle"
|
||||
class:bigVersion="{bigVersion}"
|
||||
>
|
||||
<div
|
||||
class="crinkle-background"
|
||||
class:brightColor="{brightColor}"
|
||||
>
|
||||
{#if $$slots.icon}
|
||||
<slot name="icon" />
|
||||
{:else}
|
||||
<img
|
||||
src="../../../media/{icon
|
||||
? icon
|
||||
: edges
|
||||
? brightColor
|
||||
? ''
|
||||
: 'topRightCrinkledDarkAndEdged'
|
||||
: brightColor
|
||||
? 'topRightCrinkleBrightAndUnedged'
|
||||
: 'topRightCrinkledDarkAndUnedged'}.svg"
|
||||
alt="crinkle"
|
||||
/>
|
||||
{/if}
|
||||
</div>
|
||||
<div class="action-container">
|
||||
<slot />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<style lang="less">
|
||||
#crinkle {
|
||||
height: calc(3rem - 2px);
|
||||
width: 3rem;
|
||||
margin-left: -3px;
|
||||
&.bigVersion {
|
||||
height: 72px;
|
||||
width: 72px;
|
||||
}
|
||||
.crinkle-background {
|
||||
position: relative;
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
overflow: visible;
|
||||
img {
|
||||
object-fit: cover;
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
}
|
||||
&.brightColor {
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
Reference in New Issue
Block a user