Skip to content
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

'Rate' response radio buttons appear offset to the left when viewing individual response #83

Closed
TestValleySchool opened this issue Mar 30, 2017 · 3 comments

Comments

@TestValleySchool
Copy link

When using Moodle's base 'clean' theme, or any other bootstrap-based theme, the radio buttons shown when viewing an individual response to a "rate" question are displayed with an offset to the left.

The effect of this is that users viewing an individual response believe that the choice the respondent made was one choice further to the left.

Note that my examples here used named ranks, but this appears to be a problem with standard 1..5 ranks as well.

questionnaire_template_offset_00

In this example, the user chose Strongly agree for the first entry in the table ("Test"), and Agree for the second ("Two").

This does not match the view when answering the same question, where the buttons appear correctly:

questionnaire_template_offset_01

My brief analysis suggests that /templates/response_rate.mustache is adding the radio class of the div containing the table. https://github.com/remotelearner/moodle-mod_questionnaire/blob/MOODLE_32_STABLE/templates/response_rate.mustache#L60

The .radio input[type="radio"], .checkbox input[type="checkbox"] rule in the bootstrap CSS appears to set float: left; margin-left: -20px;.

If I remove the radio class from the div on L60 of response_rate.mustache, the radio buttons appear correctly in an individiual response.

I would submit a PR, but I'm not sure if there are other implications to removing this class!

@mchurchward
Copy link
Contributor

mchurchward commented Mar 30, 2017

Can you review https://tracker.moodle.org/browse/CONTRIB-6809? I believe this has already been fixed in the latest code in the MOODLE_32_STABLE branch, and the latest release on moodle.org.
Edit - nevermind. It looks like that fixed it in some cases, but not all.

@mchurchward
Copy link
Contributor

Thanks for the report. I have created https://tracker.moodle.org/browse/CONTRIB-6815 to deal with this.

@mchurchward
Copy link
Contributor

I have fixed the issue and released version 3.2.3 with the fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants