Skip to content

feat: add rectangle/page UI, backend full-page tighten fix, and expanded docs#67

Merged
theodubus merged 1 commit into
feat/graphic_selection_dev2from
codex/add-page-censoring-feature
Feb 23, 2026
Merged

feat: add rectangle/page UI, backend full-page tighten fix, and expanded docs#67
theodubus merged 1 commit into
feat/graphic_selection_dev2from
codex/add-page-censoring-feature

Conversation

@theodubus

Copy link
Copy Markdown
Owner

Motivation

  • Clarify product behavior and limits and provide packaging guidance via updated documentation for maintainers and non-technical users.
  • Add UI affordances for page-level and rectangle redactions so operators can draw and manage rectangle rules in the viewer.
  • Ensure full-page or very tall rectangle redactions are not over-tightened by the backend so intended large redactions actually remove the content.
  • Improve end-to-end correctness by sending stricter sanitation options from the frontend when rectangle/page redactions are used.

Description

  • Documentation: rewrite README.md to explain redaction theory, feature set, limits (including flattened/scanned PDFs), media placeholders and roadmap, add CONTRIBUTING.md, and add docs/DEPLOYMENT.md with Docker and packaging guidance, and clarify docs/SECURITY.md invariants and recommendations.
  • Backend: change _tighten_rect_vertical in backend/app/redaction.py to skip aggressive vertical tightening for large rects (h > 24.0) so full-page/very-tall rectangles are preserved.
  • Tests: add an integration test backend/tests/test_redact_rectangles.py::test_redact_rectangles_full_page_rect_redacts_target that posts a full-page rectangle and asserts the audit pass and that the secret is removed.
  • Frontend: implement rectangle drawing and page rules and wire them through the app by updating frontend/src/App.tsx, frontend/src/components/PdfViewer.tsx, frontend/src/components/Rules/*, frontend/src/types/uiRules.ts, frontend/src/api.ts, locales, and styles; the UI now supports drawing rectangles, adding page rules, preview badges, tracking current page and page sizes, and sending apply_images, apply_graphics, sanitize_metadata, remove_annotations, and remove_attachments in the /api/redact/apply payload when applicable.

Testing

  • Ran git diff --check which passed with no whitespace/patch issues.
  • Performed keyword scans (rg) and manual doc sanity checks on the changed docs which passed.
  • No backend or frontend test suites were executed in this rollout; the new pytest integration test test_redact_rectangles_full_page_rect_redacts_target was added but not run here.

Codex Task

@theodubus theodubus merged commit 313bc69 into feat/graphic_selection_dev2 Feb 23, 2026
1 of 2 checks passed
@theodubus theodubus deleted the codex/add-page-censoring-feature branch February 23, 2026 21:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant