switched to nin0git

This commit is contained in:
nin0dev 2024-08-29 17:41:13 -04:00
parent d0a90826c7
commit 229884f7ac
33 changed files with 20 additions and 110 deletions

View file

@ -1,94 +0,0 @@
Copyright 2014 The DM Sans Project Authors (https://github.com/googlefonts/dm-fonts)
Copyright 2020 The DM Mono Project Authors (https://www.github.com/googlefonts/dm-mono)
This Font Software is licensed under the SIL Open Font License, Version 1.1.
This license is copied below, and is also available with a FAQ at:
https://openfontlicense.org
-----------------------------------------------------------
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
-----------------------------------------------------------
PREAMBLE
The goals of the Open Font License (OFL) are to stimulate worldwide
development of collaborative font projects, to support the font creation
efforts of academic and linguistic communities, and to provide a free and
open framework in which fonts may be shared and improved in partnership
with others.
The OFL allows the licensed fonts to be used, studied, modified and
redistributed freely as long as they are not sold by themselves. The
fonts, including any derivative works, can be bundled, embedded,
redistributed and/or sold with any software provided that any reserved
names are not used by derivative works. The fonts and derivatives,
however, cannot be released under any other type of license. The
requirement for fonts to remain under this license does not apply
to any document created using the fonts or their derivatives.
DEFINITIONS
"Font Software" refers to the set of files released by the Copyright
Holder(s) under this license and clearly marked as such. This may
include source files, build scripts and documentation.
"Reserved Font Name" refers to any names specified as such after the
copyright statement(s).
"Original Version" refers to the collection of Font Software components as
distributed by the Copyright Holder(s).
"Modified Version" refers to any derivative made by adding to, deleting,
or substituting -- in part or in whole -- any of the components of the
Original Version, by changing formats or by porting the Font Software to a
new environment.
"Author" refers to any designer, engineer, programmer, technical
writer or other person who contributed to the Font Software.
PERMISSION & CONDITIONS
Permission is hereby granted, free of charge, to any person obtaining
a copy of the Font Software, to use, study, copy, merge, embed, modify,
redistribute, and sell modified and unmodified copies of the Font
Software, subject to the following conditions:
1) Neither the Font Software nor any of its individual components,
in Original or Modified Versions, may be sold by itself.
2) Original or Modified Versions of the Font Software may be bundled,
redistributed and/or sold with any software, provided that each copy
contains the above copyright notice and this license. These can be
included either as stand-alone text files, human-readable headers or
in the appropriate machine-readable metadata fields within text or
binary files as long as those fields can be easily viewed by the user.
3) No Modified Version of the Font Software may use the Reserved Font
Name(s) unless explicit written permission is granted by the corresponding
Copyright Holder. This restriction only applies to the primary font name as
presented to the users.
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
Software shall not be used to promote, endorse or advertise any
Modified Version, except to acknowledge the contribution(s) of the
Copyright Holder(s) and the Author(s) or with their explicit written
permission.
5) The Font Software, modified or unmodified, in part or in whole,
must be distributed entirely under this license, and must not be
distributed under any other license. The requirement for fonts to
remain under this license does not apply to any document created
using the Font Software.
TERMINATION
This license becomes null and void if any of the above conditions are
not met.
DISCLAIMER
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
OTHER DEALINGS IN THE FONT SOFTWARE.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View file

@ -3,6 +3,9 @@
<head> <head>
<meta charset="utf-8" /> <meta charset="utf-8" />
<link rel="icon" href="%sveltekit.assets%/favicon.png" /> <link rel="icon" href="%sveltekit.assets%/favicon.png" />
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap" rel="stylesheet">
<meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="viewport" content="width=device-width, initial-scale=1" />
%sveltekit.head% %sveltekit.head%
</head> </head>

View file

