# File deletion from Web UI (not just unindex)

## Description

## Summary

Add ability to permanently delete files from disk via Web UI, not just unindex them.

## Background

Currently the Web UI only supports "unindex" (deactivate) which removes docs from the search index but leaves files on disk. Some users may want actual file deletion.

## Requirements

- New API endpoint: `DELETE /api/docs/:id/file` or similar
- Confirmation dialog with file path shown
- Option to move to trash vs permanent delete
- Security: strict path validation, only files in known collections
- Consider: undo capability (trash-based deletion)

## Blocked By

- gno-7tp (Web UI enhancements) - establishes the DocView edit/unindex patterns

## Notes

This is intentionally separate from the main Web UI epic to keep scope manageable. The unindex feature covers most use cases; file deletion is a "nice to have" for full PKMS functionality.

## Acceptance

- [ ] Implementation complete
- [ ] Tests passing
- [ ] Documentation updated

## Done summary

TBD

## Evidence

- Commits:
- Tests:
- PRs:
