mirror of
https://github.com/ThatGuySam/doesitarm.git
synced 2026-05-15 06:35:20 -07:00
Add game report url for games
This commit is contained in:
parent
13e36c3bc8
commit
a70cc0279d
1 changed files with 10 additions and 2 deletions
|
|
@ -1,12 +1,20 @@
|
|||
---
|
||||
import { ensureListingDetails } from '~/helpers/listing-page.js'
|
||||
import { makeLastUpdatedFriendly } from '~/helpers/parse-date.js'
|
||||
|
||||
const {
|
||||
listing
|
||||
listing
|
||||
} = Astro.props
|
||||
|
||||
const details = ensureListingDetails( listing )
|
||||
|
||||
const lastUpdatedFriendly = makeLastUpdatedFriendly( listing.lastUpdated )
|
||||
|
||||
const gameReportUrl = 'https://forms.gle/29GWt85i1G1L7Ttj8'
|
||||
const defaultReportUrl = `https://github.com/ThatGuySam/doesitarm/issues?q=is%3Aissue+${ listing.name }`
|
||||
|
||||
const reportUrl = details.isGame ? gameReportUrl : defaultReportUrl
|
||||
|
||||
---
|
||||
<div class="report-update text-xs text-center w-full shadow-none py-24">
|
||||
{ lastUpdatedFriendly !== null &&
|
||||
|
|
@ -20,7 +28,7 @@ const lastUpdatedFriendly = makeLastUpdatedFriendly( listing.lastUpdated )
|
|||
}
|
||||
<!-- https://eric.blog/2016/01/08/prefilling-github-issues/ -->
|
||||
<a
|
||||
href={ `https://github.com/ThatGuySam/doesitarm/issues?q=is%3Aissue+${ listing.name }` }
|
||||
href={ reportUrl }
|
||||
target="_blank"
|
||||
class="underline"
|
||||
rel="noopener"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue