- This topic is empty.
-
AuthorPosts
-
October 15, 2016 at 9:14 am #246574FunkaholikParticipant
sample here
See, when you hover on an element other elements shrinks (err move aside a bit)
but i want them to move closer to hoverable element ..
so hover will have kinda glue/stick effect to others)
so they will move a bit closer not asideOctober 15, 2016 at 11:45 am #246589FunkaholikParticipantexcuse me .. i’m in beast mode right now
and i need those requests badly, but not imidiately off course))October 15, 2016 at 12:49 pm #246605Paulie_DMemberThen you’ll have to set a percentage size.
October 15, 2016 at 1:06 pm #246606ShikkedielParticipantNeat, here’s a variation on that:
October 16, 2016 at 4:18 am #246614FunkaholikParticipantOctober 16, 2016 at 10:43 am #246620ShikkedielParticipantI tried to achieve that but the combination does not seem possible with CSS alone. Paulie’s suggestion was actually the last bit of the puzzle to get anywhere close to what you described. If you remove that line from the style, you’ll see another of those conundrums appear where the space between the items responds to hovering – while you cannot deselect the parent itself because it is needed to change the size. One cannot use any of the child elements for this because there is no way to address the parent from there. I can’t see any approach to “squeeze” the icons together without changing the parent size. Furthermore, hovering over any (but the first) of the icons leaves no room to select all of it’s siblings.
Not to say another member can’t have a surprise in store but I’d be quite surprised here.
October 16, 2016 at 10:57 am #246621ShikkedielParticipantYou could place invisible elements that are outside of the parent on top of the empty spaces of course. But that’s just messy – both style and calculation wise.
October 17, 2016 at 2:19 am #246651FunkaholikParticipantalrighty then i’ll leave it as it was in a pen .. thanx, Edo..)
October 17, 2016 at 2:22 am #246652FunkaholikParticipantthanx to you too, Paulie-D.
October 17, 2016 at 10:30 am #246672ShikkedielParticipantwhile you cannot deselect the parent itself
Looks like I figured it out after all:
Using
pointer-events
…October 22, 2016 at 12:06 pm #246915FunkaholikParticipantha-ha you got it now)
October 22, 2016 at 12:28 pm #246917FunkaholikParticipantalmost actualy))
when you hover over any element the rest are glued to a middle element not the hovered one
Just bringing clarity here don’t kill me))October 22, 2016 at 2:15 pm #246920ShikkedielParticipantThat would require different behaviour for each icon. Either related to changing something on the parent or all of it’s siblings. Don’t think it can be done with CSS.
Theoretically, changing the
margin: auto
of the parent to either amargin-left: auto
ormargin-right: auto
will get the effect a bit closer but I can’t see how to implement that by hovering over the particular children.I don’t know about further flexbox tricks though. Haven’t had much exercise with that.
-
AuthorPosts
- The forum ‘CSS’ is closed to new topics and replies.