-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Add the ability to set a company logo and show environment badge
Add the ability to set a logo that will be displayed next to the Capella text. Add a badge that can show the current environment with different UI depending on if the environment is productive. The badge is enabled during development by default.
- Loading branch information
Showing
22 changed files
with
365 additions
and
14 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
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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,24 @@ | ||
<!-- | ||
~ SPDX-FileCopyrightText: Copyright DB InfraGO AG and contributors | ||
~ SPDX-License-Identifier: Apache-2.0 | ||
--> | ||
|
||
<div class="flex select-none items-center gap-2"> | ||
@if (navBarService.logoUrl$ | async; as logoUrl) { | ||
<img [src]="logoUrl" aria-hidden="true" class="max-h-8 max-w-24" /> | ||
} | ||
|
||
<div class="text-2xl font-semibold text-primary">CCM</div> | ||
|
||
@if ((navBarService.badge$ | async)?.show) { | ||
<div | ||
class="rounded-md px-1 py-0.5 text-xs font-semibold uppercase tracking-wide text-white" | ||
[class.bg-hazard]="(navBarService.badge$ | async)?.variant === 'warning'" | ||
[class.bg-green-600]=" | ||
(navBarService.badge$ | async)?.variant === 'success' | ||
" | ||
> | ||
{{ (navBarService.badge$ | async)?.text }} | ||
</div> | ||
} | ||
</div> |
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,17 @@ | ||
/* | ||
* SPDX-FileCopyrightText: Copyright DB InfraGO AG and contributors | ||
* SPDX-License-Identifier: Apache-2.0 | ||
*/ | ||
import { AsyncPipe } from '@angular/common'; | ||
import { Component } from '@angular/core'; | ||
import { NavBarService } from '../nav-bar/nav-bar.service'; | ||
|
||
@Component({ | ||
selector: 'app-logo', | ||
standalone: true, | ||
templateUrl: './logo.component.html', | ||
imports: [AsyncPipe], | ||
}) | ||
export class LogoComponent { | ||
constructor(public navBarService: NavBarService) {} | ||
} |
Oops, something went wrong.