Guruprasad has proposed merging ~lgp171188/launchpad:fix-social-accounts-class-to-not-trigger-adblocker into launchpad:master.
Commit message: Update social accounts' elements' class names The previous 'social_accounts*' class names were getting blocked by the ad blockers. Requested reviews: Launchpad code reviewers (launchpad-reviewers) For more details, see: https://code.launchpad.net/~lgp171188/launchpad/+git/launchpad/+merge/459250 -- Your team Launchpad code reviewers is requested to review the proposed merge of ~lgp171188/launchpad:fix-social-accounts-class-to-not-trigger-adblocker into launchpad:master.
diff --git a/lib/canonical/launchpad/icing/css/components/social_accounts.scss b/lib/canonical/launchpad/icing/css/components/social_accounts.scss index 8284e29..1524995 100644 --- a/lib/canonical/launchpad/icing/css/components/social_accounts.scss +++ b/lib/canonical/launchpad/icing/css/components/social_accounts.scss @@ -1,4 +1,4 @@ -.social_accounts { +.user_social_accounts { &__icon { margin-right: 0.5em; height: 1.4em; diff --git a/lib/lp/app/browser/tales.py b/lib/lp/app/browser/tales.py index 6c962ea..e2cf36c 100644 --- a/lib/lp/app/browser/tales.py +++ b/lib/lp/app/browser/tales.py @@ -3065,7 +3065,7 @@ class SocialAccountFormatterAPI(ObjectFormatterAPI): def icon(self, platform): return ( - f'<img class="social_accounts__icon" alt="{platform.title}" ' + f'<img class="user_social_accounts__icon" alt="{platform.title}" ' f'title="{platform.title}" src="/@@/{platform.icon}" />' ) diff --git a/lib/lp/app/tests/test_tales.py b/lib/lp/app/tests/test_tales.py index bbfb36b..1376d95 100644 --- a/lib/lp/app/tests/test_tales.py +++ b/lib/lp/app/tests/test_tales.py @@ -406,9 +406,10 @@ class TestSocialAccountFormatterAPI(TestCaseWithFactory): person, SocialPlatformType.MATRIX, identity ) expected_html = ( - '<img class="social_accounts__icon" alt="Matrix" title="Matrix" ' - 'src="/@@/social-matrix" /> <a href=https://matrix.to//#/@fred' - ':ubuntu.com target="_blank"><strong>@fred:ubuntu.com</strong></a>' + '<img class="user_social_accounts__icon" alt="Matrix" ' + 'title="Matrix" src="/@@/social-matrix" /> ' + "<a href=https://matrix.to//#/@fred:ubuntu.com " + 'target="_blank"><strong>@fred:ubuntu.com</strong></a>' ) self.assertEqual( diff --git a/lib/lp/registry/templates/person-portlet-contact-details.pt b/lib/lp/registry/templates/person-portlet-contact-details.pt index 66d5c65..0354913 100644 --- a/lib/lp/registry/templates/person-portlet-contact-details.pt +++ b/lib/lp/registry/templates/person-portlet-contact-details.pt @@ -172,46 +172,46 @@ </dl> </div> - <div class="yui-u social_accounts" tal:condition="view/should_show_socialaccounts_section"> + <div class="yui-u user_social_accounts" tal:condition="view/should_show_socialaccounts_section"> <dl id="social-accounts"> <dt>Social accounts:</dt> - <dd class="social_accounts__item irc_account" tal:repeat="ircnick context/ircnicknames"> - <img class="social_accounts__icon" alt="IRC" title="IRC" src="/@@/social-irc"/> + <dd class="user_social_accounts__item irc_account" tal:repeat="ircnick context/ircnicknames"> + <img class="user_social_accounts__icon" alt="IRC" title="IRC" src="/@@/social-irc"/> <span><span tal:replace="structure ircnick/fmt:formatted_displayname" /></span> <a tal:replace="structure overview_menu/editircnicknames/fmt:icon"/> </dd> - <dd class="social_accounts__item jabber_account" tal:repeat="jabberid context/jabberids"> - <img class="social_accounts__icon" alt="Jabber" title="Jabber" src="/@@/social-jabber" /> + <dd class="user_social_accounts__item jabber_account" tal:repeat="jabberid context/jabberids"> + <img class="user_social_accounts__icon" alt="Jabber" title="Jabber" src="/@@/social-jabber" /> <span><span tal:replace="jabberid/jabberid/fmt:obfuscate-email" /></span> <a tal:replace="structure overview_menu/editjabberids/fmt:icon"/> </dd> - <dd class="social_accounts__item matrix_account" tal:repeat="social_account view/matrix_accounts"> + <dd class="user_social_accounts__item matrix_account" tal:repeat="social_account view/matrix_accounts"> <span><span tal:replace="structure social_account/fmt:formatted_display" /></span> <a tal:replace="structure overview_menu/editmatrixaccounts/fmt:icon" /> </dd> <tal:irc condition="view/should_show_ircnicknames_section"> - <dd class="social_accounts__item" tal:condition="not: context/ircnicknames" id="empty-irc"> - <img class="social_accounts__icon" alt="IRC" title="IRC" src="/@@/social-irc"/> + <dd class="user_social_accounts__item" tal:condition="not: context/ircnicknames" id="empty-irc"> + <img class="user_social_accounts__icon" alt="IRC" title="IRC" src="/@@/social-irc"/> <span>No IRC nicknames registered.</span> <a tal:replace="structure overview_menu/editircnicknames/fmt:icon"/> </dd> </tal:irc> <tal:jabber condition="view/should_show_jabberids_section"> - <dd class="social_accounts__item" tal:condition="context/jabberids/is_empty" id="empty-jabber"> - <img class="social_accounts__icon" alt="Jabber" title="Jabber" src="/@@/social-jabber" /> + <dd class="user_social_accounts__item" tal:condition="context/jabberids/is_empty" id="empty-jabber"> + <img class="user_social_accounts__icon" alt="Jabber" title="Jabber" src="/@@/social-jabber" /> <span>No Jabber IDs registered.</span> <a tal:replace="structure overview_menu/editjabberids/fmt:icon" /> </dd> </tal:jabber> <tal:matrix condition="view/should_show_matrix_accounts_section"> - <dd class="social_accounts__item" tal:condition="not: view/matrix_accounts" id="empty-matrix"> - <img class="social_accounts__icon" alt="Matrix" title="Matrix" src="/@@/social-matrix" /> + <dd class="user_social_accounts__item" tal:condition="not: view/matrix_accounts" id="empty-matrix"> + <img class="user_social_accounts__icon" alt="Matrix" title="Matrix" src="/@@/social-matrix" /> <span>No matrix accounts registered.</span> <a tal:replace="structure overview_menu/editmatrixaccounts/fmt:icon" /> </dd>
_______________________________________________ Mailing list: https://launchpad.net/~launchpad-reviewers Post to : launchpad-reviewers@lists.launchpad.net Unsubscribe : https://launchpad.net/~launchpad-reviewers More help : https://help.launchpad.net/ListHelp