remarkbox/docs/tickets/9.md
russell@unturf.com f1cffe2e79 Resolve all 14 tracked tickets (T0-T13)
High priority fixes:
- T0: Profile page now filters comments by namespace (was leaking cross-site)
- T1: URI hostnames and namespace names normalized to lowercase (was causing
  duplicate threads and "stock comments" bug). Includes merge script.
- T2: Thread detail API now paginated with SQL-side filtering (was 502 on
  267+ reply threads)

Features:
- T3: GDPR account deletion (tombstone user with scrubbed PII) and data export
- T4: Customizable button text and comment labels per namespace
- T5: Self-service namespace deletion for owners
- T6: @mention notifications with profile links
- T7: Webmention receiving endpoint with h-card extraction
- T8: Configurable max nesting depth and collapse depth per namespace
- T9: AJAX thread title search to prevent duplicates
- T10: Browser push notification support (VAPID/service worker)

Docs and housekeeping:
- T11: Documented thread_uri behavior when moving embeds
- T12/T13: Drafted community replies for resolved feature requests
- Collapse depth defaults to infinite (load-more disabled unless configured)

364 tests pass, 4 skipped.
2026-02-01 20:02:47 -05:00

1.1 KiB

T9: Prevent duplicate threads (AJAX search)

Status: resolved Priority: low Source: meta 642831b4-4cbf-11e9-9d67-040140774501 Filed: 2026-02-01

Problem

On standalone and FAQ sites, users can create threads with duplicate titles. There's no feedback showing existing threads before creation.

Proposed Implementation

  1. Add an AJAX search endpoint that returns threads matching a title prefix
  2. Wire it into the "new thread" form with a debounced typeahead
  3. Show matching existing threads as suggestions before submission

Files

  • remarkbox/api/__init__.py — added api-threads-search route
  • remarkbox/api/views.py — added api_search_threads() endpoint (GET /api/v1/threads/search)
  • remarkbox/static/js/custom.js — debounced typeahead for thread title input
  • remarkbox/static/css/common.css — CSS for suggestion dropdown
  • remarkbox/templates/base.j2 — added data-namespace attribute to body tag

Acceptance Criteria

  • Typing a thread title shows matching existing threads
  • Users can click a suggestion to navigate to the existing thread
  • New thread creation still works when no match exists