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

Undefined box-sizing couses scrollbar for command bar

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 3.3.2
    • 3.5
    • Module: Scheduler
    • None
    • 3.3.0
    • MOODLE_33_STABLE
    • MOODLE_35_STABLE

    Description

      The commandbar is defined with a width of 100% and a padding of .5em. Browsers as Firefox and Chrome use a box-sizing model "content-box" as default. In this model padding and border are added to the defined width of the element, which results in a width of over 100% and (depending on the theme) will lead to ugly horizontal scrollbars.

      I would suggest adding the following lines to the rule

      .path-mod-scheduler div.commandbar {
          width: 100%;
          margin-left: auto;
          margin-right: auto;
          background-color: #eee;
          padding: 0.5em;
      +    box-sizing: border-box;
      +    -moz-box-sizing: border-box;
      +    -webkit-box-sizing: border-box;
      }

      This forces a display with the box model "border-box". In this model the width includes padding and border.

      Attachments

        Activity

          People

            bostelm Henning Bostelmann
            tobias.reischmann Tobias Reischmann
            Valery Fremaux
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              17/May/18