Skip to content

Conversation

@cameronapak
Copy link
Collaborator

Ticket: https://lifechurch.atlassian.net/browse/YPE-1000

The default Bible version for the VerseOfTheDay component has been updated from KJV (version ID 1) to NIV (version ID 111). This change reflects the new required default version for the application.

Mock data and handlers have been updated to reflect the new default version.

I accidentally borked #92 so this is a re-do of it...

The default Bible version for the VerseOfTheDay component has been
updated from KJV (version ID 1) to NIV (version ID 111). This change
reflects the new required default version for the application.

Mock data and handlers have been updated to reflect the new default
version.
@chatgpt-codex-connector
Copy link

Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits.
Credits must be used to enable repository wide code reviews.

@changeset-bot
Copy link

changeset-bot bot commented Jan 9, 2026

⚠️ No Changeset found

Latest commit: 9b95eec

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Greptile Overview

Greptile Summary

This PR updates the default Bible version for the VerseOfTheDay component from KJV (version ID 1) to NIV (version ID 111) as requested in ticket YPE-1000.

Changes Made

  1. Component Default: Updated the versionId prop default from 1 to 111 in the VerseOfTheDay component
  2. Documentation: Updated JSDoc comments and inline comments to reflect NIV as the default
  3. Test Expectations: Modified the Storybook integration test to expect "Isaiah 43:19 NIV" instead of "KJV"
  4. Mock Data: Updated the Isaiah 43:19 passage mock to use version_id: 111
  5. Mock Handlers:
    • Updated the Isaiah passage handler URL from /v1/bibles/1/passages/ISA.43.19 to /v1/bibles/111/passages/ISA.43.19
    • Removed the unused /v1/bibles/1 handler for fetching version metadata

Consistency

The changes are well-coordinated across the codebase:

  • Component default aligns with mock data
  • Test expectations match the new default
  • Mock handlers properly serve the new version

The remaining handlers for version 1 (/v1/bibles/1/books and chapter endpoints) are intentionally preserved as they're still used by other components or tests in the codebase.

Confidence Score: 5/5

  • Safe to merge - straightforward default value change with complete test and mock updates
  • The PR is a clean, focused change that updates a default parameter value. All related tests, mock data, and handlers have been updated consistently. The changes are isolated to the VerseOfTheDay component and its test infrastructure. No breaking changes are introduced since users can still override the versionId prop if needed.
  • No files require special attention

Important Files Changed

File Analysis

Filename Score Overview
packages/ui/src/components/verse-of-the-day.tsx 5/5 Updated default versionId from 1 (KJV) to 111 (NIV) in component props and documentation
packages/ui/src/components/verse-of-the-day.stories.tsx 5/5 Updated test expectation to verify NIV instead of KJV in shared text
packages/ui/src/test/mock-data/passages.json 5/5 Updated Isaiah 43:19 passage mock data to use version_id 111 (NIV) instead of 1 (KJV)
packages/ui/src/test/mocks/handlers.ts 4/5 Updated Isaiah passage handler to use version 111 and removed unused version 1 handler, but kept version 1 handlers for books/chapters

Sequence Diagram

sequenceDiagram
    participant Component as VerseOfTheDay Component
    participant Hook as useVerseOfTheDay Hook
    participant API as Bible API
    participant Handler as Mock Handler
    
    Note over Component: versionId = 111 (NIV)<br/>Previously: 1 (KJV)
    
    Component->>Hook: Request VOTD for day
    Hook->>API: GET /v1/verse_of_the_days/{day}
    API-->>Hook: {passage_id: "ISA.43.19"}
    
    Component->>API: GET /v1/bibles/111/passages/ISA.43.19
    Note over Handler: Updated from /v1/bibles/1/...
    Handler-->>API: Return NIV passage data
    API-->>Component: Isaiah 43:19 content
    
    Component->>API: GET /v1/bibles/111
    Handler-->>API: Return NIV version metadata
    API-->>Component: {localized_abbreviation: "NIV"}
    
    Note over Component: Displays "Isaiah 43:19 NIV"<br/>Previously: "Isaiah 43:19 KJV"
Loading

@bmanquen bmanquen merged commit 155d103 into main Jan 9, 2026
5 checks passed
@bmanquen bmanquen deleted the cam/YPE-1000 branch January 9, 2026 20:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants