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

Add support FrankerFaceZ badges. #2101

Merged
merged 10 commits into from Oct 25, 2020
Merged

Conversation

Mm2PL
Copy link
Collaborator

@Mm2PL Mm2PL commented Oct 20, 2020

Pull request checklist:

  • CHANGELOG.md was updated, if applicable

Description

Add support for FrankerFaceZ badges, partially solving #1658 (issue requested BTTV too).

Changes

  1. Introduce badge provider,
  2. Refactor MessageElementFlags to be int64_t instead of int as there wasn't space for a new flag there,
  3. Add MessageElementFlag::BadgeFfz,
  4. Create showBadgesFfz (/appearance/badges/ffz) setting, default is true,
  5. Introduce checkbox for the showBadgesFfz setting,
  6. Add a MessageLayoutElement for ffz badges, to color them properly.

    - introduce badge provider,
    - (sadly) refactor `MessageElementFlag`s to be `int64_t` instead of `int`,
    - introduce `MessageElementFlag::BadgeFfz`,
    - introduce showBadgesFfz (`/appearance/badges/ffz`) setting, default is true,
    - introduce checkbox for showBadgesFfz,
Copy link
Collaborator

@ALazyMeme ALazyMeme left a comment

Choose a reason for hiding this comment

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

As discussed, the default ffz badge should have a background (#755000) to match the default style. Otherwise the badge shows just fine.
Web Chat:
FFZ Badge Webchat

Chatterino:
FFZ Badge Chatterino

@Mm2PL
Copy link
Collaborator Author

Mm2PL commented Oct 21, 2020

As discussed, the default ffz badge should have a background (#755000) to match the default style. Otherwise the badge shows just fine.

@ALazyMeme solved in f0231d0

@Mm2PL
Copy link
Collaborator Author

Mm2PL commented Oct 21, 2020

@pajlada, could you please review this PR? 🙂

Copy link
Member

@pajlada pajlada left a comment

Choose a reason for hiding this comment

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

Looks good from a quick review, will test in weekend

Copy link
Collaborator

@ALazyMeme ALazyMeme left a comment

Choose a reason for hiding this comment

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

Just based on the functionality alone, this works fine.

src/providers/ffz/FfzBadges.cpp Outdated Show resolved Hide resolved
src/providers/ffz/FfzBadges.cpp Outdated Show resolved Hide resolved
src/providers/ffz/FfzBadges.cpp Outdated Show resolved Hide resolved
src/providers/ffz/FfzBadges.cpp Outdated Show resolved Hide resolved
src/providers/ffz/FfzBadges.cpp Outdated Show resolved Hide resolved
src/providers/ffz/FfzBadges.cpp Outdated Show resolved Hide resolved
src/providers/ffz/FfzBadges.cpp Outdated Show resolved Hide resolved
src/providers/ffz/FfzBadges.hpp Outdated Show resolved Hide resolved
@Mm2PL
Copy link
Collaborator Author

Mm2PL commented Oct 24, 2020

@pajlada, 🔔 suggestions done, merge conflicts resolved. It's ready to merge. 🙂

@ALazyMeme
Copy link
Collaborator

PAJJED Merge it

@pajlada pajlada merged commit 3ee08b9 into Chatterino:master Oct 25, 2020
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.

None yet

4 participants