feat(site): redesigned /download, releases and links moved from GitHub to Forgejo
Some checks failed
CI / backend (cargo test + clippy) (push) Has been cancelled
CI / frontend (lint + test + build) (push) Has been cancelled
CI / mod (gradle test + checkFolderLimit) (push) Has been cancelled

- /download: the jar as an in-game item (pixel heart in an inventory slot, vanilla-style tooltip with version, size and SHA-256, copy button), spec list, three install steps, release timeline
- releases read through a cached nginx proxy (/api/releases): Forgejo's API has no CORS headers
- README, footer and landing links point to git.wihuk.pro/boba/LoVisual (the GitHub repo they used does not exist)
- release workflow publishes through the Forgejo API and ships lovisual.jar.sha256
- fix i18n interpolation placeholders ({{x}}) in the download strings
This commit is contained in:
loki5512344 2026-10-09 22:15:55 +02:00
parent fa08d50704
commit 2d96f28091
Signed by: boba
GPG key ID: 253067914055423B
19 changed files with 360 additions and 143 deletions

View file

@ -36,7 +36,7 @@ export const commonEn = {
about: 'A free visuals mod for Minecraft 26.2 on Fabric.',
sectionProduct: 'Product',
sectionProject: 'Project',
github: 'GitHub',
github: 'Source code',
download: 'Download',
legalTitle: 'Legal',
disclaimer: 'Not affiliated with Mojang or Microsoft.',

View file

@ -34,7 +34,7 @@ export const commonRu = {
about: 'Бесплатный визуальный мод для Minecraft 26.2 на Fabric.',
sectionProduct: 'Продукт',
sectionProject: 'Проект',
github: 'GitHub',
github: 'Исходный код',
download: 'Скачать',
legalTitle: 'Правовое',
disclaimer: 'Не связано с Mojang или Microsoft.',

View file

@ -1,6 +1,6 @@
import { useTranslation } from '@shared/i18n/react'
import { Link } from 'react-router'
import { GITHUB_REPO } from '@features/download/api'
import { SOURCE_URL } from '@features/download/api'
import { LanguageSwitch } from '../i18n/LanguageSwitch'
export function Footer() {
@ -11,8 +11,8 @@ export function Footer() {
{ to: '/themes', label: t('nav.themes') },
]
const project: { label: string; to?: string; href?: string }[] = [
{ href: `https://github.com/${GITHUB_REPO}`, label: t('footer.github') },
// In-site: the download page is where both download paths (ours + GitHub) live.
{ href: SOURCE_URL, label: t('footer.github') },
// In-site: the download page is where both download paths (the jar and the release history) live.
{ to: '/download', label: t('footer.download') },
]

View file

@ -106,12 +106,12 @@ test('the header language toggle switches the UI to English and back', async ()
expect(await screen.findByRole('link', { name: 'Войти' }, { timeout: 3000 })).toBeInTheDocument()
})
test('footer carries the github link and the disclaimer', async () => {
test('footer carries the source link on our Forgejo and the disclaimer', async () => {
mockFetch({ 'POST /auth/refresh': () => json({}, 401) })
renderApp(routes, '/')
expect(await screen.findByText('Не связано с Mojang или Microsoft.')).toBeInTheDocument()
const gh = screen.getByRole('link', { name: 'GitHub' })
expect(gh.getAttribute('href')).toMatch(/^https:\/\/github\.com\//)
const src = screen.getByRole('link', { name: 'Исходный код' })
expect(src.getAttribute('href')).toBe('https://git.wihuk.pro/boba/LoVisual')
})
test('page title renders one h1 with an optional lead', () => {