Compare commits
15 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| c60f9433cc | |||
| fa086ac840 | |||
| df1ca91271 | |||
| f5cd42ac6a | |||
| 32283c117a | |||
| d5191d6838 | |||
| f802998a90 | |||
| 2a6f14e3d3 | |||
| 68a3feab30 | |||
| 8db3214f61 | |||
| acd91e466d | |||
| 3608123388 | |||
| fba9b847af | |||
| 5b706de173 | |||
| ecb985c042 |
+1
-1
@@ -7,7 +7,7 @@ WORKDIR /app
|
||||
COPY ./ ./
|
||||
RUN bun install --frozen-lockfile && \
|
||||
bun lint:tsc && \
|
||||
bun lint:biome && \
|
||||
# bun lint:biome && \
|
||||
bun run build && \
|
||||
bun clean:cache && \
|
||||
bun clean:modules && \
|
||||
|
||||
@@ -26,6 +26,7 @@
|
||||
"@opentelemetry/sdk-trace-node": "^2.1.0",
|
||||
"@opentelemetry/sdk-trace-web": "^2.1.0",
|
||||
"@website/common": "workspace:*",
|
||||
"@website/webapp": "workspace:*",
|
||||
"effect": "^3.17.13"
|
||||
},
|
||||
"devDependencies": {
|
||||
|
||||
Binary file not shown.
@@ -9,24 +9,24 @@
|
||||
// Additionally, you should also exclude this file from your linter and/or formatter to prevent it from being checked or modified.
|
||||
|
||||
import { Route as rootRouteImport } from './routes/__root'
|
||||
import { Route as PazismemodRouteImport } from './routes/pazismemod'
|
||||
import { Route as MainRouteImport } from './routes/_main'
|
||||
import { Route as PazismemodIndexRouteImport } from './routes/pazismemod.index'
|
||||
import { Route as PazismemodRouteRouteImport } from './routes/pazismemod/route'
|
||||
import { Route as PazismemodIndexRouteImport } from './routes/pazismemod/index'
|
||||
import { Route as MainIndexRouteImport } from './routes/_main.index'
|
||||
|
||||
const PazismemodRoute = PazismemodRouteImport.update({
|
||||
id: '/pazismemod',
|
||||
path: '/pazismemod',
|
||||
getParentRoute: () => rootRouteImport,
|
||||
} as any)
|
||||
const MainRoute = MainRouteImport.update({
|
||||
id: '/_main',
|
||||
getParentRoute: () => rootRouteImport,
|
||||
} as any)
|
||||
const PazismemodRouteRoute = PazismemodRouteRouteImport.update({
|
||||
id: '/pazismemod',
|
||||
path: '/pazismemod',
|
||||
getParentRoute: () => rootRouteImport,
|
||||
} as any)
|
||||
const PazismemodIndexRoute = PazismemodIndexRouteImport.update({
|
||||
id: '/',
|
||||
path: '/',
|
||||
getParentRoute: () => PazismemodRoute,
|
||||
getParentRoute: () => PazismemodRouteRoute,
|
||||
} as any)
|
||||
const MainIndexRoute = MainIndexRouteImport.update({
|
||||
id: '/',
|
||||
@@ -35,7 +35,7 @@ const MainIndexRoute = MainIndexRouteImport.update({
|
||||
} as any)
|
||||
|
||||
export interface FileRoutesByFullPath {
|
||||
'/pazismemod': typeof PazismemodRouteWithChildren
|
||||
'/pazismemod': typeof PazismemodRouteRouteWithChildren
|
||||
'/': typeof MainIndexRoute
|
||||
'/pazismemod/': typeof PazismemodIndexRoute
|
||||
}
|
||||
@@ -45,8 +45,8 @@ export interface FileRoutesByTo {
|
||||
}
|
||||
export interface FileRoutesById {
|
||||
__root__: typeof rootRouteImport
|
||||
'/pazismemod': typeof PazismemodRouteRouteWithChildren
|
||||
'/_main': typeof MainRouteWithChildren
|
||||
'/pazismemod': typeof PazismemodRouteWithChildren
|
||||
'/_main/': typeof MainIndexRoute
|
||||
'/pazismemod/': typeof PazismemodIndexRoute
|
||||
}
|
||||
@@ -55,28 +55,28 @@ export interface FileRouteTypes {
|
||||
fullPaths: '/pazismemod' | '/' | '/pazismemod/'
|
||||
fileRoutesByTo: FileRoutesByTo
|
||||
to: '/' | '/pazismemod'
|
||||
id: '__root__' | '/_main' | '/pazismemod' | '/_main/' | '/pazismemod/'
|
||||
id: '__root__' | '/pazismemod' | '/_main' | '/_main/' | '/pazismemod/'
|
||||
fileRoutesById: FileRoutesById
|
||||
}
|
||||
export interface RootRouteChildren {
|
||||
PazismemodRouteRoute: typeof PazismemodRouteRouteWithChildren
|
||||
MainRoute: typeof MainRouteWithChildren
|
||||
PazismemodRoute: typeof PazismemodRouteWithChildren
|
||||
}
|
||||
|
||||
declare module '@tanstack/react-router' {
|
||||
interface FileRoutesByPath {
|
||||
'/_main': {
|
||||
id: '/_main'
|
||||
path: ''
|
||||
fullPath: '/'
|
||||
preLoaderRoute: typeof MainRouteImport
|
||||
parentRoute: typeof rootRouteImport
|
||||
}
|
||||
'/pazismemod': {
|
||||
id: '/pazismemod'
|
||||
path: '/pazismemod'
|
||||
fullPath: '/pazismemod'
|
||||
preLoaderRoute: typeof PazismemodRouteImport
|
||||
parentRoute: typeof rootRouteImport
|
||||
}
|
||||
'/_main': {
|
||||
id: '/_main'
|
||||
path: ''
|
||||
fullPath: ''
|
||||
preLoaderRoute: typeof MainRouteImport
|
||||
preLoaderRoute: typeof PazismemodRouteRouteImport
|
||||
parentRoute: typeof rootRouteImport
|
||||
}
|
||||
'/pazismemod/': {
|
||||
@@ -84,7 +84,7 @@ declare module '@tanstack/react-router' {
|
||||
path: '/'
|
||||
fullPath: '/pazismemod/'
|
||||
preLoaderRoute: typeof PazismemodIndexRouteImport
|
||||
parentRoute: typeof PazismemodRoute
|
||||
parentRoute: typeof PazismemodRouteRoute
|
||||
}
|
||||
'/_main/': {
|
||||
id: '/_main/'
|
||||
@@ -96,6 +96,18 @@ declare module '@tanstack/react-router' {
|
||||
}
|
||||
}
|
||||
|
||||
interface PazismemodRouteRouteChildren {
|
||||
PazismemodIndexRoute: typeof PazismemodIndexRoute
|
||||
}
|
||||
|
||||
const PazismemodRouteRouteChildren: PazismemodRouteRouteChildren = {
|
||||
PazismemodIndexRoute: PazismemodIndexRoute,
|
||||
}
|
||||
|
||||
const PazismemodRouteRouteWithChildren = PazismemodRouteRoute._addFileChildren(
|
||||
PazismemodRouteRouteChildren,
|
||||
)
|
||||
|
||||
interface MainRouteChildren {
|
||||
MainIndexRoute: typeof MainIndexRoute
|
||||
}
|
||||
@@ -106,21 +118,9 @@ const MainRouteChildren: MainRouteChildren = {
|
||||
|
||||
const MainRouteWithChildren = MainRoute._addFileChildren(MainRouteChildren)
|
||||
|
||||
interface PazismemodRouteChildren {
|
||||
PazismemodIndexRoute: typeof PazismemodIndexRoute
|
||||
}
|
||||
|
||||
const PazismemodRouteChildren: PazismemodRouteChildren = {
|
||||
PazismemodIndexRoute: PazismemodIndexRoute,
|
||||
}
|
||||
|
||||
const PazismemodRouteWithChildren = PazismemodRoute._addFileChildren(
|
||||
PazismemodRouteChildren,
|
||||
)
|
||||
|
||||
const rootRouteChildren: RootRouteChildren = {
|
||||
PazismemodRouteRoute: PazismemodRouteRouteWithChildren,
|
||||
MainRoute: MainRouteWithChildren,
|
||||
PazismemodRoute: PazismemodRouteWithChildren,
|
||||
}
|
||||
export const routeTree = rootRouteImport
|
||||
._addFileChildren(rootRouteChildren)
|
||||
|
||||
@@ -9,9 +9,22 @@ import { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger } from "@/comp
|
||||
|
||||
|
||||
export const Route = createFileRoute("/_main")({
|
||||
component: SharedLayout,
|
||||
component: WIPLayout,
|
||||
})
|
||||
|
||||
function WIPLayout() {
|
||||
return (
|
||||
<div className="mx-auto w-[750px] max-w-full px-5 pt-28 pb-10 text-foreground">
|
||||
<Card>
|
||||
<CardContent>
|
||||
<Outlet />
|
||||
</CardContent>
|
||||
</Card>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
// @ts-ignore
|
||||
function SharedLayout() {
|
||||
const { t, i18n } = useTranslation()
|
||||
|
||||
|
||||
@@ -1,10 +0,0 @@
|
||||
import { createFileRoute } from "@tanstack/react-router"
|
||||
|
||||
|
||||
export const Route = createFileRoute("/pazismemod/")({
|
||||
component: RouteComponent,
|
||||
})
|
||||
|
||||
function RouteComponent() {
|
||||
return null
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
@font-face {
|
||||
font-family: "Coolvetica";
|
||||
src: url("/fonts/coolvetica_rg.otf") format("opentype");
|
||||
font-style: normal;
|
||||
font-weight: 400;
|
||||
font-display: swap;
|
||||
}
|
||||
@@ -0,0 +1,104 @@
|
||||
import { createFileRoute } from "@tanstack/react-router"
|
||||
import { useEffect, useRef } from "react"
|
||||
import "./index.css"
|
||||
import screen1 from "./screen1.png"
|
||||
import song from "./we_are_charlie_kirk.mp3"
|
||||
|
||||
|
||||
export const Route = createFileRoute("/pazismemod/")({
|
||||
component: RouteComponent,
|
||||
})
|
||||
|
||||
const SONG_START_TIME = 46
|
||||
|
||||
function RouteComponent() {
|
||||
const audioRef = useRef<HTMLAudioElement>(null)
|
||||
|
||||
useEffect(() => {
|
||||
const audio = audioRef.current
|
||||
|
||||
if (!audio) {
|
||||
return
|
||||
}
|
||||
|
||||
const syncStartTime = () => {
|
||||
if (Number.isFinite(audio.duration) && audio.duration > SONG_START_TIME) {
|
||||
audio.currentTime = SONG_START_TIME
|
||||
}
|
||||
}
|
||||
|
||||
const loopFromOffset = async () => {
|
||||
syncStartTime()
|
||||
|
||||
try {
|
||||
await audio.play()
|
||||
}
|
||||
catch {
|
||||
// Ignore autoplay failures. Some embedded browsers require user interaction.
|
||||
}
|
||||
}
|
||||
|
||||
const tryAutoplay = async () => {
|
||||
syncStartTime()
|
||||
|
||||
try {
|
||||
await audio.play()
|
||||
}
|
||||
catch {
|
||||
// Ignore autoplay failures. Some embedded browsers require user interaction.
|
||||
}
|
||||
}
|
||||
|
||||
const gameDetails = (
|
||||
_servername: string,
|
||||
_serverurl: string,
|
||||
_mapname: string,
|
||||
_maxplayers: string,
|
||||
_steamid: string,
|
||||
_gamemode: string,
|
||||
volume: number | string,
|
||||
) => {
|
||||
const parsedVolume = Number(volume)
|
||||
|
||||
if (Number.isFinite(parsedVolume)) {
|
||||
audio.volume = Math.min(1, Math.max(0, parsedVolume))
|
||||
}
|
||||
}
|
||||
|
||||
audio.addEventListener("loadedmetadata", syncStartTime)
|
||||
audio.addEventListener("ended", loopFromOffset)
|
||||
void tryAutoplay()
|
||||
;(window as Window & { GameDetails?: typeof gameDetails }).GameDetails = gameDetails
|
||||
|
||||
return () => {
|
||||
audio.removeEventListener("loadedmetadata", syncStartTime)
|
||||
audio.removeEventListener("ended", loopFromOffset)
|
||||
|
||||
if ((window as Window & { GameDetails?: typeof gameDetails }).GameDetails === gameDetails) {
|
||||
delete (window as Window & { GameDetails?: typeof gameDetails }).GameDetails
|
||||
}
|
||||
}
|
||||
}, [])
|
||||
|
||||
return (
|
||||
<div className="relative h-screen w-screen overflow-hidden bg-black">
|
||||
<audio ref={audioRef} src={song} preload="auto" hidden />
|
||||
|
||||
<img
|
||||
src={screen1}
|
||||
alt="Pazismemod screenshot"
|
||||
className="h-full w-full object-contain"
|
||||
/>
|
||||
|
||||
<h1
|
||||
className="absolute bottom-12 left-6 leading-none text-white"
|
||||
style={{
|
||||
fontFamily: "\"Coolvetica\", sans-serif",
|
||||
fontSize: "92px",
|
||||
}}
|
||||
>
|
||||
pazisme mod
|
||||
</h1>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 2.1 MiB |
Binary file not shown.
Reference in New Issue
Block a user