Commit Graph

52 Commits

Author SHA1 Message Date
George Powell 885adad756 added test.bibdle.com domain 2026-02-13 01:35:31 -05:00
George Powell 8ef2a41a69 Added Sign In with Apple test route 2026-02-13 01:06:21 -05:00
George Powell ac6ec051d4 Added Sign In with Apple 2026-02-13 00:57:44 -05:00
George Powell a12c7d011a added some nice animation details 2026-02-13 00:36:06 -05:00
George Powell 77ffd6fbee Implement client-side timezone handling for daily verses
Refactored the daily verse system to properly handle users across different
timezones. Previously, the server used a fixed timezone (America/New_York),
causing users in other timezones to see incorrect verses near midnight.

Key changes:

**Server-side refactoring:**
- Extract `getVerseForDate()` into `src/lib/server/daily-verse.ts` for reuse
- Page load now uses UTC date for initial SSR (fast initial render)
- New `/api/daily-verse` POST endpoint accepts client-calculated date
- Server no longer calculates dates; uses client-provided date directly

**Client-side timezone handling:**
- Client calculates local date using browser's timezone on mount
- If server date doesn't match local date, fetches correct verse via API
- Changed verse data from `$derived` to `$state` to fix reactivity issues
- Mutating props was causing updates to fail; now uses local state
- Added effect to reload page when user returns to stale tab on new day

**Stats page improvements:**
- Accept `tz` query parameter for accurate streak calculations
- Use client's local date when determining "today" for current streaks
- Prevents timezone-based streak miscalculations

**Developer experience:**
- Added debug panel showing client local time vs daily verse date
- Added console logging for timezone fetch process
- Comprehensive test suite for timezone handling and streak logic

**UI improvements:**
- Share text uses 📜 emoji for logged-in users, 📖 for anonymous
- Stats link now includes timezone parameter for accurate display

This ensures users worldwide see the correct daily verse for their local
date, and streaks are calculated based on their timezone, not server time.

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-02-12 23:37:08 -05:00
George Powell f6652e59a7 fixed weird signin bug 2026-02-12 20:24:38 -05:00
George Powell df8a9e62bb Add staggered page load animations
Implement elegant fadeInUp animations with staggered delays for main page
elements to create a polished, progressive reveal effect on page load.

Changes:
- layout.css: Added fadeInUp keyframes and delay utility classes
  (200ms, 400ms, 600ms, 800ms)
- +page.svelte: Applied animations to title, date, verse display,
  search input, guesses table, and credits

Animation sequence:
1. Title (0ms)
2. Date + Verse Display (200ms)
3. Search Input (400ms)
4. Guesses Table (600ms)
5. Credits (800ms - when won)

Creates a smooth, professional page load experience without changing any
existing design or functionality.

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-02-11 17:24:14 -05:00
George Powell 730b65201a Redesign stats page with dark theme and enhanced statistics
- Implement dark gradient background with glassmorphism cards
- Add new statistics: worst day, best book, most seen book, unique books by testament
- Design mobile-first responsive grid layout with optimized spacing
- Update Container component to support dark theme (bg-white/10, border-white/20)
- Calculate book-specific stats by linking completions to daily verses
- Improve visual hierarchy with icons and color-coded stat cards

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-02-11 13:01:53 -05:00
George Powell 78440cfbc3 Fix infinite stats submission and improve mobile button layout
- Fix infinite loop in stats submission effect by adding statsData to early return condition
- Make bottom buttons (View Stats, Sign In/Out) full-width on small screens
- Buttons now stack vertically on mobile, side-by-side on medium+ screens

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-02-10 21:05:10 -05:00
George Powell 342bd323a1 Merge branch 'main' into auth
Brought in latest changes from main including:
- RSS feed implementation
- First letter edge case fixes
- Updated ranking formula

