forked from mirror/misskey
Fix #2133 など
This commit is contained in:
parent
01d3f5f09d
commit
454d294cf3
@ -1,6 +1,8 @@
|
|||||||
<template>
|
<template>
|
||||||
<router-link class="mk-avatar" :to="user | userPage" :title="user | acct" :target="target" :style="style" v-if="disablePreview"></router-link>
|
<span class="mk-avatar" :title="user | acct" :style="style" v-if="disableLink && !disablePreview" v-user-preview="user.id" @click="onClick"></span>
|
||||||
<router-link class="mk-avatar" :to="user | userPage" :title="user | acct" :target="target" :style="style" v-else v-user-preview="user.id"></router-link>
|
<span class="mk-avatar" :title="user | acct" :style="style" v-else-if="disableLink && disablePreview" @click="onClick"></span>
|
||||||
|
<router-link class="mk-avatar" :to="user | userPage" :title="user | acct" :target="target" :style="style" v-else-if="!disableLink && !disablePreview" v-user-preview="user.id"></router-link>
|
||||||
|
<router-link class="mk-avatar" :to="user | userPage" :title="user | acct" :target="target" :style="style" v-else-if="!disableLink && disablePreview"></router-link>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
@ -15,6 +17,10 @@ export default Vue.extend({
|
|||||||
required: false,
|
required: false,
|
||||||
default: null
|
default: null
|
||||||
},
|
},
|
||||||
|
disableLink: {
|
||||||
|
required: false,
|
||||||
|
default: false
|
||||||
|
},
|
||||||
disablePreview: {
|
disablePreview: {
|
||||||
required: false,
|
required: false,
|
||||||
default: false
|
default: false
|
||||||
@ -35,6 +41,11 @@ export default Vue.extend({
|
|||||||
borderRadius: this.$store.state.settings.circleIcons ? '100%' : null
|
borderRadius: this.$store.state.settings.circleIcons ? '100%' : null
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
onClick(e) {
|
||||||
|
this.$emit('click', e);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
@ -6,10 +6,11 @@
|
|||||||
<div class="banner"
|
<div class="banner"
|
||||||
:style="$store.state.i.bannerUrl ? `background-image: url(${$store.state.i.bannerUrl})` : ''"
|
:style="$store.state.i.bannerUrl ? `background-image: url(${$store.state.i.bannerUrl})` : ''"
|
||||||
title="%i18n:@update-banner%"
|
title="%i18n:@update-banner%"
|
||||||
@click="os.apis.updateBanner"
|
@click="() => os.apis.updateBanner()"
|
||||||
></div>
|
></div>
|
||||||
<mk-avatar class="avatar" :user="$store.state.i"
|
<mk-avatar class="avatar" :user="$store.state.i"
|
||||||
@click="os.apis.updateAvatar"
|
:disable-link="true"
|
||||||
|
@click="() => os.apis.updateAvatar()"
|
||||||
title="%i18n:@update-avatar%"
|
title="%i18n:@update-avatar%"
|
||||||
/>
|
/>
|
||||||
<router-link class="name" :to="$store.state.i | userPage">{{ $store.state.i | userName }}</router-link>
|
<router-link class="name" :to="$store.state.i | userPage">{{ $store.state.i | userName }}</router-link>
|
||||||
|
Loading…
Reference in New Issue
Block a user