position abolute within a line / unit

21 views
Skip to first unread message

Benno

unread,
Oct 26, 2011, 2:10:02 PM10/26/11
to Object Oriented CSS
Hey out there,

I'm currently creating a new website with this great framework.
Everthing is fine ... until now.

I need to position an absolute div within a line / unit. Here is an
(simple) example how it should be done: http://jsfiddle.net/jyJby/1/
The infoBox will be an hover effect (third element in line) and have
to go outside (on the right side of "line"). But line and lastUnit
have overflow hidden attributes. So when I'm trying transform this
code snippet into a simple OOCSS snippet: http://jsfiddle.net/Fm3ND/3/
the infoBox disappears (logically).

So my question is: is there a workaround for this? Am I ignoring some
facts? Hope not :-) Does anyone this before or does anyone have a hint
how to solve this?

Thank you in advance!

Evan Winslow

unread,
Oct 27, 2011, 2:49:23 AM10/27/11
to object-or...@googlegroups.com
If you can use javascript, I would look into jQuery UI's position() plugin.

--
You received this message because you are subscribed to the Google Groups "Object Oriented CSS" group.
To post to this group, send email to object-or...@googlegroups.com.
To unsubscribe from this group, send email to object-oriented...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/object-oriented-css?hl=en.


Ytterström Anders (Adeprimo)

unread,
Oct 27, 2011, 2:53:50 AM10/27/11
to <object-oriented-css@googlegroups.com>
Since the line and units are meant to deal with grids primary, I would
place the absolute positioned content somewhere else. Generally
speaking, that other place would be the parentNode of the line objekt.

Skickat från min iPhone

Ad Taylor

unread,
Oct 27, 2011, 5:07:33 AM10/27/11
to object-or...@googlegroups.com
I think that this is a really important issue. Personally speaking, I am finding that the sites I'm building are becoming visually richer more 'app-like' — widgets, like tooltips, need to break the grid and the placement of the markup should not be dictated by the CSS.

There is every chance I might be mistaken but weren't lastUnits given a new formatting context using a :after hack? If so, I'd be really interested to know the reasoning behind the change.

This is by no means a fix to the initial problem but I adjusted the fiddle to, hopefully, explain my point more articulately. http://jsfiddle.net/Fm3ND/4/

-- 
Ad Taylor
@iamadtaylor

Ethan Resnick

unread,
Oct 27, 2011, 11:31:10 AM10/27/11
to object-or...@googlegroups.com
Try this: http://jsfiddle.net/Fm3ND/6/

As was said earlier, if the widget isn't going to fall on the grid, it needs to be placed outside it (which sorta makes sense, even though it's a pain).
Reply all
Reply to author
Forward
0 new messages