mempool/frontend/src/app/app-routing.module.ts

241 lines
5.4 KiB
TypeScript
Raw Normal View History

2019-07-21 16:59:47 +02:00
import { NgModule } from '@angular/core';
import { Routes, RouterModule } from '@angular/router';
import { StartComponent } from './components/start/start.component';
import { TransactionComponent } from './components/transaction/transaction.component';
import { BlockComponent } from './components/block/block.component';
import { AddressComponent } from './components/address/address.component';
import { MasterPageComponent } from './components/master-page/master-page.component';
import { AboutComponent } from './components/about/about.component';
import { TelevisionComponent } from './components/television/television.component';
import { StatisticsComponent } from './components/statistics/statistics.component';
import { MempoolBlockComponent } from './components/mempool-block/mempool-block.component';
import { LatestBlocksComponent } from './components/latest-blocks/latest-blocks.component';
2020-04-28 12:10:31 +02:00
import { AssetComponent } from './components/asset/asset.component';
import { AssetsComponent } from './assets/assets.component';
2020-07-02 12:56:15 +02:00
import { StatusViewComponent } from './components/status-view/status-view.component';
2019-07-21 16:59:47 +02:00
const routes: Routes = [
{
path: '',
2019-07-27 17:43:17 +02:00
component: MasterPageComponent,
children: [
{
path: '',
component: StartComponent,
children: [
{
path: '',
component: LatestBlocksComponent
},
{
path: 'tx/:id',
component: TransactionComponent
},
{
path: 'block/:id',
component: BlockComponent
},
{
path: 'mempool-block/:id',
component: MempoolBlockComponent
},
],
2019-07-27 17:43:17 +02:00
},
{
path: 'graphs',
component: StatisticsComponent,
2019-07-27 17:43:17 +02:00
},
{
path: 'about',
component: AboutComponent,
2019-07-27 17:43:17 +02:00
},
2019-11-06 08:35:02 +01:00
{
path: 'address/:id',
children: [],
component: AddressComponent
2019-11-06 08:35:02 +01:00
},
2019-07-27 17:43:17 +02:00
],
2019-07-21 16:59:47 +02:00
},
{
path: 'liquid',
component: MasterPageComponent,
children: [
{
path: '',
component: StartComponent,
children: [
{
path: '',
component: LatestBlocksComponent
},
{
path: 'tx/:id',
component: TransactionComponent
},
{
path: 'block/:id',
component: BlockComponent
},
{
path: 'mempool-block/:id',
component: MempoolBlockComponent
},
],
},
{
path: 'graphs',
component: StatisticsComponent,
},
{
path: 'tv',
component: TelevisionComponent,
},
{
path: 'about',
component: AboutComponent,
},
{
path: 'address/:id',
children: [],
component: AddressComponent
},
{
path: '**',
redirectTo: ''
},
],
},
{
path: 'liquid',
component: MasterPageComponent,
children: [
{
path: '',
component: StartComponent,
children: [
{
path: '',
component: LatestBlocksComponent
},
{
path: 'tx/:id',
component: TransactionComponent
},
{
path: 'block/:id',
component: BlockComponent
},
{
path: 'mempool-block/:id',
component: MempoolBlockComponent
},
],
},
{
path: 'graphs',
component: StatisticsComponent,
},
{
path: 'about',
component: AboutComponent,
},
{
path: 'address/:id',
children: [],
component: AddressComponent
},
{
path: 'asset/:id',
component: AssetComponent
},
{
path: 'assets',
component: AssetsComponent,
},
{
path: '**',
redirectTo: ''
},
],
},
{
path: 'testnet',
component: MasterPageComponent,
children: [
{
path: '',
component: StartComponent,
children: [
{
path: '',
component: LatestBlocksComponent
},
{
path: 'tx/:id',
component: TransactionComponent
},
{
path: 'block/:id',
component: BlockComponent
},
{
path: 'mempool-block/:id',
component: MempoolBlockComponent
},
],
},
{
path: 'graphs',
component: StatisticsComponent,
},
{
path: 'about',
component: AboutComponent,
},
{
path: 'address/:id',
children: [],
component: AddressComponent
},
{
path: '**',
redirectTo: ''
},
],
},
2019-07-21 16:59:47 +02:00
{
2019-07-27 17:43:17 +02:00
path: 'tv',
component: TelevisionComponent,
2019-07-21 16:59:47 +02:00
},
{
path: 'liquid-tv',
component: TelevisionComponent,
},
{
path: 'testnet-tv',
component: TelevisionComponent,
},
2020-07-02 12:56:15 +02:00
{
path: 'status-view',
component: StatusViewComponent
},
{
path: 'liquid-status-view',
component: StatusViewComponent
},
{
path: 'testnet-status-view',
component: StatusViewComponent
},
2019-07-21 16:59:47 +02:00
{
path: '**',
redirectTo: ''
},
2019-07-21 16:59:47 +02:00
];
2019-07-21 16:59:47 +02:00
@NgModule({
imports: [RouterModule.forRoot(routes)],
exports: [RouterModule]
})
export class AppRoutingModule { }