Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Custom filed drop down with colors- NO ADD ON PURCHASE

KRC
Contributor
September 7, 2017

Hi

How do i set up a custom field called Type with drop-down options as Red, Green Yellow. if users select red, ticket shows "Type: Red" as text and background color of the text in red and if user selects option two green, then it should say green and text background as green?

I used this html , but dropdown shhows with colored background, but i need that value to displayed as needed. how can i achieve this?

<html>
<body><select>
<option value="1" style="background:red">Red</option>
<option value="2" style="background:yellow">Yellow</option>
<option value="3" style="background:green">Green</option>
</select>
</body>
</html>

1 answer

1 accepted

4 votes
Answer accepted
Bhushan Nagaraj
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
September 7, 2017

Hi KRC,

Please see image attached. You need to set each option with a span and class set to aui-lozenge aui-lozenge-success/error/current, etc. Notice the single quotes and not double quotes.

lozenge-field.png

For future reference, the Atlassian Design Guidelines (ADG) documentation is available at https://docs.atlassian.com/aui/latest/docs/lozenges.html

Thanks

Bhushan

Bhushan Nagaraj
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
September 7, 2017
KRC
Contributor
September 8, 2017

Thank you for sharing your knowledge.

KRC
Contributor
September 8, 2017

Is there a similar way to make custom date field stand out on the ticket by making it bold or adding color or something?

Rajat Sethi June 4, 2018

Thanks Bhushan!! This was really helpful. 

Bhushan Nagaraj
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
June 5, 2018

You are welcome @Rajat Sethi :)

Daniel Obst
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
October 19, 2018

Does this work for Cloud Versions?

Bhushan Nagaraj
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
October 21, 2018

@Daniel Obst no I have not tested this in Cloud and this may not work in Cloud. 

Nikki DuBois
Contributor
June 29, 2022

It does not appear to work in cloud. :(

Like # people like this
Michael Wohlgemuth
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 7, 2024

For cloud users:

I know its not nice, and a workaround at best, but you CAN add emojis to customfield options. That way, theres at least SOME way to colorcode your values.

Im using this fella, and his red, yellow and whatnot colleagues:

Which then looks like this:

Screenshot 2024-08-07 155852.png

Suggest an answer

Log in or Sign up to answer