Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Empty file modified .github/FUNDING.yml
100644 → 100755
Empty file.
Empty file modified .github/PULL_REQUEST_TEMPLATE.md
100644 → 100755
Empty file.
Empty file modified .github/dependabot.yml
100644 → 100755
Empty file.
Empty file modified .github/workflows/build-test.yml
100644 → 100755
Empty file.
Empty file modified .gitignore
100644 → 100755
Empty file.
Empty file modified .vscode/extensions.json
100644 → 100755
Empty file.
Empty file modified .vscode/settings.json
100644 → 100755
Empty file.
Empty file modified CONTRIBUTING.md
100644 → 100755
Empty file.
Empty file modified LICENSE
100644 → 100755
Empty file.
Empty file modified README.md
100644 → 100755
Empty file.
Empty file modified app/.gitignore
100644 → 100755
Empty file.
Empty file modified app/.prettierignore
100644 → 100755
Empty file.
Empty file modified app/.prettierrc
100644 → 100755
Empty file.
6 changes: 3 additions & 3 deletions app/bun.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Empty file modified app/bunfig.toml
100644 → 100755
Empty file.
2 changes: 1 addition & 1 deletion app/package.json
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@
"vite": "^8.0.0"
},
"dependencies": {
"@lucide/svelte": "^1.18.0",
"html-to-image": "^1.11.13",
"lucide-svelte": "^0.577.0",
"svelte-awesome-color-picker": "^4.1.1",
"tinycolor2": "^1.6.0",
"twemoji": "^14.0.2"
Expand Down
Empty file modified app/src/app.d.ts
100644 → 100755
Empty file.
Empty file modified app/src/app.html
100644 → 100755
Empty file.
Empty file modified app/src/components/Badge.svelte
100644 → 100755
Empty file.
2 changes: 1 addition & 1 deletion app/src/components/Banner.svelte
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
CloudAlert,
ServerOff,
Wrench,
} from "lucide-svelte";
} from "@lucide/svelte";

