misskey-awawa/src/client/app/common/views/widgets/donation.vue

54 lines
1009 B
Vue
Raw Normal View History

2018-02-15 03:36:42 +00:00
<template>
2018-09-28 10:59:19 +00:00
<div>
<mk-widget-container :show-header="false">
<article class="dolfvtibguprpxxhfndqaosjitixjohx">
<h1><fa icon="heart"/>%i18n:@title%</h1>
2018-09-28 10:59:19 +00:00
<p v-if="meta">
{{ '%i18n:@text%'.substr(0, '%i18n:@text%'.indexOf('{')) }}
<a :href="'mailto:' + meta.maintainer.email">{{ meta.maintainer.name }}</a>
2018-09-28 10:59:19 +00:00
{{ '%i18n:@text%'.substr('%i18n:@text%'.indexOf('}') + 1) }}
</p>
</article>
</mk-widget-container>
2018-02-15 03:36:42 +00:00
</div>
</template>
<script lang="ts">
2018-02-24 15:18:09 +00:00
import define from '../../../common/define-widget';
2018-02-15 03:36:42 +00:00
export default define({
name: 'donation'
}).extend({
data() {
return {
2018-08-26 01:29:24 +00:00
meta: null
};
},
created() {
(this as any).os.getMeta().then(meta => {
this.meta = meta;
});
}
2018-02-15 03:36:42 +00:00
});
</script>
<style lang="stylus" scoped>
2018-09-28 10:59:19 +00:00
.dolfvtibguprpxxhfndqaosjitixjohx
padding 20px
background var(--donationBg)
color var(--donationFg)
> h1
margin 0 0 5px 0
font-size 1em
> [data-icon]
2018-09-28 10:59:19 +00:00
margin-right 0.25em
> p
display block
z-index 1
margin 0
font-size 0.8em
2018-04-19 22:45:37 +00:00
2018-02-15 03:36:42 +00:00
</style>