= ({
onMouseUp={handleMouseUp}
/>
) : (
-
-
- {markdown}
-
+ // Show loading state while markdown is being converted to HTML
+
)
) : (
+ // For HTML, use finalHtml directly
{
- if (!h.urlReference) return false
+ const filtered = highlights.filter(h => {
+ if (!h.urlReference) {
+ console.log('⚠️ Highlight has no urlReference:', h.id, 'eventReference:', h.eventReference)
+ return false
+ }
const normalizedRef = normalizeUrl(h.urlReference)
- return normalizedSelected === normalizedRef ||
+ const matches = normalizedSelected === normalizedRef ||
normalizedSelected.includes(normalizedRef) ||
normalizedRef.includes(normalizedSelected)
+
+ if (matches) {
+ console.log('✅ URL match:', normalizedRef)
+ } else {
+ console.log('❌ URL mismatch:', normalizedRef, 'vs', normalizedSelected)
+ }
+
+ return matches
})
+
+ console.log('📊 Filtered to', filtered.length, 'highlights')
+ return filtered
}