You've already forked pages
forked from didirus/AstralRinth
Fix SVGs, cleanup, switch stats backend
This commit is contained in:
Binary file not shown.
|
Before Width: | Height: | Size: 3.8 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 12 KiB |
11
assets/images/categories/fabric.svg
Normal file
11
assets/images/categories/fabric.svg
Normal file
@@ -0,0 +1,11 @@
|
||||
<svg viewBox="0 0 276 288" fill="none" stroke="currentColor" stroke-width="23" stroke-linecap="round" stroke-linejoin="round">
|
||||
<g transform="matrix(1,0,0,1,-3302.43,-67.3276)">
|
||||
<g transform="matrix(0.564163,0,0,1.70346,1629.87,0)">
|
||||
<g transform="matrix(1.97801,-0.0501803,0.151517,0.655089,1678.7,-354.14)">
|
||||
<g>
|
||||
<path d="M820.011,761.092C798.277,738.875 754.809,694.442 734.36,673.389C729.774,668.668 723.992,663.75 708.535,674.369C688.629,688.043 700.073,696.251 703.288,699.785C711.508,708.824 787.411,788.803 800.523,803.818C802.95,806.597 780.243,781.318 793.957,764.065C799.444,757.163 811.985,752.043 820.011,761.092C826.534,768.447 830.658,779.178 816.559,790.826C791.91,811.191 714.618,873.211 689.659,893.792C677.105,904.144 661.053,896.143 653.827,887.719C646.269,878.908 623.211,853.212 602.539,829.646C596.999,823.332 598.393,810.031 604.753,804.545C639.873,774.253 696.704,730.787 716.673,713.831"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 1.0 KiB |
9
assets/images/categories/forge.svg
Normal file
9
assets/images/categories/forge.svg
Normal file
@@ -0,0 +1,9 @@
|
||||
<svg viewBox="0 0 362 208" fill="none" stroke="currentColor" stroke-width="6" stroke-linecap="round" stroke-linejoin="round">
|
||||
<g transform="matrix(1,0,0,1,-3259.27,-486.011)">
|
||||
<g transform="matrix(0.564163,0,0,1.70346,1629.87,0)">
|
||||
<g transform="matrix(6.76583,0,0,2.24074,2829.95,275.109)">
|
||||
<path d="M91.6,16.7L100,14.8L100,7.944L47.452,7.944L47.452,14.388L12,14.1C13.9,15.7 24.4,24.7 31.9,28.4C35.6,30.2 40.2,30.3 44.3,30.4C46.4,30.5 48.5,30.6 50.1,32.2C52.4,34.4 52.9,37.9 50.9,40.5C49,43.1 43.6,43.7 43.6,43.7L39,49.1L39,55.5L85.8,55.5L85.8,49.1L81.3,43.6C81.3,43.6 74.6,43.2 72.9,40.4C67.7,32.6 74.8,20.4 91.6,16.7Z"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 709 B |
Binary file not shown.
|
Before Width: | Height: | Size: 11 KiB |
15
assets/images/utils/calendar.svg
Normal file
15
assets/images/utils/calendar.svg
Normal file
@@ -0,0 +1,15 @@
|
||||
<svg viewBox="0 0 273 291" fill-rule="evenodd" stroke-linejoin="round">
|
||||
<g transform="matrix(1,0,0,1,-3303.68,-2082.6)">
|
||||
<g transform="matrix(0.564163,0,0,1.70346,1629.87,0)">
|
||||
<g transform="matrix(29.6754,0,-5.39484e-14,10.5245,2970.52,1222.47)">
|
||||
<g transform="matrix(1.4323,0,0,1.4323,-3.56656,-3.89073)">
|
||||
<path d="M10.854,7.146C10.948,7.24 11.001,7.367 11.001,7.5C11.001,7.633 10.948,7.76 10.854,7.854L7.854,10.854C7.76,10.948 7.633,11.001 7.5,11.001C7.367,11.001 7.24,10.948 7.146,10.854L5.646,9.354C5.552,9.26 5.499,9.133 5.499,9C5.499,8.725 5.725,8.499 6,8.499C6.133,8.499 6.26,8.552 6.354,8.646L7.5,9.793L10.146,7.146C10.24,7.052 10.367,6.999 10.5,6.999C10.633,6.999 10.76,7.052 10.854,7.146Z"/>
|
||||
</g>
|
||||
<path d="M1.427,4L1.427,13.715C1.427,14.264 1.879,14.715 2.427,14.715L13.573,14.715C14.121,14.715 14.573,14.264 14.573,13.715L14.573,4L1.427,4ZM1.878,1C0.781,1 -0.122,1.903 -0.122,3L-0.122,14.191C-0.122,15.288 0.781,16.191 1.878,16.191L14.183,16.191C15.28,16.191 16.183,15.097 16.183,14L16.183,3C16.183,1.903 15.28,1 14.183,1L1.878,1Z"/>
|
||||
<g transform="matrix(1.32086,0,-1.73365e-32,1.32086,-3.43823,0.00935866)">
|
||||
<path d="M4.819,0C5.094,-0 5.319,0.226 5.319,0.5L5.319,1C5.319,1.274 5.094,1.5 4.819,1.5C4.545,1.5 4.319,1.274 4.319,1L4.319,0.5C4.319,0.226 4.545,0 4.819,0ZM12.5,0C12.774,-0 13,0.226 13,0.5L13,1C13,1.274 12.774,1.5 12.5,1.5C12.226,1.5 12,1.274 12,1L12,0.5C12,0.226 12.226,0 12.5,0Z"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 1.6 KiB |
@@ -39,20 +39,7 @@
|
||||
<p>{{ formatNumber(downloads) }}</p>
|
||||
</div>
|
||||
<div class="result-image columns">
|
||||
<svg viewBox="0 0 16 16" fill="#099fef">
|
||||
<path
|
||||
fill-rule="evenodd"
|
||||
d="M10.854 7.146a.5.5 0 0 1 0 .708l-3 3a.5.5 0 0 1-.708 0l-1.5-1.5a.5.5 0 1 1 .708-.708L7.5 9.793l2.646-2.647a.5.5 0 0 1 .708 0z"
|
||||
/>
|
||||
<path
|
||||
fill-rule="evenodd"
|
||||
d="M1 4v10a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1V4H1zm1-3a2 2 0 0 0-2 2v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V3a2 2 0 0 0-2-2H2z"
|
||||
/>
|
||||
<path
|
||||
fill-rule="evenodd"
|
||||
d="M3.5 0a.5.5 0 0 1 .5.5V1a.5.5 0 0 1-1 0V.5a.5.5 0 0 1 .5-.5zm9 0a.5.5 0 0 1 .5.5V1a.5.5 0 0 1-1 0V.5a.5.5 0 0 1 .5-.5z"
|
||||
/>
|
||||
</svg>
|
||||
<CalendarIcon fill="#099fef" />
|
||||
<p>{{ $dayjs(createdAt).fromNow() }}</p>
|
||||
</div>
|
||||
<div v-if="updatedAt" class="result-image columns">
|
||||
@@ -91,22 +78,8 @@
|
||||
</div>
|
||||
|
||||
<div class="loaders columns">
|
||||
<img
|
||||
v-if="categories.includes('fabric')"
|
||||
src="https://fabricmc.net/assets/logo.png"
|
||||
alt="fabric"
|
||||
/>
|
||||
|
||||
<svg v-if="categories.includes('forge')" viewBox="0 0 90 46">
|
||||
<defs>
|
||||
<path
|
||||
id="a"
|
||||
fill="#1e2d44"
|
||||
d="M85.8 49.1l-4.5-5.5q-1.65-.1-3.55-.55-3.8-.95-4.85-2.65Q68.75 34.25 74 27q5.45-7.65 17.55-10.3l-37.8-1.9H100v-3.7H47.75v14q0 .65-1.9-11.7h-4.1v13l-1.9-12.3h-27.9q12.85 10.8 19.9 14.3 2.45 1.2 6.05 1.65 2.1.25 6.35.35 2.1.1 3.1.35 1.65.4 2.7 1.45 1.75 1.7 2 4 .3 2.4-1.2 4.3-1.2 1.65-4.35 2.6l-2.95.6L39 49.1v6.4h10.25l.3-6.3 8.95-6.3q-2.85 2.4-6.25 7.7-.95 1.5-1.7 3.5 1.7-1.45 4.9-2.3 3.3-.9 7.3-.9 3.9 0 7.2.9 3.25.85 4.95 2.3-.6-1.75-1.7-3.5-3.4-5.2-6.2-7.7l8.9 6.3.3 6.3h9.6v-6.4z"
|
||||
/>
|
||||
</defs>
|
||||
<use transform="translate(-10.95 -10.3)" xlink:href="#a" />
|
||||
</svg>
|
||||
<FabricLoader v-if="categories.includes('fabric')" stroke="#AC6C3A" />
|
||||
<ForgeLoader v-if="categories.includes('forge')" stroke="#8B81E6" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="categories">
|
||||
@@ -163,6 +136,8 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import CalendarIcon from '~/assets/images/utils/calendar.svg?inline'
|
||||
|
||||
import TechCategory from '~/assets/images/categories/tech.svg?inline'
|
||||
import AdventureCategory from '~/assets/images/categories/adventure.svg?inline'
|
||||
import CursedCategory from '~/assets/images/categories/cursed.svg?inline'
|
||||
@@ -176,6 +151,9 @@ import StorageCategory from '~/assets/images/categories/storage.svg?inline'
|
||||
import UtilityCategory from '~/assets/images/categories/utility.svg?inline'
|
||||
import WorldGenCategory from '~/assets/images/categories/worldgen.svg?inline'
|
||||
|
||||
import ForgeLoader from '~/assets/images/categories/forge.svg?inline'
|
||||
import FabricLoader from '~/assets/images/categories/fabric.svg?inline'
|
||||
|
||||
export default {
|
||||
name: 'ModResult',
|
||||
components: {
|
||||
@@ -191,6 +169,9 @@ export default {
|
||||
StorageCategory,
|
||||
UtilityCategory,
|
||||
WorldGenCategory,
|
||||
ForgeLoader,
|
||||
FabricLoader,
|
||||
CalendarIcon,
|
||||
},
|
||||
props: {
|
||||
id: {
|
||||
|
||||
@@ -83,7 +83,14 @@ export default {
|
||||
'https://fonts.googleapis.com/css2?family=Montserrat+Alternates:wght@600&display=swap',
|
||||
},
|
||||
],
|
||||
script: [],
|
||||
script: [
|
||||
{
|
||||
src: 'https://analytics.modrinth.com/umami.js',
|
||||
'data-website-id': 'c37613de-245d-4767-90e7-ba7980a4f1a2',
|
||||
async: true,
|
||||
defer: true,
|
||||
},
|
||||
],
|
||||
},
|
||||
|
||||
vue: {
|
||||
@@ -118,7 +125,6 @@ export default {
|
||||
'@nuxtjs/eslint-module',
|
||||
'@nuxtjs/svg',
|
||||
'@nuxtjs/color-mode',
|
||||
'nuxt-ackee',
|
||||
],
|
||||
/*
|
||||
** Nuxt.js modules
|
||||
@@ -131,12 +137,6 @@ export default {
|
||||
'@nuxtjs/robots',
|
||||
'@nuxtjs/sitemap',
|
||||
],
|
||||
ackee: {
|
||||
server: 'https://analytics.modrinth.com',
|
||||
domainId: '1840cc3a-64b1-431e-97a4-c122bb64d4c0',
|
||||
ignoreLocalhost: true,
|
||||
detailed: true,
|
||||
},
|
||||
robots: {
|
||||
Sitemap: 'https://modrinth.com/sitemap.xml',
|
||||
},
|
||||
|
||||
@@ -33,7 +33,6 @@
|
||||
"eslint-plugin-nuxt": "^1.0.0",
|
||||
"eslint-plugin-prettier": "^3.1.4",
|
||||
"node-sass": "^4.14.1",
|
||||
"nuxt-ackee": "^2.0.0",
|
||||
"prettier": "^2.1.2",
|
||||
"sass-loader": "^9.0.3"
|
||||
}
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
<template>
|
||||
<div>
|
||||
<header class="columns">
|
||||
<nuxt-link to="/"
|
||||
><img class="logo" src="~/assets/images/logo.svg" alt="logo"
|
||||
/></nuxt-link>
|
||||
<nuxt-link to="/">
|
||||
<img class="logo" src="~/assets/images/logo.svg" alt="logo" />
|
||||
</nuxt-link>
|
||||
<div class="links">
|
||||
<nuxt-link to="/">Home</nuxt-link>
|
||||
<nuxt-link to="/mods">Mods</nuxt-link>
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<div></div>
|
||||
<div>{{ JSON.stringify(mod) }}</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
@@ -7,13 +7,46 @@ import axios from 'axios'
|
||||
|
||||
export default {
|
||||
auth: false,
|
||||
/*
|
||||
{ 13:42:51
|
||||
id: 'kN7Mtmyo',
|
||||
team: 'eiP0Hzmw',
|
||||
title: 'Gravestones',
|
||||
description: 'A gravestones mod for fabric with tons ' +
|
||||
'of config options, an API, and more!',
|
||||
body_url: 'https://cdn.modrinth.com/file/modrinth/data/kN7Mtmyo/body.md',
|
||||
published: '2020-10-16T21:17:54.858156Z',
|
||||
updated: '2020-10-16T21:17:50.982804Z',
|
||||
status: 'processing',
|
||||
downloads: 0,
|
||||
categories: [
|
||||
'adventure',
|
||||
'utility',
|
||||
'library'
|
||||
],
|
||||
versions: [
|
||||
'XUky61nw'
|
||||
],
|
||||
icon_url: 'https://cdn.modrinth.com/file/modrinth/mods/icons/kN7Mtmyo/gravestones.png',
|
||||
issues_url: null,
|
||||
source_url: null,
|
||||
wiki_url: null
|
||||
}
|
||||
|
||||
*/
|
||||
async asyncData(data) {
|
||||
const res = await axios.get(
|
||||
let res = await axios.get(
|
||||
`https://api.modrinth.com/api/v1/mod/${data.params.id}`
|
||||
)
|
||||
const mod = res.data
|
||||
|
||||
res = await axios.get(mod.body_url)
|
||||
|
||||
console.log(res.data)
|
||||
|
||||
return {
|
||||
mod: res.data,
|
||||
mod,
|
||||
modBody: res.data,
|
||||
}
|
||||
},
|
||||
}
|
||||
|
||||
@@ -206,6 +206,7 @@
|
||||
facet-name="categories:forge"
|
||||
@toggle="toggleFacet"
|
||||
>
|
||||
<ForgeLoader />
|
||||
</SearchFilter>
|
||||
<SearchFilter
|
||||
:active-filters="facets"
|
||||
@@ -213,6 +214,7 @@
|
||||
facet-name="categories:fabric"
|
||||
@toggle="toggleFacet"
|
||||
>
|
||||
<FabricLoader />
|
||||
</SearchFilter>
|
||||
<h3>Platforms</h3>
|
||||
<SearchFilter
|
||||
@@ -271,6 +273,9 @@ import StorageCategory from '~/assets/images/categories/storage.svg?inline'
|
||||
import UtilityCategory from '~/assets/images/categories/utility.svg?inline'
|
||||
import WorldGenCategory from '~/assets/images/categories/worldgen.svg?inline'
|
||||
|
||||
import ForgeLoader from '~/assets/images/categories/forge.svg?inline'
|
||||
import FabricLoader from '~/assets/images/categories/fabric.svg?inline'
|
||||
|
||||
export default {
|
||||
auth: false,
|
||||
components: {
|
||||
@@ -290,6 +295,8 @@ export default {
|
||||
StorageCategory,
|
||||
UtilityCategory,
|
||||
WorldGenCategory,
|
||||
ForgeLoader,
|
||||
FabricLoader,
|
||||
},
|
||||
async fetch() {
|
||||
if (this.$route.query.q) this.query = this.$route.query.q
|
||||
|
||||
@@ -4,9 +4,8 @@
|
||||
<img :src="user.avatar_url" :alt="user.username" />
|
||||
<div class="info">
|
||||
<h1>{{ user.username }}</h1>
|
||||
<p>{{ user.bio }}</p>
|
||||
<p>Joined {{ $dayjs(user.created).fromNow() }}</p>
|
||||
<p></p>
|
||||
<p class="joined-text">Joined {{ $dayjs(user.created).fromNow() }}</p>
|
||||
<p class="bio" v-if="user.bio">{{ user.bio }}</p>
|
||||
<p v-if="user.role === 'admin'" class="badge red">Admin</p>
|
||||
<p v-if="user.role === 'moderator'" class="badge yellow">Moderator</p>
|
||||
<p v-if="user.role === 'developer'" class="badge green">Developer</p>
|
||||
@@ -78,6 +77,7 @@ export default {
|
||||
margin-left: 15px;
|
||||
|
||||
img {
|
||||
border-radius: var(--size-rounded-md);
|
||||
width: 250px;
|
||||
height: 250px;
|
||||
}
|
||||
@@ -85,8 +85,18 @@ export default {
|
||||
.info {
|
||||
margin-left: 15px;
|
||||
|
||||
p {
|
||||
margin-right: auto;
|
||||
h1 {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
.joined-text {
|
||||
margin-top: 5px;
|
||||
color: var(--color-grey-3);
|
||||
}
|
||||
|
||||
.bio {
|
||||
margin-top: 5px;
|
||||
font-size: 16pt;
|
||||
}
|
||||
|
||||
.badge {
|
||||
|
||||
Reference in New Issue
Block a user