Implements [[term]], [[w:term]], and [[d:term]] wiki link syntax:
- New wiki_links.ts utility for parsing and tag generation
- Extract wiki links from content and generate w/d tags
- CodeMirror syntax highlighting (violet/cyan/amber)
- Preview displays extracted wiki tags separately from hashtags
- Tutorial documentation for wiki link usage
Per WIKI_TAG_SPEC.md:
- [[term]] and [[w:term]] generate w-tags (references/mentions)
- [[d:term]] generates d-tags (definitions)
- Custom display text: [[term|display text]]
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Index event (30040) tags: blue
- Content event (30041) tags: green
- Improves visual distinction between event types
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Fixed regex bug in attribute parsing (\s instead of \\s)
- Section-specific tags now extracted correctly from AsciiDoc attributes
- Added tag display for index events (30040) in preview
- Removed duplicate document header/tags rendering
- Tags now show for all 30040 and 30041 events at all parse levels
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Increase page container width from 1024px to 1536px for modern displays
- Adjust editor/preview split from 50/50 to 60/40 (editor larger)
- Add max-width constraints to content areas (900px editor, 896px preview)
- Center content within panels for optimal reading line length
- Remove duplicate "Document tags:" display in preview
The editor now has more breathing room while maintaining readable
line lengths. Content stays centered and constrained even with long
paragraphs, improving overall UX for writing and reviewing.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
Fixes multiple issues with AsciiDoc hierarchical parsing and preview rendering:
**Content Extraction:**
- Fixed content extraction to include child headers at all parse levels
- Level 3 parsing now properly includes ==== sub headers in === parent content
- Unified content extraction logic stops only at sibling/parent headers
**Event Generation:**
- Fixed collectSectionsAtLevel to include Level 2-N sections for proper hierarchy
- Level 3 parsing creates index events for == sections, content events for === sections
- Maintains NKBIP-01 compliance: parent sections get both index+content events
**Preview Rendering:**
- Fixed heading removal to target specific section titles, not first header found
- === subheader now renders correctly as h3 in preview
- Nested content properly displays in parent sections
**Example Structure (Level 3 parsing):**
```
= title
== test 1 → Index Event (30040) + Content Event (30041)
text
=== subheader → Content Event (30041)
content + nested
==== sub subheader
nested content
== note 2 → Index Event (30040) + Content Event (30041)
text
```
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
Events now publish successfully but don't appear in feed yet. Fixed the
"Failed to execute 'postMessage' on 'Window'" error by ensuring all
event data is properly serialized before passing between components.
Changes:
- Remove non-serializable tree property from exported events
- Convert all NDKEvent properties to primitives in eventToPublishableObject
- Add JSON deep cloning in handlePublish to ensure full serializability
- Add debug logging to track event structure and serialization issues
Status: Publishing works (events are sent to relays) but feed display
needs investigation for relay read/write configuration mismatch.
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Create positioned overlay for visual hierarchy indicators
- Set up scroll synchronization with textarea
- Add state management for gutter indicators
- Implement line position calculation system
- Foundation for Phase 2 visual hierarchy features
Verified: Overlay doesn't interfere with editing functionality
Ready for: Checkpoint 2.2 line detection and event mapping
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Update parsedSections to use metadata.eventStructure for accurate hierarchy
- Add helper function findEventByDTag for event lookup
- Now supports proper 30040 vs 30041 event type distinction
- Enhanced preview logging with eventStructure information
✅ Verified: Hierarchical parser generates proper 30040/30041 events
✅ Test: Level 3 parsing shows 7 events (1 index + 2 chapter indices + 4 content)
✅ Core: Event structure metadata available for advanced preview features
Ready for: Export functionality verification
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Switch import from publication_tree_factory to asciidoc_publication_parser
- Update MAX_PARSE_LEVEL from 6 to 5 for new hierarchy limits
- No functional changes yet - foundation for hierarchical parsing
✅ Verified: App compiles, ZettelEditor loads, parse levels 2-5 available
Ready for: Function call update in next checkpoint
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
Complete the AST-based parsing migration by removing all deprecated manual
parsing functions. The codebase now exclusively uses Asciidoctor's AST
for document processing.
- Remove parseAsciiDocWithMetadata, parseAsciiDocIterative, generateNostrEvents
- Delete 484 lines of legacy parsing code from asciidoc_metadata.ts
- Clean up imports and formatting across affected files
- Fix import paths to use consistent module resolution
- Remove unused UI imports from compose page
This completes the transition to AST-based PublicationTree architecture.
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
Replace manual regex parsing with proper Asciidoctor AST traversal for more
accurate and scalable document processing. Add dynamic parse level system
that correctly maps AsciiDoc hierarchy to Nostr events.
Key changes:
- New asciidoc_ast_parser.ts using Asciidoctor's native document structure
- PublicationTree factory for seamless integration with existing architecture
- Fixed level mapping: Asciidoctor levels 1-5 → app levels 2-6
- Dynamic parse level generation (2-6) with proper event count progression
- Responsive editor height using viewport units for adaptive screen sizing
- Enhanced preview with hierarchical visualization and event boundaries
Event count progression now works correctly:
- Level 2: 3 events → Level 6: 20+ events
- Full reactivity when changing parse levels
- Proper content type detection (Article vs Notes vs None)
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Fix {@const} placement errors by using Svelte 5 snippets
- Add proper TypeScript types to levelColors objects
- Rename and fix test file from .js to .ts with proper typing
- Remove indent guides from editor text area for cleaner writing
- Improve preview layout with proper indentation and spacing
- Add continuous vertical guides in preview that don't overlap text
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Completely rewrote parseAsciiDocIterative to handle Level 3+ parsing correctly
- Fixed generateNostrEvents to build proper tree structure and create hierarchical 30040/30041 events
- Updated preview to show document titles for articles and only display hashtags (t-tags)
- Added parseSimpleAttributes export for direct tag parsing from section content
- Now supports proper index chains: Main 30040 → Sub 30040s → Content 30041s at configurable depth
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Auto-add author identity when not publishing on behalf of others
- Check for existing :author: and :p: tags, only add if missing
- Add ["author", displayName] and ["p", pubkey] tags automatically
- Move publish button from top gradient to underneath text area
- Preserve smart color functionality: blue for articles, green for notes
- Position publish button next to preview button for better UX
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>