Skip to content

Add basic download handling for files #37

Description

@culpen90

Why

Quartz currently focuses on page navigation, but a browser also needs basic file download behavior. Links that trigger downloads should not feel like failed navigations, and users should be able to choose where files go.

Where to start

  • Sources/Quartz/QuartzApp.swift
  • WKNavigationDelegate download-related APIs
  • WKDownloadDelegate

Suggested approach

Add minimal native download support. A good first version can show an NSSavePanel when WebKit starts a download, save the file to the selected location, and show success/failure feedback. A more complete version can add progress UI later.

Keep the initial scope small and reliable.

Acceptance criteria

  • Downloads triggered by navigation or link clicks are handled by Quartz instead of appearing as broken page loads.
  • Users can choose the destination path with a native save panel.
  • Failed downloads show a useful native error message.
  • Successful downloads leave the file at the selected destination.
  • swift build succeeds.

Testing

  • Download a small file from a normal website.
  • Cancel the save panel and confirm Quartz handles cancellation cleanly.
  • Download to a selected folder and confirm the file is written.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requesthelp wantedExtra attention is needed

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions