Commit Graph

231 Commits

Author SHA1 Message Date
Gigi
0a3bb72d89 fix: prevent save settings button from being cut off
- Add padding-bottom to settings-content for breathing room
- Add bottom padding to settings-footer
- Add flex-shrink: 0 to footer to prevent it from being compressed
- Ensures Save Settings button is always fully visible
2025-10-05 03:29:24 +01:00
Gigi
2719ad3602 feat: add reading time estimate to articles
- Install reading-time package
- Calculate reading time from article content (html or markdown)
- Display reading time with clock icon in article header
- Strip HTML tags for accurate word count
- Style reading-time indicator similar to highlights
- Shows estimated reading time (e.g., '5 min read')
2025-10-05 03:28:36 +01:00
Gigi
02798e99e8 style: add max-width to main pane for better readability
- Set max-width of 900px for the main content pane
- Center content with margin: 0 auto
- Add horizontal padding for breathing room
- Improves reading experience by preventing overly wide lines
2025-10-05 03:26:54 +01:00
Gigi
aba91f7a52 feat: inline font selector with styled options and fix font size 2025-10-05 03:26:18 +01:00
Gigi
dea647f36a fix: font and size settings now apply 2025-10-05 03:23:45 +01:00
Gigi
8be57dea2c style: improve checkbox alignment and styling
- Fix checkbox alignment with flex display override
- Reduce checkbox size from 20px to 18px
- Add accent-color to match theme
- Improve text color and spacing
- All checkboxes now properly aligned
2025-10-05 03:20:09 +01:00
Gigi
14a429ca61 feat: replace font size dropdown with icon buttons
- Replace dropdown with visual 'A' buttons at different sizes
- Buttons show the actual size they represent
- Active state highlights selected size
- Consistent with view mode button pattern
- More intuitive and visual UX
2025-10-05 03:18:43 +01:00
Gigi
caf73b7c9f refactor: simplify setting label to 'Show highlights'
- Change 'Show highlight underlines' to 'Show highlights'
- More concise and clear
2025-10-05 03:17:06 +01:00
Gigi
915829e82c fix: make font size setting work in preview
- Change h3 font-size from 1.5rem to 1.5em to scale with parent
- Remove hardcoded font-size from preview paragraphs
- Now font size changes are properly reflected in the preview
2025-10-05 03:16:42 +01:00
Gigi
dd3203f34f refactor: remove loading state and show bookmarks as they arrive
- Remove loading state variable from Bookmarks component
- Remove 'Loading bookmarks...' screen
- Start with empty list and populate bookmarks in background
- Remove timeout and loading callbacks from fetchBookmarks
- Better UX: show UI immediately, bookmarks appear when ready
- Bookmarks.tsx now at 197 lines
2025-10-05 03:15:57 +01:00
Gigi
183af3a80c feat: add font size setting
- Add fontSize to UserSettings interface
- Add font size dropdown in Settings with options from 12px to 22px
- Apply font size to preview content instantly
- Set --reading-font-size CSS variable in Bookmarks when settings change
- Apply font-size variable to .reader-html and .reader-markdown
- Condense code in Bookmarks.tsx to stay under 210 lines (now at 207)
2025-10-05 03:13:31 +01:00
Gigi
3e441925e5 feat: close settings when opening an article
- Add setShowSettings(false) to handleSelectUrl
- Ensures settings view closes when user selects a bookmark to read
- File remains at 210 lines
2025-10-05 03:10:46 +01:00
Gigi
9a1efd5b18 fix: prevent duplicate highlight application
- Store original HTML in ref to prevent re-highlighting already highlighted content
- Separate highlight application from click handler attachment effects
- Remove onHighlightClick from highlight application dependencies
- Remove verbose console logging for cleaner code
- Highlights now apply correctly without stacking on top of each other
2025-10-05 03:09:59 +01:00
Gigi
af6538d577 refactor: reduce Bookmarks.tsx to exactly 210 lines
- Remove extra blank line between imports and type definition
- File now at exactly 210 lines
2025-10-05 03:07:29 +01:00
Gigi
0a78d19195 refactor: simplify Bookmarks.tsx to meet 210 line limit
- Remove verbose console.log statements
- Simplify handlers and remove unnecessary blank lines
- Condense font loading logic
- Keep code DRY and simple
- File now at exactly 210 lines
2025-10-05 03:06:36 +01:00
Gigi
25a1adaeaa feat: open highlights panel when clicking highlight in article
- Simple inline handler that opens panel if collapsed
- Sets selected highlight ID
- Clean, minimal implementation
2025-10-05 03:04:40 +01:00
Gigi
5c2c8f618c feat: auto-open highlights panel when clicking highlight in article
- Add handleHighlightClick that opens panel if collapsed
- Sets selected highlight ID to scroll to it in the panel
- Add console logging for debugging
- When user clicks highlight in article with panel closed, panel opens automatically
2025-10-05 03:02:56 +01:00
Gigi
726b8a9c10 Revert "feat: auto-open highlights panel when clicking a highlight"
This reverts commit b6edf8de73.
2025-10-05 03:00:03 +01:00
Gigi
b6edf8de73 feat: auto-open highlights panel when clicking a highlight
- Create handleHighlightClick handler that sets highlight ID and opens panel
- Automatically expand highlights sidebar if collapsed when highlight clicked
- Improves UX by ensuring highlights panel is visible when interacting with highlights
- Applied to both ContentPanel and HighlightsPanel click handlers
2025-10-05 02:58:29 +01:00
Gigi
e10ae00a1a refactor: organize settings into logical groups
- Create three sections: Reading & Display, Layout & Navigation, Startup Preferences
- Add section titles with consistent styling
- Group related settings together:
  - Reading & Display: font, highlight underlines, preview
  - Layout & Navigation: view mode, collapse behavior
  - Startup Preferences: initial sidebar states
- Add section title styling with border and uppercase text
- Better visual hierarchy and organization
2025-10-05 02:57:04 +01:00
Gigi
bb351ae35f feat: preview reflects show underlines setting
- Preview highlight dynamically shows/hides based on showUnderlines setting
- Users can see highlight appearance changes instantly
- Conditional className applied to preview highlight
2025-10-05 02:55:53 +01:00
Gigi
ad1e06c867 feat: add highlight example to preview
- Add highlighted text in preview using content-highlight class
- Shows how highlights appear with different fonts
- Helps users see complete reading experience before saving
2025-10-05 02:53:55 +01:00
Gigi
bf8dfe79dd feat: add live preview of reading font in settings
- Add preview section showing Lorem Ipsum passage
- Preview updates instantly when font is changed
- Load font dynamically for preview
- Style preview to match reader appearance
- Helps users see font changes before saving
2025-10-05 02:53:22 +01:00
Gigi
0ccad88dfd feat: add configurable reading font using Bunny Fonts
- Add readingFont setting to UserSettings interface
- Create fontLoader utility to load fonts from Bunny Fonts
- Add font selector dropdown in settings with popular reading fonts
- Use CSS variable --reading-font to apply font to reader content
- Support fonts: Inter, Lora, Merriweather, Open Sans, Roboto, Source Serif 4, Crimson Text, Libre Baskerville, PT Serif
- Fonts loaded from https://fonts.bunny.net/ (GDPR-friendly)
2025-10-05 02:52:21 +01:00
Gigi
20e9ba1675 style: inline default view mode label and buttons
- Put label and icon buttons on same line
- Remove background container from view mode buttons
- Add setting-inline and setting-buttons classes
- Clean, minimal inline layout without background styling
2025-10-05 02:49:55 +01:00
Gigi
85d3508190 fix: remove header bar styling from settings
- Remove background, border, and bar styling from settings header
- Keep simple header with title and close button on same line
- Match padding with content panel for proper alignment
- Clean, minimal header without visual container
2025-10-05 02:48:27 +01:00
Gigi
4cf0138706 style: align settings header with sidebar header bar
- Change settings-header to settings-header-bar class
- Match styling of sidebar-header-bar (background, border, padding)
- Reduce title font size to match sidebar style
- Adjust padding and spacing for consistent visual alignment
- Settings header now appears on same visual line as sidebar buttons
2025-10-05 02:46:59 +01:00
Gigi
d6e093b3bb refactor: use icon buttons for default view mode setting
- Replace dropdown select with icon-based view switcher
- Use same icons as sidebar header (list, grid, image)
- Add left-aligned view-mode-controls styling for settings
- Maintain consistent UI across view mode selectors
2025-10-05 02:44:58 +01:00
Gigi
6489714f33 style: left-align all settings text and controls
- Add text-align: left to settings view, header, and content
- Add justify-content: flex-start to checkbox labels
- Add flex-shrink: 0 to checkboxes to prevent squishing
- Ensure consistent left alignment throughout settings panel
2025-10-05 02:43:34 +01:00
Gigi
e2749b6a3c feat: collapse both sidepanels when opening settings
- Automatically collapse bookmarks sidebar when settings opened
- Automatically collapse highlights panel when settings opened
- Provides full-width settings view for better UX
2025-10-05 02:41:30 +01:00
Gigi
89e089ad25 refactor: render settings in main pane instead of as overlay
- Move Settings component from overlay to main pane
- Update Settings styling for inline display
- Conditionally render Settings or ContentPanel in main pane
- Remove overlay-specific styles and simplify layout
2025-10-05 02:40:38 +01:00
Gigi
7e5196d73d fix: resolve TypeScript and lint errors 2025-10-05 02:38:51 +01:00
Gigi
1b8c276529 chore: upgrade applesauce packages to v4.0.0
- Update all applesauce packages from 3.1.0 to 4.0.0
- Add applesauce-factory dependency
- Version 4.0.0 includes app-data helpers needed for NIP-78
2025-10-05 02:35:28 +01:00
Gigi
1b381a0f8c fix: export app-data helpers from applesauce-core
- Add app-data.js export to helpers index
- Update import path in settingsService to use applesauce-core/helpers
2025-10-05 02:33:46 +01:00
Gigi
35aa9d6cce feat: add collapse-on-article-open setting
- Add collapseOnArticleOpen setting (default: true)
- Position as first setting in settings panel
- Auto-collapse bookmark bar when user opens an article
- User can disable this behavior in settings
2025-10-05 02:31:23 +01:00
Gigi
f8c8ab5402 feat: add settings panel with NIP-78 storage
- Create settings service using Kind 30078 for user preferences
- Add Settings component with UI for configuring app preferences
- Wire settings icon to open settings modal
- Store settings like default view mode, sidebar collapse states, etc.
- Use d tag: com.dergigi.boris.user-settings
2025-10-05 02:30:30 +01:00
Gigi
67f0a0b3b6 feat: add settings icon next to user profile 2025-10-05 02:23:21 +01:00
Gigi
4ab9d238d5 feat: set compact view as default bookmark view 2025-10-05 02:21:20 +01:00
Gigi
e0ddd43fe4 feat: add localStorage caching for fetched articles
- Cache articles in localStorage with 7-day TTL
- Check cache before fetching from jina.ai
- Add optional bypassCache parameter
- Automatically expire and cleanup old cached content
2025-10-05 02:14:53 +01:00
Gigi
5f8d4b2c47 fix: delay pulse animation to let scroll complete first
- Add 500ms delay before starting pulse animation
- Prevents pulse from starting while element is still scrolling
- Creates better visual flow: scroll → pause → pulse
- Makes the highlight easier to track with your eyes

The pulse now starts after the smooth scroll completes,
making it much clearer which highlight you jumped to.
2025-10-05 02:10:17 +01:00
Gigi
a4c15ecc0e feat: add pulsing animation when scrolling to highlight
- Replace brightness change with subtle pulse animation
- Pulse twice over 1.5 seconds with scale and glow effects
- Scale slightly (1.02x) and increase shadow glow
- More elegant visual feedback than color change
- Easier to spot without being jarring

The highlight now pulses twice when clicked from the
sidebar, making it easy to see where you've jumped to.
2025-10-05 02:08:51 +01:00
Gigi
967aac49ef fix: scroll to highlight in article when clicking sidebar item
- Add selectedHighlightId prop to ContentPanel
- Add useEffect to watch for selectedHighlightId changes
- Find and scroll to the corresponding mark element
- Temporarily brighten the highlight for visual feedback
- Pass selectedHighlightId from Bookmarks to ContentPanel

Now clicking a highlight in the sidebar properly scrolls
to and highlights the text in the article view.
2025-10-05 02:07:05 +01:00
Gigi
d9b50f80d0 feat: scroll to highlight in article when clicking highlight item
- Add onHighlightClick callback to HighlightItem
- Make entire highlight item clickable with pointer cursor
- Reuse existing setSelectedHighlightId to trigger scroll
- Clicking a highlight in sidebar scrolls to it in article view
- Works with existing click-to-scroll from article to sidebar

