-
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.
Merge pull request ceph#35956 from ishanrai05/hover
mgr/dashboard: Display description on mouse hover Reviewed-by: Tiago Melo <[email protected]>
- Loading branch information
Showing
7 changed files
with
43 additions
and
2 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
22 changes: 21 additions & 1 deletion
22
...pybind/mgr/dashboard/frontend/src/app/ceph/dashboard/info-group/info-group.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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,26 @@ | ||
<div class="row"> | ||
<span class="info-group-title">{{ groupTitle }}</span> | ||
<div class="info-group-title" | ||
[ngbPopover]="popInfoTemplate" | ||
#popInfo="ngbPopover" | ||
triggers=""> | ||
<span>{{ groupTitle }}</span> | ||
<button type="button" | ||
class="popover-icon btn btn-link p-0" | ||
(click)="popInfo.toggle()"> | ||
<i [ngClass]="[icons.infoCircle, icons.large]"></i> | ||
</button> | ||
</div> | ||
</div> | ||
|
||
<div class="row"> | ||
<ng-content></ng-content> | ||
</div> | ||
|
||
<ng-template #popInfoTemplate> | ||
<div class="text-center" | ||
i18n>For an overview of {{ groupTitle|lowercase }} widgets click | ||
<cd-doc section="dashboard-landing-page-{{ groupTitle|lowercase }}" | ||
docText="here" | ||
i18n-docText></cd-doc> | ||
</div> | ||
</ng-template> |
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 |
---|---|---|
|
@@ -2,3 +2,7 @@ | |
font-size: 1.75rem; | ||
margin: 0 0 0.5vw 0.5vw; | ||
} | ||
|
||
.popover-icon:focus { | ||
box-shadow: none; | ||
} |
4 changes: 4 additions & 0 deletions
4
...ind/mgr/dashboard/frontend/src/app/ceph/dashboard/info-group/info-group.component.spec.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
3 changes: 3 additions & 0 deletions
3
src/pybind/mgr/dashboard/frontend/src/app/ceph/dashboard/info-group/info-group.component.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 |
---|---|---|
@@ -1,11 +1,14 @@ | ||
import { Component, Input } from '@angular/core'; | ||
|
||
import { Icons } from '../../../shared/enum/icons.enum'; | ||
|
||
@Component({ | ||
selector: 'cd-info-group', | ||
templateUrl: './info-group.component.html', | ||
styleUrls: ['./info-group.component.scss'] | ||
}) | ||
export class InfoGroupComponent { | ||
icons = Icons; | ||
@Input() | ||
groupTitle: string; | ||
} |
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