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

Multi-language layout not supported in the view of message/notificationpreferences.php

    XMLWordPrintable

Details

    • Bug
    • Resolution: Deferred
    • Minor
    • None
    • 3.11.5
    • Messages
    • None
    • MOODLE_311_STABLE
    • Hide

      Hi! Please follow these steps:

      1. Log in to Moodle.
      2. Go to your.moodle.domain/message/notificationpreferences.php?lang=ca. Change 'your.moodle.domain' for whichever is your Moodle instance domain.
      3. Test with many different languages, at least:
        1. Spanish
        2. English
        3. French
        4. Portuguese
        5. Arabic
        6. Finnish
        7. Czech
        8. Català
      4. You should see that the table layout fits the contents from each language appropriately.
      Show
      Hi! Please follow these steps: Log in to Moodle. Go to your.moodle.domain/message/notificationpreferences.php?lang=ca. Change 'your.moodle.domain' for whichever is your Moodle instance domain. Test with many different languages, at least: Spanish English French Portuguese Arabic Finnish Czech Català You should see that the table layout fits the contents from each language appropriately.
    • 1

    Description

      Hi team! The title of this bug may sound a little bit like a feature request, but I don't think that seeing garbled text, chopped off sentences, and overlapping text in different languages counts as anything but a bug.

      The issue occurs when visiting `message/notificationpreferences.php?lang=var1` where var1 is a variable representing different languages. The one that looks consistently good is English, when `var1 == en`. Other than that, results are not predictable. In some languages it looks acceptable, and not in others. A few pictures are better than my words (the ones in the attachments were taken by a colleague of mine). The images show that this affects Boost and other themes such as Snap.

      After researching this issue, it was discovered that this table is generated with a fixed column width, which means that the width will be constant regardless of the selected language. This does not allow the table to resize itself to appropriately layout content in different languages.

      Another problem is that the help icon is placed in the same HTML element as the text. For instance, lets say it was `<div>Online help_icon</div>`, and `<div>Offline help_icon</div>`. This makes it so that the content is treated as part of the same element, which in turn means that the help icon is displayed at the end of the line. To change this, it was necessary to modify the mustache template responsible for generating each row of the table, so that the help icon is rendered in its own HTML element with its own CSS classes, so that styling can be applied separately to the help icon.

      If my QA team approves the change, I will send it here too so that your QA guys can test our proposed PR.

      Attachments

        1. tailandesSnap.jpg
          tailandesSnap.jpg
          206 kB
        2. tailandes.jpg
          tailandes.jpg
          249 kB
        3. siteVersion310.jpg
          siteVersion310.jpg
          214 kB
        4. ok.jpg
          ok.jpg
          190 kB
        5. Info icon fix.png
          Info icon fix.png
          98 kB
        6. francesSnap.jpg
          francesSnap.jpg
          201 kB
        7. frances.jpg
          frances.jpg
          253 kB

        Issue Links

          Activity

            People

              lucaboesch Luca Bösch
              julian.tovar Julian Tovar
              Votes:
              1 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - 1 day
                  1d
                  Remaining:
                  Remaining Estimate - 1 day
                  1d
                  Logged:
                  Time Spent - Not Specified
                  Not Specified

                  Clockify

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