Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(Pi Fansubs): Movie or TV Show as activity name #9372

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

Kuriel23
Copy link
Contributor

@Kuriel23 Kuriel23 commented Mar 6, 2025

Description

Resolves #9366

Acknowledgements

Screenshots

Proof showing the creation/modification is working as expected

image

presenceData.largeImageKey = getImage(
'.mark-1 > div:nth-child(1) > img:nth-child(1)',
)
presenceData.details = 'No Pi Fansubs'
// eslint-disable-next-line regexp/no-unused-capturing-group
Copy link
Member

Choose a reason for hiding this comment

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

Do not ignore eslint rules unless necessary

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I need this regex

Copy link
Member

Choose a reason for hiding this comment

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

Could you remove the unused capturing groups?

/: \d+x\d+/

@Timeraa Timeraa requested a review from Copilot March 9, 2025 18:23
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

PR Overview

This PR addresses issue #9366 by updating the activity name handling for Pi Fansubs, specifically for movies and TV shows. Key changes include:

  • Importing getTimestamps from premid and replacing presence.getTimestamps calls.
  • Replacing the assignment of presenceData.state/details with presenceData.name and a constant details string.
  • Adjusting regex logic for TV series activity naming.

Reviewed Changes

File Description
websites/P/Pi Fansubs/presence.ts Updated activity properties for movie and TV show presentations

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

Comments suppressed due to low confidence (1)

websites/P/Pi Fansubs/presence.ts:128

  • A constant assignment for details may lead to confusion in future updates. Verify that this static value meets design requirements or consider a more informative assignment.
presenceData.details = 'No Pi Fansubs'

presenceData.largeImageKey = getImage('.poster > img:nth-child(1)')
presenceData.details = 'No Pi Fansubs'
Copy link
Preview

Copilot AI Mar 9, 2025

Choose a reason for hiding this comment

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

Using a constant string for details may not provide meaningful information for the activity. Consider using a more descriptive or dynamic value to clarify the activity's context.

Suggested change
presenceData.details = 'No Pi Fansubs'
presenceData.details = textContent('.sheader > div:nth-child(2) > h1:nth-child(1)') || 'No Pi Fansubs'

Copilot is powered by AI, so mistakes are possible. Review output carefully before use.

Positive Feedback
Negative Feedback

Provide additional feedback

Please help us improve GitHub Copilot by sharing more details about this comment.

Please select one or more of the options
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.

Pi Fansubs - Show the bl title as the activity name
2 participants