Browse Source

web-ui: Add the AddressDetails view

scalafmt-draft
Alexis Hernandez 7 years ago
parent
commit
1dafe92bea
  1. 2
      web-ui/src/app/app-routing.module.ts
  2. 4
      web-ui/src/app/app.module.ts
  3. 0
      web-ui/src/app/components/address-details/address-details.component.css
  4. 3
      web-ui/src/app/components/address-details/address-details.component.html
  5. 25
      web-ui/src/app/components/address-details/address-details.component.spec.ts
  6. 15
      web-ui/src/app/components/address-details/address-details.component.ts

2
web-ui/src/app/app-routing.module.ts

@ -3,9 +3,11 @@ import { Routes, RouterModule } from '@angular/router';
import { HomeComponent } from './components/home/home.component';
import { TransactionDetailsComponent } from './components/transaction-details/transaction-details.component';
import { AddressDetailsComponent } from './components/address-details/address-details.component';
const routes: Routes = [
{ path: '', component: HomeComponent },
{ path: 'addresses/:address', component: AddressDetailsComponent },
{ path: 'transactions/:txid', component: TransactionDetailsComponent },
{ path: '**', redirectTo: '' }
];

4
web-ui/src/app/app.module.ts

@ -24,6 +24,7 @@ import { FooterComponent } from './components/footer/footer.component';
import { NavbarComponent } from './components/navbar/navbar.component';
import { TransactionDetailsComponent } from './components/transaction-details/transaction-details.component';
import { TransactionFinderComponent } from './components/transaction-finder/transaction-finder.component';
import { AddressDetailsComponent } from './components/address-details/address-details.component';
@NgModule({
declarations: [
@ -32,7 +33,8 @@ import { TransactionFinderComponent } from './components/transaction-finder/tran
FooterComponent,
NavbarComponent,
TransactionDetailsComponent,
TransactionFinderComponent
TransactionFinderComponent,
AddressDetailsComponent
],
imports: [
AppRoutingModule,

0
web-ui/src/app/components/address-details/address-details.component.css

3
web-ui/src/app/components/address-details/address-details.component.html

@ -0,0 +1,3 @@
<p>
address-details works!
</p>

25
web-ui/src/app/components/address-details/address-details.component.spec.ts

@ -0,0 +1,25 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { AddressDetailsComponent } from './address-details.component';
describe('AddressDetailsComponent', () => {
let component: AddressDetailsComponent;
let fixture: ComponentFixture<AddressDetailsComponent>;
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [ AddressDetailsComponent ]
})
.compileComponents();
}));
beforeEach(() => {
fixture = TestBed.createComponent(AddressDetailsComponent);
component = fixture.componentInstance;
fixture.detectChanges();
});
it('should create', () => {
expect(component).toBeTruthy();
});
});

15
web-ui/src/app/components/address-details/address-details.component.ts

@ -0,0 +1,15 @@
import { Component, OnInit } from '@angular/core';
@Component({
selector: 'app-address-details',
templateUrl: './address-details.component.html',
styleUrls: ['./address-details.component.css']
})
export class AddressDetailsComponent implements OnInit {
constructor() { }
ngOnInit() {
}
}
Loading…
Cancel
Save