diff --git a/README.md b/README.md index 382941e..31c59f3 100644 --- a/README.md +++ b/README.md @@ -1,47 +1,3 @@ -# Svelte + Vite +# simple-loading-screen -This template should help get you started developing with Svelte in Vite. - -## Recommended IDE Setup - -[VS Code](https://code.visualstudio.com/) + [Svelte](https://marketplace.visualstudio.com/items?itemName=svelte.svelte-vscode). - -## Need an official Svelte framework? - -Check out [SvelteKit](https://github.com/sveltejs/kit#readme), which is also powered by Vite. Deploy anywhere with its serverless-first approach and adapt to various platforms, with out of the box support for TypeScript, SCSS, and Less, and easily-added support for mdsvex, GraphQL, PostCSS, Tailwind CSS, and more. - -## Technical considerations - -**Why use this over SvelteKit?** - -- It brings its own routing solution which might not be preferable for some users. -- It is first and foremost a framework that just happens to use Vite under the hood, not a Vite app. - -This template contains as little as possible to get started with Vite + Svelte, while taking into account the developer experience with regards to HMR and intellisense. It demonstrates capabilities on par with the other `create-vite` templates and is a good starting point for beginners dipping their toes into a Vite + Svelte project. - -Should you later need the extended capabilities and extensibility provided by SvelteKit, the template has been structured similarly to SvelteKit so that it is easy to migrate. - -**Why `global.d.ts` instead of `compilerOptions.types` inside `jsconfig.json` or `tsconfig.json`?** - -Setting `compilerOptions.types` shuts out all other types not explicitly listed in the configuration. Using triple-slash references keeps the default TypeScript setting of accepting type information from the entire workspace, while also adding `svelte` and `vite/client` type information. - -**Why include `.vscode/extensions.json`?** - -Other templates indirectly recommend extensions via the README, but this file allows VS Code to prompt the user to install the recommended extension upon opening the project. - -**Why enable `checkJs` in the JS template?** - -It is likely that most cases of changing variable types in runtime are likely to be accidental, rather than deliberate. This provides advanced typechecking out of the box. Should you like to take advantage of the dynamically-typed nature of JavaScript, it is trivial to change the configuration. - -**Why is HMR not preserving my local component state?** - -HMR state preservation comes with a number of gotchas! It has been disabled by default in both `svelte-hmr` and `@sveltejs/vite-plugin-svelte` due to its often surprising behavior. You can read the details [here](https://github.com/sveltejs/svelte-hmr/tree/master/packages/svelte-hmr#preservation-of-local-state). - -If you have state that's important to retain within a component, consider creating an external store which would not be replaced by HMR. - -```js -// store.js -// An extremely simple external store -import { writable } from 'svelte/store' -export default writable(0) -``` +need to write this soon... diff --git a/public/audio/Lady.mp3 b/public/audio/Lady.mp3 new file mode 100644 index 0000000..283b0cb Binary files /dev/null and b/public/audio/Lady.mp3 differ diff --git a/public/audio/Rapp Snitch Knishes.mp3 b/public/audio/Rapp Snitch Knishes.mp3 new file mode 100644 index 0000000..1056b76 Binary files /dev/null and b/public/audio/Rapp Snitch Knishes.mp3 differ diff --git a/public/is there a point (girl u know).mp3 b/public/audio/is there a point (girl u know).mp3 similarity index 100% rename from public/is there a point (girl u know).mp3 rename to public/audio/is there a point (girl u know).mp3 diff --git a/public/cover.jpg b/public/cover.jpg deleted file mode 100644 index 69bfc70..0000000 Binary files a/public/cover.jpg and /dev/null differ diff --git a/public/img/1.jpg b/public/img/1.jpg new file mode 100644 index 0000000..9227222 Binary files /dev/null and b/public/img/1.jpg differ diff --git a/public/img/2.jpg b/public/img/2.jpg new file mode 100644 index 0000000..f968461 Binary files /dev/null and b/public/img/2.jpg differ diff --git a/public/img/3.jpg b/public/img/3.jpg new file mode 100644 index 0000000..6ca7cc4 Binary files /dev/null and b/public/img/3.jpg differ diff --git a/public/img/4.jpg b/public/img/4.jpg new file mode 100644 index 0000000..9dd4652 Binary files /dev/null and b/public/img/4.jpg differ diff --git a/public/img/5.jpg b/public/img/5.jpg new file mode 100644 index 0000000..52077af Binary files /dev/null and b/public/img/5.jpg differ diff --git a/public/img/6.jpg b/public/img/6.jpg new file mode 100644 index 0000000..0af9de7 Binary files /dev/null and b/public/img/6.jpg differ diff --git a/public/img/7.jpg b/public/img/7.jpg new file mode 100644 index 0000000..f9b352b Binary files /dev/null and b/public/img/7.jpg differ diff --git a/public/img/8.jpg b/public/img/8.jpg new file mode 100644 index 0000000..6fc9977 Binary files /dev/null and b/public/img/8.jpg differ diff --git a/src/App.svelte b/src/App.svelte index 47696ec..d1aab19 100644 --- a/src/App.svelte +++ b/src/App.svelte @@ -3,15 +3,18 @@ import { Map, Gamepad2, Disc3 } from "lucide-svelte"; import { gameDetails } from "./lib/events"; + import Slideshow from "./lib/Slideshow.svelte"; + import Playlist from "./lib/Playlist.svelte"; + import { writable } from "svelte/store"; - let volume = 0.05; + let title = writable(); {#if $gameDetails}
- - + +
@@ -25,7 +28,7 @@

