diff --git a/src/components/default-listing.astro b/src/components/default-listing.astro index bcc31fd..7424d4e 100644 --- a/src/components/default-listing.astro +++ b/src/components/default-listing.astro @@ -7,6 +7,7 @@ import { import Aliases from '~/src/components/listing-parts/aliases.astro' import RelatedLinks from '~/src/components/listing-parts/related-links.astro' +import Devices from '~/src/components/listing-parts/devices.astro' import RelatedVideos from '~/src/components/listing-parts/related-videos.astro' import AllUpdatesSubscribe from '~/components/all-updates-subscribe.vue' @@ -48,6 +49,10 @@ const details = new ListingDetails( listing ) /> + + diff --git a/src/components/listing-parts/devices.astro b/src/components/listing-parts/devices.astro new file mode 100644 index 0000000..e7b54fe --- /dev/null +++ b/src/components/listing-parts/devices.astro @@ -0,0 +1,33 @@ +--- +import Heading from './heading.astro' + +const { + listing +} = Astro.props + +const hasDeviceSupport = Array.isArray( listing.deviceSupport ) +--- +{ hasDeviceSupport && ( +
+ + + +
+ + { listing.deviceSupport.map( device => ( + + )) } + +
+ +
+)}