XF 2.2 adding multiple titles to elements within same xf:button

KSA

Well-known member
I am trying to add a title for data-sk-follow and another title for data-sk-unfollow but struggled to do that. Here is my code, any advice would be much appreciated

HTML:
<xf:if is="$user is not empty AND $xf.visitor.canFollowUser($user)">
                <xf:button href="{{ link('members/follow', $user) }}"
                    class="button--link"
                    data-xf-click="switch"
                    data-sk-follow= "addClass:fa-bell,removeClass:fa-bell-slash,"
                    data-sk-unfollow="addClass:fa-bell-slash,removeClass:fa-bell,"
                    class="fa fa-bell {{ $xf.visitor.isFollowing($user) ? 'fa fa-bell-slash': '' }}">
                </xf:button>
      </xf:if>
 
Top Bottom