diff --git a/resources/assets/javascripts/lib/blubber.js b/resources/assets/javascripts/lib/blubber.js index 3e93985e493ec9878142dcf98ff6c5be4a9e751e..4e724b46cbd0f1cd2c49a691dbb02f0c644420c2 100644 --- a/resources/assets/javascripts/lib/blubber.js +++ b/resources/assets/javascripts/lib/blubber.js @@ -47,6 +47,7 @@ const Blubber = { subscribe: follow, }); }).then(() => { + elements.attr('aria-pressed', follow ? 'true' : 'false'); elements.toggleClass('unfollowed', !follow); }).finally(() => { elements.removeClass('loading'); diff --git a/templates/blubber/global_context.php b/templates/blubber/global_context.php index 77c4a2905e6a56b15abc188b47ef5c0f92e5aae0..4a524076ed32e84871b7de7f6a08e29f1708ec8b 100644 --- a/templates/blubber/global_context.php +++ b/templates/blubber/global_context.php @@ -7,6 +7,8 @@ onClick="STUDIP.Blubber.followunfollow('global'); return false;" class="followunfollow<?= $unfollowed ? " unfollowed" : "" ?>" title="<?= _("Benachrichtigungen für diese Konversation abstellen.") ?>" + aria-pressed="<?= $unfollowed ? 'false' : 'true' ?>" + role="button" data-thread_id="global"> <?= Icon::create("decline")->asImg(20, ['class' => "follow text-bottom"]) ?> <?= Icon::create("notification2")->asImg(20, ['class' => "unfollow text-bottom"]) ?>