-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merged in feature/SHIBUI-1311 (pull request #333)
SHIBUI-1311 Updated dashboard provider list Approved-by: Ryan Mathis <rmathis@unicon.net>
- Loading branch information
Showing
21 changed files
with
305 additions
and
180 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
import { TestBed, async } from '@angular/core/testing'; | ||
|
||
import { NavigationService } from './navigation.service'; | ||
|
||
describe('Navigation Service', () => { | ||
let service: NavigationService; | ||
|
||
beforeEach(() => { | ||
TestBed.configureTestingModule({ | ||
imports: [], | ||
providers: [ | ||
NavigationService | ||
] | ||
}); | ||
service = TestBed.get(NavigationService); | ||
}); | ||
|
||
it('should instantiate', () => { | ||
expect(service).toBeDefined(); | ||
}); | ||
|
||
describe('addAction method', () => { | ||
it('should add a navigation option to the list of actions', () => { | ||
service.addAction('foo', { | ||
action: () => {}, | ||
category: 'bar', | ||
label: 'baz', | ||
content: 'something' | ||
}); | ||
|
||
expect(service.actionList.length).toBe(1); | ||
}); | ||
|
||
it('should emit the value from an observable when an action is added', (done: DoneFn) => { | ||
const action = { | ||
action: () => { }, | ||
category: 'bar', | ||
label: 'baz', | ||
content: 'something' | ||
}; | ||
const actionName = 'foo'; | ||
service.addAction(actionName, action); | ||
|
||
service.emitter.subscribe((actions) => { | ||
expect(actions.length).toBe(1); | ||
done(); | ||
}); | ||
}); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,32 +1,34 @@ | ||
import { Action } from '@ngrx/store'; | ||
import { MetadataEntity } from '../../domain/model'; | ||
import { Action, MemoizedSelector } from '@ngrx/store'; | ||
import { Metadata } from '../../domain/domain.type'; | ||
|
||
export const ENTITY_SEARCH = '[Metadata Entity Search] Entity Search'; | ||
export const ENTITY_FILTER = '[Metadata Entity Filter] Entity Filter'; | ||
export const ENTITY_SEARCH_COMPLETE = '[Metadata Entity Search] Entity Search COMPLETE'; | ||
export enum DashboardSearchActionTypes { | ||
ENTITY_SEARCH_COMPLETE = '[Metadata Entity Search] Entity Search COMPLETE', | ||
ENTITY_FILTER = '[Metadata Entity Filter] Entity Filter', | ||
ENTITY_SEARCH = '[Metadata Entity Search] Entity Search', | ||
} | ||
|
||
/** | ||
* Add Resolver to Collection Actions | ||
*/ | ||
export class SearchAction implements Action { | ||
readonly type = ENTITY_SEARCH; | ||
readonly type = DashboardSearchActionTypes.ENTITY_SEARCH; | ||
|
||
constructor(public payload: string) { } | ||
constructor(public payload: { query: string, selector: MemoizedSelector<object, any[]> }) { } | ||
} | ||
|
||
export class FilterAction implements Action { | ||
readonly type = ENTITY_FILTER; | ||
readonly type = DashboardSearchActionTypes.ENTITY_FILTER; | ||
|
||
constructor(public payload: string) { } | ||
} | ||
|
||
export class SearchCompleteAction implements Action { | ||
readonly type = ENTITY_SEARCH_COMPLETE; | ||
readonly type = DashboardSearchActionTypes.ENTITY_SEARCH_COMPLETE; | ||
|
||
constructor(public payload: Array<MetadataEntity>) { } | ||
constructor(public payload: Array<Metadata>) { } | ||
} | ||
|
||
export type Actions = | ||
export type DashboardSearchActionsUnion = | ||
| SearchAction | ||
| FilterAction | ||
| SearchCompleteAction; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 14 additions & 0 deletions
14
ui/src/app/metadata/manager/container/dashboard-providers-list.component.scss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
@import '../../../../theme/palette'; | ||
.provider-index { | ||
font-size: 1.8rem; | ||
line-height: 1.8rem; | ||
font-weight: lighter; | ||
font-family: monospace; | ||
width: 45px; | ||
} | ||
|
||
.table-providers { | ||
tr > td { | ||
vertical-align: middle; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.