8000 GitHub - freezer71/omne: Privacy-first toolbox. Everything runs in your browser. No file is ever uploaded. Β· GitHub
[go: up one dir, main page]

Skip to content
freezer71Public

About

Privacy-first toolbox. Everything runs in your browser. No file is ever uploaded.

Resources

Stars

4 stars

Watchers

0 watching

Forks

Latest commit

Β 

History

143 Commits

Folders and files

Repository files navigation

omne logo

omne

Privacy-first toolbox. Everything runs in your browser. No file is ever uploaded.

πŸ‡«πŸ‡· Lire en franΓ§ais


omne is a collection of 90 online tools β€” PDF, video, audio, image, SVG, passwords, JSON, XML, text, encoding, QR codes, colors, developer utilities β€” that run entirely client-side. No analytics, no third-party CDN, no cookies, no server-side file processing β€” your files never leave the tab. The two narrow, documented exceptions (a skills.sh search proxy and a one-time AI model download) are covered in the privacy-first promise and on the in-app privacy page.

Bilingual English / French, light / dark mode, ⌘K / Ctrl+K command palette (also reachable from the header search button on phones).


Values

These are not feature ideas β€” they are constraints. Everything in the codebase has to honor them.

  • πŸ›‘οΈ Privacy by design. Files never leave the device. Processing happens in the browser, in WebAssembly when needed. There is no "trust us, we'll delete it later" β€” there is no server to delete from.
  • πŸ” Verifiable, not promised. Open the DevTools Network tab during a conversion: you should see zero outbound requests. The only two sanctioned exceptions β€” the Skills browser's search proxy and the one-time background-removal model download β€” are documented below and on the in-app privacy page; anything else is a bug, not a feature.
  • 🚫 No tracking, ever. No analytics, no telemetry, no cookies, no third-party CDN, no fingerprinting. We don't know who you are and we don't want to know.
  • 🧱 Self-hosted heavy assets. ffmpeg.wasm, pdf.js worker, the QR scanner, the OCR engine (tesseract.js + its language data) and the ONNX runtime (onnxruntime-web) are all served from this origin so processing doesn't leak metadata to a CDN. The one documented exception: the RMBG-1.4 background-removal model weights (~44 MB) are fetched once from Hugging Face on first use, then cached by the browser β€” your image itself never leaves the device (see the in-app privacy page).
  • πŸ†“ No friction. No signup, no account, no paywall, no rate limit, no "premium tier". Open the page, do the thing, close the tab.
  • 🌍 Open source, built in the open. Every line is auditable on github.com/freezer71/omne β€” also linked from the site header and footer. If you can't verify a claim by reading the code, the claim doesn't count.
  • πŸŒ— Accessible and bilingual. Light & dark themes with pre-paint anti-flash, English & French at full parity (enforced by CI), and an ⌘K palette for keyboard users.

The privacy-first promise

This is the reason the project exists, not a marketing line:

  • Every conversion runs in the browser via Web APIs, WebAssembly and Web Workers.
  • @ffmpeg/ffmpeg (video, audio), pdfjs-dist (PDF) and tesseract.js (OCR, with its English + French models) are self-hosted under /public/ffmpeg/, /public/pdfjs/ and /public/ocr/ β€” the DevTools Network tab must show zero outbound traffic during processing, OCR included.
  • The app serves Cross-Origin-Opener-Policy: same-origin and Cross-Origin-Embedder-Policy: require-corp to enable SharedArrayBuffer (required by the multi-thread ffmpeg build). Because every asset is same-origin, this hardens the page instead of breaking anything.
  • No external services: no Sentry, no Google Analytics, no tracking pixel, no asset CDN.
  • Two documented exceptions, both opt-in and file-free: the Skills browser (/dev/skills-browse) is the only tool that makes network requests at runtime β€” it relays your search to skills.sh through two same-origin proxy routes (app/api/skills-search, app/api/skills-feed); and the background remover fetches its RMBG-1.4 model (~44 MB) once from Hugging Face, then your browser caches it. Both are flagged network in lib/tools/registry.ts, disclosed in their own UI and footer, and detailed on the in-app privacy page.

Any contribution that would break that promise (server-side file processing, telemetry, undocumented remote loads) is out of scope. A new network-touching feature is only acceptable with the same treatment as the exceptions above: a network flag in the registry, in-UI disclosure, and privacy-page documentation.


Getting started

Requirements: Node.js 20+.

npm install   # runs the postinstall that copies ffmpeg + pdf.js + qr-scanner + fonts + OCR + ONNX runtime into /public
npm run dev   # http://localhost:3000

⚠️ npm run dev deliberately uses Webpack (next dev --webpack). Turbopack panics on HMR through [locale] dynamic routes. npm run dev:turbo exists for spot checks only.

After a clean clone, if ffmpeg/pdf.js/OCR/background-removal features fail, re-run:

node scripts/copy-ffmpeg.mjs && node scripts/copy-pdfjs.mjs && node scripts/copy-qr-scanner.mjs && node scripts/copy-fonts.mjs && node scripts/copy-ocr.mjs && node scripts/copy-ort.mjs

Tool catalog

Category Tools
PDF Merge Β· Split Β· Rotate Β· Resize Β· Watermark Β· Sign Β· PDF β†’ images Β· Extract images Β· Images β†’ PDF
Video Convert (MP4 / WebM / GIF) Β· Trim Β· Split Β· Merge Β· Compress Β· Resize Β· Mute Β· Crop Β· Rotate / flip Β· Extract frames Β· Watermark Β· Speed Β· Short Studio (split + numbered watermark, optional 9:16)
Audio Convert Β· Extract (from video) Β· Trim Β· Merge Β· Volume / normalize / fades Β· ID3 tags
Image Convert Β· Compress Β· Resize Β· Crop Β· Rotate / flip Β· Remove background (local AI, beta) Β· Paste from clipboard Β· Banner maker (color background + text & image layers, size presets)
SVG Viewer Β· Editor Β· Optimize (SVGO) Β· β†’ PNG / JPG / WebP Β· β†’ Data URL Β· Favicon generator
Password Generate Β· Passphrase (Diceware) Β· Hash (SHA) Β· bcrypt Β· Strength meter
JSON Format Β· Tree Β· JSONPath Β· Table Β· CSV ↔ JSON Β· Diff Β· Schema (draft-07 / 2020-12)
XML Beautify Β· Minify Β· Validate (line/column errors) Β· XML ↔ JSON
Text Case Β· Counter Β· Lorem Ipsum Β· Diff Β· Regex tester Β· Slugify Β· Sort lines Β· Escape/Unescape Β· Whitespace cleaner Β· Markdown preview Β· Find & Replace
Reading & accessibility Guided reading (bold-start / "bionic") Β· Text to dyslexia font (OpenDyslexic + spacing + colour overlay β†’ HTML/PDF, reflows text incl. PDFs) Β· PDF to dyslexia font (keeps images & layout, swaps the font in place β€” same font & colour-overlay palette as the text tool) Β· Read aloud (on-device text-to-speech) Β· Immersive reading (sentence focus ruler) β€” both dyslexia tools offer a fullscreen reading mode right in the browser (continuous page scrolling for PDFs, auto-hiding controls, Aβˆ’/A+ text sizing), and the text tools auto-detect corrupted PDF text layers (broken ligatures from Pages/Quartz exports) and scanned PDFs, and recover the text with on-device OCR (English + French)
Encoding Base64 Β· URL Β· JWT Β· Hex Β· HTML entities Β· Binary Β· Morse code
QR Generate (WiFi, vCard…) Β· Scan (camera or image) Β· Barcode generate (Code 128 / EAN) Β· Barcode scan
Color Converter (hex / rgb / hsl / oklch) Β· WCAG contrast Β· Palette from image Β· Gradient builder Β· Tints & shades Β· Blender Β· Color-blindness simulator
Developer Build a skills installer (parse npx skills add commands) Β· Browse & install skills (search the skills.sh catalog, discover top skills by All Time / Trending 24h / Hot, and install multiple in one one-liner) β€” both emit Bash, PowerShell or CMD output and download a ready-to-run .sh / .ps1 / .cmd script

Source of truth: lib/tools/registry.ts. The sitemap, the home page cards and MIME-based drop routing all derive from it.


Tech stack

  • Next.js 16 (App Router) + React 19
  • TypeScript (strict)
  • Tailwind v4 β€” CSS-first config (no tailwind.config.js), tokens in @theme inline inside app/globals.css
  • @ffmpeg/ffmpeg for video and audio β€” multi-thread build (@ffmpeg/core-mt) to parallelize across CPU cores
  • pdf-lib + @pdf-lib/fontkit + pdfjs-dist for PDFs (fontkit embeds the self-hosted OpenDyslexic font into generated reading PDFs)
  • tesseract.js for on-device OCR β€” recovers text from corrupted PDF text layers and scanned PDFs in the reading tools (wasm core + English/French models self-hosted under /public/ocr/)
  • @huggingface/transformers for image background removal (local ONNX model)
  • SVGO for SVG optimization
  • @cfworker/json-schema for JSON Schema validation β€” it interprets schemas instead of compiling them to JavaScript, so it runs under the production CSP, which has no unsafe-eval (Ajv did not)
  • fast-xml-parser for XML validation, formatting and XML↔JSON conversion
  • loading-dev for the "Bouncing dots" loader shown during every processing run (bundled, no network request)
  • In-house i18n β€” no runtime, static dictionaries at messages/{en,fr}.json
  • Vitest (unit + components + setup) + Playwright (e2e on chromium + webkit)

Architecture

Routing (Next 16 specifics)

  • proxy.ts at the project root replaces the old middleware.ts convention. It sniffs Accept-Language and 307-redirects bare paths into /[locale]/....
  • All routes live under app/[locale]/.... There is no app/layout.tsx β€” the only root layout is app/[locale]/layout.tsx.
  • params is a Promise in every page, layout and generateMetadata: const { locale } = await params; is mandatory.
  • Per-locale category landing pages live at app/[locale]/[category]/page.tsx (/en/pdf, /fr/image, …). They're prerendered for every populated category, with their own metadata, OpenGraph image, breadcrumb and CollectionPage JSON-LD.
  • A localized 404 at app/[locale]/not-found.tsx catches unmatched paths under /[locale]/..., picks language via Accept-Language, and suggests popular tools. The PWA manifest (app/manifest.ts) and theme-color viewport are emitted automatically.

Anatomy of a tool

Each tool follows the same 5-file skeleton plus one registry entry:

  1. Pure logic β€” lib/tools/implementations/<id>.ts (testable in Node, no React)
  2. Client component β€” components/tools/<id>-tool.tsx ('use client')
  3. Page β€” app/[locale]/<category>/<id>/page.tsx (Server Component)
  4. OpenGraph image β€” app/[locale]/<category>/<id>/opengraph-image.tsx
  5. Registry entry β€” lib/tools/registry.ts
  6. Translations β€” tools.<category>.<id> keys in both messages/{en,fr}.json (seo block included, parity checked in CI). An optional content block (howItWorks + features arrays) provides tool-specific copy for the SEO footer. A new category also needs a categories.<category> block (name, intro, seo) for its landing page.

Real-time preview is mandatory: every tool must render a live result that reflects the current parameters β€” drive it from a ~150–250 ms debounced effect, no "Apply" button before the preview shows. For heavy pipelines (ffmpeg, pdf.js, remove-bg), render a lightweight proxy (lower resolution, first page/frame).

Every wait shows motion: a processing button takes loading={busy} (components/ui/button.tsx), which prepends the Bouncing dots loader (components/ui/loader.tsx). Pipelines that report progress (ffmpeg) also render <Progress> (components/ui/progress.tsx) under the action row: indeterminate while nothing has been reported yet (core download, file copy), then the percentage with the time-remaining estimate as hint. Never put the percentage back in the button label: ffmpeg reports in ~10 % steps, and a number frozen between steps reads as a hang.

Every preview opens in a large viewer: clicking a preview (PDF page thumbnails, image outputs) opens MediaViewer (comp 9AA9 onents/ui/media-viewer.tsx) β€” a fullscreen dialog with zoom controls (+/βˆ’/reset, up to 500%), page navigation for PDFs, Escape/backdrop close and a focus trap. Viewer strings come from common.viewer in both dictionaries and reach every preview through ViewerMessagesProvider mounted once in app/[locale]/layout.tsx (read with useViewerMessages()); a preview outside that provider simply stays non-interactive. PDF rendering goes through the shared getPdfDocument cache, never a second parse.

Nothing downloads behind the user's back: a tool that runs an expensive pipeline hands its output to <ToolResult> (components/ui/tool-result.tsx) instead of calling downloadBlob itself. The panel plays or displays the produced file, states the size change against the source, and carries the only Download button, plus a Change settings button that clears it while keeping the source file loaded. Hold the output with useToolResult(signature) (lib/hooks/use-tool-result.ts): build signature from the source file identity plus every option that feeds the pipeline, and the hook drops the result the moment they diverge, so the panel can never show a file the controls no longer describe. The strings are shared across tools under common.result β€” pass them down as result={dict.common.result}.

Show the queue, not the file names: merge tools measure every queued clip with useClipMetadata and summarise it with lib/tools/clip-summary.ts β€” thumbnail, duration and dimensions per row, a running total, and a warning when the clips are not all the same size. Ordering clips by file name is exactly where users get it wrong, and without this the mistake only surfaced after the encode.

Focus must land on something visible: option chips wrap an sr-only radio in a styled <label>, and file pickers put an sr-only input beside a styled button. sr-only clips the control to 1Γ—1px, so the base focus ring was painted where nobody could see it. Two selectors in app/globals.css move it onto the visible proxy β€” keep the hidden control a direct child of its label, or the immediate previous sibling of its button. Once a file is loaded, most tools follow the input with a preview instead of the button; a third selector then rings the input's container.

Don't promise a number you cannot compute: video/compress encodes H.264 at a constant quality (libx264 -crf, falling back to mpeg4 -q:v if x264 fails), so its output size cannot be derived from duration Γ— bitrate. estimateCompressedSize answers it by encoding the first few seconds at the chosen preset and scaling up β€” the lightweight-proxy rule applied to a figure rather than a picture. It is an approximation by construction, is labelled as one, and fails silently rather than showing something wrong.

A failed run is never a result: ffmpeg.wasm reports failure through the exit code, not by rejecting. runFfmpegCommand (lib/ffmpeg-loader.ts) throws on any non-zero code, with the tail of ffmpeg's log attached β€” before that, video/watermark showed "your file is ready" over a 0-byte file. A re-encode must not inflate the file either: audio tools cap their bitrate at the source's (lib/tools/audio-bitrate.ts) and trim by stream copy, video resize never defaults above the source size, image resize shows the exact weight of the file it will download before you click, and when an output still ends up heavier, <ToolResult> says why and suggests keeping the original. Every run is also capped to a few threads (withThreadCaps): the multithreaded core has a fixed pool of 32 workers, and ffmpeg's per-core defaults exhausted it and froze H.264 encodes. Re-encoding video tools output H.264 (lib/tools/h264.ts), which every browser plays β€” Chrome cannot decode the MPEG-4 Part 2 they used to produce.

Say why it failed, when you can tell: media tools route their failures through mediaErrorMessage (lib/media-errors.ts), which separates a lost cross-origin isolation (reload; the file is fine) and heap exhaustion (shorter clip, lighter preset) from everything else, and falls back to the tool's own wording rather than guessing.

Every long run is escapable: an ffmpeg tool calls useFfmpegCancel(busy) (lib/hooks/use-ffmpeg-cancel.ts), which renders a Cancel button beside the busy primary button, warns before the tab is closed mid-encode, and calls terminateFfmpeg() (lib/ffmpeg-loader.ts) to abort the worker. Terminating leaves the FFmpeg object dead, so the loader drops its cached instance and the next run loads a fresh core. Call beginRun() at the top of the handler and gate the failure report on wasCancelled() β€” a cancel rejects the pending exec too, and reporting it would tell the user their file is broken when it is not.

Full details in CLAUDE.md.


Commands

Command Description
npm run dev Dev server on :3000 (Webpack β€” see warning above)
npm run build Production build
npm run start Serve the production build
npm run lint ESLint (flat config)
npm test Vitest (unit + components + setup) one-shot
npm run test:watch Vitest in watch mode
npm run test:ui Vitest UI
npm run test:e2e Playwright (chromium + webkit)
npm run test:all Vitest then Playwright
npm run favicons Regenerate app/favicon.ico (16/32/48) + app/apple-icon.png (180Γ—180) from app/icon.svg
npm run lastmod Regenerate lib/seo/lastmod.json (per-page sitemap <lastmod> dates from git history) β€” run after content changes and commit the result

Run a single test:

npx vitest run path/to/file.test.ts -t "test name"
npx playwright test tests/e2e/<name>.spec.ts --project=chromium

Repository layout

