-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(admin-ui): Can add custom buttons to list/detail views
Relates to #55
- Loading branch information
1 parent
0d86927
commit ef47c62
Showing
38 changed files
with
281 additions
and
108 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
1 change: 1 addition & 0 deletions
1
packages/admin-ui/src/app/catalog/components/collection-list/collection-list.component.html
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
1 change: 1 addition & 0 deletions
1
packages/admin-ui/src/app/catalog/components/facet-list/facet-list.component.html
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
12 changes: 6 additions & 6 deletions
12
packages/admin-ui/src/app/core/components/main-nav/main-nav.component.html
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
46 changes: 46 additions & 0 deletions
46
packages/admin-ui/src/app/core/providers/nav-builder/nav-builder-types.ts
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,46 @@ | ||
import { ActivatedRoute } from '@angular/router'; | ||
import { Observable } from 'rxjs'; | ||
|
||
/** | ||
* A NavMenuItem is a menu item in the main (left-hand side) nav | ||
* bar. | ||
*/ | ||
export interface NavMenuItem { | ||
id: string; | ||
label: string; | ||
routerLink: RouterLinkDefinition; | ||
onClick?: (event: MouseEvent) => void; | ||
icon?: string; | ||
requiresPermission?: string; | ||
} | ||
|
||
/** | ||
* A NavMenuSection is a grouping of links in the main | ||
* (left-hand side) nav bar. | ||
*/ | ||
export interface NavMenuSection { | ||
id: string; | ||
label: string; | ||
items: NavMenuItem[]; | ||
requiresPermission?: string; | ||
collapsible?: boolean; | ||
collapsedByDefault?: boolean; | ||
} | ||
|
||
/** | ||
* A button in the ActionBar area at the top of one of the list or detail views. | ||
*/ | ||
export interface ActionBarItem { | ||
id: string; | ||
label: string; | ||
locationId: string; | ||
disabled?: Observable<boolean>; | ||
onClick?: (event: MouseEvent, route: ActivatedRoute) => void; | ||
routerLink?: RouterLinkDefinition; | ||
buttonColor?: 'primary' | 'success' | 'warning'; | ||
buttonStyle?: 'solid' | 'outline' | 'link'; | ||
icon?: string; | ||
requiresPermission?: string; | ||
} | ||
|
||
export type RouterLinkDefinition = ((route: ActivatedRoute) => any[]) | any[]; |
Oops, something went wrong.