- Eliminate a component that is no longer needed.
- Reduce duplicate code.
- Tidy up code along the way.
- Ran `deno fmt` to auto-format code (hence the large diff).
Implements a checkbox option for kinds 30041 and 30818 that allows users to display all loaded content events instead of being limited by the number input.
Changes:
- Added showAll property to EventKindConfig interface
- Added toggleShowAllContent method to visualization store
- Updated EventTypeConfig UI to show "All" checkbox for content kinds
- Modified display filtering to respect showAll setting
- Disabled number input when showAll is checked
This improves the user experience by making it easy to show all content when working with publications and wiki pages.
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Give disconnected nodes (like kind 0) random initial positions so they appear in the graph
- Add center and radial forces to keep disconnected nodes visible within the viewport
- Update filterByDisplayLimits to respect per-kind limits from visualization config
- Now properly limits kind 0 profiles to the configured display limit (e.g., 5 of 7 fetched)
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Use total pubkeys size instead of newly fetched profile events length
- This accounts for profiles that were already cached
- Update both initial fetch and missing events fetch
The issue was that when profiles were already cached, profileEvents.length
was 0, making it look like no profiles were fetched even though they were
available from cache.
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Change default follow list limit from 1 to 0
- Add explicit check to skip fetching when limit is 0
- This prevents unnecessary profile fetching on initial load
- When users change limit to >0, then all follow list profiles are fetched
This provides the optimal default behavior:
- Initial load only fetches profiles from event authors
- Users can opt-in to social graph by increasing follow list limit
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
This commit represents a checkpoint in implementing a sophisticated event
configuration system with people tag anchors. The implementation has grown
complex and needs reimplementation in a smarter way.
## Major Changes:
### Event Configuration System Overhaul
- Replaced simple allowed/disabled kinds with EventKindConfig objects
- Each event kind now has individual limits and type-specific settings:
- Kind 0 (profiles): Controls max profiles to fetch
- Kind 3 (follow lists): Has depth setting and complex fetch logic
- Kind 30040: Has nestedLevels setting
- Created new EventTypeConfig component replacing EventKindFilter
### Follow List Fetching Logic
- Kind 3 limit=1: Fetches only user's follow list
- Kind 3 limit>1: Fetches user's + (limit-1) follow lists from follows
- Added depth traversal (0=direct, 1=2 degrees, 2=3 degrees)
- Attempted to implement "addFollowLists" toggle (later simplified)
### Profile Fetching Changes
- Modified to be more selective about which profiles to fetch
- Attempted to limit based on follow lists and event authors
- Added progress indicators for profile loading
### People Tag Anchors Implementation
- Complex logic to create "p" tag anchors from follow lists
- Synthetic event creation to connect people to visualization
- "Only show people with publications" checkbox
- Attempted to connect people to:
- Events they authored (pubkey match)
- Events where they're tagged with "p"
- Display limiting based on kind 0 limit
### UI/UX Changes
- Tag anchors legend now scrollable when >20 items
- Auto-disable functionality when >20 tag anchors
- Added various UI controls that proved confusing
- Multiple iterations on settings panel layout
## Problems with Current Implementation:
1. **Overly Complex Logic**: The synthetic event creation and connection
logic for people tag anchors became convoluted
2. **Confusing UI**: Too many interdependent settings that aren't intuitive:
- Limit inputs control different things for different event types
- The relationship between kind 3 and kind 0 limits is unclear
- "addFollowLists" checkbox functionality was confusing
3. **Performance Concerns**: Fetching all profiles then limiting display
may not be optimal
4. **Unclear Requirements**: The exact behavior for people tag anchors
connections needs clarification
## Next Steps:
Need to revert and reimplement with:
- Clearer separation of concerns
- Simpler UI that's more intuitive
- Better defined behavior for people tag anchors
- More efficient profile fetching strategy
## Files Changed:
- EventTypeConfig.svelte: New component for event configuration
- visualizationConfig.ts: Major overhaul for EventKindConfig
- profileCache.ts: Added selective fetching logic
- visualize/+page.svelte: Complex follow list and profile fetching
- EventNetwork components: People tag anchor implementation
- settings_panel.org: Documentation of intended behavior
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>