Skip to content

feat(BookJourney): add activity#10538

Open
quetrea wants to merge 10 commits intoPreMiD:mainfrom
quetrea:add-bookjourney-activity
Open

feat(BookJourney): add activity#10538
quetrea wants to merge 10 commits intoPreMiD:mainfrom
quetrea:add-bookjourney-activity

Conversation

@quetrea
Copy link

@quetrea quetrea commented Mar 4, 2026

Description

This PR adds a new PreMiD activity for BookJourney (bookreading.space).

What’s included

  • Added new activity files under websites/B/BookJourney:
    • metadata.json
    • presence.ts
    • assets/logo.png
    • assets/thumbnail.png
  • Presence is shown only on session routes: /s/[id].
  • Activity reads page state from the app’s DOM contract (#bookjourney-premid-state) and updates Rich Presence accordingly.
  • Implemented session states:
    • join screen
    • loading
    • active session
    • ended session
    • not found (clears activity)
  • Implemented role/queue-aware active state:
    • hosting (host/mod)
    • currently reading
    • waiting in queue with position
  • Added privacy-safe behavior:
    • for private/passcode-protected sessions, activity is generic and does not expose book/author/reader details.
  • Updated logo/thumbnail handling with valid 512x512 assets and schema-compliant URLs.

Validation

  • Activity lint/type checks pass.
  • npx pmd build BookJourney --validate passes successfully.

Acknowledgements

Screenshots

Proof showing the creation/modification is working as expected image image image

@theusaf theusaf changed the title Add BookJourney activity feat(BookJourney): add activity Mar 8, 2026
Comment on lines +15 to +16
"logo": "https://raw.githubusercontent.com/quetrea/Activities/add-bookjourney-activity/websites/B/BookJourney/assets/logo-v2.png",
"thumbnail": "https://raw.githubusercontent.com/quetrea/Activities/add-bookjourney-activity/websites/B/BookJourney/assets/thumbnail-v2.png",
Copy link
Contributor

Choose a reason for hiding this comment

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

Remove the assets from the PR. You can still use the assets using commit hash in the URL here.

Comment on lines +60 to +63
{
label: 'Open BookJourney',
url: siteUrl,
},
Copy link
Contributor

Choose a reason for hiding this comment

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

Buttons leading to home page are not allowed

quetrea and others added 2 commits March 9, 2026 03:07
- Remove assets from PR, use commit hash URLs instead
- Remove home page button (not allowed per store rules)
- Use clearActivity() instead of empty setActivity()

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@quetrea quetrea requested a review from theusaf March 9, 2026 00:19
"regExp": "^https?[:][/][/]([a-z0-9-]+[.])*bookreading[.]space[/]",
"version": "1.0.0",
"logo": "https://raw.githubusercontent.com/quetrea/Activities/821ae5755/websites/B/BookJourney/assets/logo-v2.png",
"thumbnail": "https://raw.githubusercontent.com/quetrea/Activities/821ae5755/websites/B/BookJourney/assets/thumbnail-v2.png",
Copy link
Contributor

Choose a reason for hiding this comment

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

Thumbnail should be a landscape promotional image or screenshot, not the same as the logo

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Development

Successfully merging this pull request may close these issues.

2 participants