feat: Add branding, port more text from old site

This commit is contained in:
Jesse Wierzbinski 2024-07-22 13:12:55 +02:00
parent 02695bc22c
commit 5ab772df21
No known key found for this signature in database
9 changed files with 37 additions and 26 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 15 KiB

View file

@ -10,8 +10,8 @@ import type { ReactNode } from "react";
export const metadata: Metadata = {
title: {
template: "%s - Protocol API Reference",
default: "Protocol API Reference",
template: "%s - Lysand API Reference",
default: "Lysand API Reference",
},
};
@ -31,6 +31,9 @@ export default async function RootLayout({
return (
<html lang="en" className="h-full" suppressHydrationWarning={true}>
<head>
<link rel="icon" href="/favicon.png" type="image/png" />
</head>
<body className="flex min-h-full bg-white antialiased dark:bg-zinc-900">
<Providers>
<div className="w-full">

View file

@ -3,40 +3,44 @@ import { Resources } from '@/components/Resources'
import { HeroPattern } from '@/components/HeroPattern'
export const metadata = {
title: 'API Documentation',
title: 'Lysand Documentation',
description:
'Learn everything there is to know about the Protocol API and integrate Protocol into your product.',
'Introduction to the Lysand Protocol, a communication medium for federated applications, leveraging the HTTP stack.',
}
export const sections = [
{ title: 'Vocabulary', id: 'vocabulary' },
{ title: 'Guides', id: 'guides' },
{ title: 'Resources', id: 'resources' },
]
<HeroPattern />
# API Documentation
# Lysand Federation Protocol
Use the Protocol API to access contacts, conversations, group messages, and more and seamlessly integrate your product into the workflows of dozens of devoted Protocol users. {{ className: 'lead' }}
The Lysand Protocol is designed as a communication medium for federated applications, leveraging the HTTP stack. Its simplicity ensures ease of implementation and comprehension. {{ className: 'lead' }}
<div className="not-prose mb-16 mt-6 flex gap-3">
<Button href="/quickstart" arrow="right">
<>Quickstart</>
<>Introduction</>
</Button>
<Button href="/sdks" variant="outline">
<>Explore SDKs</>
</Button>
</div>
## Getting started {{ anchor: false }}
## Vocabulary
To get started, create a new application in your [developer settings](#), then read about how to make requests for the resources you need to access using our HTTP APIs or dedicated client SDKs. When your integration is ready to go live, publish it to our [integrations directory](#) to reach the Protocol community. {{ className: 'lead' }}
<Note>
The words **MUST**, **MUST NOT**, **SHOULD**, **SHOULD NOT**, and **MAY** are used in this document as defined in [RFC 2119](https://tools.ietf.org/html/rfc2119).
</Note>
<div className="not-prose">
<Button href="/sdks" variant="text" arrow="right">
<>Get your API key</>
</Button>
</div>
The Lysand Protocol uses the following terms:
- **Entity**: A generic term for any JSON object in the protocol, such as an [Actor](./objects/actors), a [Note](./objects/notes), or a [Like](./objects/likes). Entities are uniquely identified by their `id` property.
- **Implementation**: A software application that implements the Lysand Protocol.
- **Instance**: An application deploying an **Implementation**.
- Using the same nomenclature, an ActivityPub Implementation would be `Mastodon`, and an Instance would be `mastodon.social`.
- **Federation**: The process of exchanging data between two or more **Instances**.
<Guides />

View file

@ -1,16 +1,20 @@
import logo from "@/images/branding/logo.webp";
import clsx from "clsx";
import type { ComponentPropsWithoutRef } from "react";
export function Logo(props: ComponentPropsWithoutRef<"svg">) {
export function Logo(props: ComponentPropsWithoutRef<"div">) {
return (
<svg viewBox="0 0 99 24" aria-hidden="true" {...props}>
<path
className="fill-brand-400"
d="M16 8a5 5 0 0 0-5-5H5a5 5 0 0 0-5 5v13.927a1 1 0 0 0 1.623.782l3.684-2.93a4 4 0 0 1 2.49-.87H11a5 5 0 0 0 5-5V8Z"
/>
<path
className="fill-zinc-900 dark:fill-white"
d="M26.538 18h2.654v-3.999h2.576c2.672 0 4.456-1.723 4.456-4.333V9.65c0-2.61-1.784-4.333-4.456-4.333h-5.23V18Zm4.58-10.582c1.52 0 2.416.8 2.416 2.241v.018c0 1.441-.896 2.25-2.417 2.25h-1.925V7.418h1.925ZM38.051 18h2.566v-5.414c0-1.371.923-2.206 2.382-2.206.396 0 .791.061 1.178.15V8.287a3.843 3.843 0 0 0-.958-.123c-1.257 0-2.136.615-2.443 1.661h-.159V8.323h-2.566V18Zm11.55.202c2.979 0 4.772-1.88 4.772-5.036v-.018c0-3.128-1.82-5.036-4.773-5.036-2.953 0-4.772 1.916-4.772 5.036v.018c0 3.146 1.793 5.036 4.772 5.036Zm0-2.013c-1.372 0-2.145-1.116-2.145-3.023v-.018c0-1.89.782-3.023 2.144-3.023 1.354 0 2.145 1.134 2.145 3.023v.018c0 1.907-.782 3.023-2.145 3.023Zm10.52 1.846c.492 0 .967-.053 1.283-.114v-1.907a6.057 6.057 0 0 1-.755.044c-.87 0-1.24-.387-1.24-1.257v-4.544h1.995V8.323H59.41V6.012h-2.592v2.311h-1.495v1.934h1.495v5.133c0 1.88.949 2.645 3.304 2.645Zm7.287.167c2.98 0 4.772-1.88 4.772-5.036v-.018c0-3.128-1.82-5.036-4.772-5.036-2.954 0-4.773 1.916-4.773 5.036v.018c0 3.146 1.793 5.036 4.773 5.036Zm0-2.013c-1.372 0-2.145-1.116-2.145-3.023v-.018c0-1.89.782-3.023 2.145-3.023 1.353 0 2.144 1.134 2.144 3.023v.018c0 1.907-.782 3.023-2.144 3.023Zm10.767 2.013c2.522 0 4.034-1.353 4.297-3.463l.01-.053h-2.374l-.017.036c-.229.966-.853 1.467-1.908 1.467-1.37 0-2.135-1.08-2.135-3.04v-.018c0-1.934.755-3.006 2.135-3.006 1.099 0 1.74.615 1.908 1.556l.008.017h2.391v-.026c-.228-2.162-1.749-3.56-4.315-3.56-3.033 0-4.738 1.837-4.738 5.019v.017c0 3.217 1.714 5.054 4.738 5.054Zm10.257 0c2.98 0 4.772-1.88 4.772-5.036v-.018c0-3.128-1.82-5.036-4.772-5.036-2.953 0-4.773 1.916-4.773 5.036v.018c0 3.146 1.793 5.036 4.773 5.036Zm0-2.013c-1.371 0-2.145-1.116-2.145-3.023v-.018c0-1.89.782-3.023 2.145-3.023 1.353 0 2.144 1.134 2.144 3.023v.018c0 1.907-.782 3.023-2.144 3.023ZM95.025 18h2.566V4.623h-2.566V18Z"
/>
</svg>
<div
{...props}
className={clsx(
"flex flex-row gap-x-2 items-center",
props.className,
)}
>
<img src={logo.src} alt="Logo" className="h-full rounded-sm" />
<span className="fill-zinc-900 dark:fill-white font-semibold text-lg">
Lysand Protocol
</span>
</div>
);
}

View file

@ -170,7 +170,7 @@ function NavigationGroup({
<li className={clsx("relative mt-6", className)}>
<motion.h2
layout="position"
className="text-xs font-semibold text-zinc-900 dark:text-white"
className="text-sm font-semibold text-zinc-900 dark:text-white"
>
{group.title}
</motion.h2>

Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB

BIN
images/branding/logo.webp Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.3 KiB

BIN
public/favicon.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.5 KiB