mirror of
https://iceshrimp.dev/limepotato/jormungandr-bite.git
synced 2024-11-23 02:17:40 -07:00
wip
This commit is contained in:
parent
c32ca37376
commit
51eae4a86b
2 changed files with 17 additions and 10 deletions
|
@ -1,10 +0,0 @@
|
|||
<mk-file-type-icon>
|
||||
<template v-if="kind == 'image'">%fa:file-image%</template>
|
||||
<style lang="stylus" scoped>
|
||||
:scope
|
||||
display inline
|
||||
</style>
|
||||
<script lang="typescript">
|
||||
this.kind = this.opts.type.split('/')[0];
|
||||
</script>
|
||||
</mk-file-type-icon>
|
17
src/web/app/common/views/components/file-type-icon.vue
Normal file
17
src/web/app/common/views/components/file-type-icon.vue
Normal file
|
@ -0,0 +1,17 @@
|
|||
<template>
|
||||
<span>
|
||||
<template v-if="kind == 'image'">%fa:file-image%</template>
|
||||
</span>
|
||||
</template>
|
||||
|
||||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
export default Vue.extend({
|
||||
props: ['type'],
|
||||
computed: {
|
||||
kind(): string {
|
||||
return this.type.split('/')[0];
|
||||
}
|
||||
}
|
||||
});
|
||||
</script>
|
Loading…
Reference in a new issue