Completed the basic UX behavior of the panels finally!
Made hideIntroPanel method generic to hidePanel, so it can be used for both the intro panel and the pageAction panel, which are really the same <panel> with the same <browser> element with different src values.
Log and send telemetry pings when buttons are pressed and panels are dismissed.
Also I differentiated the "dismiss" behavior between the intro panel and the pageAction panel:
Intro <panel> uses noautohide set to true.
pageAction <panel> uses noautohide set to false.
Rationale:
The intro panel has stickier behavior (noautohide = true), since it can be dismissed from a button in the panel itself, and it only shows once and then goes away forever. As a result, I have to manually close it via panel.hidePopup on window-close, tab-change, location-change-same-tab
By contrast, the pageAction panel can be accessed any time by clicking the pageAction icon, and it has no button to dismiss it in the panel (only a button to disable Tracking Protection), so it has a behavior of noautohide = false.
TODO:
Add dynamic data and correct strings based on branch.
Completed the basic UX behavior of the panels finally!
Made
hideIntroPanel
method generic tohidePanel
, so it can be used for both the intro panel and the pageAction panel, which are really the same<panel>
with the same<browser>
element with differentsrc
values.Log and send telemetry pings when buttons are pressed and panels are dismissed.
Also I differentiated the "dismiss" behavior between the intro panel and the pageAction panel:
<panel>
usesnoautohide
set totrue
.<panel>
usesnoautohide
set tofalse
. Rationale: The intro panel has stickier behavior (noautohide = true), since it can be dismissed from a button in the panel itself, and it only shows once and then goes away forever. As a result, I have to manually close it viapanel.hidePopup
on window-close, tab-change, location-change-same-tab By contrast, the pageAction panel can be accessed any time by clicking the pageAction icon, and it has no button to dismiss it in the panel (only a button to disable Tracking Protection), so it has a behavior of noautohide = false.TODO: