diff --git a/common/constants.js b/common/constants.js index 2ba7fc2bb8c3a9ca8dcdf85ba95d770e2dbb9d2b..64e7626ba53fb648da7e77361e8e29c4372c1ac3 100644 --- a/common/constants.js +++ b/common/constants.js @@ -22,6 +22,7 @@ PIN_DATASET: 'Toggle pinning dataset', TEXT_INPUT_SEARCH_REGION: 'Search for any region of interest in the atlas selected', CLEAR_SELECTED_REGION: 'Clear selected region', + VIEW_PINNED: `View pinned datasets.`, BULK_DOWNLOAD: `Download all pinned data`, NO_BULK_DOWNLOAD: `No datasets pinned`, diff --git a/docs/releases/v2.4.3.md b/docs/releases/v2.4.3.md index ede740c0394d101dc0fdf1074816c325bffbcbeb..a91b54fd8df91420a49c0a69415f04782b0a7c12 100644 --- a/docs/releases/v2.4.3.md +++ b/docs/releases/v2.4.3.md @@ -2,4 +2,5 @@ ## Bugfixes -- fix some of the big brain maps \ No newline at end of file +- fix some of the big brain maps +- added UI indication for deprecation/unavailability of functionalities diff --git a/src/ui/topMenu/topMenuCmp/topMenu.components.ts b/src/ui/topMenu/topMenuCmp/topMenu.components.ts index 92f65b7268a2760a01f2639b3ecb721edd1f046e..0ad9293108f5b9225d270fd4b4987d1e570fef2c 100644 --- a/src/ui/topMenu/topMenuCmp/topMenu.components.ts +++ b/src/ui/topMenu/topMenuCmp/topMenu.components.ts @@ -3,6 +3,7 @@ import { Component, Input, TemplateRef, + ViewChild, } from "@angular/core"; import { select, Store } from "@ngrx/store"; import { Observable } from "rxjs"; @@ -11,7 +12,7 @@ import { AuthService } from "src/auth"; import { IavRootStoreInterface, IDataEntry } from "src/services/stateStore.service"; import { MatDialog, MatDialogConfig, MatDialogRef } from "@angular/material/dialog"; import { MatBottomSheet } from "@angular/material/bottom-sheet"; -import { CONST, QUICKTOUR_DESC } from 'common/constants' +import { CONST, QUICKTOUR_DESC, ARIA_LABELS } from 'common/constants' import { IQuickTourData } from "src/ui/quickTour/constrants"; @Component({ @@ -25,6 +26,7 @@ import { IQuickTourData } from "src/ui/quickTour/constrants"; export class TopMenuCmp { + public ARIA_LABELS = ARIA_LABELS public PINNED_DATASETS_BADGE_DESC = CONST.PINNED_DATASETS_BADGE_DESC public matBtnStyle = 'mat-icon-button' @@ -57,6 +59,14 @@ export class TopMenuCmp { order: 8, } + public pinnedDsNotAvail = 'We are reworking pinned dataset feature. Please check back later.' + @ViewChild('savedDatasets', { read: TemplateRef }) + private savedDatasetTmpl: TemplateRef<any> + + public openPinnedDatasets(){ + // this.bottomSheet.open(this.savedDatasetTmpl) + } + constructor( private store$: Store<IavRootStoreInterface>, private authService: AuthService, diff --git a/src/ui/topMenu/topMenuCmp/topMenu.template.html b/src/ui/topMenu/topMenuCmp/topMenu.template.html index cb253e7ecf66bd29d1cb972f7d3f491b1e220f3d..4dc319f6a9fcc0a66f4bba8cdd5e776f7dc37f7e 100644 --- a/src/ui/topMenu/topMenuCmp/topMenu.template.html +++ b/src/ui/topMenu/topMenuCmp/topMenu.template.html @@ -107,16 +107,19 @@ <!-- pinned dataset btn --> <ng-template #pinnedDatasetBtnTmpl> <div class="btnWrapper" - (click)="bottomSheet.open(savedDatasets)" + (click)="openPinnedDatasets()" [matBadge]="(favDataEntries$ | async)?.length > 0 ? (favDataEntries$ | async)?.length : null " matBadgeColor="accent" matBadgePosition="above after" [matBadgeDescription]="PINNED_DATASETS_BADGE_DESC" - matTooltip="Pinned datasets"> + [matTooltip]="pinnedDsNotAvail" + aria-disabled="true" + role="button"> <iav-dynamic-mat-button [attr.pinned-datasets-length]="(favDataEntries$ | async)?.length" [iav-dynamic-mat-button-style]="matBtnStyle" [iav-dynamic-mat-button-color]="matBtnColor" + [iav-dynamic-mat-button-disabled]="true" iav-dynamic-mat-button-aria-label="Show pinned datasets"> <i class="fas fa-thumbtack"></i> diff --git a/src/viewerModule/nehuba/statusCard/statusCard.component.ts b/src/viewerModule/nehuba/statusCard/statusCard.component.ts index a6daa233d6acdc5197d19d4a9dbc284c3e26f329..76dfa6bbbdb0288b6755984fa651d71b3e50c5df 100644 --- a/src/viewerModule/nehuba/statusCard/statusCard.component.ts +++ b/src/viewerModule/nehuba/statusCard/statusCard.component.ts @@ -57,6 +57,8 @@ export class StatusCardComponent implements OnInit, OnChanges{ order: 6, } + public saneUrlDeprecated = `Custom URL is going away. New custom URLs can no longer be created. Custom URLs you generated in the past will continue to work.` + public SHARE_BTN_ARIA_LABEL = ARIA_LABELS.SHARE_BTN public COPY_URL_TO_CLIPBOARD_ARIA_LABEL = ARIA_LABELS.SHARE_COPY_URL_CLIPBOARD public SHARE_CUSTOM_URL_ARIA_LABEL = ARIA_LABELS.SHARE_CUSTOM_URL diff --git a/src/viewerModule/nehuba/statusCard/statusCard.template.html b/src/viewerModule/nehuba/statusCard/statusCard.template.html index 5e4d793a725e31f41f5bd45406a11b95ef1340a6..5f57d9719055a265dbfb005c5c4d7d3cc46ab1ea 100644 --- a/src/viewerModule/nehuba/statusCard/statusCard.template.html +++ b/src/viewerModule/nehuba/statusCard/statusCard.template.html @@ -154,9 +154,11 @@ Copy link to this view </span> </mat-list-item> - <mat-list-item (click)="openDialog(shareSaneUrl, { ariaLabel: SHARE_CUSTOM_URL_DIALOG_ARIA_LABEL })" + <mat-list-item [attr.aria-label]="SHARE_CUSTOM_URL_ARIA_LABEL" - [attr.tab-index]="10"> + [attr.tab-index]="10" + [matTooltip]="saneUrlDeprecated" + class="text-muted"> <mat-icon class="mr-4" fontSet="fas"