Skip to content

Commit

Permalink
Comment out s&box blogs
Browse files Browse the repository at this point in the history
  • Loading branch information
Nolankicks committed Dec 20, 2024
1 parent 302a048 commit 40711b5
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 28 deletions.
4 changes: 2 additions & 2 deletions src/routes/+page.server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export const load: PageServerLoad = async ({ fetch }) => {
})
);

try
/*try
{
const allNewsPostsFetch = await fetch("https://services.facepunch.com/sbox/news/organization/nolankicks");
Expand All @@ -37,7 +37,7 @@ export const load: PageServerLoad = async ({ fetch }) => {
}
}
catch
{}
{}*/

unsortedPosts = unsortedPosts.filter((post: App.BlogPost) => post.published ?? true);

Expand Down
50 changes: 26 additions & 24 deletions src/routes/+page.svelte
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script>
import NameCard from "$lib/components/NameCard.svelte";
import NameCard from '$lib/components/NameCard.svelte';
export const pfpUrl =
'https://avatars.githubusercontent.com/u/95300917?s=400&u=4b7a75efdafbd368929511d483099250821ded21&v=4';
Expand All @@ -14,30 +14,32 @@
<NameCard />

<div class="w-full flex items-center justify-center p-5">
<div class="flex flex-col items-center justify-center max-w-3xl rounded-md animate-fadein w-full">
<h2 class="text-white font-poppins text-2xl flex items-start w-full font-bolder">Latest Blog</h2>
<hr class="my-5 w-full text-white"/>
<a
href={`${data.posts[0]?.IsNews ? 'sboxnews/' : 'blog/'}${data.posts[0]?.slug}`}
class="block p-5 bg-secondary rounded-md mb-4 hover:scale-[1.01] active:scale-[0.99] transition-all w-full"
>
<h2 class="text-2xl font-bold text-white">{data.posts[0]?.title}</h2>
<div class="flex flex-col items-center justify-center max-w-3xl rounded-md animate-fadein w-full">
<h2 class="text-white font-poppins text-2xl flex items-start w-full font-bolder">
Latest Blog
</h2>
<hr class="my-5 w-full text-white" />
<a
href={`${data.posts[0]?.IsNews ? 'sboxnews/' : 'blog/'}${data.posts[0]?.slug}`}
class="block p-5 bg-secondary rounded-md mb-4 hover:scale-[1.01] active:scale-[0.99] transition-all w-full"
>
<h2 class="text-2xl font-bold text-white">{data.posts[0]?.title}</h2>

{#if data.posts[0]?.description}
<p class="text-white font-semibold">{data.posts[0]?.description}</p>
{/if}
<p class="text-gray-400 text-white">
{new Date(data.posts[0]?.date).toLocaleDateString('en-US', {
year: 'numeric',
month: 'short',
day: 'numeric'
})}
</p>
{#if data.posts[0]?.description}
<p class="text-white font-semibold">{data.posts[0]?.description}</p>
{/if}
<p class="text-gray-400 text-white">
{new Date(data.posts[0]?.date).toLocaleDateString('en-US', {
year: 'numeric',
month: 'short',
day: 'numeric'
})}
</p>

<p class="text-gray-400 text-white">
{data.posts[0]?.IsNews ? 'Sbox.Game Blog' : 'Kicks Blog'}
</p>
</a>
</div>
<p class="text-gray-400 text-white">
{data.posts[0]?.IsNews ? 'Sbox.Game Blog' : 'Kicks Blog'}
</p>
</a>
</div>
</div>
<DiscordEmbed title="Kicks" description="My personal website" />
4 changes: 2 additions & 2 deletions src/routes/blog/+page.server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export const load: PageServerLoad = async ({ fetch }) => {
})
);

try
/*try
{
const allNewsPostsFetch = await fetch("https://services.facepunch.com/sbox/news/organization/nolankicks");
Expand All @@ -37,7 +37,7 @@ export const load: PageServerLoad = async ({ fetch }) => {
}
}
catch
{}
{}*/

unsortedPosts = unsortedPosts.filter((post: App.BlogPost) => post.published ?? true);

Expand Down

0 comments on commit 40711b5

Please sign in to comment.