Skip to content

feat(files): unified download dialog, public-upload fix, and upload UX polish#180

Merged
Nic-dorman merged 1 commit into
mainfrom
feat/upload-download-improvements
Jul 15, 2026
Merged

feat(files): unified download dialog, public-upload fix, and upload UX polish#180
Nic-dorman merged 1 commit into
mainfrom
feat/upload-download-improvements

Conversation

@Nic-dorman

Copy link
Copy Markdown
Contributor

Splits a batch of upload/download improvements out of a testing session. (Sibling PR for LAN devnet Developer Options is separate — the two touch different regions of lib.rs/en.json and don't conflict.)

Download

  • Unified dialog: merges "Download by Address" and "Download by Datamap" into one Download dialog with a smart input that auto-detects and routes:
    • a hex address (0x… / 64 hex) → download_public
    • an autonomi:// link → download_public (parses name / filename+filetype for the save-as name)
    • a local .datamap path or file:// URI → download_file
    • an http(s) .datamap URL → fetch then download_file
    • plus a drop zone for a .datamap file, and an auto-filled save-as name.
  • Require a full 64-hex address — the old {8,} check enabled the button then failed in the backend (which requires exactly 32 bytes).
  • Fetch a datamap from a URL — new read_datamap_url (reqwest, 15s timeout, 5 MiB streamed cap; parsed via ant-core's format sniffer). The file data still comes from Autonomi, so a hostile URL can't substitute content.

Upload

  • Fix: public uploads were silently stored private in direct-key mode (devnet / imported key). wallet_upload now takes visibility and calls the public variant, returning public_address — so the PUBLIC badge and shareable address show. This affected Sepolia and Arbitrum One imported-key uploads too, not just devnet.
  • Already-on-network files no longer auto-dismiss the confirm dialog — the private (get the DataMap) vs public (publish the DataMap) choice is a real decision even when the data exists. The approve gate now counts already-stored entries, and the button reads "Get Datamap" for already-stored + private.
  • Remove the redundant "Already stored" badge that crowded the filename.

Uploads table

  • Address column truncates to the column width (shows the full address when it fits) and never truncates the PUBLIC tag.
  • Vertically centre the status column.

i18n

New/updated download+upload strings across all 18 locales. Non-English is machine-generated best guess — will refine with community feedback.

Both this and the sibling branch build clean (tauri dev) and were exercised against a local devnet.

🤖 Generated with Claude Code

…X polish

Download:
- Merge "Download by Address" and "Download by Datamap" into one Download
  dialog with a smart input that auto-detects a hex address, an autonomi://
  link, a local .datamap path, or an http(s) .datamap URL, plus a drop zone
  and an auto-filled save-as name.
- Require a full 64-hex address (was >=8 chars, which enabled the button then
  failed in the backend).
- Parse autonomi:// links for name / filename+filetype.
- Fetch a datamap from an http(s) URL (read_datamap_url; reqwest with a 15s
  timeout and a 5 MiB streamed cap).

Upload:
- Fix: public uploads in direct-key mode (devnet / imported key) were silently
  stored private — wallet_upload now takes visibility and returns
  public_address, so the PUBLIC badge and shareable address show.
- Already-on-network files no longer auto-dismiss the confirm dialog; the
  private (get datamap) vs public (publish) choice is preserved, the approve
  gate counts them, and the button reads "Get Datamap" for already-stored +
  private.
- Remove the redundant "Already stored" badge that crowded the filename.

Table:
- Address column truncates to the column width (full address when it fits) and
  never truncates the PUBLIC tag.
- Vertically centre the status column.

i18n: new/updated download and upload strings across all 18 locales
(machine-generated best guess for non-English; will refine with feedback).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@Nic-dorman
Nic-dorman force-pushed the feat/upload-download-improvements branch from 64f8090 to b9a5eaa Compare July 14, 2026 12:00
@Nic-dorman
Nic-dorman merged commit 11f8641 into main Jul 15, 2026
4 checks passed
@Nic-dorman
Nic-dorman deleted the feat/upload-download-improvements branch July 15, 2026 14:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant