-
Notifications
You must be signed in to change notification settings - Fork 40
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature/round of frontend cleanup #1641
Conversation
Codecov Report
@@ Coverage Diff @@
## develop #1641 +/- ##
===========================================
- Coverage 79.4% 79.33% -0.08%
===========================================
Files 46 45 -1
Lines 3297 3271 -26
Branches 497 493 -4
===========================================
- Hits 2618 2595 -23
+ Misses 679 676 -3
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ran this locally and spotted two unexpected things. Though they could be due to an error in my setup, so would appreciate help double-checking.
First, on the /data
section, there's a DEVELOPMENT banner that's not appearing for other sections of the site.
Second the raising/spending overview data visualizations disappeared. This may be due to an error in running my local env, but I'm suspicious of that because the API seems to be connected and populating everything else just fine.
fec/data/templates/landing.jinja
Outdated
@@ -327,7 +327,5 @@ | |||
{% block scripts %} | |||
<script src="{{ asset_for_js('dataviz-common.js') }}"></script> | |||
<script src="{{ asset_for_js('landing.js') }}"></script> | |||
<script> | |||
TOUR_PAGE = 'campaign-finance-data'; | |||
</script> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Was this closing <script>
supposed to get deleted too?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oof, good catch! Should have removed closing tag too.
|
I tested this locally as well and came across a couple of things so far: In the About section of the top nav menu, when you click on Working with the FEC, you're taken to the bottom of the page, but the menu on the left stays stuck at the top of the screen, so if you scroll up, it looks like this: In the Legal section of the top nav menu, clicking on Court Cases takes you to that page and the menu stays in place when you click and scroll around the page - is this expected? All that said, most of the code changes themselves are okay as far as I can tell now! |
@ccostino: thanks for bringing up those bugs! so I realized the way I was "fixing" overscrolling caused weirdness on any sticky elements, including those side nav bars. So I found another solution that will still successfully hide glossary from overscrolling but doesn't touch the overflow settings of |
Thanks, @xtine! Things look okay to me now in poking around, but will do a final code review again too. :-) @lbeaufort, please feel free to take a look and review too! |
Ah, @xtine I did find a thing that removing the sticky component broke: the left-hand-side jump menu, as seen on https://www.fec.gov/help-candidates-and-committees/filing-reports/ |
The left sticky component shouldn’t be affected with my latest change. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank very much, @xtine!
Summary
This is a round of front end cleanup/refactoring on JavaScript initialization files and modules.
tour__point
classes that contained tour tooltip content andTOUR_PAGE
JS global variablescms_url
andwebAppUrl
now that we can directly reference relative pathsStickyBar
module that is not being used anymore (was previously used on election page before redesign)between-commitees.jinja
template. https://github.com/18F/fec-cms/issues/1632landing.js
todata-landing.js
to be more specific that it is JS for the landing page of the data section.reaction-box.js
Impacted areas of the application
List general components of the application that this PR will affect:
Screenshots
Fixes this overscrolling issue: