mirror of
https://activitypub.software/TransFem-org/Sharkey.git
synced 2024-12-14 10:05:46 +01:00
🎨
This commit is contained in:
parent
f128813a5e
commit
c7daaba370
4 changed files with 41 additions and 3 deletions
27
src/client/app/common/views/components/avatars.vue
Normal file
27
src/client/app/common/views/components/avatars.vue
Normal file
|
@ -0,0 +1,27 @@
|
||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
<mk-avatar v-for="user in us" :user="user" :key="user.id" style="width:32px;height:32px;"/>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script lang="ts">
|
||||||
|
import Vue from 'vue';
|
||||||
|
|
||||||
|
export default Vue.extend({
|
||||||
|
props: {
|
||||||
|
userIds: {
|
||||||
|
required: true
|
||||||
|
},
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
us: []
|
||||||
|
};
|
||||||
|
},
|
||||||
|
async created() {
|
||||||
|
this.us = await this.$root.api('users/show', {
|
||||||
|
userIds: this.userIds
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
</script>
|
|
@ -19,7 +19,6 @@ export default Vue.extend({
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
||||||
<style lang="stylus" scoped>
|
<style lang="stylus" scoped>
|
||||||
.a
|
.a
|
||||||
display block
|
display block
|
||||||
|
|
|
@ -9,6 +9,7 @@
|
||||||
<ui-hr/>
|
<ui-hr/>
|
||||||
<ui-margin>
|
<ui-margin>
|
||||||
<router-link :to="`/i/groups/${group.id}`">{{ group.name }}</router-link>
|
<router-link :to="`/i/groups/${group.id}`">{{ group.name }}</router-link>
|
||||||
|
<x-avatars :user-ids="group.userIds" style="margin-top:8px;"/>
|
||||||
</ui-margin>
|
</ui-margin>
|
||||||
</div>
|
</div>
|
||||||
</ui-container>
|
</ui-container>
|
||||||
|
@ -18,7 +19,8 @@
|
||||||
<div class="hwgkdrbl" v-for="(group, i) in joinedGroups" :key="group.id">
|
<div class="hwgkdrbl" v-for="(group, i) in joinedGroups" :key="group.id">
|
||||||
<ui-hr v-if="i != 0"/>
|
<ui-hr v-if="i != 0"/>
|
||||||
<ui-margin>
|
<ui-margin>
|
||||||
<router-link :to="`/i/groups/${group.id}`">{{ group.name }}</router-link>
|
<div>{{ group.name }}</div>
|
||||||
|
<x-avatars :user-ids="group.userIds" style="margin-top:8px;"/>
|
||||||
</ui-margin>
|
</ui-margin>
|
||||||
</div>
|
</div>
|
||||||
</ui-container>
|
</ui-container>
|
||||||
|
@ -29,6 +31,7 @@
|
||||||
<ui-hr v-if="i != 0"/>
|
<ui-hr v-if="i != 0"/>
|
||||||
<ui-margin>
|
<ui-margin>
|
||||||
<div class="name">{{ invite.group.name }}</div>
|
<div class="name">{{ invite.group.name }}</div>
|
||||||
|
<x-avatars :user-ids="invite.group.userIds" style="margin-top:8px;"/>
|
||||||
<ui-horizon-group>
|
<ui-horizon-group>
|
||||||
<ui-button @click="acceptInvite(invite)"><fa :icon="faCheck"/> {{ $t('accept-invite') }}</ui-button>
|
<ui-button @click="acceptInvite(invite)"><fa :icon="faCheck"/> {{ $t('accept-invite') }}</ui-button>
|
||||||
<ui-button @click="rejectInvite(invite)"><fa :icon="faBan"/> {{ $t('reject-invite') }}</ui-button>
|
<ui-button @click="rejectInvite(invite)"><fa :icon="faBan"/> {{ $t('reject-invite') }}</ui-button>
|
||||||
|
@ -41,11 +44,15 @@
|
||||||
|
|
||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
import Vue from 'vue';
|
import Vue from 'vue';
|
||||||
import i18n from '../../../i18n';
|
|
||||||
import { faUsers, faPlus, faCheck, faBan, faEnvelopeOpenText } from '@fortawesome/free-solid-svg-icons';
|
import { faUsers, faPlus, faCheck, faBan, faEnvelopeOpenText } from '@fortawesome/free-solid-svg-icons';
|
||||||
|
import i18n from '../../../i18n';
|
||||||
|
import XAvatars from '../../views/components/avatars.vue';
|
||||||
|
|
||||||
export default Vue.extend({
|
export default Vue.extend({
|
||||||
i18n: i18n('common/views/components/user-groups.vue'),
|
i18n: i18n('common/views/components/user-groups.vue'),
|
||||||
|
components: {
|
||||||
|
XAvatars
|
||||||
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
ownedGroups: [],
|
ownedGroups: [],
|
||||||
|
|
|
@ -8,6 +8,7 @@
|
||||||
<ui-hr/>
|
<ui-hr/>
|
||||||
<ui-margin>
|
<ui-margin>
|
||||||
<router-link :to="`/i/lists/${list.id}`">{{ list.name }}</router-link>
|
<router-link :to="`/i/lists/${list.id}`">{{ list.name }}</router-link>
|
||||||
|
<x-avatars :user-ids="list.userIds" style="margin-top:8px;"/>
|
||||||
</ui-margin>
|
</ui-margin>
|
||||||
</div>
|
</div>
|
||||||
</ui-container>
|
</ui-container>
|
||||||
|
@ -17,9 +18,13 @@
|
||||||
import Vue from 'vue';
|
import Vue from 'vue';
|
||||||
import i18n from '../../../i18n';
|
import i18n from '../../../i18n';
|
||||||
import { faListUl, faPlus } from '@fortawesome/free-solid-svg-icons';
|
import { faListUl, faPlus } from '@fortawesome/free-solid-svg-icons';
|
||||||
|
import XAvatars from '../../views/components/avatars.vue';
|
||||||
|
|
||||||
export default Vue.extend({
|
export default Vue.extend({
|
||||||
i18n: i18n('common/views/components/user-lists.vue'),
|
i18n: i18n('common/views/components/user-lists.vue'),
|
||||||
|
components: {
|
||||||
|
XAvatars
|
||||||
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
fetching: true,
|
fetching: true,
|
||||||
|
|
Loading…
Reference in a new issue