Commit Graph

15 Commits

Author SHA1 Message Date
Giulio Gratta
c3ff17a8f1 Add FA loading spinner to each problem
- This is so that if a site loads slowly users know which/how many problems they need to wait for.
- Spinner gets replaced automatically by problem content when it loads.
2018-01-19 11:28:10 -08:00
Albert St. Aubin
dbb66f8c09 Updated the problem meta to show a score of 0 and refactored/simplified the JS that build the problem meta string
TNL-5549
2016-10-21 06:40:20 -04:00
cahrens
1122c40f07 Moving ignore rules to relevant classes instead general rule.
Also replaces section with div, updates short_id, and makes textbox accessible.

TNL-5576, TNL-5575, TNL-5574, TNL-5671, TNL-5376
2016-10-06 17:35:54 -04:00
muhammad-ammar
c3b6b10478 Problem (capa) feedback UX revamp.
TNL-4877
2016-10-06 17:34:43 -04:00
Giulio Gratta
0eca0eadaf Revert "Add fa loading spinner to CAPA problems"
This reverts commit a3eb726f5f.
2016-09-20 12:56:20 -07:00
Giulio Gratta
a3eb726f5f Add font awesome loading spinner to CAPA problems
- loading spinner is automatically replaced by the content when AJAX problem_get returns
2016-09-14 14:58:35 -07:00
David Ormsbee
dbee08c721 Make Capa problems do initial load without AJAX.
Before this commit, calling the student_view on a capa problem would
cause it to render an empty placeholder <div>, wait for the
DOMContentLoaded event to be fired, and then make AJAX requests to the
the problem_get handlers to retrieve the HTML it needed to render the
actual problems. This can significantly increase the end user load
times for pages, particularly when there are many problems in a
vertical.

This commit takes a very conservative approach and has the server side
add the rendered HTML into a new data-content attribute on the <div>
enclosing the problem. When Capa's JS initialization runs, it grabs
from that data-content attribute rather than reaching over the network
for an AJAX request.

I had attempted to make it somewhat smarter and push the rendered
problem straight into the document instead of relying on the
data-content attribute. This was faster, and should be our long term
goal. However, it caused odd bugs, particularly around MathJAX
rendering, and I never quite tracked the issue down. I'm still going
forward with these changes because it's significantly better than the
current situation that students have to deal with, and we can make the
JS more performant in a future iteration.

[PERF-261]
2016-04-06 18:08:14 +05:00
David Ormsbee
b8b7327e93 Revert "Make Capa problems do initial load without AJAX."
This reverts commit 9984bbc29a.
2016-03-17 14:26:04 -04:00
David Ormsbee
9984bbc29a Make Capa problems do initial load without AJAX.
Before this commit, calling the student_view on a capa problem would
cause it to render an empty placeholder <div>, wait for the
DOMContentLoaded event to be fired, and then make AJAX requests to the
the problem_get handlers to retrieve the HTML it needed to render the
actual problems. This can significantly increase the end user load
times for pages, particularly when there are many problems in a
vertical.

This commit takes a very conservative approach and has the server side
add the rendered HTML into a new data-content attribute on the <div>
enclosing the problem. When Capa's JS initialization runs, it grabs
from that data-content attribute rather than reaching over the network
for an AJAX request.

I had attempted to make it somewhat smarter and push the rendered
problem straight into the document instead of relying on the
data-content attribute. This was faster, and should be our long term
goal. However, it caused odd bugs, particularly around MathJAX
rendering, and I never quite tracked the issue down. I'm still going
forward with these changes because it's significantly better than the
current situation that students have to deal with, and we can make the
JS more performant in a future iteration.

[PERF-261]
2016-02-26 16:15:07 -05:00
Dave St.Germain
a6797899da Removed inappropriate section tags. Because screen readers announce each section, they should not be used unless they are actually defining meaningful sections. 2014-02-05 11:32:08 -05:00
Renzo Lucioni
1fc4ac864e Add feature showing current score next to problem title 2013-07-19 16:14:24 -04:00
cahrens
26cb1c5a25 Fixes for https://edx.lighthouseapp.com/projects/102637/tickets/144 (progress tab not updating). 2013-01-29 16:30:41 -05:00
Prem Sichanugrist
8fb06ce194 Update code according to changes in 829e502 2012-07-03 14:33:24 -04:00
Calen Pennington
2011861444 Get capa problems to display from a keystore 2012-06-29 12:42:48 -04:00
Calen Pennington
5ba03130aa Moving LMS code into subdirectory 2012-06-06 14:09:01 -04:00