import routes from 'global/constants/routes'

export const TABS = {
    MESSAGES: 'MESSAGES',
    OVERVIEW: 'OVERVIEW',
    PARTICIPANTS: 'PARTICIPANTS',
    NO_COURSES: 'NO COURSES',
}

export const makeTabs = (courseId) => [
    {
        value: TABS.OVERVIEW,
        label: 'Overview',
        route: `${routes.COURSE}/${courseId}${routes.OVERVIEW}`,
        regex: routes.regex.COURSE_OVERVIEW,
    },
    {
        value: TABS.MESSAGES,
        label: 'Messages',
        route: `${routes.COURSE}/${courseId}${routes.MESSAGES}`,
        regex: routes.regex.COURSE_MESSAGES,
    },
    {
        value: TABS.PARTICIPANTS,
        label: 'Participants',
        route: `${routes.COURSE}/${courseId}${routes.PARTICIPANTS}`,
        regex: routes.regex.COURSE_PARTICIPANTS,
    },
    {
        value: TABS.NO_COURSES,
        label: 'Create a Course',
        route: '/class',
        regex: routes.regex.COURSE_NONE,
    },
]
