Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prod release #1912

Merged
merged 22 commits into from
May 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
c184b21
fix: remove selected scene when filtered out
tylercchase Apr 1, 2024
2275906
fix: sbas clear selected on filtered out
tylercchase Apr 1, 2024
fe7ba19
Merge branch 'test' into tcc-baseline-fixes
tylercchase Apr 10, 2024
7fb0431
fix: scene memoize function no longer checks order
tylercchase Apr 25, 2024
d8626f7
Merge branch 'test' into tcc-baseline-fixes
tylercchase Apr 29, 2024
3d7ccd7
Merge pull request #1898 from asfadmin/tcc-baseline-fixes
tylercchase Apr 29, 2024
37eb727
fix: sbas RTC job use pair's products
tylercchase Apr 29, 2024
6351854
DS5349 - Menu issue in the drawing toolbar for AOI on SMALL desktop
artisticlight Apr 30, 2024
db3e062
Merge pull request #1904 from asfadmin/DS5349-andy-aoi
artisticlight Apr 30, 2024
e2e5cb2
Fixed spacing issue in doc modal
artisticlight May 1, 2024
57d8d40
Merge pull request #1905 from asfadmin/DS-5346-andy-doc-button
artisticlight May 1, 2024
5b718c7
Help "i" icons now link to the help docs matching Vertex language.
artisticlight May 2, 2024
b286c5b
Merge pull request #1907 from asfadmin/DS-5367-andy-lang-help-links
artisticlight May 2, 2024
a9a1cc5
adds aria version for aria products
May 7, 2024
79aca09
Merge pull request #1908 from asfadmin/topic-aria-version
SpicyGarlicAlbacoreRoll May 7, 2024
c4d7c15
Updated translations from Phrase
ASF-Discovery May 8, 2024
4961a3b
Merge branch 'test' into phrase-translations
artisticlight May 8, 2024
29d339e
Merge pull request #1909 from asfadmin/phrase-translations
artisticlight May 8, 2024
ece3fe4
Updated translations from Phrase
ASF-Discovery May 8, 2024
c4457c9
Updated translations from Phrase
ASF-Discovery May 8, 2024
a6ef742
Merge pull request #1910 from asfadmin/phrase-translations
artisticlight May 8, 2024
96e192f
fix: check for product date change for dummy products
tylercchase May 17, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ Add the following line via the methods below to set up local.asf.alaska.edu to p
| Windows | Modify c:\windows\system32\drivers\etc\hosts as Administrator |
```
ng serve --port 4444 --host local.asf.alaska.edu
ng serve --port 4445 --ssl true --host local.asf.alaska.edu
```

### Setting up HTTPS
Expand Down
2 changes: 2 additions & 0 deletions src/app/components/baseline-chart/baseline-chart.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,8 @@ export class BaselineChartComponent implements OnInit, OnDestroy {
if (selected) {
const selectedPoint = this.productToPoint(selected);
this.setDataset(ChartDatasets.SELECTED, [selectedPoint]);
} else {
this.setDataset(ChartDatasets.SELECTED, [])
}

this.setDataset(ChartDatasets.PRODUCTS, points);
Expand Down
4 changes: 2 additions & 2 deletions src/app/components/header/header.component.scss
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,9 @@ $config: mat.define-legacy-typography-config();
height: auto;
position: fixed;
top: 100px;
z-index: 1;
z-index: 2;
margin: 0;
padding: 3px 16px 16px;
padding: 3px 16px 25px;
}

.breadcrumb {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -361,6 +361,42 @@ export class ScenesListComponent implements OnInit, OnDestroy, AfterContentInit
)
);

this.subs.add(
combineLatest([
this.scenesService.scenes$,
this.store$.select(scenesStore.getSelectedScene)
]).pipe(
debounceTime(50),
).subscribe(([scenes, selectedScene]: any) => {
if(scenes && selectedScene) {
if(scenes.slice(0, this.numberProductsInList).findIndex((value) => {
return value.id === selectedScene.id;
}) === -1) {
this.selectedFromList = false;
this.store$.dispatch(new scenesStore.SetSelectedScene(null))
}
}
})
)

this.subs.add(
combineLatest([
this.pairService.pairs$,
this.store$.select(scenesStore.getSelectedPair)
]).pipe(
debounceTime(50)
).subscribe(([pairs, selectedPair]: any) => {
if(!selectedPair){
return
}
if([...pairs.pairs, ...pairs.custom].findIndex((value) => {
return value[0].id === selectedPair[0].id && value[1].id === selectedPair[1].id
}) === -1) {
this.selectedFromList = false;
this.store$.dispatch(new scenesStore.SetSelectedPair(null))
}
})
)
}

ngAfterContentInit() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@
<button mat-menu-item
*ngIf="breakpoint !== breakpoints.MOBILE"
(click)="onImportSelected()"
[disabled]="breakpoint <= breakpoints.SMALL"
class="control-mat-button-toggle">
<mat-icon class="interaction-icon">upload</mat-icon>
{{'UPLOAD_GEOSPATIAL_FILE' | translate}}
Expand Down
6 changes: 4 additions & 2 deletions src/app/components/shared/docs-modal/docs-modal-iframe.scss
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,13 @@
}

.mat-mdc-dialog-content {
max-height: calc(100% - 80px);
max-height: calc(100% - 75px);
padding: 0;
margin: -3px 0 0 0
}

