Compare commits

...

3 Commits

Author SHA1 Message Date
fdf64a2bf3 update :3
All checks were successful
Build Full Stack / release-image (push) Successful in 11m45s
2025-04-02 22:57:52 +02:00
a0dde77659 wawa
All checks were successful
Build Full Stack / release-image (push) Successful in 3m25s
2024-12-22 01:54:37 +01:00
7057f0e04a yeah.. linting..
Some checks failed
Build Full Stack / release-image (push) Failing after 2m22s
2024-12-22 01:45:56 +01:00
16 changed files with 86 additions and 46 deletions

View File

@ -36,7 +36,7 @@ RUN yarn build
FROM base AS runner
WORKDIR /app
ENV NODE_ENV production
ENV NODE_ENV=production
# Uncomment the following line in case you want to disable telemetry during runtime.
# ENV NEXT_TELEMETRY_DISABLED 1
@ -58,8 +58,8 @@ USER nextjs
EXPOSE 3000
ENV PORT 3000
ENV PORT=3000
# set hostname to localhost
ENV HOSTNAME "0.0.0.0"
ENV HOSTNAME="0.0.0.0"
CMD ["node", "server.js"]

12
app/api/lastfm/route.ts Normal file
View File

@ -0,0 +1,12 @@
export async function GET() {
const res = await fetch(
`http://ws.audioscrobbler.com/2.0/?method=user.getrecenttracks&user=yae_miku&api_key=${process.env.API_KEY}&format=json&limit=1`,
{
headers: {
'Content-Type': 'application/json',
},
}
);
const data = await res.json();
return Response.json(data.recenttracks.track[0]);
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 25 KiB

View File

@ -2,6 +2,6 @@
@tailwind components;
@tailwind utilities;
ul {
/* ul {
@apply flex flex-row gap-x-4 flex-wrap list-inside items-center justify-center
}
} */

3
app/icon.svg Normal file
View File

@ -0,0 +1,3 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100">
<text y="1em" font-size="80">🌺</text>
</svg>

After

Width:  |  Height:  |  Size: 112 B

View File

@ -1,6 +1,6 @@
import type { Metadata } from 'next';
import { Geist, Geist_Mono } from 'next/font/google';
import './globals.css';
import bg from '@/public/orchids.webp';
export const metadata: Metadata = {
title: 'Nikola Kubiczek',
@ -13,8 +13,13 @@ export default function RootLayout({
children: React.ReactNode;
}>) {
return (
<html lang="en">
<body className="antialiased">{children}</body>
<html lang="en" className="dark">
<body
className="antialiased bg-stone-900 bg-cover"
style={{ backgroundImage: `url(${bg.src})` }}
>
{children}
</body>
</html>
);
}

View File

@ -3,32 +3,30 @@
import Image from 'next/image';
import useSWR, { Fetcher } from 'swr';
type ListenBrainz = {
payload: {
listens: {
track_metadata: {
track_name: string;
artist_name: string;
release_name: string;
};
}[];
type LastFM = {
artist: { '#text': string };
image: [{ size: string; '#text': string }];
mbid: string;
album: {
mbid: string;
'#text': string;
};
name: string;
'@attr': { nowplaying: string };
url: string;
};
const fetcher: Fetcher<ListenBrainz, string> = (...args) =>
const fetcher: Fetcher<LastFM, string> = (...args) =>
fetch(...args).then((res) => res.json());
export default function Home() {
const { data, isLoading } = useSWR(
'https://api.listenbrainz.org/1/user/yaemiku/listens?count=1',
fetcher
);
const { data, isLoading } = useSWR('/api/lastfm', fetcher);
return (
<div className="prose prose-stone mx-auto mt-6 p-4">
<header className="text-center">
<div className="prose prose-invert mx-auto pt-6 pb-4 px-6 shadow-sm">
<header className="text-center backdrop-blur-sm p-2 border-2 border-gray-700 rounded-md">
<Image
src={'/pfp_fb_cropped.jpg'}
src={'/pfp_pic.webp'}
width={200}
height={200}
alt="My Picture"
@ -39,10 +37,22 @@ export default function Home() {
{isLoading ? (
<></>
) : (
<samp className="lead">
<em>Last song I have listened to:</em> <br />
<b>{data?.payload.listens[0].track_metadata.track_name}</b>
<br />- {data?.payload.listens[0].track_metadata.artist_name} <br />
<samp className="lead flex flex-col text-center">
<em className="break flex mx-auto items-center gap-2">
<span>🎶</span>
<span>{data?.['@attr']
? "Currently listening to"
: 'Last song'}</span>
<span>🎶</span>
</em>
<b className="">
<a href={data?.url} target="_blank">
{data?.name}
</a>
</b>
<i className=" text-sm">
{data?.album['#text']}, {data?.artist['#text']}
</i>
</samp>
)}
</header>
@ -53,7 +63,7 @@ export default function Home() {
Currently studying pure mathematics at the University of Warsaw and
doing commissions on the side. I had been considering studying
computer science but decided not to - mathematics is the love of my
life and an absolute passion.
life, an absolute passion.
</p>
<p>
In my free time I love listening to music - be it on headphones,
@ -89,10 +99,10 @@ export default function Home() {
<ul>
<li>
<a
href="https://listenbrainz.org/user/yaemiku/"
href="https://www.last.fm/user/yae_miku"
target="_blank"
>
listenbrainz
last.fm
</a>
</li>
@ -104,19 +114,19 @@ export default function Home() {
instagram
</a>
</li>
<li>
{/* <li>
<a
href="https://stats.foldingathome.org/donor/id/711660268"
target={'_blank'}
>
folding@home
</a>
</li>
<li>
</li> */}
{/* <li>
<a href="/cv/" target={'_blank'}>
cv
</a>
</li>
</li> */}
<li>
<a href="https://git.yaemiku.dev/yaemiku" target={'_blank'}>
git
@ -124,9 +134,13 @@ export default function Home() {
</li>
</ul>
And if you&apos;d want to send me any crypto
<ul className='block list-outside'>
<li>cosmos1gy6tg8jaf4qwmpug8jp8kqnyy9en3lmjxq0twf</li>
<li className='break-all'>46MiubQK8psbDWys429WvTQ71DyDiLkKmSLznoDYYFQbA6MfTvuVRJzSAbCCA17n8RGjCojx5GcpKH3q1DbpKJaQPCVcabi</li>
<ul className="block list-outside">
<li className="break-all">
cosmos1gy6tg8jaf4qwmpug8jp8kqnyy9en3lmjxq0twf
</li>
<li className="break-all">
46MiubQK8psbDWys429WvTQ71DyDiLkKmSLznoDYYFQbA6MfTvuVRJzSAbCCA17n8RGjCojx5GcpKH3q1DbpKJaQPCVcabi
</li>
</ul>
</div>
</div>

View File

@ -1,6 +1,6 @@
import { NextRequest, NextResponse } from "next/server";
import { NextResponse } from "next/server";
export async function GET(_request: NextRequest) {
export async function GET() {
const pk = `-----BEGIN PGP PUBLIC KEY BLOCK-----
mQINBGHThigBEACa2l79D1WeKXvlJsua8s90P0p50sWaKCS6QOwG9jCvcSfSll8g

View File

@ -1,6 +1,6 @@
import { dirname } from "path";
import { fileURLToPath } from "url";
import { FlatCompat } from "@eslint/eslintrc";
import { dirname } from 'path';
import { fileURLToPath } from 'url';
import { FlatCompat } from '@eslint/eslintrc';
const __filename = fileURLToPath(import.meta.url);
const __dirname = dirname(__filename);
@ -10,7 +10,13 @@ const compat = new FlatCompat({
});
const eslintConfig = [
...compat.extends("next/core-web-vitals", "next/typescript"),
...compat.config({
extends: ['next/core-web-vitals', 'next/typescript'],
rules: {
'@typescript-eslint/no-unused-vars': 'off',
'react/no-unescaped-entities': 'off',
},
}),
];
export default eslintConfig;

View File

@ -1,7 +1,7 @@
import type { NextConfig } from "next";
const nextConfig: NextConfig = {
/* config options here */
output: 'standalone'
};
export default nextConfig;

BIN
public/orchids.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 225 KiB

BIN
public/orchids.webp Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 297 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 90 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 262 KiB

BIN
public/pfp_pic.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 492 KiB

BIN
public/pfp_pic.webp Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 451 KiB