mirror of
https://github.com/Kareadita/Kavita.git
synced 2025-05-31 12:14:44 -04:00
* Moved libraryType into chapter info * Fixed a bug where you could not reset cover on a series * Patched in relevant changes from another polish branch * Refactored invite user setup to shift the checking for accessibility to the backend and always show the link. This will help with users who have some unique setups in docker. * Refactored invite user to always print the url to setup a new account. * Single page renderer uses canvasImage rather than re-requesting and relying on cache * Fixed a rendering issue where fit to split on single on a cover wouldn't force width scaling just for that image * Fixed a rendering bug with split image functionality * Added title to copy button * Fixed a bug in GetContinuePoint when a chapter is added to an already read volume and a new chapter is added loose leaf. The loose leaf would be prioritized over the volume chapter. Refactored 2 methods from controller into service and unit tested. * Fixed a bug on opening a volume in series detail that had a chapter added to it after the volume (0 chapter) was read would cause a loose leaf chapter to be opened. * Added mark as read/actionables on Files in volume detail modal. Fixed a bug where we were showing the wrong page count in a volume detail modal. * Removed OnDeck page and replaced it with a pre-filtered All-Series. Hooked up the ability to pass read state to the filter via query params. Fixed some spacing on filter post bootstrap update. * Fixed up some poor documentation on FilterDto.
81 lines
3.0 KiB
TypeScript
81 lines
3.0 KiB
TypeScript
import { NgModule } from '@angular/core';
|
|
import { Routes, RouterModule } from '@angular/router';
|
|
import { LibraryDetailComponent } from './library-detail/library-detail.component';
|
|
import { SeriesDetailComponent } from './series-detail/series-detail.component';
|
|
import { RecentlyAddedComponent } from './recently-added/recently-added.component';
|
|
import { UserLoginComponent } from './user-login/user-login.component';
|
|
import { AuthGuard } from './_guards/auth.guard';
|
|
import { LibraryAccessGuard } from './_guards/library-access.guard';
|
|
import { DashboardComponent } from './dashboard/dashboard.component';
|
|
import { AllSeriesComponent } from './all-series/all-series.component';
|
|
import { AdminGuard } from './_guards/admin.guard';
|
|
import { ThemeTestComponent } from './theme-test/theme-test.component';
|
|
|
|
// TODO: Once we modularize the components, use this and measure performance impact: https://angular.io/guide/lazy-loading-ngmodules#preloading-modules
|
|
|
|
const routes: Routes = [
|
|
{path: '', component: UserLoginComponent},
|
|
{
|
|
path: 'admin',
|
|
canActivate: [AdminGuard],
|
|
loadChildren: () => import('./admin/admin.module').then(m => m.AdminModule)
|
|
},
|
|
{
|
|
path: 'collections',
|
|
canActivate: [AuthGuard],
|
|
loadChildren: () => import('./collections/collections.module').then(m => m.CollectionsModule)
|
|
},
|
|
{
|
|
path: 'preferences',
|
|
canActivate: [AuthGuard],
|
|
loadChildren: () => import('./user-settings/user-settings.module').then(m => m.UserSettingsModule)
|
|
},
|
|
{
|
|
path: 'lists',
|
|
canActivate: [AuthGuard],
|
|
loadChildren: () => import('./reading-list/reading-list.module').then(m => m.ReadingListModule)
|
|
},
|
|
{
|
|
path: 'registration',
|
|
loadChildren: () => import('../app/registration/registration.module').then(m => m.RegistrationModule)
|
|
},
|
|
{
|
|
path: '',
|
|
runGuardsAndResolvers: 'always',
|
|
canActivate: [AuthGuard, LibraryAccessGuard],
|
|
children: [
|
|
{path: 'library/:id', component: LibraryDetailComponent},
|
|
{path: 'library/:libraryId/series/:seriesId', component: SeriesDetailComponent},
|
|
{
|
|
path: 'library/:libraryId/series/:seriesId/manga',
|
|
loadChildren: () => import('../app/manga-reader/manga-reader.module').then(m => m.MangaReaderModule)
|
|
},
|
|
{
|
|
path: 'library/:libraryId/series/:seriesId/book',
|
|
loadChildren: () => import('../app/book-reader/book-reader.module').then(m => m.BookReaderModule)
|
|
}
|
|
]
|
|
},
|
|
{
|
|
path: '',
|
|
runGuardsAndResolvers: 'always',
|
|
canActivate: [AuthGuard],
|
|
children: [
|
|
{path: 'library', component: DashboardComponent},
|
|
{path: 'recently-added', component: RecentlyAddedComponent},
|
|
{path: 'all-series', component: AllSeriesComponent},
|
|
|
|
]
|
|
},
|
|
{path: 'theme', component: ThemeTestComponent},
|
|
|
|
{path: 'login', component: UserLoginComponent}, // TODO: move this to registration module
|
|
{path: '**', component: UserLoginComponent, pathMatch: 'full'}
|
|
];
|
|
|
|
@NgModule({
|
|
imports: [RouterModule.forRoot(routes, {scrollPositionRestoration: 'enabled'})],
|
|
exports: [RouterModule]
|
|
})
|
|
export class AppRoutingModule { }
|