Moodle
  1. Moodle
  2. MDL-25682

When using AJAX, iconsmall class is not added to section icons

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Trivial Trivial
    • Resolution: Fixed
    • Affects Version/s: 2.0
    • Fix Version/s: 2.0.2
    • Component/s: AJAX and JavaScript
    • Labels:
    • Affected Branches:
      MOODLE_20_STABLE
    • Fixed Branches:
      MOODLE_20_STABLE
    • Rank:
      15300

      Description

      When a user has enabled ajax and is viewing a course, the update/edit button (editing_update) is not resized.
      other icons are resized because they are re-created entirely. The updateButton is cloned from the original HTML and appended back so is never resized.

        Activity

        Hide
        Andrew Nicols added a comment -

        The cloned button(s) (e.g. update) have the field 'iconsmall' set which ensures that the icons are resized to 11x11pix.
        The newly re-created buttons (e.g. moveleft, moveright) don't.

        In the default icon themeset, the icons are dropped lower because of the missing class rather than resized.
        I think that they should have the class. Differing icon sizes gives a poor UX

        Show
        Andrew Nicols added a comment - The cloned button(s) (e.g. update) have the field 'iconsmall' set which ensures that the icons are resized to 11x11pix. The newly re-created buttons (e.g. moveleft, moveright) don't. In the default icon themeset, the icons are dropped lower because of the missing class rather than resized. I think that they should have the class. Differing icon sizes gives a poor UX
        Hide
        Andrew Nicols added a comment -

        Patch to correctly set the iconsmall class on all buttons in the section

        Show
        Andrew Nicols added a comment - Patch to correctly set the iconsmall class on all buttons in the section
        Hide
        Andrew Nicols added a comment -

        Added another icon I'd missed. This should ensure that the moveleft icon is correctly set up when indenting right and creating the moveleft icon for the first time.

        Show
        Andrew Nicols added a comment - Added another icon I'd missed. This should ensure that the moveleft icon is correctly set up when indenting right and creating the moveleft icon for the first time.
        Hide
        Andrew Nicols added a comment -

        For clarification, the larger and more recent of the two patches is the one to use. can't remove the former

        Show
        Andrew Nicols added a comment - For clarification, the larger and more recent of the two patches is the one to use. can't remove the former
        Hide
        Dan Poltawski added a comment -

        Screenshotofchange

        Show
        Dan Poltawski added a comment - Screenshotofchange
        Hide
        Dan Poltawski added a comment -

        Its quite a subtle change with the default theme. I've attached a screenshot demonstrating the problem.

        It will make more a difference for themesets with icons of different sizes.

        Show
        Dan Poltawski added a comment - Its quite a subtle change with the default theme. I've attached a screenshot demonstrating the problem. It will make more a difference for themesets with icons of different sizes.
        Hide
        Dan Poltawski added a comment -

        PULL-43 created

        Show
        Dan Poltawski added a comment - PULL-43 created
        Hide
        Eloy Lafuente (stronk7) added a comment -

        Closing as fixed. Be ready for aligned icons in hours,

        Thanks, Dan, ciao

        Show
        Eloy Lafuente (stronk7) added a comment - Closing as fixed. Be ready for aligned icons in hours, Thanks, Dan, ciao

          People

          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: