Skip to content
wimuellerPublic

About

Desktop app for structuring and analyzing HL7 v2 messages (Tauri + React + TypeScript). Fully offline.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Repository files navigation

HL7 Viewer

A desktop application for entering, structuring, and analyzing HL7 v2 messages. The application splits a raw message into its individual segments and fields and clearly explains what each segment and field stands for — in a modern, dark UI.

Build Tauri React License

Features

  • Raw input of an HL7 v2 message with live parsing
  • Structured segment view with a description of every segment and its fields
  • HL7 definitions for versions 2.3, 2.4, 2.5, 2.5.1, 2.6, and 2.7 (derived from HAPI HL7v2 via hamaluik/hl7-definitions)
  • Value-set resolution — coded field values are translated into plain text (e.g. PID-8 "M" → "Male")
  • Bidirectional hover highlighting between the raw message and the structured view (segment and field level) with auto-scroll
  • Save / load messages locally (in the OS app-data directory)
  • Fully offline — no data is ever sent to the internet (restrictive Content-Security-Policy, no HTTP plugin, file access limited to app data)

UI overview

Three columns: raw HL7 message (left) · structured segment cards (center) · saved messages (right).

Tech stack

  • Tauri 2 (Rust backend + native WebView)
  • React 18 + TypeScript + Tailwind CSS
  • Vitest (unit tests for the HL7 parser)

Prerequisites

Setup & development

# Install dependencies
npm install

# Start the dev app (opens the native window)
cargo tauri dev

# Frontend-only dev server (in the browser, with a localStorage fallback for saved messages)
npm run dev

Unit tests, typecheck, and build

npm test            # Vitest (HL7 parser tests)
npm run typecheck   # tsc --noEmit
npm run build       # Frontend production build into dist/

cargo check --manifest-path src-tauri/Cargo.toml   # Rust check
cargo fmt --manifest-path src-tauri/Cargo.toml     # Format Rust (requires rustfmt)

Creating a distribution bundle

Before a final build, set the bundle.active flag to true in src-tauri/tauri.conf.json, then:

cargo tauri build

This produces platform-specific installers bundles (.app/.dmg on macOS, .exe/.msi on Windows, AppImage/.deb on Linux).

Project structure

src/
  hl7/parser.ts          HL7 v2 parser (delimiters, fields, components, escapes)
  data/                   HL7 definition library (v2.3 ... v2.7) + value sets
  components/             React components (Header, MessageInput, SegmentCard, FieldRow, SavedList)
  hover.ts                Shared hover logic between the raw view and cards
  storage.ts              Persistence (Tauri IPC with a localStorage fallback)
src-tauri/
  src/lib.rs              Rust backend (Tauri commands: save/load/list/delete)
  tauri.conf.json         Tauri configuration (CSP, window, bundle)
  capabilities/           Permissions (local file access only, limited to the app-data directory)

Privacy

The application runs entirely offline. HL7 messages are stored exclusively in the operating system's app-data directory. tauri.conf.json enforces a restrictive Content-Security-Policy (connect-src 'self' ipc:) that blocks every outgoing network request. No HTTP plugin is bundled.

License

This project is licensed under the GNU General Public License v3.0.

The bundled HL7 v2 definition data (src/data/v2.*.json, src/data/tables.json) is derived from hamaluik/hl7-definitions (originally fernandojsg/hl7-dictionary) and follows their licensing terms.

About

Desktop app for structuring and analyzing HL7 v2 messages (Tauri + React + TypeScript). Fully offline.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages