Skip to content

Commit

Permalink
Restore fragments
Browse files Browse the repository at this point in the history
  • Loading branch information
dgcohen committed Dec 11, 2024
1 parent 702b3ec commit 1645a55
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 11 deletions.
11 changes: 3 additions & 8 deletions src/components/BibPage/BibDetail.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -61,14 +61,9 @@ const DetailElement = (label: string, listChildren: ReactNode[]) => {
<>
<dt>{label}</dt>
<dd>
<List
noStyling
data-testid={kebabCase(label)}
type="ol"
listItems={listChildren.map((listElement) => (
<>{listElement}</>
))}
/>
<List noStyling data-testid={kebabCase(label)} type="ol">
{listChildren}
</List>
</dd>
</>
)
Expand Down
8 changes: 6 additions & 2 deletions src/components/HoldPages/HoldConfirmationItemDetails.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,19 @@ const HoldConfirmationItemDetails = ({
mb="l"
mt={0}
>
{pickupLocationLabel && (
{pickupLocationLabel ? (
<PlainTextElement
label="Pickup location"
value={[pickupLocationLabel]}
/>
) : (
<></>
)}
<PlainTextElement label="Call number" value={[item.callNumber]} />
{item.barcode && (
{item.barcode ? (
<PlainTextElement label="Barcode" value={[item.barcode]} />
) : (
<></>
)}
</List>
)
Expand Down
4 changes: 3 additions & 1 deletion src/components/HoldPages/HoldRequestItemDetails.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,10 @@ const HoldRequestItemDetails = ({ item }: HoldRequestItemDetailsProps) => {
link="internal"
/>
<PlainTextElement label="Call number" value={[item.callNumber]} />
{item.volume && (
{item.volume ? (
<PlainTextElement label="Volume/date" value={[item.volume]} />
) : (
<></>
)}
</List>
)
Expand Down

0 comments on commit 1645a55

Please sign in to comment.