Desktop-only download manager for NIMH Data Archive (NDA) packages. The renderer is built with Angular and runs inside the Electron shell; using the Angular dev server directly in a browser is not a supported app mode.
- Signs users in with NIH Research Auth Service (RAS) through the Electron desktop shell.
- Handles
nda-dm://protocol callbacks from the RAS sign-in flow. - Lists packages that are ready to download in
My Packages. - Lists packages available in
Shared Packages. - Adds shared packages to
My Packages. - Displays package files with file name, size, creation date, local download status, download progress state, and file explorer actions.
- Lets users select a download directory and remembers the last selected directory in local storage.
- Scans the selected download directory to detect missing, partial, and already-downloaded files.
- Switches package row actions between download and show behavior when package files are downloaded.
- Supports downloading an entire package or only selected files.
- Skips complete local files before starting download work.
- Downloads files from S3 with token prefetching, parallel file/chunk work, disk-space checks, and progress events from Electron.
- Supports pause, resume, and cancel controls for active download jobs.
- Opens downloaded files or completed package folders in the system file explorer.
- Provides a help request modal that sends support requests through the Electron main process.
- Node.js compatible with the versions required by Angular 21 and Electron 42.
- npm.
- Network access to the selected NDA environment.
- A desktop environment that can run Electron.
Install dependencies:
npm.cmd installAll start commands build the Electron main process, start Angular on 127.0.0.1:4200, wait for the renderer, and then launch Electron.
Default environment:
npm.cmd run startStage environment:
npm.cmd run start:stageRevengers environment:
npm.cmd run start:revengersThe local Angular URL is a development implementation detail. Use the Electron window for normal app testing.
Runtime logs from local app runs are written under logs/, including Electron main-process and renderer console output in logs/main.log. Packaged builds use the app data directory's logs folder.
The API host and renderer Zendesk token are compiled from Angular environment files. There is no runtime environment selector in the UI.
| Command | Angular configuration | Environment file | API host |
|---|---|---|---|
npm.cmd run start |
development |
src/environments/environment.ts |
https://nda.nih.gov |
npm.cmd run start:stage |
stage |
src/environments/environment.stage.ts |
https://stage.nimhda.org |
npm.cmd run start:revengers |
revengers |
src/environments/environment.revengers.ts |
https://revengers.nimhda.org |
Angular selects non-default environment files through fileReplacements in angular.json.
Do not log or document the actual Zendesk token value. NDA_DM_ZENDESK_TOKEN is still available as a local fallback if the compiled environment token is blank.
Build the Angular renderer:
npm.cmd run build:rendererBuild the Electron main process:
npm.cmd run build:electronBuild both renderer and Electron:
npm.cmd run buildRun lint:
npm.cmd run lintCreate a packaged desktop build:
npm.cmd run packageLaunch Electron against an already-running local renderer at 127.0.0.1:4200:
npm.cmd run electron- Start the app for the desired environment.
- Sign in with RAS.
- Wait for packages to load.
- Optionally add packages from
Shared PackagestoMy Packages. - Choose a download directory from the account menu.
- Select a package from
My Packages. - Scan the download directory to refresh local file status.
- Download the package from the package row action, or select individual files and use
Download Selected. - Use pause, resume, or cancel controls while a download is active.
- Use
Showactions to open completed files or package folders in the system file explorer.
- The Electron main process owns desktop-only behavior such as protocol handling, file system access, directory selection, showing files in the system file explorer, and S3 download work.
- The renderer communicates with Electron through the preload bridge.
- Complete files are not selectable for download.
- The selected package list pane can be resized by dragging the splitter between the package and file panes.