Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-62359

moodleform addGroup separator does not work same as in previous version

XMLWordPrintable

      While updating plugins used at moodle.org for moodle 3.5, I have discovered a regression in the Boost theme.

      I have a form code like this:

          public function definition() {
              
              $mform = $this->_form;
              
              $mform->addGroup([
                  $mform->createElement('checkbox', 'foo1', null, 'Foo1'),
                  $mform->createElement('checkbox', 'foo2', null, 'Foo2'),
                  $mform->createElement('checkbox', 'foo3', null, 'Foo3'),
              ], 'foos', 'Select foos', '<br>', false);
          }
      

      In Clean theme and in Boost 3.4, the checkbox elements are displayed as stacked vertically, using the <br> as the separator.

      In Boost 3.5 however, the separator seems to be ignored and the items are displayed next to each other.

      Steps to reproduce

      1. Go to a course and turn editing mode on
      2. Add a new SCORM activity
      3. Expand the Appearance section
      4. Click "Show more..." link
      5. Observe the checkbox options for the "Options (Prevented by some browsers)" field

      Expected behaviour: Options are supposed to be stacked vertically

      Actual behaviour: Options are displayed next to each other

        1. screenshot-1-moodle34.png
          19 kB
          David Mudrák (@mudrd8mz)
        2. screenshot-2-moodle35.png
          21 kB
          David Mudrák (@mudrd8mz)
        3. screenshot-3-scorm35.png
          17 kB
          David Mudrák (@mudrd8mz)

            basbrands Bas Brands
            mudrd8mz David Mudrák (@mudrd8mz)
            David Mudrák (@mudrd8mz) David Mudrák (@mudrd8mz)
            Andrew Lyons Andrew Lyons
            Mark Nelson Mark Nelson
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved:

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