kirakira/README.md

46 lines
3.5 KiB
Markdown
Raw Permalink Normal View History

2026-09-29 21:35:02 +03:00
# キラキラ kirakira
2024-02-17 20:32:01 +05:30
[![AI-DECLARATION: copilot](https://img.shields.io/badge/䷼%20AI--DECLARATION-copilot-fee2e2?labelColor=fee2e2)](https://ai-declaration.md)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT) ![Powered by Mistral](https://img.shields.io/badge/Powered_by-Mistral_AI-FA520F?logo=mistral-ai&logoColor=white) ![Flutter](https://img.shields.io/badge/Flutter-02569B?logo=flutter&logoColor=white) [![Forked from flash-mail](https://img.shields.io/badge/Forked_from-sarthakkimtani%2Fflash--mail-59636e?logo=github&logoColor=white)](https://github.com/sarthakkimtani/flash-mail)
2026-09-29 21:35:02 +03:00
A mobile and desktop client for [smolmail](https://smol.place), a minimalist end-to-end encrypted mail protocol: one Ed25519 identity, five operations, sealed and signed messages over a Noise_NX transport.
2024-02-17 20:32:01 +05:30
2026-09-29 21:35:02 +03:00
kirakira began as [FlashMail](https://github.com/sarthakkimtani/flash-mail), a Flutter UI template for a disposable-email app built on mail.tm. Its protocol core is now [fumi-core](https://code.randogoth.com/randogoth/fumi), the Rust library the reference CLI is built on: `native/` wraps it into a C ABI and ships it in the APK as `libsmol_mail_native.so` (SQLite bundled), `lib/native/` speaks that ABI over dart:ffi, and `lib/smol/` is the thin facade the UI reads. The UI is Material 3 — dark navy and mint green by default, with a matching light theme — built from a single `ColorScheme` and `AppColors` extension rather than hardcoded colors per screen.
2024-02-17 20:32:01 +05:30
## What it does
2024-02-17 20:32:01 +05:30
- Create or restore an identity from a 32-byte seed — that's the only secret.
- Pin a server's key, register or recall an address, then fetch and send sealed mail.
- Trust-on-first-use for server and contact keys, with rotation support and on-screen warnings for anything unverified.
- Export/import inbox, sent mail, contacts and server pins as one shareable backup file — never the seed.
- Share your address as a `smol://` QR code, and react to any `smol://` link a scanner or browser hands the device: its key lands in the confirm-first import dialog.
2024-02-17 20:32:01 +05:30
2026-09-29 21:35:02 +03:00
Mail, contacts and pinned server keys live in fumi-core's SQLite store, bundled into the native library; the seed, read marks and settings stay app-side in Hive.
## Layout
2024-02-17 20:32:01 +05:30
```
2026-09-29 21:35:02 +03:00
lib/native/ dart:ffi binding: handles, error codes, isolate plumbing
lib/smol/ thin facades over the binding: address, store, client
lib/presentation/ screens, widgets and theme (Riverpod + auto_route)
lib/data/ Riverpod providers
2026-09-29 21:35:02 +03:00
native/ Rust wrapper crate: the C ABI over fumi-core, pinned by rev
integration_test/ Patrol device tests against a live server
test/ store, recall, binding, interop and e2e tests
```
2024-02-17 20:32:01 +05:30
## Run and verify
2024-02-17 20:32:01 +05:30
```
2026-09-29 21:35:02 +03:00
devbox run build-native-android # the .so the APK loads — once per Rust change
devbox run analyze
devbox run test
2026-09-29 21:35:02 +03:00
flutter run --flavor prod
```
2024-02-17 20:32:01 +05:30
`test/e2e_test.dart` runs a live round-trip against the local bunshin on `127.0.0.1:1961` and skips itself when nothing's listening there. On-device flows are covered by the Patrol suite — `devbox run test-integration` builds the `integration` flavor (installed beside the real app, its data cleared between tests) and drives onboarding, registration, fetch cancellation, rotation and the unchanged-key refresh against the same server. To exercise the smol:// deep link by hand, scan `test-qr.png` — it encodes the `kirakira@localhost` identity — with any device camera and confirm the import dialog.
2024-02-17 20:32:01 +05:30
## License
MIT — see LICENSE.md.