Skip to content

Commit

Permalink
Merge branch 'main' into placeholder-text
Browse files Browse the repository at this point in the history
  • Loading branch information
vinnyjth authored Mar 12, 2024
2 parents 75c797b + 5a9963f commit d005254
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 3 deletions.
2 changes: 1 addition & 1 deletion packages/web-shared/components/ContentSeriesSingle.js
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@ function ContentSeriesSingle(props = {}) {
<H3 mb="xs">{props.feature?.title}</H3>
<Box
display="grid"
gridGap="100px 30px"
gridGap="70px 30px"
gridTemplateColumns={{
_: 'repeat(1, minmax(0, 1fr));',
md: 'repeat(2, minmax(0, 1fr));',
Expand Down
8 changes: 7 additions & 1 deletion packages/web-shared/components/ContentSingle.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,11 @@ import { getURLFromType } from '../utils';
import { format, parseISO } from 'date-fns';
import FeatureFeed from './FeatureFeed';
import FeatureFeedComponentMap from './FeatureFeed/FeatureFeedComponentMap';
import { add as addBreadcrumb, useBreadcrumbDispatch } from '../providers/BreadcrumbProvider';
import {
add as addBreadcrumb,
remove as removeBreadcrumb,
useBreadcrumbDispatch,
} from '../providers/BreadcrumbProvider';
import { set as setModal, useModal } from '../providers/ModalProvider';

import {
Expand Down Expand Up @@ -169,6 +173,7 @@ function ContentSingle(props = {}) {
)}`
: null;
const handleActionPress = (item) => {
dispatchBreadcrumb(removeBreadcrumb());
if (searchParams.get('id') !== getURLFromType(item)) {
dispatchBreadcrumb(
addBreadcrumb({
Expand Down Expand Up @@ -264,6 +269,7 @@ function ContentSingle(props = {}) {
flexDirection="row"
justifyContent="space-between"
alignItems="center"
mb="base"
>
{title ? <Title>{title}</Title> : null}
{/* Button moves below on mobile views */}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ function HorizontalCardListFeature(props = {}) {
dispatchBreadcrumb(
addBreadcrumb({
url: `?id=${getURLFromType(item.relatedNode)}`,
title: item.relatedNode?.title,
title: item.relatedNode?.title || item?.title,
})
);
setSearchParams(`?id=${getURLFromType(item.relatedNode)}`);
Expand Down

0 comments on commit d005254

Please sign in to comment.