- Fork elmeg-demo codebase for multi-band support - Add data importer infrastructure with base class - Create band-specific importers: - phish.py: Phish.net API v5 - grateful_dead.py: Grateful Stats API - setlistfm.py: Dead & Company, Billy Strings (Setlist.fm) - Add spec-kit configuration for Gemini - Update README with supported bands and architecture
22 lines
753 B
TypeScript
22 lines
753 B
TypeScript
"use client"
|
|
|
|
import { usePreferences } from "@/contexts/preferences-context"
|
|
|
|
interface SocialWrapperProps {
|
|
type: "comments" | "ratings" | "reviews"
|
|
children: React.ReactNode
|
|
}
|
|
|
|
export function SocialWrapper({ type, children }: SocialWrapperProps) {
|
|
const { preferences, loading } = usePreferences()
|
|
|
|
// While loading, show content (assume defaults: wiki_mode=false, show_comments=true, show_ratings=true)
|
|
// Only hide once we know the user's preference is explicitly set to hide
|
|
if (!loading) {
|
|
if (preferences.wiki_mode) return null
|
|
if (type === "comments" && !preferences.show_comments) return null
|
|
if (type === "ratings" && !preferences.show_ratings) return null
|
|
}
|
|
|
|
return <>{children}</>
|
|
}
|