Merged
Conversation
bensonwong
pushed a commit
that referenced
this pull request
Feb 10, 2026
…ervability, and component architecture ## Summary Phase A-C implementation of DX audit recommendations: **Phase A - README & Hooks** (#0-2, #4, #9) - Rewrite README.md with pain-point-first messaging, teaser code, component showcase, requirements tables, troubleshooting tips - Add deprecation JSDoc to legacy APIs (getAllCitationsFromDeferredResponse, etc.) - Soft-document compound components as experimental **Phase B - Documentation** (#4, #5, #6, #8, #13) - Create docs/error-handling.md with copy-paste retry patterns - Create docs/MIGRATION.md for tracking breaking changes - Cross-link docs with Related footers (getting-started, components, styling, index) **Phase C - CSS Theming** (#5) - Expose 12 CSS custom properties for full citation color customization - Replace hardcoded Tailwind classes with inline CSS var() styles - Add data-dc-indicator attributes for semantic test targeting - Update all tests to use data attributes instead of Tailwind selectors **Phase D - Observability** (#7, #8, #9) - Implement structured error hierarchy (DeepCitationError with 5 subclasses) - Map HTTP status codes to appropriate error types (401→Auth, 429→RateLimit, etc.) - Add optional DeepCitationLogger for structured observability - Add logging to all client methods: uploads, verification, caching, cache cleanup **Phase E - Component Architecture** (#10) - Extract useCitationEvents() hook to eliminate duplicate event handlers (30+ lines per variant) - Extract StatusIndicators component for shared verified/partial/miss/pending rendering - Reduce CitationVariants.tsx from 690→609 lines (81 lines removed, ~20-30 per variant) **Phase F - Accessibility** (#12) - Add aria-live regions for verification status change announcements - Add aria-describedby linking citations to their status descriptions ## Test Coverage - All 718 tests pass (624 main + 94 rendering) - TypeScript compiles cleanly - No breaking changes to public APIs (error classes are new exports, logging is optional) Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.