Opened 6 years ago

Closed 3 years ago

#9605 closed enhancement (wontfix)

Choose alignment of tickets

Reported by: bastik Owned by: erinn
Priority: Medium Milestone:
Component: Internal Services/Service - trac Version:
Severity: Normal Keywords:
Cc: Actual Points:
Parent ID: Points:
Reviewer: Sponsor:

Description

The alignment of tickets now it is centered.

Would it be possible to have a setting for this?
(I'd opt for left alignment.)

Child Tickets

Change History (4)

comment:1 Changed 6 years ago by bastik

Some CSS modifications.

margin-left at #content.ticket in ticket.css can be set to somewhat percent

5% work fine for me

or to pixels

50px work fine for me

Now "Download in other formats:" including its links are still centered.

This is probably controlled via text-align at #altlinks in trac.css or tor.css
which can be set to left

which would make it appear leftmost, what doesn't look good

now you can add margin-left: with n% or npx

(where n is what you pick for #content.ticket)

Note that this has an effect on the whole wiki, what is not intended

I'm unable to save my CSS edits, thus the page looks like it did before.

My options appear to be:

  • Wait for trac to come with a setting to control it and you to use it
  • Wait for you patching trac to allow user to choose alignment of tickets (including altlinks in a nice way)
  • Using UserOptions.css (if these work, I don't know how)
  • Use, yet another, add-on to apply my modifications to this website

comment:2 Changed 6 years ago by bastik

What took apparently an hour, felt like hours.

So yes, UserOptions.css is an option, but since edits require Firefox restarts I picked "Generic CSS Loader 2" add-on for Firefox because it can show me if I succeed and is lightweight (less than 10kb) especially compared to Stylish.

Display tickets left:

@-moz-document domain("trac.torproject.org") {
#content.ticket {
margin-left: 5% !important;
}

}

It took me ages to find out why my CSS is not applied. It requires !important to be added.

Display the "Download in other formats:" along with its links also left, but not leftmost *and* only on tickets.

@-moz-document url-prefix("https://trac.torproject.org/projects/tor/ticket/"){
#altlinks {
text-align: left !important;
margin-left: 6%;
}

}

Note that margin-left works without !important because it doesn't need to be overridden. Also note that this should work for https:// only, which is no issue since it gets shipped over https anyway.

The quotation marks (") around the domain and URL seem to be not required. You can play around with the percentages or replace them with pixels (px).

@-moz-document domain applies everything to a given domain.
@-moz-document URL applies everything to specific URL.
@-moz-document URL-prefix applies everything to URLs that begin with what you specify.

I'm not going to close this ticket, yet. I'm going to wait for some input e.g. for opening a ticket in Trac's Trac (if this is a something that affects Trac as product) or if this can be an optional thing in Tor's Trac settings, or whatever.

Last edited 6 years ago by bastik (previous) (diff)

comment:3 Changed 4 years ago by qbi

Component: TracService - trac

Move all tickets from trac to "Service - trac" component.

comment:4 Changed 3 years ago by bastik

Resolution: wontfix
Severity: Normal
Status: newclosed

Nothing to worry for you, just my personal taste... others may change it for themselves as well, but nothing to spend time on for a general option.

Note: See TracTickets for help on using tickets.