Decision buttons in notification emails are clipped in Outlook desktop

Description

Problem

In Approval Path notification emails, the decision buttons (e.g. "Approve", "Reject", "Abstain") inserted by the {{{actionButtons}}} placeholder render incorrectly in Outlook desktop (Windows). The button border has its full size, but the colored background and the label are cut off vertically, so the text cannot be read. The buttons still work. The problem affects default and custom templates, emails to Atlassian users and to external approvers, in both Approval Path for Jira and Approval Path for Confluence.

Cause

Since the change that added custom button colors, borders and icons, a button is built as a styled link. Outlook desktop does not support this layout: it draws the border at full size but clips the background and text to the line height.

Steps to reproduce

  1. Configure a definition with a User step where decision buttons in emails are enabled (with and without icons).

  2. Start an approval so the approver receives an email with decision buttons.

  3. Open the email in Outlook desktop on Windows.

Actual behavior

Button labels are clipped and the background does not fill the border.

Expected behavior

Buttons show the full label and icon, the background fills the whole button, and the buttons sit next to each other on one line.

Acceptance criteria

  • In Outlook desktop on Windows, every decision button shows its full, readable label and the background fills the whole button.

  • The same holds with icons enabled and disabled, and with longer custom button names.

  • Buttons also render correctly in Outlook on the web, the new Outlook and Gmail.

  • Custom button colors, icons and names from the settings are still shown in the email.

  • Applies to emails sent to Atlassian users and to external approvers, in Jira and in Confluence.

  • Button links lead to the same decision as today.

Change

  • One place builds the decision buttons for every email, so the fix covers Jira and Confluence emails, Atlassian users and external approvers, and default and custom templates. Templates do not need to change.

  • Each button is now a table cell that carries the background and the padding, with the icon and the button name in their own middle-aligned cells inside it, a fixed gap between them, and the remaining space split evenly on both sides, so Outlook desktop keeps the icon level with the name. Outlook desktop draws table cells in full, so the background fills the button and the name is no longer cut off. The buttons sit in one row with a small gap. In email clients that support it (Apple Mail, iOS Mail) the padding moves onto the name link, so the button is clickable around the name; Outlook desktop and Gmail ignore that and keep the padding on the cell.

  • Only gray (white) buttons have a border; coloured buttons have no border of their own colour and no separate link background, so Outlook Classic draws no lines inside them when zoomed. All buttons keep the same size. A 10px spacer row under the buttons keeps the gray buttons' bottom border visible.

  • The line inside a button is tall enough for the icon, so Outlook cannot clip the icon either.

  • In Outlook Classic each button keeps its icon and name on one line (no width: auto; the content does not wrap).

  • The link keeps the button's colors as well, so an email client that drops the cell styling still shows a readable colored name instead of white text on white.

  • The template preview (Settings, Message templates, Test template) shows the buttons the same way as the email.

  • In Outlook desktop the buttons keep their own width even when the email's HTML wrapper makes tables full width; an empty last cell takes the spare width, so the row never runs past the right edge.

  • In emails, the icons on white (gray) and yellow buttons sit on an opaque tile in the button's colour (a 40px image shown at 20px), so they stay visible when a dark theme (Outlook Classic Dark, the new Outlook and Outlook on the web Black) darkens the button. The tile is invisible in light themes and in Gmail. Buttons with white icons are unchanged, and so are the buttons on the app's own pages.

  • The button markup is about 40% shorter, so emails sent through Jira stay well under the 10,000 characters Jira keeps (see Decisions).