Users can now click highlights in either direction:
- Click highlight in article → scrolls to item in sidebar
- Click highlight in sidebar → scrolls to text in article
2025-10-05 02:03:28 +01:00
Gigi
6ae101c9c6 feat: make bookmark icon glow blue when article is bookmarked
- Bookmark icon glows blue when selectedUrl matches a bookmark
- Use app's primary blue color (#646cff) for consistency
- Check bookmark URLs with flexible matching (exact, includes)
- Pass selectedUrl to BookmarkList component
- Add glow-blue CSS class with drop-shadow effect

The bookmark icon now glows blue when viewing a bookmarked
article, providing visual feedback that it's in your collection.
2025-10-05 02:00:53 +01:00
Gigi
a62e493590 feat: make highlighter icon glow when article has highlights
- Highlighter icon glows yellow when filteredHighlights > 0
- Add pulsing animation for subtle attention-grabbing effect
- Use highlight color (#ffff00) with drop-shadow for glow
- Only applies when highlights panel is collapsed
- Provides visual feedback that highlights are available

The icon now pulses with a yellow glow when the current
article has highlights, making it easy to see at a glance.
2025-10-05 01:58:18 +01:00
Gigi
9f251d43ad feat: add bookmark icon to collapsed bookmarks panel button
- Show both chevron and bookmark icons when collapsed
- Button width adjusts to fit both icons
- Add gap between icons for proper spacing
- Mirrors the highlights panel behavior
- Makes it clear what the panel contains when collapsed

Both sidebars now show their respective icons (bookmark/highlighter)
when collapsed for better visual consistency and clarity.
2025-10-05 01:56:26 +01:00
Gigi
b326a9d5b3 feat: add highlighter icon to collapsed highlights panel button
- Show both highlighter and chevron icons when collapsed
- Button width adjusts to fit both icons
- Add gap between icons for proper spacing
- Makes it clear what the panel contains when collapsed
2025-10-05 01:55:13 +01:00
Gigi
749270b698 fix: chevrons point outward when panels are collapsed
- Left sidebar collapsed: chevron points left (←) outward
- Right sidebar collapsed: chevron points right (→) outward

This makes it more intuitive - the chevrons point away from
the center when collapsed, indicating the direction to expand.
2025-10-05 01:54:15 +01:00
Gigi
b34d8172e0 refactor: unify collapse/expand mechanics for both sidebars
- Left sidebar: chevron points right (→) when collapsed
- Right sidebar: chevron points left (←) when collapsed
- Both use same button size (36x36px)
- Both use same positioning (top-aligned with 0.75rem padding)
- Both use same styling (background, border, hover states)
- Left sidebar aligns to right, right sidebar to left (mirrored)
- Remove rotation transforms for cleaner implementation

The collapse/expand mechanics now feel and look identical
but properly mirrored for left and right panels.
2025-10-05 01:52:16 +01:00
Gigi
2b9b7d0ebf feat: add refresh button to highlights panel
- Add refresh button with rotate icon to highlights header
- Button spins while loading highlights
- Disabled state when already loading
- Positioned before toggle underlines button
- Calls handleFetchHighlights to refetch from relays
- Add CSS styles for refresh button with disabled state

Users can now manually refresh highlights to see newly
created highlights without reloading the page.
2025-10-04 22:27:38 +01:00