Clanbite Social Kit

clanbite_social_kit_reaction_icon( array $type, string $css_class = '' ): string

Markup for one reaction's icon: the same glyph everywhere a reaction appears (picker, summary, tooltip, action button).

A reaction type is rendered from its icon_url when it has one, otherwise from its emoji, so a reaction added by a third party or extension plugin looks identical in the selector and once selected. Use this for server-rendered lists of reaction types (pickers); use clanbite_social_kit_reaction_icon_bound() inside Interactivity templates.

Namespace: Kernowdev\ClanbiteSocialKit

Parameters

$type (array<string, mixed>) Required

Reaction definition (slug, label, emoji, optional icon_url).

$css_class (string) Optional

CSS class for the wrapper element (context sizing hook).

Default: ''

Returns

string Escaped HTML.

Defined in inc/functions.php