Skip to content

Find Twitch's chat identity button, which is not called identity - #23

Merged
JRBlaze merged 1 commit into
mainfrom
twitch-chat-identity
Aug 29, 2026
Merged

Find Twitch's chat identity button, which is not called identity#23
JRBlaze merged 1 commit into
mainfrom
twitch-chat-identity

Conversation

@JRBlaze

@JRBlaze JRBlaze commented Aug 29, 2026

Copy link
Copy Markdown
Owner

The Chat identity chip never appeared on Twitch. Two guesses had to be right for it to work, and both were wrong.

Twitch does not call it identity. The control is the badge carousel: data-a-target="chat-badge-carousel-badge-icon", accessible name ChatBadgeCarousel. The word "identity" appears nowhere on the page, so a search for it found nothing.

It is not in the buttons container. Cheer, the emote picker, the balances, the settings gear and Send all live in .chat-input__buttons-container — the only place this looked. The badge carousel sits beside them in the .chat-input row, outside that container. Confirmed on a signed-in page: inButtonsContainer: false.

Both facts are now read off a real signed-in channel page rather than guessed, and the harness markup was rewritten to match it, so the same miss cannot happen quietly again.

Kick

Kick was already working and still resolves the identical button — checked against a live page, the old selector and the new one return the same element (sameElement: true).

It is pinned to the exact badge anyway. Kick gives every badge in chat an identity-badge-* test id and names two of its icons ...Badge (VerifiedBadge, ModeratorBadge), so the loose *identity* match worked only because the footer happens to contain exactly one of them today. The exact test id and the exact icon name cannot be hijacked by a second one appearing.

Tests

New chatidentity suite builds each platform's real markup and asserts the adapter finds that control, never returns the send button, and offers nothing at all on a page that is not showing one. 1369 passing.

🤖 Generated with Claude Code

The chip never appeared on Twitch. Two guesses had to be right for it to work
and both were wrong:

- Twitch does not call it identity. The control is the badge carousel, and its
  only names are `data-a-target="chat-badge-carousel-badge-icon"` and an
  accessible name of "ChatBadgeCarousel". Searching for the word "identity"
  found nothing on the page at all.
- It is not in the buttons container. Cheer, the emote picker, the balances,
  the settings gear and Send all live in `.chat-input__buttons-container`, which
  is the only place this looked. The badge carousel sits beside them in the
  `.chat-input` row, outside that container.

Both are now taken from a signed-in channel page rather than guessed, and the
harness markup is the real markup so the fault cannot come back unnoticed.

Kick was already working and still resolves the identical button — checked
against a live page, old selector and new selector return the same element. It
is pinned to the exact badge anyway: Kick gives every badge in chat an
`identity-badge-*` test id and names two icons `...Badge`, so the loose match
that worked did so only because the footer happens to hold one of them today.

The new suite builds each platform's real markup and asserts the adapter finds
that control, refuses the send button, and offers nothing on a page that is not
showing one.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@JRBlaze
JRBlaze merged commit 3fd50c2 into main Aug 29, 2026
3 checks passed
@JRBlaze
JRBlaze deleted the twitch-chat-identity branch August 29, 2026 05:55
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.

1 participant