Decisions

  • The button box is drawn on the table cell, the standard approach for Outlook, without Outlook-only code that Jira's email processing could remove. Only the button name is a link; the icon is not. Each direct decision link is long, and one link per button keeps emails sent through Jira within Jira's size limit. In Apple Mail and iOS Mail the space around the name is clickable too. In Outlook desktop, Gmail and Outlook on the web only the name is clickable.

  • Jira keeps only the first 10,000 characters of a notification's HTML and the first 1,000 of its subject. When the HTML Approval Path sends to Jira is longer, for example with a long customised template, Approval Path sends Jira only the plain-text version, which has the same decision links, and logs a warning with the host, work item id, template type and length. A subject over 1,000 characters is cut with "…".

  • Outlook desktop shows square corners; other clients keep rounded corners.

  • The buttons stay in one row. On a narrow screen a long name wraps inside its button, and a name with a word longer than 12 characters may break inside that word, so the row is never wider than the email. All buttons in the row keep the same height.

  • Button cells carry their width, height and centring, so they keep their size when Jira's email processing strips the padding. Rows wider than 500px fall back to equal widths and may wrap.

  • The button row is left-aligned. A custom template that centers the placeholder no longer centers the buttons.

  • The width Outlook desktop uses for each button is estimated from the name and icon in Arial; in Outlook desktop a button can have a few pixels of extra space after its name. Other email clients size the buttons by their content, as before.

  • Outlook dark themes recolour button backgrounds but never images. Instead of a separate dark-mode stylesheet, which Outlook Classic ignores and Jira's email processing may remove, the dark icons used in emails sit on an opaque tile in the button colour. It is invisible in light themes and the icons keep their size.

  • Email icon images are cached by email clients for a long time, so a changed icon image always gets a new file name (the tiled icons are *-tile-gray.png and *-tile-yellow.png).

  • The dark theme icon issue existed before this ticket (same icons since the custom button colours were added) and is fixed here because it affects the same buttons.

Fixes included

  1. In emails sent through Jira the decision buttons were broken in every Outlook version: Jira cuts notifications after 10,000 characters, and three buttons with icons and direct decision links went past that. The button markup is now about 40% shorter.

  2. An email whose HTML is still too long for Jira is sent as plain text with working decision links instead of being cut; a subject that is too long is shortened with "…".

Manual tester notes

  • Approval Path for Jira: in Settings, Actions, Decision buttons, keep the default buttons with icons on. Start an approval with a User step that sends decision buttons in emails. Open the email in Outlook desktop on Windows: each button shows its full name and icon, the icon sits level with the name with a small gap, the color fills the whole button, the buttons sit side by side in one row, the buttons are only as wide as their icon and name, not the full window, and the third button's right border is visible; check an email Approval Path sends itself (sender no-reply@...) and one sent through Jira. Click each button: it opens the same decision as before.

  • Approval Path for Jira, decisions sent as Jira notifications, Abstain on, icons on: open the email in Outlook Classic, the new Outlook and Outlook on the web. All three buttons show whole, and the expiry notice, the thank-you line and the guide link appear after them.

  • Repeat with icons turned off, then with long custom names (up to 30 characters, including one without spaces, for example ApproveTheProductionDeployment) and different colors, including gray (white button with a gray border), with Abstain enabled.

  • In Outlook Classic, zoom the email to 90%, 100%, 110%, 120% and 130%: no white lines inside coloured buttons, and gray buttons keep a complete border.

  • Open the same emails in Outlook on the web, the new Outlook, and Gmail on the web and on a phone: the buttons look the same, and long names wrap inside their buttons on the phone, the row stays within the screen.

  • In Outlook Classic with the Dark theme, and in the new Outlook and Outlook on the web with the Black theme, open freshly sent emails with icons on and Abstain enabled, with buttons in every colour (gray, yellow, blue, green, red, purple): every icon is visible without hovering. In light themes the buttons look as before.

  • In Outlook Classic, compare an email Approval Path sends itself with one sent through Jira: the buttons have the same size and each keeps its icon and name on one line.

  • External approver: allow decisions from email, start an approval with an external approver step and open that email in Outlook desktop and Gmail.

  • Approval Path for Confluence: repeat the first check for a page approval email.

  • Settings, Message templates: open a template that contains the decision buttons, go to Test template, choose the HTML field and an approval, click Render: the buttons look like in the email.

  • In Apple Mail or iOS Mail, click each button in the coloured area around the name: it opens the decision. In Outlook desktop and Gmail only the name is clickable; the icon is not a link.