Ask Your Question
4

CSS should not use fixed width for elements with localizable text

asked 2012-08-05 03:29:30 -0600

Zahid gravatar image

updated 2012-08-05 23:54:21 -0600

I see lots of cosmetic bugs. By checking I found that most of the elements are of fixed width. It is a bad practice actually. Let say about button Ask you question if I use my locale translation it cut-off. It is because of css fixed width. same for fixed height also.

Need to maintain it by css padding and margin.

As per Evegeny's comment, I'm attaching a screenshot. But actually lots of problem in other pages also. This make such a great app ugly :( image description

See highlighted area with red rectangle.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2012-08-05 11:55:09 -0600

Evgeny gravatar image

It's fixed width to make the button look as wide as the column below - for the same cosmetic reasons.

You can create a fix for your language using the "lang-..." class on the body, which is added automatically.

edit flag offensive delete link more

Comments

It is fine that top ask you questions are fixed width. But I have seen lots of other elements arround with fixed width.

Does askbot provide any setting to set lang property in html body?

Thanks again!

Zahid gravatar imageZahid ( 2012-08-05 12:07:10 -0600 )edit
1

The language code is automatically set as class name on the "body" tag - take a look in the html source. I agree that most elements should not have fixed width - let me know which you find problematic.

Evgeny gravatar imageEvgeny ( 2012-08-05 12:21:33 -0600 )edit

I have attached a screenshot with a cosmetic-error.

Zahid gravatar imageZahid ( 2012-08-05 23:54:52 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2012-08-05 03:29:30 -0600

Seen: 176 times

Last updated: Aug 05 '12