traxxx/assets/components/tile/network.vue

75 lines
1.2 KiB
Vue
Raw Normal View History

<template>
<a
:href="`/network/${network.slug}`"
:title="network.name"
class="tile"
2020-03-23 03:58:23 +00:00
:class="{ sfw }"
>
2020-01-05 02:02:02 +00:00
<img
:src="`/img/logos/${network.slug}/network.png`"
:alt="network.name"
class="logo"
2020-01-05 02:02:02 +00:00
>
</a>
</template>
<script>
2020-03-23 03:58:23 +00:00
function sfw() {
return this.$store.state.ui.sfw;
}
export default {
props: {
network: {
type: Object,
default: null,
},
},
2020-03-23 03:58:23 +00:00
computed: {
sfw,
},
};
</script>
<style lang="scss" scoped>
@import 'theme';
.tile {
height: 6rem;
2020-03-23 03:58:23 +00:00
background: var(--profile);
display: flex;
flex-shrink: 0;
flex-direction: column;
align-items: center;
box-sizing: border-box;
padding: .5rem 1rem;
box-shadow: 0 0 3px rgba(0, 0, 0, .25);
text-align: center;
}
.link {
text-decoration: none;
}
.logo {
width: 100%;
height: 100%;
color: $text;
display: flex;
align-items: center;
justify-content: center;
object-fit: contain;
font-size: 1rem;
font-weight: bold;
2020-03-23 04:01:31 +00:00
/* filter: $logo-highlight; */
}
.title {
2020-03-23 03:58:23 +00:00
color: var(--text);
height: 100%;
display: flex;
align-items: center;
margin: 0;
}
</style>