Skip to content

Commit

Permalink
Allow customizing strings for data catalog and stories banners (#664)
Browse files Browse the repository at this point in the history
Allows [this](US-GHG-Center/veda-config-ghg#96)
without needing custom code on the `ghg` branch
  • Loading branch information
nerik authored Sep 20, 2023
2 parents dba8c2b + 1459aaf commit c66fb54
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 5 deletions.
12 changes: 9 additions & 3 deletions app/scripts/components/data-catalog/index.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React, { useMemo, useRef } from 'react';
import styled from 'styled-components';
import { DatasetData, datasets, datasetTaxonomies } from 'veda';
import { DatasetData, datasets, datasetTaxonomies, getString } from 'veda';
import { Link } from 'react-router-dom';
import { glsp } from '@devseed-ui/theme-provider';
import { Subtitle } from '@devseed-ui/typography';
Expand Down Expand Up @@ -155,11 +155,17 @@ function DataCatalog() {
<PageMainContent>
<LayoutProps
title='Data Catalog'
description='This dashboard explores key indicators to track and compare changes over time.'
description={
getString('dataCatalogBanner')?.other ||
'This dashboard explores key indicators to track and compare changes over time.'
}
/>
<PageHero
title='Data Catalog'
description='This dashboard explores key indicators to track and compare changes over time.'
description={
getString('dataCatalogBanner')?.other ||
'This dashboard explores key indicators to track and compare changes over time.'
}
/>

<FeaturedDatasets />
Expand Down
4 changes: 2 additions & 2 deletions app/scripts/components/stories/hub/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -161,11 +161,11 @@ function StoriesHub() {
<PageMainContent>
<LayoutProps
title={getString('stories').other}
description='Explore the guided narratives below to discover how NASA satellites and other Earth observing resources reveal a changing planet.'
description={getString('storiesBanner')?.other || 'Explore the guided narratives below to discover how NASA satellites and other Earth observing resources reveal a changing planet.'}
/>
<PageHero
title={getString('stories').other}
description='Explore the guided narratives below to discover how NASA satellites and other Earth observing resources reveal a changing planet.'
description={getString('storiesBanner')?.other || 'Explore the guided narratives below to discover how NASA satellites and other Earth observing resources reveal a changing planet.'}
/>

<FeaturedStories />
Expand Down

0 comments on commit c66fb54

Please sign in to comment.