@ -5,7 +5,8 @@
} }
:root { :root {
--bg-clr: #10121d; background-color: black !important;
--bg-clr: #11111b;
--fg-clr: #fff; --fg-clr: #fff;
--muted-clr: #b7b9c5; --muted-clr: #b7b9c5;
height: 100%; height: 100%;
@ -15,7 +16,7 @@ body {
background-color: black; background-color: black;
color: var(--fg-clr); color: var(--fg-clr);
color-scheme: dark; color-scheme: dark;
font-family: 'DM Sans', system-ui, Roboto, sans-serif; font-family: Inter;
height: 100%; height: 100%;
margin: 0; margin: 0;
overflow: hidden; overflow: hidden;

View file

@ -2,7 +2,7 @@ import languagecolors from './languagecolors'
export default async function getLanguages(owner: string, repo: string) { export default async function getLanguages(owner: string, repo: string) {
const languages = (await fetch( const languages = (await fetch(
`https://git.gay/api/v1/repos/${encodeURIComponent(owner)}/${encodeURIComponent(repo)}/languages` `https://git.nin0.dev/api/v1/repos/${encodeURIComponent(owner)}/${encodeURIComponent(repo)}/languages`
).then(response => response.json())) as { [key: string]: number } ).then(response => response.json())) as { [key: string]: number }
let sum = 0 let sum = 0
const values = Object.values(languages) const values = Object.values(languages)

View file

@ -1,7 +1,7 @@
// eslint-disable-next-line @typescript-eslint/ban-ts-comment // eslint-disable-next-line @typescript-eslint/ban-ts-comment
// @ts-nocheck // @ts-nocheck
import puppeteer from 'puppeteer' import puppeteer from 'puppeteer'
const BASE_URL = process.env.BASE_URL || 'https://git.gay' const BASE_URL = process.env.BASE_URL || 'https://git.nin0.dev'
const browser = await puppeteer.launch({ const browser = await puppeteer.launch({
defaultViewport: { defaultViewport: {

View file

@ -56,7 +56,7 @@
width: 100%; width: 100%;
height: 100%; height: 100%;
position: relative; position: relative;
background-color: #10121d; background-color: #11111b;
display: grid; display: grid;
grid-template-rows: 1fr min-content 1.5rem; grid-template-rows: 1fr min-content 1.5rem;
} }

View file

@ -3,10 +3,10 @@ import type { Owner } from '$lib/types/forgejo.js'
export async function load({ params }) { export async function load({ params }) {
const [owner, reposCount] = await Promise.all([ const [owner, reposCount] = await Promise.all([
fetch( fetch(
`https://git.gay/api/v1/users/${encodeURIComponent(params.owner)}` `https://git.nin0.dev/api/v1/users/${encodeURIComponent(params.owner)}`
).then(response => response.json()) as Promise<Owner>, ).then(response => response.json()) as Promise<Owner>,
fetch( fetch(
`https://git.gay/api/v1/users/${encodeURIComponent(params.owner)}/repos` `https://git.nin0.dev/api/v1/users/${encodeURIComponent(params.owner)}/repos`
).then(response => response.headers.get('x-total-count')) as Promise<string> ).then(response => response.headers.get('x-total-count')) as Promise<string>
]) ])
owner.repos_count = parseInt(reposCount) owner.repos_count = parseInt(reposCount)

View file

@ -29,7 +29,7 @@
} }
.heading .name { .heading .name {
font-size: 5rem; font-size: 5rem;
font-weight: 800; font-weight: 600;
} }
.description { .description {
color: var(--muted-clr); color: var(--muted-clr);

View file

@ -3,7 +3,7 @@ import getLanguages from '$lib/getLanguages.js'
export async function load({ params }) { export async function load({ params }) {
const [repo, languages] = await Promise.all([ const [repo, languages] = await Promise.all([
fetch( fetch(
`https://git.gay/api/v1/repos/${encodeURIComponent(params.owner)}/${encodeURIComponent(params.repo)}` `https://git.nin0.dev/api/v1/repos/${encodeURIComponent(params.owner)}/${encodeURIComponent(params.repo)}`
).then(response => response.json()), ).then(response => response.json()),
getLanguages(params.owner, params.repo) getLanguages(params.owner, params.repo)
]) ])

View file

@ -16,7 +16,7 @@
line-height: 1.125; line-height: 1.125;
} }
.heading .name { .heading .name {
font-weight: 800; font-weight: 600;
} }
.description { .description {
color: var(--muted-clr); color: var(--muted-clr);

View file

@ -10,7 +10,7 @@ export async function load({ params }) {
const [issue, languages] = await Promise.all([ const [issue, languages] = await Promise.all([
fetch( fetch(
`https://git.gay/api/v1/repos/${encodeURIComponent(params.owner)}/${encodeURIComponent(params.repo)}/issues/${encodeURIComponent(params.num)}` `https://git.nin0.dev/api/v1/repos/${encodeURIComponent(params.owner)}/${encodeURIComponent(params.repo)}/issues/${encodeURIComponent(params.num)}`
).then(response => response.json()), ).then(response => response.json()),
getLanguages(params.owner, params.repo) getLanguages(params.owner, params.repo)
]) ])
@ -19,7 +19,7 @@ export async function load({ params }) {
let commits let commits
if (issue.pull_request) if (issue.pull_request)
commits = await fetch( commits = await fetch(
`https://git.gay/api/v1/repos/${encodeURIComponent(params.owner)}/${encodeURIComponent(params.repo)}/pulls/${encodeURIComponent(params.num)}/commits` `https://git.nin0.dev/api/v1/repos/${encodeURIComponent(params.owner)}/${encodeURIComponent(params.repo)}/pulls/${encodeURIComponent(params.num)}/commits`
).then(response => response.json()) ).then(response => response.json())
let stats let stats

View file

@ -40,6 +40,6 @@
} }
.message .title { .message .title {
color: var(--fg-clr); color: var(--fg-clr);
font-weight: 800; font-weight: 600;
} }
</style> </style>

View file

@ -17,10 +17,10 @@ function prepareLanguageResults(languages: { [key: string]: number }) {
export async function load({ params }) { export async function load({ params }) {
const [commitResponse, languages] = await Promise.all([ const [commitResponse, languages] = await Promise.all([
fetch( fetch(
`https://git.gay/api/v1/repos/${encodeURIComponent(params.owner)}/${encodeURIComponent(params.repo)}/git/commits/${encodeURIComponent(params.sha)}` `https://git.nin0.dev/api/v1/repos/${encodeURIComponent(params.owner)}/${encodeURIComponent(params.repo)}/git/commits/${encodeURIComponent(params.sha)}`
).then(response => response.json()), ).then(response => response.json()),
fetch( fetch(
`https://git.gay/api/v1/repos/${encodeURIComponent(params.owner)}/${encodeURIComponent(params.repo)}/languages` `https://git.nin0.dev/api/v1/repos/${encodeURIComponent(params.owner)}/${encodeURIComponent(params.repo)}/languages`
).then(response => response.json()) ).then(response => response.json())
]) ])
const { commit, author, stats } = commitResponse const { commit, author, stats } = commitResponse

View file

@ -25,7 +25,7 @@
} }
.message { .message {
font-size: 4rem; font-size: 4rem;
font-weight: 800; font-weight: 600;
line-height: 1.25; line-height: 1.25;
overflow: hidden; overflow: hidden;