import Vue from "vue";
import VueRouter from 'vue-router';

import Pregraft from "../views/Pregraft"
import Postgraft from "../views/Postgraft"
import UseCase from "../views/UseCase"
import Acknowledgement from "../views/Acknowledgement"
import SolutionProgressbar from "../views/SolutionProgressbar"

Vue.use(VueRouter);

const routes = [
    {
        path: '/', name: 'home',
        meta: {
            reload: true,
        },
        component: Pregraft
    },
    {
        path: '/example', name: 'example',
        meta: {
            reload: true,
            activateExample: true
        },
        component: Pregraft
    },
    {
        path: '/results/check/:jobId',
        name: 'results-check',
        component: SolutionProgressbar,
        props: true

    },
    {
        path: '/results/view/:jobId',
        name: 'results-view',
        component: Postgraft,
        props: true
    },
    {
        path: '/usecase', name: 'usecase',
        meta: {
            reload: false
        },
        component: UseCase
    },
    {
        path: '/acknowledgement', name: 'acknowledgement',
        meta: {
            reload: false
        },
        component: Acknowledgement
    }
]

export default new VueRouter({
    routes
})