Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

How to apply CSS to the Expand macro

Jordan Packer July 15, 2014

I understand how to apply CSS stylesheets to a space, but how can I reference the Expand macro objects in the stylesheet?

I have a list of hyperlinks, some of them are just direct URL hyperlinks and others are Expand links (that open up to expand a sub-list of URL hyperlinks). However, when you put a mixture of those right after another, the format looks awful. I think this is because the Expand macro has a different margin setting and so the spacing right after it is different than if it were just a regular <p> object. Any ideas???

To better visualize, here's an example of what I get right now:

And here's what I would like to have:

3 answers

1 accepted

0 votes
Answer accepted
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.
July 31, 2014

You could give the expand-control class a 10px margin-top. That should fix it for you. It currently has a 10px margin-bottom, and p elements have a 10px margin-top and no margin-bottom. That is why they butt up against each other. You could add it to either the space or global stylesheet, or if you only want it on one page you could use the Content Formatting Macros stylesheet macro to put a style block in your page.

.expand-control {
    margin-top: 10px;
}

Jordan Packer July 31, 2014

That helps, thank you.

0 votes
Jordan Packer July 31, 2014

Never really found a good way to do this.... closing this question since I'm not getting any other answers.

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.
July 16, 2014

If you are using a fairly modern browser they all come with developer tools that allow you to look at the source and css styles for specific elements. That would be the place to go to see what is going on. Also, you may look at the storeage format for the actual page to see if the wysiwyg editor did something wonky. The Confluence Source Editor will let you peek into and edit the storage format.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events