Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Init Tickets #1157

Merged
merged 144 commits into from
Aug 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
144 commits
Select commit Hold shift + click to select a range
6cf97ab
a rough start
thejessewinton Jun 26, 2024
435cbeb
experiments
thejessewinton Jul 1, 2024
5cfba05
Merge branch 'main' into init-playground
thejessewinton Jul 2, 2024
b131b91
experiment
thejessewinton Jul 2, 2024
98108b3
some works
thejessewinton Jul 2, 2024
d01e76f
working
thejessewinton Jul 3, 2024
85b8ea7
add animated component
thejessewinton Jul 3, 2024
b3ab776
new v
thejessewinton Jul 4, 2024
23800df
new thoughts
thejessewinton Jul 4, 2024
bb38355
Update Heading.svelte
thejessewinton Jul 4, 2024
48ac3ee
update
thejessewinton Jul 4, 2024
3731afe
lockup stuff
thejessewinton Jul 4, 2024
b6330d3
updates to init homepage
thejessewinton Jul 5, 2024
a5e3485
animation updates
thejessewinton Jul 5, 2024
7646cb5
updates
thejessewinton Jul 5, 2024
af13f1b
Merge branch 'main' into init-playground
thejessewinton Jul 8, 2024
6d26ed1
clean up
thejessewinton Jul 8, 2024
8ef7f06
clean up
thejessewinton Jul 8, 2024
6c87bb1
getting there
thejessewinton Jul 8, 2024
5a19b39
getting better
thejessewinton Jul 9, 2024
8d1a504
Update Lockup.svelte
thejessewinton Jul 9, 2024
1fcdd81
Merge branch 'main' into init-playground
thejessewinton Jul 11, 2024
1eb64dc
mostly finish lockup
thejessewinton Jul 11, 2024
a2e99eb
pretty much there
thejessewinton Jul 11, 2024
e22d3fc
Update Lockup.svelte
thejessewinton Jul 12, 2024
7cd11ab
Merge branch 'main' into init-playground
thejessewinton Jul 12, 2024
47a4d6c
Update Lockup.svelte
thejessewinton Jul 13, 2024
46513df
back to js
thejessewinton Jul 13, 2024
1ada350
Merge branch 'main' into init-playground
thejessewinton Jul 15, 2024
e7e01d9
update
thejessewinton Jul 15, 2024
ef7068f
Update Lockup.svelte
thejessewinton Jul 15, 2024
70b33aa
Update Lockup.svelte
thejessewinton Jul 15, 2024
544ce32
some tweaks
thejessewinton Jul 15, 2024
ddf485b
multi-path
thejessewinton Jul 15, 2024
057fd3b
Update Lockup.svelte
thejessewinton Jul 15, 2024
46ce091
Update Lockup.svelte
thejessewinton Jul 15, 2024
5030c24
Update Lockup.svelte
thejessewinton Jul 15, 2024
e47a9b9
add controls component
thejessewinton Jul 15, 2024
ba13864
update
thejessewinton Jul 15, 2024
58fce8f
Update Lockup.svelte
thejessewinton Jul 15, 2024
e1381b0
Update Lockup.svelte
thejessewinton Jul 15, 2024
70c58de
Update Lockup.svelte
thejessewinton Jul 16, 2024
4da8469
update
thejessewinton Jul 16, 2024
d1be9fe
Update Lockup.svelte
thejessewinton Jul 16, 2024
0717500
update
thejessewinton Jul 16, 2024
07b6576
tweaks
thejessewinton Jul 16, 2024
eb50576
faster lines
thejessewinton Jul 16, 2024
b64a2e0
more tweaks
thejessewinton Jul 16, 2024
82c86d9
fix
thejessewinton Jul 16, 2024
85e3ad4
Update Lockup.svelte
thejessewinton Jul 16, 2024
7ebdc97
update
thejessewinton Jul 16, 2024
c0c5ff2
update
thejessewinton Jul 16, 2024
5e5a5eb
2 tickets start
thejessewinton Jul 16, 2024
2f5362b
Update Ticket.svelte
thejessewinton Jul 16, 2024
7335146
Merge branch 'main' into init-playground
thejessewinton Jul 17, 2024
e1ed770
biiiiig updates
thejessewinton Jul 17, 2024
5cf53dc
updates
thejessewinton Jul 17, 2024
7776071
Update Ticket.svelte
thejessewinton Jul 18, 2024
82d760f
fix noise and shine
thejessewinton Jul 18, 2024
58179bf
update tickets
thejessewinton Jul 18, 2024
97b2c4e
fix lockup
thejessewinton Jul 18, 2024
b0c863e
add drawer for ticket
thejessewinton Jul 18, 2024
b90b98e
more work on drawer
thejessewinton Jul 18, 2024
113a576
finish desktop tickets
thejessewinton Jul 18, 2024
74b2e37
updates
thejessewinton Jul 19, 2024
934a13c
fix
thejessewinton Jul 19, 2024
ad03d3e
tickets
thejessewinton Jul 19, 2024
7924f5c
come back later
thejessewinton Jul 20, 2024
672a94a
wrap the ticket marquee
thejessewinton Jul 20, 2024
22f09da
Update Ticket.svelte
thejessewinton Jul 20, 2024
be9da6e
update
thejessewinton Jul 20, 2024
7e1f2c9
tweaks
thejessewinton Jul 22, 2024
55e744e
simplify ticket
thejessewinton Jul 22, 2024
6fad449
continue
thejessewinton Jul 22, 2024
e0cba58
ticket lines
thejessewinton Jul 22, 2024
bc56bf4
mobile ticket
thejessewinton Jul 22, 2024
eea756d
update
thejessewinton Jul 22, 2024
7856d29
finish it up
thejessewinton Jul 22, 2024
87f82cd
change contributions fetch to account for streaming
thejessewinton Jul 22, 2024
4457af0
update
thejessewinton Jul 22, 2024
d2e718d
finish clean up
thejessewinton Jul 22, 2024
9e5bcc5
done
thejessewinton Jul 22, 2024
c00503d
Update Ticket.svelte
thejessewinton Jul 23, 2024
2502404
revert
thejessewinton Jul 23, 2024
19abded
Update TicketActions.svelte
thejessewinton Jul 23, 2024
852b33b
ticket page
thejessewinton Jul 23, 2024
7732d65
Update Hero.svelte
thejessewinton Jul 23, 2024
6a80d9e
backlight whole card
thejessewinton Jul 23, 2024
0e45271
work on OG image
thejessewinton Jul 23, 2024
5140848
start on layout/pages
thejessewinton Jul 24, 2024
c5e782f
OG image
thejessewinton Jul 24, 2024
ea84eba
Update getTicketSvg.server.ts
thejessewinton Jul 24, 2024
b078084
done with OG image
thejessewinton Jul 24, 2024
8f213f3
update ticket
thejessewinton Jul 24, 2024
2a317a2
finish ticket
thejessewinton Jul 24, 2024
de3cb0b
add effect to lockup
thejessewinton Jul 24, 2024
4db1625
update
thejessewinton Jul 24, 2024
a17572d
Update Lines.svelte
thejessewinton Jul 24, 2024
eff3c9e
update
thejessewinton Jul 24, 2024
2efcbd3
some fixes
thejessewinton Jul 25, 2024
06230fc
update
thejessewinton Jul 26, 2024
5514a27
Merge branch 'main' into init-playground
thejessewinton Jul 26, 2024
85216f6
add env to build steps
thejessewinton Jul 26, 2024
bd2e46e
update typo
thejessewinton Aug 2, 2024
98ed2f8
Merge branch 'main' into init-playground
thejessewinton Aug 2, 2024
3508142
Empty-Commit
thejessewinton Aug 2, 2024
d456c99
Update .env.example
thejessewinton Aug 2, 2024
5ba2001
Empty-Commit
thejessewinton Aug 2, 2024
d244630
Update tests.yml
ArmanNik Aug 2, 2024
b74c415
Empty-Commit
thejessewinton Aug 2, 2024
7b39dd6
update naming
thejessewinton Aug 2, 2024
cbf1d94
Merge branch 'init-playground' of https://github.com/appwrite/website…
thejessewinton Aug 2, 2024
a6b0134
Update +server.ts
thejessewinton Aug 2, 2024
e2a7678
Empty-Commit
thejessewinton Aug 2, 2024
8b398c9
fix?
thejessewinton Aug 2, 2024
168f601
update OG image
thejessewinton Aug 2, 2024
43615cf
Update helpers.ts
thejessewinton Aug 2, 2024
b06c2f6
clean up lines
thejessewinton Aug 2, 2024
f81ae5c
update lockup
thejessewinton Aug 2, 2024
8e8286c
Update Lockup.svelte
thejessewinton Aug 2, 2024
17bcb39
clean up css
thejessewinton Aug 2, 2024
fb9d09c
tweak endpoint for CORS?
thejessewinton Aug 4, 2024
44ea9c5
update
thejessewinton Aug 5, 2024
45cf8ae
update dates
thejessewinton Aug 5, 2024
228be3c
fix: ci for tests
TorstenDittmann Aug 5, 2024
01bf643
ci: fix ref commit id
TorstenDittmann Aug 5, 2024
8334b19
add dashboard env
thejessewinton Aug 5, 2024
1c4e27f
Merge branch 'init-playground' of https://github.com/appwrite/website…
thejessewinton Aug 5, 2024
592ac6d
Merge branch 'main' into init-playground
TorstenDittmann Aug 5, 2024
94a8afa
Merge branch 'main' into init-playground
TorstenDittmann Aug 5, 2024
0e9a42e
update links to use env
thejessewinton Aug 5, 2024
42ea794
update visuals
thejessewinton Aug 5, 2024
5672575
updates
thejessewinton Aug 5, 2024
33b5e02
Update +server.ts
thejessewinton Aug 5, 2024
30359f4
fix ticket scroll
thejessewinton Aug 5, 2024
a962fe0
tweak lockup
thejessewinton Aug 5, 2024
ec1a37a
tweak lockup lines
thejessewinton Aug 5, 2024
28de057
start announcement banner
thejessewinton Aug 5, 2024
accb93d
start init banner
thejessewinton Aug 5, 2024
5e843ac
first pass at banner
thejessewinton Aug 5, 2024
b091c46
Update +page.svelte
thejessewinton Aug 6, 2024
85b60a8
ci: add new env variables
TorstenDittmann Aug 6, 2024
9946ead
Merge branch 'init-playground' of https://github.com/appwrite/website…
TorstenDittmann Aug 6, 2024
f601e76
update ticket styles
thejessewinton Aug 6, 2024
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
2 changes: 2 additions & 0 deletions .github/workflows/production.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ jobs:
push: true
tags: ghcr.io/appwrite/website:${{ env.TAG }}
build-args: |
"PUBLIC_APPWRITE_ENDPOINT=${{ secrets.PUBLIC_APPWRITE_ENDPOINT }}"
"PUBLIC_APPWRITE_DASHBOARD=${{ secrets.PUBLIC_APPWRITE_DASHBOARD }}"
"PUBLIC_APPWRITE_PROJECT_ID=${{ vars.PUBLIC_APPWRITE_PROJECT_ID }}"
"PUBLIC_APPWRITE_DB_MAIN_ID=${{ vars.PUBLIC_APPWRITE_DB_MAIN_ID }}"
"PUBLIC_APPWRITE_COL_THREADS_ID=${{ vars.PUBLIC_APPWRITE_COL_THREADS_ID }}"
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/staging.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@ jobs:
push: true
tags: ghcr.io/appwrite/website:${{ env.TAG }}
build-args: |
"PUBLIC_APPWRITE_ENDPOINT=${{ secrets.PUBLIC_APPWRITE_ENDPOINT }}"
"PUBLIC_APPWRITE_DASHBOARD=${{ secrets.PUBLIC_APPWRITE_DASHBOARD }}"
"PUBLIC_APPWRITE_PROJECT_ID=${{ vars.PUBLIC_APPWRITE_PROJECT_ID }}"
"PUBLIC_APPWRITE_DB_MAIN_ID=${{ vars.PUBLIC_APPWRITE_DB_MAIN_ID }}"
"PUBLIC_APPWRITE_COL_THREADS_ID=${{ vars.PUBLIC_APPWRITE_COL_THREADS_ID }}"
Expand Down
6 changes: 6 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
FROM node:20-bullseye as base

