In my usecase I solved this by setting the blocked one to a fixed value (for example a border which should not be crossed). Like this:
```
rect.draggable(function (x, y) {
var res = {x: x, y: y};
if (x < 100) {
res.x = 100;
}
return res;
}
```
But I am excited to see your solution ;)