-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
22 changed files
with
323 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,51 @@ | ||
<script lang="ts"> | ||
import { browser } from '$app/environment' | ||
import { base } from '$app/paths' | ||
import Header from '$lib/Header.svelte' | ||
import { keyboards } from './showcase' | ||
</script> | ||
|
||
<svelte:head> | ||
<title>Cosmos Keyboard</title> | ||
<title>Showcase • Cosmos Keyboard</title> | ||
<link rel="canonical" href="https://ryanis.cool/cosmos/showcase" /> | ||
<link rel="icon" href="{base}/favicon.png" /> | ||
</svelte:head> | ||
|
||
<svelte:body class="bg-brand-dark" /> | ||
<svelte:body class="bg-brand-dark font-urbanist text-white" /> | ||
|
||
<Header /> | ||
|
||
<div class="font-urbanist text-center text-white"> | ||
<p class="mt-20"> | ||
There's nothing here yet. In the meantime, you can view some keyboards <a | ||
class="s-link" | ||
href="https://www.youtube.com/watch?v=dQw4w9WgXcQ">here</a | ||
>. | ||
</p> | ||
<p class="mt-2"> | ||
If you're interested in posting your keyboard here when the page goes live, ping me on Discord! | ||
</p> | ||
<h1 class="uppercase text-xl sm:text-3xl text-[#68e4a9] font-medium text-center mt-10"> | ||
Keyboards from the Community | ||
</h1> | ||
<p class="text-center mt-2">You can click on any keyboard to view more information.</p> | ||
<p class="text-center mt-2 opacity-50"> | ||
n.b. most of these will have bugs when you import them. I'll fix the models once V3 is publicly | ||
released. | ||
</p> | ||
<div | ||
class="mx-8 my-6 grid sm:grid-cols-[repeat(2,18rem)] md:grid-cols-[repeat(2,21rem)] gap-2 justify-center" | ||
> | ||
{#each keyboards as kbd} | ||
<a class="block bg-[#2e272d]/50 rounded-2 overflow-hidden citem" href="{base}/showcase/{kbd.key}"> | ||
{#if browser} | ||
<div class="w-full aspect-[1.9/1] vignette"> | ||
<img | ||
src={kbd.image} | ||
alt="Image of {kbd.author}'s keyboard" | ||
class="w-full h-full object-cover" | ||
/> | ||
</div> | ||
<div class="flex gap-4 mx-2 my-2 items-center"> | ||
<img src={kbd.authorImage} alt="Profile icon for {kbd.author}" class="h-6 w-6 rounded-full" /> | ||
{kbd.author} | ||
</div> | ||
{:else} | ||
<div class="w-full aspect-[1.9/1] bg-slate-800" /> | ||
<div class="my-2 h-6" /> | ||
{/if} | ||
</a> | ||
{/each} | ||
</div> | ||
|
||
<style> | ||
</style> | ||
<p class="text-center opacity-50 mb-6">The order of keyboards is shuffled daily.</p> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import { error } from '@sveltejs/kit' | ||
import { keyboards } from '../showcase.js' | ||
|
||
export const load = ({ params }) => { | ||
const keyboard = keyboards.find(k => k.key == params.slug) | ||
|
||
if (!keyboard) { | ||
error(404, { | ||
message: 'Not found', | ||
}) | ||
} | ||
|
||
return { keyboard } | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
<script lang="ts"> | ||
import { base } from '$app/paths' | ||
import Header from '$lib/Header.svelte' | ||
import Icon from '$lib/presentation/Icon.svelte' | ||
import { mdiChevronRight } from '@mdi/js' | ||
import type { keyboards } from '../showcase' | ||
export let data: { keyboard: (typeof keyboards)[number] } | ||
$: kbd = data.keyboard | ||
</script> | ||
|
||
<svelte:head> | ||
<title>{kbd.name} • Showcase • Cosmos Keyboard</title> | ||
<link rel="canonical" href="https://ryanis.cool/cosmos/showcase" /> | ||
<link rel="icon" href="{base}/favicon.png" /> | ||
</svelte:head> | ||
|
||
<svelte:body class="bg-brand-dark font-urbanist text-white" /> | ||
|
||
<Header /> | ||
|
||
<div class="mx-auto container max-w-[calc(190vh-21rem)]"> | ||
<div class="w-full aspect-[1.9/1]"> | ||
<img | ||
src={kbd.largeImage} | ||
alt="Image of {kbd.author}'s keyboard" | ||
class="w-full h-full object-cover" | ||
/> | ||
</div> | ||
<div class="flex mt-2 mx-2"> | ||
<div class="w-full"> | ||
<h1 class="uppercase text-xl sm:text-3xl text-[#68e4a9] font-medium"> | ||
{kbd.name} | ||
</h1> | ||
<div class="flex gap-4 mx-0.5 my-2 items-center"> | ||
<img src={kbd.authorImage} alt="Profile icon for {kbd.author}" class="h-6 w-6 rounded-full" /> | ||
{kbd.author} | ||
</div> | ||
{#if kbd.details} | ||
<p class="mt-2 mb-4">{kbd.details}</p> | ||
{/if} | ||
</div> | ||
<div class="flex-none"> | ||
{#if kbd.config} | ||
<a | ||
href="{base}/beta{kbd.config}" | ||
class="text-black font-semibold rounded inline-flex items-center gap-16 my-4 pl-6 pr-4 bg-brand-green <sm:ml-6 transition hover:shadow-lg shadow-teal/30" | ||
> | ||
Fit, Edit and Download | ||
<Icon path={mdiChevronRight} size="100%" class="w-[28px] sm:w-[32px]" /> | ||
</a> | ||
{/if} | ||
</div> | ||
</div> | ||
</div> | ||
|
||
<style> | ||
</style> |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.