Reputation: 18103
If you check this:
Then you can see that the box(div element) is moving more at the left than the text. It doesnt get center like the text does. Why is this occuring and how can i fix this?
Upvotes: 0
Views: 62
Reputation: 8390
Take a look at this modified version of jsfiddle:
I have added a background-color to both the right and left elements to help you visualize the result and reason why the centering was not happening the way you wanted. This seems to work in chrome.
Hope this helps.
Bob
Upvotes: 1
Reputation: 14327
#recentStatus
is centering as you're expecting as a result of its display: inline
style.
So if you add display: inline-block
to .userStatusComment
, it'll center similarly to the other elements.
Upvotes: 1