How Can I Detect Wrapping With Javascript?
I have a load of fixed width divs inside a dynamic width div. The fixed divs all go next to each other and eventually wrap. What I want is to detect if one div ends up on a line on
Solution 1:
so you want to know if the div is on it's own row?
you can check each div's offsetTop to check against the other div's if they are on the same row. if the div's offsetTop dont match any of the others, then it's on it's own.
Post a Comment for "How Can I Detect Wrapping With Javascript?"