Skip to content

Commit f242053

Browse files
committed
Hide subscribe/subscribed text on toggle
Signed-off-by: Matt Friedman <maf675@gmail.com>
1 parent a67d419 commit f242053

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

styles/all/template/event/notification_dropdown_footer_after.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@
22
<div class="wpn-notification-dropdown-footer" title="{{ lang('NOTIFY_WEBPUSH_DROPDOWN_TITLE') }}">
33
<span class="ellipsis-text">{{ lang('NOTIFY_WEBPUSH_ENABLE') ~ lang('COLON') }}</span>
44
<button id="subscribe_webpush" name="subscribe_webpush" data-l-err="{{ lang('INFORMATION') }}" data-l-msg="{{ lang('NOTIFY_WEBPUSH_DENIED') }}">
5-
<i class="icon fa-toggle-off fa-fw icon-lightgray"></i><span>{{ lang('NOTIFY_WEBPUSH_SUBSCRIBE') }}</span>
5+
<i class="icon fa-toggle-off fa-fw icon-lightgray" aria-hidden="true" title="{{ lang('NOTIFY_WEBPUSH_SUBSCRIBE') }}"></i>
66
</button>
77
<button id="unsubscribe_webpush" name="unsubscribe_webpush" class="hidden">
8-
<i class="icon fa-toggle-on fa-fw icon-blue"></i><span>{{ lang('NOTIFY_WEBPUSH_SUBSCRIBED') }}</span>
8+
<i class="icon fa-toggle-on fa-fw icon-blue" aria-hidden="true" title="{{ lang('NOTIFY_WEBPUSH_SUBSCRIBED') }}"></i>
99
</button>
1010
</div>
1111
{% endif %}

tests/functional/functional_test.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,8 +105,8 @@ public function test_dropdown_subscribe_button()
105105
// Assert subscribe dropdown is present
106106
$crawler = self::request('GET', 'index.php');
107107
$this->assertCount(1, $crawler->filter('.wpn-notification-dropdown-footer'));
108-
$this->assertContainsLang('NOTIFY_WEBPUSH_SUBSCRIBE', $crawler->filter('.wpn-notification-dropdown-footer #subscribe_webpush')->text());
109-
$this->assertContainsLang('NOTIFY_WEBPUSH_SUBSCRIBED', $crawler->filter('.wpn-notification-dropdown-footer #unsubscribe_webpush')->text());
108+
$this->assertContainsLang('NOTIFY_WEBPUSH_SUBSCRIBE', $crawler->filter('.wpn-notification-dropdown-footer #subscribe_webpush')->html());
109+
$this->assertContainsLang('NOTIFY_WEBPUSH_SUBSCRIBED', $crawler->filter('.wpn-notification-dropdown-footer #unsubscribe_webpush')->html());
110110

111111
// Assert subscribe button is not displayed in UCP when dropdown subscribe is present
112112
$crawler = self::request('GET', 'ucp.php?i=ucp_notifications&mode=notification_options');

0 commit comments

Comments
 (0)