* Add generate version module script
* Remove Fork me on GitHub banner
* Add app-version.ts
* Revert "Add app-version.ts"
This reverts commit fe1a37e631.
* Add app-version.ts
* Add agent icon class
* Move settings component under agent folder
* Add AboutComponent
* Add agent routes
* Add index.ts for agent folder
* Fix agent folder imports in shared module
* Add agent menu to side menu, with Settings and About pages under it
* Fix agent icon alignment in side menu
* Simplify About page
* Make Agent menu 0 level in side menu
* Remove bottom Settings menu
* Fix Agent menu closing if My UHK is closed in side menu
* Fix version text alignment in auto update settings
* Remove github fork ribbon styles
* use package.json instead of app-version.ts
* fix OpenUrlInNewWindow naming
* fix lint request
* fix: firmware download url calculation
53 lines
2.1 KiB
TypeScript
53 lines
2.1 KiB
TypeScript
import { ModuleWithProviders } from '@angular/core';
|
|
import { RouterModule, Routes } from '@angular/router';
|
|
|
|
import { deviceRoutes } from './components/device';
|
|
import { addOnRoutes } from './components/add-on';
|
|
import { keymapRoutes } from './components/keymap';
|
|
import { macroRoutes } from './components/macro';
|
|
import { PrivilegeCheckerComponent } from './components/privilege-checker/privilege-checker.component';
|
|
import { MissingDeviceComponent } from './components/missing-device/missing-device.component';
|
|
import { UhkDeviceDisconnectedGuard } from './services/uhk-device-disconnected.guard';
|
|
import { UhkDeviceConnectedGuard } from './services/uhk-device-connected.guard';
|
|
import { UhkDeviceUninitializedGuard } from './services/uhk-device-uninitialized.guard';
|
|
import { UhkDeviceInitializedGuard } from './services/uhk-device-initialized.guard';
|
|
import { MainPage } from './pages/main-page/main.page';
|
|
import { agentRoutes } from './components/agent/agent.routes';
|
|
import { LoadingDevicePageComponent } from './pages/loading-page/loading-device.page';
|
|
import { UhkDeviceLoadingGuard } from './services/uhk-device-loading.guard';
|
|
import { UhkDeviceLoadedGuard } from './services/uhk-device-loaded.guard';
|
|
|
|
const appRoutes: Routes = [
|
|
{
|
|
path: 'detection',
|
|
component: MissingDeviceComponent,
|
|
canActivate: [UhkDeviceConnectedGuard, UhkDeviceUninitializedGuard]
|
|
},
|
|
{
|
|
path: 'privilege',
|
|
component: PrivilegeCheckerComponent,
|
|
canActivate: [UhkDeviceInitializedGuard]
|
|
},
|
|
{
|
|
path: 'loading',
|
|
component: LoadingDevicePageComponent,
|
|
canActivate: [UhkDeviceLoadedGuard]
|
|
},
|
|
{
|
|
path: '',
|
|
component: MainPage,
|
|
canActivate: [UhkDeviceDisconnectedGuard, UhkDeviceLoadingGuard],
|
|
children: [
|
|
...deviceRoutes,
|
|
...keymapRoutes,
|
|
...macroRoutes,
|
|
...addOnRoutes,
|
|
...agentRoutes
|
|
]
|
|
}
|
|
];
|
|
|
|
export const appRoutingProviders: any[] = [];
|
|
|
|
export const routing: ModuleWithProviders = RouterModule.forRoot(appRoutes, { useHash: true });
|