* Revert "fix: featured version ui shifts (#1191)"

This reverts commit 3036f43b75.

* Revert "Fix CTRL clicking on versions issue (#1189)"

This reverts commit f4560bd7d8.
This commit is contained in:
Prospector
2023-06-20 14:51:49 -07:00
committed by GitHub
parent 247be0c11f
commit 6b940ed675

View File

@@ -569,46 +569,47 @@
<ChevronRightIcon class="featured-header-chevron" aria-hidden="true" /> <ChevronRightIcon class="featured-header-chevron" aria-hidden="true" />
</nuxt-link> </nuxt-link>
</div> </div>
<ClientOnly> <div
<NuxtLink v-for="version in featuredVersions"
v-for="(version, index) in featuredVersions" :key="version.id"
:key="index" class="featured-version button-transparent"
class="featured-version button-transparent" @click="
:to="`/${project.project_type}/${ $router.push(
project.slug ? project.slug : project.id `/${project.project_type}/${
}/version/${encodeURI(version.displayUrlEnding)}`" project.slug ? project.slug : project.id
:ref_key="`featured-version-${index}`" }/version/${encodeURI(version.displayUrlEnding)}`
)
"
>
<a
v-tooltip="
version.primaryFile.filename + ' (' + $formatBytes(version.primaryFile.size) + ')'
"
:href="version.primaryFile.url"
class="download square-button brand-button"
:aria-label="`Download ${version.name}`"
@click.stop="(event) => event.stopPropagation()"
> >
<NuxtLink <DownloadIcon aria-hidden="true" />
v-tooltip=" </a>
version.primaryFile.filename + ' (' + $formatBytes(version.primaryFile.size) + ')' <div class="info">
" <nuxt-link
:to="version.primaryFile.url" :to="`/${project.project_type}/${
external project.slug ? project.slug : project.id
class="download square-button brand-button" }/version/${encodeURI(version.displayUrlEnding)}`"
:aria-label="`Download ${version.name}`" class="top"
> >
<DownloadIcon aria-hidden="true" /> {{ version.name }}
</NuxtLink> </nuxt-link>
<div class="info"> <div v-if="version.game_versions.length > 0" class="game-version item">
<NuxtLink {{ version.loaders.map((x) => $formatCategory(x)).join(', ') }}
:to="`/${project.project_type}/${ {{ $formatVersion(version.game_versions) }}
project.slug ? project.slug : project.id
}/version/${encodeURI(version.displayUrlEnding)}`"
class="top"
>
{{ version.name }}
</NuxtLink>
<div v-if="version.game_versions.length > 0" class="game-version item">
{{ version.loaders.map((x) => $formatCategory(x)).join(', ') }}
{{ $formatVersion(version.game_versions) }}
</div>
<Badge v-if="version.version_type === 'release'" type="release" color="green" />
<Badge v-else-if="version.version_type === 'beta'" type="beta" color="orange" />
<Badge v-else-if="version.version_type === 'alpha'" type="alpha" color="red" />
</div> </div>
</NuxtLink> <Badge v-if="version.version_type === 'release'" type="release" color="green" />
</ClientOnly> <Badge v-else-if="version.version_type === 'beta'" type="beta" color="orange" />
<Badge v-else-if="version.version_type === 'alpha'" type="alpha" color="red" />
</div>
</div>
<hr class="card-divider" /> <hr class="card-divider" />
</template> </template>
<h2 class="card-header">Project members</h2> <h2 class="card-header">Project members</h2>