Making format option "Code" a bit more visible?

Lynoure Braakman August 7, 2024

In the company we have pages that have just tiny fragments of code, say a path to a file, Unix permissions or a single line command. However, when using the "Code" format option, the result looks extremely similar to normal text making these important pieces of information hard to spot. Yet a code snippet would be an overkill.

Is there any way to increase the visibility of the formatting, say by having a different background color by default?

2 answers

0 votes
Barbara Szczesniak
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 8, 2024

@Lynoure Braakman For a more distinct contrast, you could apply a highlight color (or even a combination of text color and highlight color).

Note however, that this does not change the font of the text to a monospaced font.

HighlightColorControl.png

0 votes
Shawn Doyle - ReleaseTEAM
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
August 7, 2024

Hi @Lynoure Braakman 

 

When using both the code snippet and the code macro (ctrl + shift + M),  I get a different background color, it's not a drastically different color, but it's still noticeable, I do not believe there is a way to customize this further without a Marketplace addon.

light_code.pngdark_code.png

 

 

Lynoure Braakman August 8, 2024

I'll only address the light mode, as that's what our Confluence uses.

With the Code Snippet, the line number area ( with #E3E5E9 ) does stands out sufficiently. A single word in a text with 'Code' formatting option, with only the background color, really does not on very many monitors.

For example, on a new Dell laptop screen, I can see it. The brand new Dell external modern midrange monitor? Not even a chance. The difference is so subtle, that only if I know where to look at, I can just barely notice the background being a different shade.
For myself I can choose to have Confluence only on my laptop screen (though that's a huge pity), but I cannot enforce that on anyone else.

The code background seems to be #F1F2F4, even lighter than the standard "light gray" (#E8E8E8) and it's meant to stand out in contrast to the standard background of  #FFFFFF. 

The curse of UI designers is that they typically have way better monitors than average office workers.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
FREE
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events