const {
type = "fail",
Expand Down
Empty file modified app/src/components/ChatDisplay.svelte
100644 → 100755
Empty file.
Empty file modified app/src/components/ChatMessage.svelte
100644 → 100755
Empty file.
Empty file modified app/src/components/ChatOverlay.svelte
100644 → 100755
Empty file.
76 changes: 50 additions & 26 deletions app/src/components/Dialog.svelte
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,16 +1,32 @@
<script lang="ts">
import { X } from "lucide-svelte";
import { X } from "@lucide/svelte";
import type { Snippet } from "svelte";
import Button from "./Inputs/Button.svelte";

let { name, show = $bindable(false), children } = $props();
type Props = {
name: string;
show: boolean;
buttons?: Snippet;
children: Snippet;
};

let { name, show = $bindable(false), buttons, children }: Props = $props();

const close = () => (show = false);
</script>

{#if show}
<section class="dialog">
<h3>{name} <button onclick={close}><X /></button></h3>

{@render children()}
<span id="header">
<p>{name}</p>
<Button onclick={close}><X /></Button>
</span>
<hr />
<section id="content">{@render children()}</section>
{#if typeof buttons != "undefined"}
<hr />
<section id="buttons">{@render buttons()}</section>
{/if}
</section>
<section id="site-blackout"></section>
{/if}
Expand All @@ -20,7 +36,7 @@
position: absolute;
width: 100%;
height: 100%;
background-color: rgba(0, 0, 0, 0.25);
background-color: rgba(0, 0, 0, 0.5);
z-index: 999;
}

Expand All @@ -30,46 +46,54 @@
left: 50%;
transform: translate(-50%, -50%);
z-index: 100000;
background-color: rgb(17, 17, 17);
background-color: #0a0a0a;
box-shadow: 0 10px 20px rgba(0, 0, 0, 0.5);

// overflow: hidden;

display: flex;
flex-direction: column;

gap: 0.7rem;

max-width: 30rem;
max-height: 25rem;

padding: 0.4rem 0.7rem;
border-radius: 1rem;

border-radius: 0.5rem;
& > *:not(hr) {
padding: 0.5rem 1rem;
box-sizing: border-box;
// outline: 1px red solid;
}

h3 {
#header {
margin: 0;
display: flex;
display: inline-flex;
align-items: center;
justify-content: space-between;
user-select: none;
padding-bottom: 0.2rem;

border-bottom: 1px #242424 solid;
}

button {
background: none;
border: none;
cursor: pointer;
#buttons {
display: inline-flex;
justify-content: space-between;

color: white;
padding-block: 0.5rem;

&:hover {
color: rgba(255, 255, 255, 0.75);
}
& > :global(*) {
display: inline-flex;
gap: 0.5rem;
}
}
}

@media (max-width: 768px) {
.dialog {
width: 80%;
max-width: unset;
max-height: unset;

border-radius: unset;

width: 100%;
height: 100%;
}
}
</style>
193 changes: 193 additions & 0 deletions app/src/components/Inputs/Button.svelte
Original file line number Diff line number Diff line change
@@ -0,0 +1,193 @@
<script lang="ts">
import type { Snippet } from "svelte";
import type {
HTMLButtonAttributes,
HTMLAnchorAttributes,
} from "svelte/elements";

type Props = {
href?: string | null;
icon?: Snippet;
iconRight?: Snippet;
element?: HTMLElement;
disabled?: boolean;
wide?: boolean;
center?: boolean;
primary?: boolean;
secondary?: boolean;
danger?: boolean;
approve?: boolean;
layout?: "row" | "column";
children?: Snippet;
} & HTMLButtonAttributes &
HTMLAnchorAttributes;

let {
href,
icon,
iconRight,
element = $bindable(),
disabled = false,
wide = false,
center = false,
primary = false,
secondary = false,
danger = false,
approve = false,
layout = "row",
children,
...restProps
}: Props = $props();
</script>

{#if href}
<a
bind:this={element}
{href}
{...restProps}
class:disabled
class:wide
class:center
class:primary
class:secondary
class:danger
class:approve
class:column={layout == "column"}
>
{@render icon?.()}
<span>{@render children?.()}</span>
{@render iconRight?.()}
</a>
{:else}
<button
bind:this={element}
{...restProps}
{disabled}
class:disabled
class:wide
class:center
class:secondary
class:primary
class:danger
class:approve
class:column={layout == "column"}
>
{@render icon?.()}
<span>{@render children?.()}</span>
{@render iconRight?.()}
</button>
{/if}

<style lang="scss">
a,
button {
background-color: var(--ghost);
color: var(--ghost-text);
border: var(--ghost-border);
border-radius: 10px;
padding: 0.5rem;
cursor: pointer;
font-size: inherit;
display: inline-flex;
align-items: center;
text-align: center;
gap: 0.5rem;

white-space: nowrap;
user-select: none;
flex-wrap: nowrap;

&.column {
flex-direction: column;
}

text-decoration: none !important;

transition:
background-color 0.3s ease,
border-radius 0.3s ease;

&.center {
justify-content: center;
}

&.wide {
width: 100%;
}

&:active,
&:hover {
background-color: var(--ghost-hover);
border-radius: 7px;
}

&.active {
border-radius: 5px;
background-color: var(--ghost-active);
}

&.primary {
background-color: var(--primary);
color: var(--primary-text);
border: var(--primary-border);

&:active,
&:hover {
background-color: var(--primary-hover);
}

&.active {
background-color: var(--primary-active);
}
}

&.secondary {
background-color: var(--secondary);
color: var(--secondary-text);
border: var(--secondary-border);

&:active,
&:hover {
background-color: var(--secondary-hover);
}

&.active {
background-color: var(--secondary-active);
}
}

&.danger {
background-color: var(--danger);
color: var(--danger-text);
border: var(--danger-border);

&:active,
&:hover {
background-color: var(--danger-hover);
color: var(--danger-text-hover);
}

&.active {
background-color: var(--danger-active);
color: var(--danger-text-active);
}
}

&.approve {
background-color: var(--approve);
color: var(--approve-text);
border: var(--approve-border);

&:active,
&:hover {
background-color: var(--approve-hover);
color: var(--approve-text-hover);
}

&.active {
background-color: var(--approve-active);
color: var(--approve-text-active);
}
}
}
</style>
Loading
Loading