2020-02-18 08:57:00 +01:00
|
|
|
import { RouteConfig } from "vue-router";
|
2020-11-30 10:24:11 +01:00
|
|
|
import { EsModuleComponent } from "vue/types/options";
|
2020-02-18 08:57:00 +01:00
|
|
|
|
2019-02-22 14:55:47 +01:00
|
|
|
export enum ActorRouteName {
|
2020-02-18 08:57:00 +01:00
|
|
|
GROUP = "Group",
|
|
|
|
CREATE_GROUP = "CreateGroup",
|
|
|
|
PROFILE = "Profile",
|
|
|
|
MY_GROUPS = "MY_GROUPS",
|
2019-06-17 17:15:27 +02:00
|
|
|
}
|
|
|
|
|
2020-02-18 08:57:00 +01:00
|
|
|
export const actorRoutes: RouteConfig[] = [
|
|
|
|
{
|
|
|
|
path: "/groups/create",
|
|
|
|
name: ActorRouteName.CREATE_GROUP,
|
2020-11-30 10:24:11 +01:00
|
|
|
component: (): Promise<EsModuleComponent> =>
|
|
|
|
import(/* webpackChunkName: "CreateGroup" */ "@/views/Group/Create.vue"),
|
2020-02-18 08:57:00 +01:00
|
|
|
meta: { requiredAuth: true },
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: "/@:preferredUsername",
|
|
|
|
name: ActorRouteName.GROUP,
|
2020-11-30 10:24:11 +01:00
|
|
|
component: (): Promise<EsModuleComponent> =>
|
|
|
|
import(/* webpackChunkName: "Group" */ "@/views/Group/Group.vue"),
|
2020-02-18 08:57:00 +01:00
|
|
|
props: true,
|
|
|
|
meta: { requiredAuth: false },
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: "/groups/me",
|
|
|
|
name: ActorRouteName.MY_GROUPS,
|
2020-11-30 10:24:11 +01:00
|
|
|
component: (): Promise<EsModuleComponent> =>
|
|
|
|
import(/* webpackChunkName: "MyGroups" */ "@/views/Group/MyGroups.vue"),
|
2020-02-18 08:57:00 +01:00
|
|
|
meta: { requiredAuth: true },
|
|
|
|
},
|
|
|
|
];
|