Tether: Set max width/height only when it's needed
Created by: vovakulikov
Context
Prior to this PR tether package always set max sizes to the floating element. This led to problems with overflow content in some corner cases in firefox and chrome. I suspect that for some reason (I'm still not sure why it happens) getBoundingClientRect
returns not fully corrected values. This PR tweaks logic around setting max sizes in a way that if the floating element wasn't constrained tether logic doesn't set max values.