Merge pull request #6608 from Ocelot-Social-Community/6236-groups-highlighting

fix(webapp): groups highlighting
This commit is contained in:
Hannes Heine 2023-07-20 09:19:54 +02:00 committed by GitHub
commit 9e52ec5469
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
16 changed files with 14 additions and 14 deletions

View File

@ -58,14 +58,14 @@ export default {
routes.push({
label: this.$t('group.contentMenu.visitGroupPage'),
icon: 'home',
name: 'group-id-slug',
path: `/groups/${this.group.id}`,
params: { id: this.group.id, slug: this.group.slug },
})
}
if (this.group.myRole === 'owner') {
routes.push({
label: this.$t('admin.settings.name'),
path: `/group/edit/${this.group.id}`,
path: `/groups/edit/${this.group.id}`,
icon: 'edit',
})
}

View File

@ -1,7 +1,7 @@
<template>
<nuxt-link
class="group-teaser"
:to="{ name: 'group-id-slug', params: { id: group.id, slug: group.slug } }"
:to="{ name: 'groups-id-slug', params: { id: group.id, slug: group.slug } }"
>
<base-card
:class="{

View File

@ -9,7 +9,7 @@
<p class="description">{{ $t(`notifications.reason.${notification.reason}`) }}</p>
<nuxt-link
class="link"
:to="{ name: isGroup ? 'group-id-slug' : 'post-id-slug', params, ...hashParam }"
:to="{ name: isGroup ? 'groups-id-slug' : 'post-id-slug', params, ...hashParam }"
@click.native="$emit('read')"
>
<base-card wideContent>

View File

@ -65,7 +65,7 @@
class="notification-mention-post"
:class="{ 'notification-status': notification.read }"
:to="{
name: isGroup(notification.from) ? 'group-id-slug' : 'post-id-slug',
name: isGroup(notification.from) ? 'groups-id-slug' : 'post-id-slug',
params: params(notification.from),
hash: hashParam(notification.from),
}"

View File

@ -96,7 +96,7 @@ export default {
groupLink() {
const { id, slug } = this.group
if (!(id && slug)) return ''
return { name: 'group-id-slug', params: { slug, id } }
return { name: 'groups-id-slug', params: { slug, id } }
},
groupSlug() {
const { slug } = this.group || {}

View File

@ -148,7 +148,7 @@ export default {
case 'User':
return 'profile-id-slug'
case 'Group':
return 'group-id-slug'
return 'groups-id-slug'
default:
return null
}

View File

@ -24,7 +24,7 @@ const options = {
}
`,
message: 'error-pages.group-not-found',
path: 'group',
path: 'groups',
}
const persistentLinks = PersistentLinks(options)

View File

@ -59,7 +59,7 @@ export default {
})
this.$toast.success(this.$t('group.groupCreated'))
this.$router.history.push({
name: 'group-id-slug',
name: 'groups-id-slug',
params: { id: responseId, slug: responseSlug },
})
} catch (error) {

View File

@ -33,11 +33,11 @@ export default {
return [
{
name: this.$t('group.general'),
path: `/group/edit/${this.group.id}`,
path: `/groups/edit/${this.group.id}`,
},
{
name: this.$t('group.members'),
path: `/group/edit/${this.group.id}/members`,
path: `/groups/edit/${this.group.id}/members`,
},
]
},

View File

@ -60,7 +60,7 @@ export default {
})
this.$toast.success(this.$t('group.updatedGroup'))
this.$router.history.push({
name: 'group-id-slug',
name: 'groups-id-slug',
params: { id: responseId, slug: responseSlug },
})
} catch (error) {

View File

@ -1,5 +1,5 @@
import { mount } from '@vue/test-utils'
import groups from './groups.vue'
import groups from './index.vue'
const localVue = global.localVue

View File

@ -7,7 +7,7 @@
<ds-space>
<!-- create group -->
<ds-space centered>
<nuxt-link :to="{ name: 'group-create' }">
<nuxt-link :to="{ name: 'groups-create' }">
<base-button
class="group-add-button"
icon="plus"