Compare commits

..

7 commits

3 changed files with 30 additions and 13 deletions

View file

@ -16,7 +16,7 @@ Everything that ties Orbit to a particular network or brand lives in
"url": "https://example.org", "url": "https://example.org",
"tagline": "Chat with", "tagline": "Chat with",
"taglineEm": "everyone.", "taglineEm": "everyone.",
"subtitle": "Public rooms, private messages, no signup required." "subtitle": "Public rooms, private messages, and moderation that works."
} }
} }
``` ```

View file

@ -3,16 +3,18 @@ Order: 10
# Overview # Overview
**Orbit** is a modern web client for **IRC** — the open chat protocol that has quietly run **Orbit** is a modern web client for **IRC**, the open chat protocol that has quietly run
communities for decades. It runs entirely in the browser: pick a nick and you're talking, with communities for decades. It runs entirely in the browser, with nothing to install, and handles
**no install and no signup**. everything from a quick guest nick to a full account (SASL login and in-app registration).
Whether a deployment lets people in as guests or asks them to register is its own choice, not
the client's.
It powers [tchatou.fr](https://tchatou.fr/app/), and is built to be **re-pointed at any IRCv3 It powers [tchatou.fr](https://tchatou.fr/app/), and is built to be **re-pointed at any IRCv3
network** and **rebranded** from a single `config.json` without recompiling. network** and **rebranded** from a single `config.json`, without recompiling.
## What makes it different ## What makes it different
- **Full IRCv3.** Orbit negotiates 24 capabilities — SASL, message-tags, reactions, typing - **Full IRCv3.** Orbit negotiates 25 capabilities: SASL, message-tags, reactions, typing
indicators, read-markers, multi-line messages, server-side history, account registration, and indicators, read-markers, multi-line messages, server-side history, account registration, and
Web Push. See [IRCv3 capabilities](https://orbit.tchatou.fr/docs/ircv3/). Web Push. See [IRCv3 capabilities](https://orbit.tchatou.fr/docs/ircv3/).
- **Pluggable at runtime.** A static `config.json` is fetched on startup and sets the server, - **Pluggable at runtime.** A static `config.json` is fetched on startup and sets the server,
@ -25,11 +27,11 @@ network** and **rebranded** from a single `config.json` — without recompiling.
Brazilian + European Portuguese). Pin a default with `defaults.lang`. Brazilian + European Portuguese). Pin a default with `defaults.lang`.
- **Self-hostable.** A static build behind any web server. The project even runs its own git - **Self-hostable.** A static build behind any web server. The project even runs its own git
server with [push-to-deploy](https://orbit.tchatou.fr/docs/push-to-deploy/). server with [push-to-deploy](https://orbit.tchatou.fr/docs/push-to-deploy/).
- **Free software.** AGPL-3.0 use it, modify it, self-host it. - **Free software.** AGPL-3.0: use it, modify it, self-host it.
## Tech ## Tech
React 19 · TypeScript · Vite · zustand. Tested with Vitest, linted, and built in CI. The codebase React 19, TypeScript, Vite and zustand. Tested with Vitest, linted, and built in CI. The codebase
is a clean modular tree see [Architecture](https://orbit.tchatou.fr/docs/architecture/). is a clean modular tree; see [Architecture](https://orbit.tchatou.fr/docs/architecture/).
> New here? Jump to the [Quick start](https://orbit.tchatou.fr/docs/quick-start/) to run your own in a minute. > New here? Jump to the [Quick start](https://orbit.tchatou.fr/docs/quick-start/) to run your own.

View file

@ -21,7 +21,14 @@ Add script URLs to `plugins` in [`config.json`](https://orbit.tchatou.fr/docs/co
``` ```
They load in order, after the app boots. Host them anywhere the page can reach They load in order, after the app boots. Host them anywhere the page can reach
(same-origin recommended). (same-origin recommended). For a third-party origin, pin the file with
Subresource Integrity by giving an object instead of a URL:
```json
{ "plugins": [{ "url": "https://cdn.example/x.js", "integrity": "sha384-…" }] }
```
(`crossorigin` defaults to `anonymous` when an `integrity` hash is set.)
## A quick plugin ## A quick plugin
@ -79,6 +86,8 @@ instead. See **[Compiled plugins](https://orbit.tchatou.fr/docs/compiled-plugins
| `orbit.i18n.pick(table)` | pick a string from a `{ lang: text }` table by the current language | | `orbit.i18n.pick(table)` | pick a string from a `{ lang: text }` table by the current language |
| `orbit.addUi(slot, render)` | add UI to a slot (returns a remover) | | `orbit.addUi(slot, render)` | add UI to a slot (returns a remover) |
| `orbit.addSettingsSection({label, icon?, render})` | add a whole Settings section | | `orbit.addSettingsSection({label, icon?, render})` | add a whole Settings section |
| `orbit.addMessageDecorator(m => …)` | inline UI after every message's text; `m` = `{id, nick, text, raw, kind, ts, mine}` (`text` is formatting-stripped, `raw` keeps mIRC codes) |
| `orbit.addMessageAction(m => …)` | a button in every message's hover action toolbar (next to reply/react); same `m` |
| `orbit.h / orbit.html` | render helpers | | `orbit.h / orbit.html` | render helpers |
| `log(…)` | namespaced console logger | | `log(…)` | namespaced console logger |
@ -93,10 +102,16 @@ instead. See **[Compiled plugins](https://orbit.tchatou.fr/docs/compiled-plugins
| Slot | Where | | Slot | Where |
|---|---| |---|---|
| `composer_button` | a button in the message composer toolbar | | `composer_button` | a button in the message composer toolbar |
| `topbar_item` | an item in the channel topbar action row (next to search / notifications) |
| `sidebar_item` | an item in the conversation sidebar header (next to the compose button) |
| `settings_section` | a whole section in Settings (own nav entry + pane) — use `orbit.addSettingsSection()` | | `settings_section` | a whole section in Settings (own nav entry + pane) — use `orbit.addSettingsSection()` |
More slots (message decorators, side panels) will be added as the core grows Two per-message hooks run for every rendered message:
stable homes for them. `orbit.addMessageDecorator(m => …)` appends inline UI after the text, and
`orbit.addMessageAction(m => …)` adds a button to the hover action toolbar next
to reply/react. Every contributed slot, action and decorator renders inside its
own error boundary, so a crashing plugin renders nothing instead of taking down
the app.
### Localization (i18n) ### Localization (i18n)