Resolved conflicts by:
- Combining .env.example variables from both branches
- Keeping auth version (3.0.0alpha)
- Preserving extended user schema from auth
- Keeping onMount umami approach and adding RSS feed link

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-02-09 12:03:31 -05:00
George Powell 06ff0820ce Implement anonymous stats migration on signin
- Fix AuthModal to pass anonymousId on both signin and signup
- Add comprehensive migration logic in signin that moves anonymous completion stats to authenticated user
- Implement deduplication algorithm to handle overlapping completion dates
- Maintain earliest completion when duplicates exist

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2026-02-05 18:49:14 -05:00
George Powell b1591229ba Move UI controls to bottom and require authentication for stats
- Moved stats button, auth buttons, and debug info to bottom of main page
- Added authentication requirement for /stats route
- Show login prompt for unauthenticated users accessing stats
- Include AuthModal for sign in/sign up from stats page

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2026-02-05 17:57:29 -05:00
George Powell 96024d5048 Support authenticated users in stats and page loading 2026-02-05 17:46:53 -05:00
George Powell 86f81cf9dd Use user ID for umami identify when authenticated 2026-02-05 17:46:14 -05:00
George Powell dfe1c40a8a switched to bun:sqlite 2026-02-05 00:47:55 -05:00
George Powell 7d93ead70c added demo stats page (needs refinement) 2026-02-04 23:35:23 -05:00
George Powell 4c82aa078b added identifying with umami anonymous ID 2026-02-03 23:43:03 -05:00
George Powell 2058149207 delayed loading of umami tracker script until page is already
interactive
2026-02-03 00:18:11 -05:00
George Powell 3947e8adb0 rss improvements 2026-02-02 02:52:53 -05:00
George Powell 244113671e created rss feed 2026-02-02 02:07:12 -05:00
George Powell f7ec0742e1 fixed "first letter" clue edge cases 2026-02-02 01:27:12 -05:00
George Powell d797b980ea updated ranking formula 2026-02-02 00:48:35 -05:00
George Powell d21ca9d687 add percentile stats, update chapter guess UI 2026-01-28 23:03:51 -05:00
George Powell fe9cc09df6 added test dev buttons and email button 2026-01-28 16:02:52 -05:00
George Powell 55a9fd59ea fixed some epistle bugs with firstLetter, maybe. and wording 2026-01-28 15:15:40 -05:00
George Powell 0ee3d8a4d0 Revamped middle statline (ranking instead of arbitrary percentage) 2026-01-28 15:04:29 -05:00
George Powell 8c488d27df add First Letter column with special epistle handling 2026-01-26 23:31:24 -05:00
George Powell cec85be7c9 feat: Add Imposter game component and update project assets 2026-01-26 00:25:51 -05:00
George Powell 1b1bc7bd3c Added chapter guess challenge 2026-01-04 16:36:28 -05:00
George Powell 0f6870344f major styling and spacing 2026-01-04 01:25:49 -05:00
George Powell a91a5af014 Merge github/main into embeddings 2025-12-30 15:34:03 -05:00
George Powell a83039a6a2 style changes 2025-12-30 15:21:18 -05:00
George Powell 2b7682684a fixed sloppy umami events 2025-12-27 11:50:35 -05:00
George Powell c71170e6b3 added first-guess and correct-guess umami event tracking 2025-12-27 11:42:15 -05:00
George Powell 54c7e3cdbb Visual fixes, typo fixes, and updated todo + metadata 2025-12-27 00:48:06 -05:00
George Powell 0daefcb080 created embeddings 2025-12-26 00:33:16 -05:00
George Powell d8cff2ff7a fixed "1 guess" on results 2025-12-25 00:56:49 -05:00
George Powell 704a4e1996 fixed dev divider 2025-12-24 01:05:57 -05:00
George Powell 1edaec4bdd spacing change 2025-12-23 22:59:51 -05:00
George Powell 0e3505b8e7 Added greek bible and centered title correctly and added date 2025-12-23 22:56:46 -05:00
George Powell f9f0928278 switched to NKJV, improved grading, improved styling 2025-12-23 17:33:33 -05:00
George Powell 93acafc232 add fade-in animations and conditional rendering to GuessesTable 2025-12-23 01:10:33 -05:00
George Powell 2e7cc1fa54 silly little BIBDLE title animation 2025-12-23 00:32:22 -05:00
George Powell 77a40e9b48 SEO 2025-12-21 19:38:27 -05:00
George Powell 5999221b8f v2.1: stylistic updates & countdown timer 2025-12-21 18:24:38 -05:00
George Powell 0d50ff5f27 i forhor 2025-12-19 03:36:59 -05:00
George Powell 68a946a0a0 redirect to bibdle.dev and components 2025-12-19 02:53:45 -05:00
George Powell d052bd21f2 fixed share, added crossed out options 2025-12-17 13:38:21 -05:00
George Powell 2979a25129 v2.01 style change 2025-12-16 20:52:18 -05:00
George Powell 32a078dd98 v2 2025-12-16 20:44:52 -05:00