import { createRouter, createWebHistory } from 'vue-router'
import HomeView from '../views/HomeView.vue'
import ProfileView from '../views/ProfileView.vue'
import SearchView from '../views/SearchView.vue'
import LoginView from '../views/LoginView.vue'
import UploadView from '../views/UploadView.vue'
import UpdateAccountView from '@/views/UpdateAccountView.vue'
import ProfileVideosView from '@/views/ProfileVideosView.vue'
import ExploreView from '@/views/ExploreView.vue'
import ExploreVideosView from '@/views/ExploreVideosView.vue'
import ContactView from '@/views/ContactView.vue'

const router = createRouter({
	history: createWebHistory(import.meta.env.BASE_URL),
	routes: [
		{
			path: '/',
			name: 'home',
			component: HomeView,
		},
		{
			path: '/profile/:id',
			name: 'about',
			component: ProfileView,
		},
		{
			path: '/profile/:id/videos',
			name: 'profileVideos',
			component: ProfileVideosView,
		},
		{
			path: '/search',
			name: 'search',
			component: SearchView,
		},
		{
			path: '/login',
			name: 'login',
			component: LoginView,
		},
		{
			path: '/upload',
			name: 'upload',
			component: UploadView,
		},
		{
			path: '/updateAccount',
			name: 'updateAccount',
			component: UpdateAccountView,
		},
		{
			path: '/explore',
			name: 'explore',
			component: ExploreView,
		},
		{
			path: '/explore/videos',
			name: 'exploreVideos',
			component: ExploreVideosView
		},
		{
			path: '/contact',
			name: 'contact',
			component: ContactView,
		}
	],
})

export default router