Listening to:

-

EVABOY - is there a point (girl u know)

+

{$title}

diff --git a/src/config.json b/src/config.json new file mode 100644 index 0000000..968d2bb --- /dev/null +++ b/src/config.json @@ -0,0 +1,9 @@ +{ + "imageDuration": 10, + "images": ["/img/1.jpg", "/img/2.jpg", "/img/3.jpg", "/img/4.jpg", "/img/5.jpg", "/img/6.jpg", "/img/7.jpg", "/img/8.jpg"], + "playlist": [ + { "title": "MF DOOM - Rapp Snitch Knishes", "location": "/audio/Rapp Snitch Knishes.mp3" }, + { "title": "Modjo - Lady (Hear Me Tonight)", "location": "/audio/Lady.mp3" }, + { "title": "EVABOY - is there a point (girl u know)", "location": "/audio/is there a point (girl u know).mp3" } + ] +} diff --git a/src/lib/Playlist.svelte b/src/lib/Playlist.svelte new file mode 100644 index 0000000..8332c34 --- /dev/null +++ b/src/lib/Playlist.svelte @@ -0,0 +1,20 @@ + + + diff --git a/src/lib/Slideshow.svelte b/src/lib/Slideshow.svelte new file mode 100644 index 0000000..9d61954 --- /dev/null +++ b/src/lib/Slideshow.svelte @@ -0,0 +1,25 @@ + + + + {#each images as image} + + {/each} + + +{#each images as image} + {#if selected === image} + + {/if} +{/each} diff --git a/src/lib/steam.js b/src/lib/steam.js index 726b370..afac46f 100644 --- a/src/lib/steam.js +++ b/src/lib/steam.js @@ -1,3 +1,6 @@ +/** + * @param {string} steamid64 + */ export default async function (steamid64) { const response = await fetch(`https://steamcommunity.com/profiles/${steamid64}/?xml=1`); const xml = await response.text(); diff --git a/src/main.js b/src/main.js index 8a909a1..f5807a3 100644 --- a/src/main.js +++ b/src/main.js @@ -1,8 +1,8 @@ -import './app.css' -import App from './App.svelte' +import "./app.css"; +import App from "./App.svelte"; const app = new App({ - target: document.getElementById('app'), -}) + target: document.getElementById("app"), +}); -export default app +export default app;