Commit 64aac104 authored by David Trattnig's avatar David Trattnig
Browse files

Make avatar link optional

parent cfdd8a58
Pipeline #1796 passed with stages
in 7 minutes and 42 seconds
......@@ -10,7 +10,6 @@
</script>
<style lang="scss">
.card-media-overlay {
background-color: var(--mdc-theme-on-secondary);
border: 0;
......@@ -33,12 +32,26 @@
.card-media-overlay * {
margin: 0;
}
</style>
<template>
<Card class="aura-card host">
<PrimaryAction on:click={openLink(urlHostDetail + host.id)}>
{#if urlHostDetail}
<PrimaryAction on:click={openLink(urlHostDetail + host.id)}>
<Media
class="card-media-square mdc-card--outlined host-avatar"
aspectRatio="square"
style={host.image ? 'background-image:url(' + host.image + ');' : ''}>
{#if displayOverlay == true}
<div class="card-media-overlay">
<span class="name mdc-typography--headline6">
<Display value={host.name} {renderhtml} />
</span>
</div>
{/if}
</Media>
</PrimaryAction>
{:else}
<Media
class="card-media-square mdc-card--outlined host-avatar"
aspectRatio="square"
......@@ -51,6 +64,6 @@
</div>
{/if}
</Media>
</PrimaryAction>
{/if}
</Card>
</template>
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment