diff --git a/README.md b/README.md index c856c5a..6897196 100644 --- a/README.md +++ b/README.md @@ -16,9 +16,6 @@ you can host anywhere. The canonical repository is hosted on Radicle: `rad://z2gAKC6ESt5ZBV419uVPf2vFtEHCT`. -The backup mirror is -[`https://git.shipoclu.com/moon/plspace.git`](https://git.shipoclu.com/moon/plspace.git). - ## What it looks like | MySpace | plspace | diff --git a/src/App.svelte b/src/App.svelte index 2516112..bd0a843 100644 --- a/src/App.svelte +++ b/src/App.svelte @@ -18,6 +18,7 @@ import Search from '$routes/Search.svelte' import Login from '$routes/Login.svelte' import Settings from '$routes/Settings.svelte' + import About from '$routes/About.svelte' import Compose from '$routes/Compose.svelte' import NotFound from '$routes/NotFound.svelte' import type { TimelineKind } from '$lib/api/endpoints' @@ -50,7 +51,7 @@ const route = $derived(router.current) /** Route names that are usable before a server is chosen. */ - const ALWAYS_AVAILABLE = new Set(['login', 'settings', 'notfound']) + const ALWAYS_AVAILABLE = new Set(['login', 'settings', 'about', 'notfound']) const TIMELINE_KINDS: readonly TimelineKind[] = ['home', 'public', 'local'] @@ -109,6 +110,8 @@ {:else if route.name === 'settings'} + {:else if route.name === 'about'} + {:else} {/if} diff --git a/src/components/chrome/SiteFooter.svelte b/src/components/chrome/SiteFooter.svelte index 141040d..9051cb0 100644 --- a/src/components/chrome/SiteFooter.svelte +++ b/src/components/chrome/SiteFooter.svelte @@ -15,6 +15,7 @@ Browse Search Settings + About plspace {#if domain} About this server {/if} diff --git a/src/lib/router.svelte.ts b/src/lib/router.svelte.ts index 6cdfe61..f6e1bce 100644 --- a/src/lib/router.svelte.ts +++ b/src/lib/router.svelte.ts @@ -25,6 +25,7 @@ const ROUTES: RoutePattern[] = [ { name: 'home', pattern: '/' }, { name: 'login', pattern: '/login' }, { name: 'settings', pattern: '/settings' }, + { name: 'about', pattern: '/about' }, { name: 'browse', pattern: '/browse' }, { name: 'search', pattern: '/search' }, { name: 'mail', pattern: '/mail' }, diff --git a/src/lib/router.test.ts b/src/lib/router.test.ts index 6ad97ed..5639632 100644 --- a/src/lib/router.test.ts +++ b/src/lib/router.test.ts @@ -17,4 +17,11 @@ describe('parseHash', () => { params: { id: 'status/one' }, }) }) + + it('routes the public About page', () => { + expect(parseHash('#/about')).toMatchObject({ + name: 'about', + params: {}, + }) + }) }) diff --git a/src/routes/About.svelte b/src/routes/About.svelte new file mode 100644 index 0000000..cac45d9 --- /dev/null +++ b/src/routes/About.svelte @@ -0,0 +1,34 @@ + + +
+

About plspace

+

It’s always Pleroma™.

+ +
+ +

+ plspace is free software licensed under the + GNU Affero General Public License (AGPL). +

+

+ The source code is in the canonical Radicle repository: + {RADICLE_REPOSITORY}. +

+

+ Made by @zero@posting.solutions. +

+

+ Privacy policy: zero logging and zero tracking. +

+

proudly 100% vibe-coded slop.

+
+
+
diff --git a/src/routes/About.test.ts b/src/routes/About.test.ts new file mode 100644 index 0000000..6b7b52f --- /dev/null +++ b/src/routes/About.test.ts @@ -0,0 +1,23 @@ +import { render } from '@testing-library/svelte' +import { describe, expect, it } from 'vitest' +import About from './About.svelte' + +describe('About', () => { + it('identifies the license, canonical source, author, and provenance', () => { + const view = render(About) + + expect(view.getByRole('heading', { name: 'About plspace', level: 1 })).toBeInTheDocument() + expect(view.getByText(/GNU Affero General Public License/)).toBeInTheDocument() + expect( + view.getByRole('link', { + name: 'rad://z2gAKC6ESt5ZBV419uVPf2vFtEHCT', + }), + ).toHaveAttribute('href', 'rad://z2gAKC6ESt5ZBV419uVPf2vFtEHCT') + expect(view.getByRole('link', { name: '@zero@posting.solutions' })).toHaveAttribute( + 'href', + '#/@zero@posting.solutions', + ) + expect(view.getByText(/zero logging and zero tracking/i)).toBeInTheDocument() + expect(view.getByText('proudly 100% vibe-coded slop.')).toBeInTheDocument() + }) +}) diff --git a/src/routes/Login.svelte b/src/routes/Login.svelte index 3fd60b8..36f9c17 100644 --- a/src/routes/Login.svelte +++ b/src/routes/Login.svelte @@ -25,7 +25,7 @@ * anonymous timeline reads; suggesting one of those hands a first-time * visitor an empty page. Re-check before adding to this list. */ - const SUGGESTIONS = ['pleroma.soykaf.com', 'lain.com', 'spinster.xyz'] + const SUGGESTIONS = ['pleroma.soykaf.com', 'lain.com', 'fosstodon.org'] async function signIn(event: SubmitEvent): Promise { event.preventDefault()