var pk = pk || {};
(function(pk) {
    pk.drag = function(opt) {
        var el = opt.element;
        var handle = opt.handle || opt.element;
        var container = {
            element: opt.container && opt.container.element ? opt.container.element : document.body,
            style: opt.container && opt.container.style ? opt.container.style : 'restrict'
        };

        pk.addClass(handle, 'pk-drag');
        var fn = opt.listeners;
        var m = opt.move;
        if (m && typeof m !== 'object') {
            m = {
                x: true,
                y: true
            };
        }
        var dragging = false;
        var dragStart = {};
        var startOffset;
        var containerD = {};
        var elD = {};

        function augmentEvent(e) {

            e.dragStart = dragStart;
            e.dragOffset = startOffset;

            e.dragEnd = {
                x: e.clientX,
                y: e.clientY
            };
            e.dragDist = {
                x: e.dragEnd.x - e.dragStart.x,
                y: e.dragEnd.y - e.dragStart.y
            };
            e.dragPerc = {
                x: (pk.layout(el).left + e.dragDist.x + e.dragOffset.x) / pk.layout(container.element).width,
                y: (pk.layout(el).top + e.dragDist.y + e.dragOffset.y) / pk.layout(container.element).height
            };
            return e;
        }

        pk.bindEvent("mousedown", handle, function(e) {
            dragging = true;
            dragStart = {
                x: e.clientX,
                y: e.clientY
            };
            startOffset = {
                x: e.clientX - el.getBoundingClientRect().left,
                y: e.clientY - el.getBoundingClientRect().top
            };
            e = augmentEvent(e);
            pk.addClass(handle, 'pk-drag-dragging');
            pk.addClass(document.body, 'pk-noselect');
            document.onselectstart = function() {
                return false;
            };
            containerD = pk.layout(container.element);
            elD = pk.layout(el);
            if (fn && fn.dragstart) {
                fn.dragstart(el, e);
            }
        });
        pk.bindEvent("mouseup", window, function(e) {
            if (!dragging) {
                return;
            }
            dragging = false;
            e = augmentEvent(e);
            pk.removeClass(handle, 'pk-drag-dragging');
            pk.removeClass(document.body, 'pk-noselect');
            document.onselectstart = function() {
                return true;
            };
            if (m && container.style === "snap") {
                contain();
            }
            if (fn && fn.dragend) {
                fn.dragend(el, e);
            }
        });

        function contain() {


            var h = container.element.tagName === "BODY" ? document.documentElement.clientHeight : container.element.offsetHeight,
                w = container.element.tagName === "BODY" ? document.documentElement.clientWidth : container.element.offsetWidth;

            if (m.x && el.offsetLeft < 0) {
                el.style.left = 0 + 'px';
            } else if (m.x && el.offsetLeft > w - el.offsetWidth) {
                el.style.left = w - el.offsetWidth + 'px';
            }
            if (m.y && el.offsetTop < 0) {
                el.style.top = 0 + 'px';
            } else if (m.y && el.offsetTop > h - el.offsetHeight) {
                el.style.top = h - el.offsetHeight + 'px';
            }
        }
        pk.bindEvent("mousemove", window, function(e) {
            if (!dragging) {
                return;
            }
            e = augmentEvent(e);
            if (m.x) {
                el.style.left = el.offsetLeft + (e.dragEnd.x - el.getBoundingClientRect().left) - e.dragOffset.x + 'px';
            }
            if (m.y) {
                el.style.top = el.offsetTop + (e.dragEnd.y - el.getBoundingClientRect().top) - e.dragOffset.y + 'px';
            }
            if (container.style === "restrict") {
                contain();
            }
            if (fn && fn.dragging) {
                fn.dragging(el, e);
            }
        });
    };
})(pk);

@@ -3028,16 +3028,78 @@
 setWidth
+,%0A%09%09%09%09oX = container.style.x %7C%7C 0, oY = container.style.y %7C%7C 0
 ;%0A%0A     
@@ -3132,17 +3132,24 @@
 tLeft %3C 
-0
+(0 + oX)
 ) %7B%0A    
@@ -3176,17 +3176,24 @@
 .left = 
-0
+(0 + oX)
  + 'px';
@@ -3257,16 +3257,21 @@
 setWidth
+ - oX
 ) %7B%0A    
@@ -3317,16 +3317,21 @@
 etWidth 
+- oX 
 + 'px';%0A
@@ -3382,17 +3382,24 @@
 etTop %3C 
-0
+(0 + oY)
 ) %7B%0A    
@@ -3425,19 +3425,26 @@
 e.top = 
+(
 0 +
+ oY) +
  'px';%0A 
@@ -3506,16 +3506,21 @@
 etHeight
+ - oY
 ) %7B%0A    
@@ -3566,16 +3566,21 @@
 tHeight 
+- oY 
 + 'px';%0A
@@ -4118,16 +4118,60 @@
 estrict%22
+ %7C%7C (container.style.x && container.style.y)
 ) %7B%0A    

Update drag.js