Uploaded image for project: 'Plugins'
  1. Plugins
  2. CONTRIB-6815

Radio response buttons pushed left on individual response display

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • 3.2.3
    • 3.2
    • Module: Questionnaire
    • None

      _Originally raised on Github - https://github.com/remotelearner/moodle-mod_questionnaire/issues/83_

      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!

            mchurch Mike Churchward
            mchurch Mike Churchward
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.