brave / brave-browser

Brave browser for Android, iOS, Linux, macOS, Windows.
https://brave.com
Mozilla Public License 2.0
17.54k stars 2.27k forks source link

initial notification to try Brave Rewards if user is not opted in #1439

Closed LaurenWags closed 5 years ago

LaurenWags commented 5 years ago

Description

Per discussion with @NejcZdovc - logging a tracking issue for initial notification to try Brave Rewards.

From the spec: "If a user is not opted into Brave Rewards, they will see a red notification notifier on the Brave Rewards icon in the URL bar with a “1” indicating that they should click on it. This in turn brings up the panel in its initial state, which is asking that a user opt in. As soon as the panel has been opened, the notification has been viewed and the “1” in the red circle disappears."

Steps to Reproduce

  1. Clean profile or upgrade profile without Brave Payments enabled.
  2. There should be a 1 in a red bubble on the BAT logo on the URL bar.
  3. Clicking on the logo should show the initial panel.
  4. Once the panel is opened the notification is considered viewed and should be removed.
LaurenWags commented 5 years ago

Verified passed on macOS

Brave 0.58.11 Chromium: 71.0.3578.80 (Official Build) beta(64-bit)
Revision 2ac50e7249fbd55e6f517a28131605c9fb9fe897-refs/branch-heads/3578@{#860}
OS Mac OS X

Verification passed on

Brave 0.58.11 Chromium: 71.0.3578.80 (Official Build) beta (64-bit)
Revision 2ac50e7249fbd55e6f517a28131605c9fb9fe897-refs/branch-heads/3578@{#860}
OS Windows

Verification passed on 17.10

Brave 0.58.14 Chromium: 71.0.3578.98 (Official Build) (64-bit)
Revision 15234034d19b85dcd9a03b164ae89d04145d8368-refs/branch-heads/3578@{#897}
OS Linux
srirambv commented 5 years ago

This has a different behaviour on Linux. When a clean profile is launched, it flashes the initial notification on the badge and then its removed. Console logs the error

[14157:14157:1212/143847.708418:ERROR:x11_input_method_context_impl_gtk.cc(144)] Not implemented reached in virtual void libgtkui::X11InputMethodContextImplGtk::SetSurroundingText(const base::string16 &, const gfx::Range &)
[14157:14173:1212/143849.455952:ERROR:rewards_service_impl.cc(141)] Failed to read file: /home/sriram/.config/BraveSoftware/Brave-Browser-Beta/Default/ledger_state

Clicking on the BAT logo then brings up the notification and closing and restarting browser still retains the notification icon Recording here: https://drive.google.com/open?id=1Ydf691x6IAekcUcG0BC5FxHzIYt3Nkav