Merge lp:~rharding/launchpad/info_type_events into lp:launchpad
Status: | Merged |
---|---|
Approved by: | Aaron Bentley |
Approved revision: | no longer in the source branch. |
Merged at revision: | 16037 |
Proposed branch: | lp:~rharding/launchpad/info_type_events |
Merge into: | lp:launchpad |
Diff against target: |
659 lines (+357/-85) 9 files modified
lib/lp/app/javascript/banners/banner.js (+24/-20) lib/lp/app/javascript/banners/beta-notification.js (+53/-33) lib/lp/app/javascript/banners/privacy.js (+104/-20) lib/lp/app/javascript/banners/tests/test_privacy.html (+2/-3) lib/lp/app/javascript/banners/tests/test_privacy.js (+32/-3) lib/lp/app/javascript/information_type.js (+63/-0) lib/lp/app/javascript/tests/test_information_type.js (+75/-0) lib/lp/blueprints/browser/specification.py (+2/-4) lib/lp/bugs/javascript/filebug.js (+2/-2) |
To merge this branch: | bzr merge lp:~rharding/launchpad/info_type_events |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Aaron Bentley (community) | Approve | ||
Review via email: mp+126317@code.launchpad.net |
Commit message
Add events to information_type and privacy banner to drive usage.
Description of the change
= Summary =
This is the first of a series of branches to update the PrivacyBanner to be
event driven. The end goal is that the information type changes at the widget
level will fire global events that will update the banner appropriately.
== Pre Implementation ==
Talked with JC about how things currently worked.
== Implementation Notes ==
This branch includes some general cleanup and linting. Sorting ATTRS into
alphabetical order, moving functions up above the class definitions.
It also includes one drive by import warning around #636 of the diff.
This adds published events to the information_type module. Currently, these
are not fired in real code, but tests are added that you can fire an event
that the information type has changed, and it'll determine if the new value is
public or private and fire a secondary event with that info.
It also adds logic and events to the PrivacyBanner. It watches for changes to
the information type so that it can know if it should show/hide. PrivacyBanner
is also used for security notification so it needs manual events so that when
something is a security issue, it can be told to show, but with a custom
message and nothing to do with information type itself.
== Tests ==
test_informatio
test_privacy.html