Show only published linked location on credits
This commit is contained in:
@@ -121,19 +121,21 @@
|
||||
</dt>
|
||||
<dd>
|
||||
<ul>
|
||||
{#each location as { location_id: { name, slug: slugLocation, country: { slug: slugCountry, flag }}}, index}
|
||||
{#each location as loc}
|
||||
{#if loc.location_id}
|
||||
<li>
|
||||
<a href="/{slugCountry}/{slugLocation}" sveltekit:noscroll tabindex="0">
|
||||
<a href="/{loc.location_id.country.slug}/{loc.location_id.slug}" sveltekit:noscroll tabindex="0">
|
||||
<Image
|
||||
id={flag.id}
|
||||
id={loc.location_id.country.flag.id}
|
||||
sizeKey="square-small"
|
||||
width={16}
|
||||
height={16}
|
||||
alt="Flag of {slugCountry}"
|
||||
alt="Flag of {loc.location_id.country.slug}"
|
||||
/>
|
||||
<span>{name}</span>
|
||||
<span>{loc.location_id.name}</span>
|
||||
</a>
|
||||
</li>
|
||||
{/if}
|
||||
{/each}
|
||||
</ul>
|
||||
</dd>
|
||||
@@ -165,7 +167,7 @@
|
||||
name
|
||||
website
|
||||
location {
|
||||
location_id {
|
||||
location_id (filter: { status: { _eq: "published" }}) {
|
||||
name
|
||||
slug
|
||||
country {
|
||||
@@ -179,7 +181,6 @@
|
||||
}
|
||||
}
|
||||
`)
|
||||
|
||||
const { data } = res
|
||||
|
||||
return {
|
||||
|
||||
Reference in New Issue
Block a user