ARG PUBLIC_APPWRITE_ENDPOINT
ENV PUBLIC_APPWRITE_ENDPOINT ${PUBLIC_APPWRITE_ENDPOINT}

ARG PUBLIC_APPWRITE_DASHBOARD
ENV PUBLIC_APPWRITE_DASHBOARD ${PUBLIC_APPWRITE_DASHBOARD}

ARG PUBLIC_APPWRITE_COL_MESSAGES_ID
ENV PUBLIC_APPWRITE_COL_MESSAGES_ID ${PUBLIC_APPWRITE_COL_MESSAGES_ID}

Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
},
"packageManager": "[email protected]+sha512.f549b8a52c9d2b8536762f99c0722205efc5af913e77835dbccc3b0b0b2ca9e7dc8022b78062c17291c48e88749c70ce88eb5a74f1fa8c4bf5e18bb46c8bd83a",
"dependencies": {
"@ethercorps/sveltekit-og": "^3.0.0",
"@sentry/sveltekit": "^8.12.0",
"embla-carousel-svelte": "^8.1.5",
"embla-carousel-wheel-gestures": "^8.0.1",
Expand Down
3,466 changes: 1,959 additions & 1,507 deletions pnpm-lock.yaml

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions src/lib/appwrite/index.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import { PUBLIC_APPWRITE_PROJECT_ID } from '$env/static/public';
import { PUBLIC_APPWRITE_ENDPOINT, PUBLIC_APPWRITE_PROJECT_ID } from '$env/static/public';
import { Client, Databases, Functions } from '@appwrite.io/console';

export const client = new Client();

client.setEndpoint('https://cloud.appwrite.io/v1').setProject(PUBLIC_APPWRITE_PROJECT_ID);
client.setEndpoint(PUBLIC_APPWRITE_ENDPOINT).setProject(PUBLIC_APPWRITE_PROJECT_ID);

export const databases = new Databases(client);
export const functions = new Functions(client);
4 changes: 2 additions & 2 deletions src/lib/appwrite/init.server.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import { APPWRITE_API_KEY_INIT } from '$env/static/private';
import { PUBLIC_APPWRITE_PROJECT_INIT_ID } from '$env/static/public';
import { PUBLIC_APPWRITE_ENDPOINT, PUBLIC_APPWRITE_PROJECT_INIT_ID } from '$env/static/public';
import { Client, Databases } from '@appwrite.io/console';

const clientServer = new Client();
clientServer
.setEndpoint('https://cloud.appwrite.io/v1')
.setEndpoint(PUBLIC_APPWRITE_ENDPOINT)
.setProject(PUBLIC_APPWRITE_PROJECT_INIT_ID)
.setKey(APPWRITE_API_KEY_INIT);

Expand Down
6 changes: 2 additions & 4 deletions src/lib/appwrite/init.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
import { PUBLIC_APPWRITE_PROJECT_INIT_ID } from '$env/static/public';
import { PUBLIC_APPWRITE_ENDPOINT, PUBLIC_APPWRITE_PROJECT_INIT_ID } from '$env/static/public';
import { Client, Account } from '@appwrite.io/console';

const client = new Client();
client
.setEndpoint('https://cloud.appwrite.io/v1')
.setProject(PUBLIC_APPWRITE_PROJECT_INIT_ID);
client.setEndpoint(PUBLIC_APPWRITE_ENDPOINT).setProject(PUBLIC_APPWRITE_PROJECT_INIT_ID);

export const appwriteInit = {
client,
Expand Down
66 changes: 66 additions & 0 deletions src/lib/components/AnnouncementBanner.svelte
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
<div class="banner">
<div class="content web-u-color-text-primary">
<div class="headings">
<span style:font-weight="500"
>init<span class="web-u-color-text-accent">_</span> is coming
</span>
<span class="web-u-color-text-secondary">The start of something new</span>
</div>
<a href="/init/tickets" rel="noopener noreferrer">
<span class="web-caption-500">Register now</span>
<span class="web-icon-arrow-right" aria-hidden="true" />
</a>
</div>
<div class="shine" />
<div class="border" />
</div>

<style lang="scss">
.banner {
--shine: rgba(255, 255, 255, 0.04);
position: relative;
min-height: 80px;
display: flex;
align-items: center;
border-bottom: 1px solid hsl(var(--web-color-border));

.content {
display: flex;
justify-content: space-between;
align-items: center;
width: 100%;
position: relative;
z-index: 10;
padding-inline: clamp(1.25rem, 4vw, 120rem);

.headings {
display: flex;
flex-direction: column;
}
}

.shine {
position: absolute;
inset: 0;
background: hsl(var(--web-color-background))
linear-gradient(
-24deg,
rgba(255, 255, 255, 0) 0,
var(--shine) 20%,
rgba(255, 255, 255, 0) 40%,
var(--shine) 50%,
rgba(255, 255, 255, 0) 60%,
var(--shine) 80%,
rgba(255, 255, 255, 0) 100%
);
}
.border {
position: absolute;
left: 0;
right: 0;
height: 1px;
background-color: hsl(var(--web-color-border));
bottom: 0;
}
}
</style>
4 changes: 3 additions & 1 deletion src/lib/components/IsLoggedIn.svelte
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
<script lang="ts">
import { PUBLIC_APPWRITE_DASHBOARD } from '$env/static/public';

export let classes = '';
</script>

<a href="https://cloud.appwrite.io" class={`web-button ${classes}`}>
<a href={PUBLIC_APPWRITE_DASHBOARD} class={`web-button ${classes}`}>
<span class="logged-in"><slot name="isLoggedIn">Go to Console</slot></span>
<span class="not-logged-in"><slot name="isNotLoggedIn">Get started</slot></span>
</a>
Expand Down
6 changes: 5 additions & 1 deletion src/lib/components/MobileNav.svelte
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
<script lang="ts">
import { afterNavigate } from '$app/navigation';
import { PUBLIC_APPWRITE_DASHBOARD } from '$env/static/public';
import { IsLoggedIn } from '$lib/components';
import { GITHUB_STARS } from '$lib/constants';
import type { NavLink } from '$lib/layouts/Main.svelte';
Expand All @@ -17,7 +18,10 @@
<nav class="web-side-nav web-is-not-desktop" class:u-hide={!open}>
<div class="web-side-nav-wrapper web-u-padding-inline-16">
<div class="u-flex items-center u-gap-8">
<a href="https://cloud.appwrite.io/register" class="web-button is-secondary web-u-flex-1">
<a
href={`${PUBLIC_APPWRITE_DASHBOARD}/register`}
class="web-button is-secondary web-u-flex-1"
>
Sign up
</a>
<IsLoggedIn classes="web-u-flex-1" />
Expand Down
7 changes: 4 additions & 3 deletions src/lib/components/PreFooter.svelte
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
<script lang="ts">
import { PUBLIC_APPWRITE_DASHBOARD } from '$env/static/public';
</script>

<img src="/images/bgs/pre-footer.png" alt="" class="web-pre-footer-bg" style="z-index:-1" />
Expand All @@ -9,7 +10,7 @@
Start building today
</h2>
<a
href="https://cloud.appwrite.io"
href={PUBLIC_APPWRITE_DASHBOARD}
class="web-button is-transparent web-u-cross-child-center"
>
<span class="text">Get started</span>
Expand All @@ -36,7 +37,7 @@
For personal hobby projects and students.
</p>
<a
href="https://cloud.appwrite.io/register"
href={`${PUBLIC_APPWRITE_DASHBOARD}/register`}
class="web-button is-secondary is-full-width-mobile web-u-cross-child-end"
>
<span class="text">Get started</span>
Expand All @@ -54,7 +55,7 @@
For pro developers and teams that need to scale their products.
</p>
<a
href="https://cloud.appwrite.io/console?type=createPro"
href={`${PUBLIC_APPWRITE_DASHBOARD}/console?type=createPro`}
class="web-button is-full-width-mobile web-u-cross-child-end"
target="_blank"
rel="noopener noreferrer"
Expand Down
6 changes: 4 additions & 2 deletions src/lib/constants.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
export const GITHUB_STARS = '42.8K';
export const BANNER_KEY = 'discord-banner-01'; // Change key to force banner to show again
export const SENTRY_DSN = 'https://[email protected]/4507497727000576'
export const BANNER_KEY = 'init-banner-02'; // Change key to force banner to show again
export const SENTRY_DSN =
'https://[email protected]/4507497727000576';

/**
* History:
* discord-banner-01
* init-banner-02
* pricing-banner-01
*/

Expand Down
9 changes: 7 additions & 2 deletions src/lib/layouts/Docs.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@
import { isMac } from '$lib/utils/platform';
import { getContext, setContext } from 'svelte';
import { GITHUB_STARS } from '$lib/constants';
import { PUBLIC_APPWRITE_DASHBOARD } from '$env/static/public';

export let variant: DocsLayoutVariant = 'default';
export let isReferences = false;
Expand Down Expand Up @@ -99,10 +100,14 @@
</a>
</div>
<div class="web-mobile-header-end">
<a href="https://cloud.appwrite.io" class="web-button web-is-only-desktop">
<a href={PUBLIC_APPWRITE_DASHBOARD} class="web-button web-is-only-desktop">
<span class="web-sub-body-500">Go to Console</span>
</a>
<button class="web-button is-text" aria-label="open navigation" on:click={toggleSidenav}>
<button
class="web-button is-text"
aria-label="open navigation"
on:click={toggleSidenav}
>
{#if $layoutState.showSidenav}
<span aria-hidden="true" class="web-icon-close" />
{:else}
Expand Down
37 changes: 11 additions & 26 deletions src/lib/layouts/Main.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@
import { onMount } from 'svelte';
import { page } from '$app/stores';
import { loggedIn } from '$lib/utils/console';
import { PUBLIC_APPWRITE_DASHBOARD } from '$env/static/public';
import AnnouncementBanner from '$lib/components/AnnouncementBanner.svelte';

export let omitMainId = false;
let theme: 'light' | 'dark' | null = 'dark';
Expand Down Expand Up @@ -141,11 +143,6 @@

return $scrollInfo.deltaDirChange < 200;
})();

const hideTopBanner = () => {
document.body.dataset.bannerHidden = '';
localStorage.setItem(BANNER_KEY, 'true');
};
</script>

<div class="u-position-relative">
Expand Down Expand Up @@ -174,7 +171,7 @@
</div>
<div class="web-mobile-header-end">
{#if !$isMobileNavOpen}
<a href="https://cloud.appwrite.io" class="web-button">
<a href={PUBLIC_APPWRITE_DASHBOARD} class="web-button">
<span class="text">Get started</span>
</a>
{/if}
Expand All @@ -192,29 +189,13 @@
</div>
</section>
<header
class="web-main-header is-special-padding theme-{resolvedTheme} is-transparent"
class="web-main-header theme-{resolvedTheme} is-transparent"
style="padding-left:0;padding-right:0;"
class:is-hidden={$isHeaderHidden}
>
<div class="web-top-banner">
<div class="web-top-banner-content web-u-color-text-primary">
<a href="/discord" target="_blank" rel="noopener noreferrer">
<span class="web-caption-500">We are having lots of fun on</span>
<span class="web-icon-discord" aria-hidden="true" />
<span class="web-caption-500">Discord. Come and join us!</span>
</a>
{#if browser}
<button
class="web-top-banner-button"
aria-label="close discord message"
on:click={hideTopBanner}
>
<span class="web-icon-close" aria-hidden="true" />
</button>
{/if}
</div>
</div>
<AnnouncementBanner />

<div class="web-main-header-wrapper">
<div class="web-main-header-wrapper is-special-padding">
<div class="web-main-header-start">
<a href="/">
<img
Expand Down Expand Up @@ -289,6 +270,10 @@
}
}

.is-special-padding {
padding-inline: clamp(1.25rem, 4vw, 120rem);
}

[data-badge] {
position: relative;

Expand Down
4 changes: 3 additions & 1 deletion src/lib/utils/console.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,11 @@ import { derived, writable } from 'svelte/store';
import { browser } from '$app/environment';
import { Account, Client, Teams } from '@appwrite.io/console';
import { Query, type Models } from '@appwrite.io/console';
import { PUBLIC_APPWRITE_ENDPOINT } from '$env/static/public';

const client = new Client();

client.setEndpoint('https://cloud.appwrite.io/v1').setProject('console');
client.setEndpoint(PUBLIC_APPWRITE_ENDPOINT).setProject('console');

const account = new Account(client);
const teams = new Teams(client);
Expand All @@ -22,6 +23,7 @@ export async function createSource(
utmSource: string | null,
utmCampaign: string | null,
utmMedium: string | null
// eslint-disable-next-line @typescript-eslint/no-explicit-any
): Promise<any> {
const path = `/console/sources`;
const params = {
Expand Down
12 changes: 12 additions & 0 deletions src/lib/utils/date.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,15 @@ export const formatDate = (date: string | Date | number): string => {
const year = dt.getFullYear();
return `${month} ${day}, ${year}`;
};

export const addDays = (date: Date, days: number) => {
return new Date(date.getTime() + days * 24 * 60 * 60 * 1000);
};

export const toReleaseDate = (date: Date) => {
return date.toLocaleDateString('en-US', {
weekday: 'long',
month: 'short',
day: 'numeric'
});
};
6 changes: 6 additions & 0 deletions src/lib/utils/numbers.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
export const numberWithinRange = (number: number, min: number, max: number) =>
Math.min(Math.max(number, min), max);

export const getRandomNumber = (min: number, max: number) => {
return Math.random() * (max - min) + min;
};
3 changes: 2 additions & 1 deletion src/routes/+page.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
import FooterNav from '../lib/components/FooterNav.svelte';
import MainFooter from '../lib/components/MainFooter.svelte';
import DeveloperCard from './DeveloperCard.svelte';
import { PUBLIC_APPWRITE_DASHBOARD } from '$env/static/public';

const title = 'Appwrite - Build like a team of hundreds';
const description = DEFAULT_DESCRIPTION;
Expand Down Expand Up @@ -104,7 +105,7 @@
the frameworks and languages of your choice.
</p>
<a
href="https://cloud.appwrite.io"
href={PUBLIC_APPWRITE_DASHBOARD}
class="web-button is-full-width-mobile u-margin-block-start-32"
>
<span class="text">Get started</span>
Expand Down
File renamed without changes
Loading
Loading