omne/
β”œβ”€β”€ app/
β”‚   β”œβ”€β”€ [locale]/         # Pages (Server Components) per category/tool + not-found.tsx
β”‚   └── manifest.ts       # PWA Web App Manifest (icons, theme, start_url)
β”œβ”€β”€ components/tools/     # Client components for each tool
β”œβ”€β”€ lib/
β”‚   β”œβ”€β”€ tools/
β”‚   β”‚   β”œβ”€β”€ implementations/  # Pure logic (testable outside the DOM)
β”‚   β”‚   β”œβ”€β”€ registry.ts       # Source of truth for the catalog
β”‚   β”‚   └── mime-router.ts    # MIME-based routing on drop
β”‚   β”œβ”€β”€ seo/                  # metadata, JSON-LD (WebApplication, CollectionPage, BreadcrumbList, FAQPage)
β”‚   └── og/                   # OG image template + builder (hub / privacy / tool / category)
β”‚   β”œβ”€β”€ i18n/             # Server-side dictionaries (server-only)
β”‚   β”œβ”€β”€ ffmpeg-loader.ts  # Singleton ffmpeg.wasm
β”‚   β”œβ”€β”€ ocr-loader.ts     # Singleton tesseract.js worker (self-hosted assets)
β”‚   └── file-utils.ts     # downloadBlob, outputName, etc.
β”œβ”€β”€ messages/{en,fr}.json # Translations (parity enforced in CI)
β”œβ”€β”€ public/
β”‚   β”œβ”€β”€ ffmpeg/           # ffmpeg-core.js + .wasm (postinstall-copied, gitignored)
β”‚   β”œβ”€β”€ pdfjs/            # pdf.worker.min.mjs (same)
β”‚   β”œβ”€β”€ ocr/              # tesseract worker + wasm cores + eng/fra traineddata (same)
β”‚   β”œβ”€β”€ ort/              # onnxruntime-web wasm runtime for remove-bg (same)
β”‚   β”œβ”€β”€ kouma-tile-*.svg  # Kouma Labs tiles for the co-branded lockup (committed)
β”‚   └── theme-init.js     # Static script to avoid theme flash
β”œβ”€β”€ proxy.ts              # /[locale] redirect (replaces middleware.ts)
β”œβ”€β”€ scripts/              # copy-ffmpeg, copy-pdfjs, copy-qr-scanner, copy-fonts, copy-ocr, copy-ort
└── tests/
    β”œβ”€β”€ unit/             # Vitest (Node env)
    β”œβ”€β”€ components/       # Vitest (jsdom) + RTL
    β”œβ”€β”€ setup/            # Cross-cutting tests (i18n parity…)
    └── e2e/              # Playwright

Contributing a new tool

  1. Implement the pure logic in lib/tools/implementations/<id>.ts with a unit test.
  2. Build the client component in components/tools/<id>-tool.tsx with a real-time preview β€” and, if the pipeline is expensive, a <ToolResult> panel rather than an automatic download.
  3. Wire the page under app/[locale]/<category>/<id>/page.tsx + the opengraph-image.tsx.
  4. Add the entry in lib/tools/registry.ts.
  5. Add tools.<category>.<id> keys (including the seo block) in messages/en.json and messages/fr.json.
  6. Verify: npm test (i18n parity + unit + components), then npm run test:e2e.

The sitemap, MIME-based routing and the ⌘K palette pick the new tool up automatically.


Brand

omne is a Kouma Labs product. The header and the footer carry the co-branded lockup β€” the Kouma Labs app-icon, a muted slash, then the omne logo β€” as specified in the brand kit at koumalabs.org/brands. The omne mark's size is derived from the tile's rather than fixed, so the two marks stay balanced at every step of the scale. The ring sits at ~0.73 of the tile: omne's solid stroke outweighs the Kouma halftone at equal height, so it has to be visibly the smaller shape to read as its equal. The ratio was settled by comparing candidates side by side, not by arithmetic. The header drops the tile below md, where it has no room; the footer shows the full lockup at every width.

Both tiles (public/kouma-tile-{dark,light}.svg) are self-hosted and swapped through the --kouma-tile CSS variable under [data-theme] rather than Tailwind's dark: variant: this project drives its theme from the data-theme attribute, so a prefers-color-scheme swap would desync from what the user actually sees. Linking to koumalabs.org adds no outbound request β€” the privacy promise is unchanged.


License

Open source, built in the open.

About

Privacy-first toolbox. Everything runs in your browser. No file is ever uploaded.

Resources

Stars

4 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages

0