-
Notifications
You must be signed in to change notification settings - Fork 3
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
7 changed files
with
78 additions
and
100 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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,21 +1,26 @@ | ||
<script> | ||
import Queue from "./queue.svelte"; | ||
import Song from "./song.svelte" | ||
import Favorites from "./favorites.svelte" | ||
import {Heading} from "flowbite-svelte" | ||
import { Tabs, TabItem} from "flowbite-svelte" | ||
import StarSolid from "flowbite-svelte-icons/StarSolid.svelte" | ||
import ListMusicSolid from "flowbite-svelte-icons/ListMusicSolid.svelte" | ||
</script> | ||
<Heading tag="h1" align="center">Gerry UI</Heading> | ||
<div class="grid grid-cols-3 gap-4 m-5 items-center justify-item-center"> | ||
<div> | ||
<Heading tag="h4">Queue</Heading> | ||
<Tabs style="underline"> | ||
<TabItem open> | ||
<div slot="title" class="flex items-center gap-2"> | ||
<ListMusicSolid /> | ||
Queue | ||
</div> | ||
<Queue /> | ||
</div> | ||
<div> | ||
<Song /> | ||
</div> | ||
<div> | ||
<Heading tag="h4">Favorites</Heading> | ||
</TabItem> | ||
<TabItem> | ||
<div slot="title" class="flex items-center gap-2"> | ||
<StarSolid /> | ||
Favorites | ||
</div> | ||
<Favorites /> | ||
</div> | ||
</TabItem> | ||
</Tabs> | ||
<div > | ||
</div> | ||
|
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,27 +1,11 @@ | ||
<script> | ||
import {Heading} from "flowbite-svelte" | ||
import {Button, Dropdown, DropdownItem } from "flowbite-svelte" | ||
import { Button } from "flowbite-svelte"; | ||
</script> | ||
|
||
<div class="grid grid-row-3 gap-4"> | ||
<Button>Add to favorites</Button> | ||
<Dropdown> | ||
<DropdownItem> | ||
<Button class="w-25 absolute right-9 bottom-5"> | ||
Add to Favorites | ||
</Button> | ||
<div class="grid grid-col-2 gap-4"> | ||
|
||
</DropdownItem> | ||
</Dropdown> | ||
|
||
<Button>Remove from favorites</Button> | ||
<Dropdown> | ||
<DropdownItem> | ||
|
||
</DropdownItem> | ||
</Dropdown> | ||
|
||
<Button>Show favorites</Button> | ||
<Dropdown> | ||
<DropdownItem> | ||
|
||
</DropdownItem> | ||
</Dropdown> | ||
</div> |
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,56 +1,43 @@ | ||
<script> | ||
import {AddToQueue, RemoveFromQueue, GetQueue} from '../lib/queue' | ||
import {Label, Input} from 'flowbite-svelte' | ||
import {Button, Dropdown, DropdownItem } from "flowbite-svelte" | ||
import {Button} from "flowbite-svelte"; | ||
import {Avatar} from "flowbite-svelte" | ||
import {P, Heading, A} from "flowbite-svelte"; | ||
import { GetQueue, AddToQueue, RemoveFromQueue } from "../lib/queue"; | ||
import PlaySolid from "flowbite-svelte-icons/PlaySolid.svelte" | ||
import PauseSolid from "flowbite-svelte-icons/PauseSolid.svelte" | ||
let queue = GetQueue("145618799947677696", "iAADRNu7eEfcHmcT9j9pbUsI4Rff7ihG"); | ||
</script> | ||
|
||
<div class="grid grid-row-3 gap-4"> | ||
<Button>Add a song to the queue</Button> | ||
<Dropdown> | ||
<DropdownItem> | ||
<form> | ||
<Label for="id" class="block mb-2">Guild ID</Label> | ||
<Input type="text" id="id" /> | ||
<Label for="link" class="mt-2">Song name or link</Label> | ||
<Input type="text" id="song" /> | ||
<Label for="token" class="mt-2">User token</Label> | ||
<Input type="text" id="token" /> | ||
<Label for="playlist" class="mt-2"> Playlist </Label> | ||
<Input type="checkbox" id="playlist" /> | ||
<Label for="shuffle" class="mt-2"> Shuffle </Label> | ||
<Input type="checkbox" id="shuffle" /> | ||
<Label for="loop" class="mt-2"> Loop </Label> | ||
<Input type="checkbox" id="loop" /> | ||
<Label for="priority" class="mt-2"> Priority </Label> | ||
<Input type="checkbox" id="priority" /> | ||
|
||
<Button class="mt-2" on:click={AddToQueue} >Submit</Button> | ||
</form> | ||
</DropdownItem> | ||
</Dropdown> | ||
<Button>Skip song</Button> | ||
<Dropdown> | ||
<DropdownItem> | ||
<form> | ||
<Label for="id" class="block mb-2">Guild ID</Label> | ||
<Input type="text" id="id" /> | ||
<Label for="clear" class="mt-2">Clear queue?</Label> | ||
<Input type="checkbox" id="clear" /> | ||
<Button class="w-25 absolute right-9 bottom-5"> | ||
Add to Queue | ||
</Button> | ||
|
||
<Button class="mt-2" on:click={RemoveFromQueue} >Submit</Button> | ||
</form> | ||
</DropdownItem> | ||
</Dropdown> | ||
<Button>Show queue</Button> | ||
<Dropdown> | ||
<DropdownItem> | ||
<Label for="id" class="block mb-2"> Guild ID</Label> | ||
<Input type="text" id="id" /> | ||
<Label for="token" class="mt-2">User token</Label> | ||
<Input type="text" id="token" /> | ||
|
||
<Button class="mt-2" on:click={GetQueue} >Submit</Button> | ||
</DropdownItem> | ||
</Dropdown> | ||
|
||
</div> | ||
|
||
{#await queue} | ||
<P>Fetching Queue</P> | ||
{:then json} | ||
<div class="grid grid-cols-2 gap-4"> | ||
<div > | ||
<img alt="thumbnail" src={json[0].thumbnail} class=""/> | ||
<div class="mt-5 grid grid-cols-2"> | ||
<div class="justify-self-end"><PauseSolid /></div> | ||
<div class="justify-self-start"><PlaySolid /></div> | ||
</div> | ||
<P class="mt-5">{json[0].title}</P> | ||
<P>Requested by {json[0].user}</P> | ||
</div> | ||
<div> | ||
<Heading tag="h4" class="mb-5" align="center">Queue</Heading> | ||
{#each json as song, index} | ||
{#if index != 0} | ||
<div class="grid grid-cols-3 justify-items-center mt-3" > | ||
<Avatar src={song.thumbnail} rounded/> | ||
<A href={song.link}>{song.title}</A> | ||
<P>{song.duration}</P> | ||
</div> | ||
{/if} | ||
{/each} | ||
</div> | ||
</div> | ||
{/await} |
This file was deleted.
Oops, something went wrong.