Forums

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

Upcoming/past dates appear in orange/red - how to turn off?

Mark Stewart
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!
February 12, 2019

We write out release plans in Confluence that include a table where one column is is a date (using the calendar macro where you type "//" then the calendar appears). Something changed this week in our implementation where these dates now change color if they are in the past (bold and red) or upcoming (bold and orange).

We don't want this feature. It appears to have the classes "date-upcoming" and "date-past" which trigger the css changes. How can we turn this off?

6 answers

3 votes
Shannon S
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
February 27, 2019

Hello everyone!

This is a known bug at this time, and I have reported it here:

  • CONFCLOUD-65700 Past dates are showing up red (late) when not attached to a task

Please vote on the bug if you are experiencing it, and watch for any updates going forward.

Thank you for your attention!

Regards,

Shannon

1 vote
Bill Bailey
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.
February 13, 2019

Add rules to the global stylesheet to override those rules.

0 votes
Marinda
Contributor
July 3, 2019

We would actually prefer the old editor look - we'd like the upcoming dates to show up in orange and past dates in red. Is there any way we can make that happen in the new editor?

Henrik Juel Petersen October 30, 2019

Did you find a way to do this?

Shannon S
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
October 30, 2019

Hi @Marinda and @Henrik Juel Petersen,

I've logged a feature request below to bring this feature to the new editor:

  •  CONFCLOUD-68345 Display past and approaching dates in date macro in orange and red

Please vote on the request and you will be automatically added to the list of watchers and receive updates on this in the future.

Regards,

Shannon

Henrik Juel Petersen October 30, 2019

Hi,

I made a quick and dirty solution, where I made a user macro, that adds an id to a <p> tag and then takes a date as input and place it inside the <p> tag with a "time datetime" that triggers the date picker style of dates.

This way I can control, that it's only coloring the dates, where I use the usermacro, instead of the whole confluence instance, which it did - when I just added the chages to CSS(without the dateExpire id)..

 

Unfortunately I could only get it to work with the date format: MM/dd/yyyy.

 

User macro:

"No macro body"

## @Param inputDate:title=Input date|type=date|desc=Format: MM/dd/yyyy
#set($inputDate=$content.currentDate)
$inputDate.setTime($content.currentDate.parse($paraminputDate))
<p id="dateExpire"><time datetime="$action.dateFormatter.formatGivenString("yyyy-MM-dd", $inputDate)"/></p

(The user macro is inspired by some other macro I found somewhere in the community)

Added following to the CSS stylesheet in the general configuration:
p#dateExpire.conf-macro.output-inline time.date-past { color:red }

 

There's also the date classes: date-future and date-upcomming

Im not sure, when a date-future becomes a date-upcomming - but I'm guessing its the same old rules that has always been there.

 

Hope you can use it to some extend - even tho it's not an optimal solution.

 

/Henrik

Shannon S
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
October 31, 2019

Henrik,

Thank you for sharing your workaround. Unfortunately, this thread is regarding Confluence Cloud, so it's not possible to use User Macros in Cloud.

Although, if someone comes across this that wants to do the same on Server, it should be able to help them.

Thank you, and take care!

Regards,

Shannon

0 votes
Suren Raj
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
February 19, 2019

Hi, @Mark Stewart 

I understand you see different date colors while using the date picker in Confluence. As of now, there are two editors in Confluence: old editor and the new editor.

In the old editor: When you use date picker here, all the past dates chosen are red in color, the present one week is orange and any futures dates are grey. 

In the new editor: When you use date picker here, all the dates no matter past or present are a grey color.

As of now, your instance seems to be using the old editor. That being said, at this point, 90% of the customers have the new editor template enabled and for the rest 10%, it will be rolled out soon. Once this is done you will not see any difference in the color for dates.

Regards,
Suren Raj

Marinda
Contributor
July 3, 2019

We would actually prefer the old editor look - we'd like the upcoming dates to show up in orange and past dates in red. Is there any way we can make that happen in the new editor?

Like # people like this
0 votes
Bill Bailey
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.
February 14, 2019

@Mark Stewarthad both versions tagged, so not clear if Cloud or not. But if Cloud, they make it much harder than with the server version.

0 votes
Davin Studer
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.
February 14, 2019

Looks like it is for Cloud though. However, there is a style macro in Cloud. You could override it on a page by page basis. Or maybe put the styles into a page and then include that page onto pages where you have dates. That way you don't have to type out the styles each time.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events