Skip to content

Issue 413 Reading Pane Too Narrow On Tablets

Ed Mozley edited this page Nov 20, 2026 · 1 revision

📖 #413 The reading pane was too narrow on tablets and small laptops

GitHub #413, reported by @cloudcogsio · Tickets · fixed in 5.8.0 (#3027)

What you saw

On a portrait iPad or a narrow laptop window, opening a ticket gave you a reading pane a few words wide: the title wrapped one word per line, the properties were squashed and the message was a strip. Everything worked; nothing was readable.

What was wrong

Between the phone layout (768px and below) and a normal laptop, the inbox kept its three desktop columns at desktop sizes: folders a fixed 280px, the list a fixed 400px, and the reading pane whatever was left.

Window Reading pane
800px 120px
900px 220px
1024px 344px
1100px 420px

The cure already existed - discussion #292 added a folders strip in 5.4.0 - but only for people who went looking for it in Preferences, and someone on a tablet has no reason to.

The fix

@cloudcogsio laid out four options and suggested the third; that is what was built.

  1. The folders fold themselves on a narrow window. From 769 to 1100px, with Tickets - folders on Always visible, the folders start as the 28px strip and come back when the window is wider. [ and the buttons still switch them for the visit; crossing 1100px hands the choice back to the width. Click to open and Show on hover are a strip already, so they do not change. "Always visible" now means "always, when there's room" - Preferences and the Tickets help say so.

    // assets/js/ticket-folders-pane.js
    var narrow = window.matchMedia('(min-width: 769px) and (max-width: 1100px)');
    if (pref === 'always' && narrow.matches) mode = 'click';
    ...
    function onWidth() {
        if (pref !== 'always') return;
        mc.classList.remove('folders-open');
        mode = narrow.matches ? 'click' : 'always';
        apply();
    }
    narrow.addEventListener('change', onWidth);
  2. The list narrows with the window, 400px at 1100px down to 300px at 1000px and below:

    /* assets/css/inbox.css, inside the desktop-only block */
    @media (max-width: 1100px) {
        .email-list-container { width: clamp(300px, 100vw - 700px, 400px); }
    }

The wrong turn worth keeping

The suggestion was to let the list shrink - flex-shrink: 1; min-width: 300px. Built that way it did nothing: measured, the list stayed 400px. flex-shrink only takes space back when the row overflows, and once the folders had folded to a strip the row fitted; the reading pane (flex: 1) simply took what was left. Shrinking is the wrong tool when nothing is short of room - the list has to be told a smaller width.

📁 Files

File Change
🟡 assets/js/ticket-folders-pane.js Follows the width when the preference is Always visible
🔵 assets/css/inbox.css The list's narrow width
🟣 tickets/index.php ticket-folders-pane.js?v=2
🟣 system/preferences/index.php, tickets/help.php One line each saying so
🌐 lang/*/system.php, lang/*/tickets.php panels_narrow, folders_narrow - 9 languages
⚪ ~235 pages inbox.css?v=97

The 1100px lives in two places, the CSS and the script; each has a TRAP: comment pointing at the other.

How it was verified

Tickets loaded in frames of fixed widths on a test install, measuring the three columns:

Window Folders List Reading pane (was)
800px 28 300 472 (120)
900px 28 300 572 (220)
1024px 28 324 672 (344)
1100px 28 400 672 (420)
1101px 280 400 421 - unchanged
1280px 280 400 600 - unchanged

1101px and 1280px are the control: above the threshold nothing moved. Table view and the ticket workspace set the list's width with more specific rules, so they are not affected; phones are outside the desktop media query.

What this means for you

Update to 5.8.0 and a tablet or a narrow window gets a reading pane you can read. If you would rather keep the folders open anyway, press [.

FreeITSM

Getting Started

Modules

Multi-tenancy (planned)

Responses to feedback

Blue sky thinking

Bugs resolved

Pull requests

Links

Clone this wiki locally