.mat-mdc-dialog-actions {
padding: 16px 0 8px;
padding: 18px 30px;
}

.content-hr {
Expand Down
26 changes: 23 additions & 3 deletions src/app/components/shared/docs-modal/docs-modal.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@
import { Component, Input, OnInit, Inject } from '@angular/core';
import { MatDialog, MAT_DIALOG_DATA } from '@angular/material/dialog';
import { DomSanitizer } from '@angular/platform-browser';
import { TranslateService } from "@ngx-translate/core";


export interface DialogData {
rawUrl: string;
Expand All @@ -41,11 +43,15 @@ export class DocsModalComponent implements OnInit {
public safeDocURL: any;

constructor(public dialog: MatDialog,
private _sanitizer: DomSanitizer) {}
public translate: TranslateService,
private _sanitizer: DomSanitizer) {
}

ngOnInit(): void {
this.docURL = ( this.url ) ? this.url : 'https://docs.asf.alaska.edu';
this.safeDocURL = this._sanitizer.bypassSecurityTrustResourceUrl(this.docURL);
this.docURL = (this.url) ? this.url : 'https://docs.asf.alaska.edu';
let tempURL = this.docsLanguageAdjust(this.docURL);
this.safeDocURL = this._sanitizer.bypassSecurityTrustResourceUrl(tempURL);

}

public showDoc() {
Expand Down Expand Up @@ -73,6 +79,20 @@ export class DocsModalComponent implements OnInit {
const domain = (new URL(url)).hostname.replace('www.', '');
return domain.includes('asf.alaska.edu');
}

public docsLanguageAdjust(url: string): string {
let langCode = this.translate.currentLang;
if (langCode === 'es') {
url = this.insertLangCode(url, langCode);
}
return url;
}

public insertLangCode(url: string, langCode: string): string {
let newUrl = url.replace('.edu/', '.edu/' + langCode + '/');
return newUrl;
}

}

@Component({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -210,6 +210,10 @@
</li>


<li *ngIf="!!scene.metadata.ariaVersion">
<b> {{'ARIA_VERSION' | translate }} </b> • {{scene.metadata.ariaVersion}}
</li>

<li *ngIf="dataset.source as source" class="detail-item-margin">
<a *ngIf="source.url" [href]="source.url" target="_blank"> {{'DATA_COURTESY_OF' | translate}} {{ dataset.source.name }}</a>
<span *ngIf="!source.url" class="faint-text"> {{'DATA_COURTESY_OF' | translate}} {{ dataset.source.name }}</span>
Expand Down
3 changes: 3 additions & 0 deletions src/app/models/cmr-product.model.ts
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,9 @@ export interface CMRProductMetadata {
// BURST XML, OPERA-S1
subproducts: any[];
parentID: string;

// ARIA S1 GUNW
ariaVersion: string | null;
}

export interface SLCBurstMetadata {
Expand Down
4 changes: 3 additions & 1 deletion src/app/services/possible-hyp3-jobs.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,9 @@ export class PossibleHyp3JobsService {
));

private hyp3ableJobsSBAS$ = combineLatest([
this.possibleProductJobs$,
this.pairService.productsFromPairs$.pipe(map(
products => products.map(p => [p])
)),
this.pairs$,
]).pipe(
map(([possibleJobs, {pairs, custom}]) => {
Expand Down
3 changes: 2 additions & 1 deletion src/app/services/product.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,8 @@ export class ProductService {
opera: g.s1o ? g.s1o : null,
pgeVersion: g.pge !== null ? parseFloat(g.pge) : null,
subproducts: [],
parentID: null
parentID: null,
ariaVersion: g.ariav ? g.ariav : null
})

private isNumber = n => !isNaN(n) && isFinite(n);
Expand Down
6 changes: 4 additions & 2 deletions src/app/store/scenes/scenes.reducer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -426,12 +426,14 @@ function arrayEquals(a, b) {
return Array.isArray(a) &&
Array.isArray(b) &&
a.length === b.length &&
a.toString() === b.toString() &&
a.every((value, index) => {
if(Array.isArray(value) && Array.isArray(b[index])) {
return arrayEquals(value, b[index])
} else {
value.id === b[index].id
return b.findIndex((b_value) =>
{
return b_value?.id === value?.id && b_value.metadata.date === value.metadata.date
}) >= 0
}
}
)
Expand Down
1 change: 1 addition & 0 deletions src/assets/i18n/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@
"AREA_OF_INTEREST": "Area Of Interest",
"AREA_OF_INTEREST_OPTIONS": "Area of Interest Options",
"AREA_OF_INTEREST_WKT": "Area of Interest • WKT",
"ARIA_VERSION": "ARIA Version",
"ARROW_BACKWARD": "arrow_backward",
"ARROW_FORWARD": "arrow_forward",
"ASCENDING": "Ascending",
Expand Down
1 change: 1 addition & 0 deletions src/assets/i18n/es.json
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@
"AREA_OF_INTEREST": "Área de Interés",
"AREA_OF_INTEREST_OPTIONS": "Opciones de Área de Interés",
"AREA_OF_INTEREST_WKT": "Área de Interés • WKT",
"ARIA_VERSION": "Versión ARIA",
"ARROW_BACKWARD": "flecha_hacia atrás",
"ARROW_FORWARD": "flecha_adelante",
"ASCENDING": "Ascendente",
Expand Down
Loading