Skip to content

Commit

Permalink
Removed draggable attribute
Browse files Browse the repository at this point in the history
  • Loading branch information
Piotr Nalepa committed Dec 12, 2016
1 parent 376cae2 commit 0f3f426
Show file tree
Hide file tree
Showing 6 changed files with 22 additions and 23 deletions.
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "dragsterjs",
"version": "1.3.4",
"version": "1.3.5",
"homepage": "https://github.com/sunpietro/dragster",
"authors": [
"Piotr Nalepa <[email protected]>"
Expand Down
31 changes: 15 additions & 16 deletions dragster.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*@preserve
* Dragster - drag'n'drop library v1.3.4
* Dragster - drag'n'drop library v1.3.5
* https://github.com/sunpietro/dragster
*
* Copyright 2015-2016 Piotr Nalepa
Expand All @@ -8,7 +8,7 @@
* Released under the MIT license
* https://github.com/sunpietro/dragster/blob/master/LICENSE
*
* Date: 2016-11-25T07:00Z
* Date: 2016-12-12T07:00Z
*/
(function (window, document) {
'use strict';
Expand Down Expand Up @@ -37,6 +37,7 @@
DIV = 'div',
FALSE = false,
TRUE = true,
NULL = null,
dummyCallback = function () {},
finalParams = {
elementSelector: '.dragster-block',
Expand All @@ -56,13 +57,12 @@
scrollWindowOnDrag: FALSE,
dragOnlyRegionsEnabled: FALSE,
cloneElements: FALSE,
wrapDraggableElements: TRUE
wrapDraggableElements: TRUE,
},
draggableAttrName = 'draggable',
placeholderAttrName = 'data-placeholder-position',
visiblePlaceholder = {
top: FALSE,
bottom: FALSE
bottom: FALSE,
},
defaultDragsterEventInfo = {
drag: {
Expand All @@ -72,7 +72,7 @@
* @property node
* @type {HTMLElement}
*/
node: {}
node: NULL,
},
drop: {
/**
Expand All @@ -81,7 +81,7 @@
* @property node
* @type {HTMLElement}
*/
node: {}
node: NULL,
},
shadow: {
/**
Expand All @@ -90,7 +90,7 @@
* @property node
* @type {HTMLElement}
*/
node: {},
node: NULL,
/**
* Contains top position value of shadow element
*
Expand All @@ -113,37 +113,37 @@
* @property node
* @type {HTMLElement}
*/
node: {},
node: NULL,
/**
* Contains position type of placeholder
*
* @property position
* @type {String}
* @example 'top' or 'bottom'
*/
position: ''
position: NULL,
},
/**
* Reference to dropped element
*
* @property dropped
* @type {HTMLElement}
*/
dropped: null,
dropped: NULL,
/**
* Reference to cloned element
*
* @property clonedFrom
* @type {HTMLElement}
*/
clonedFrom: null,
clonedFrom: NULL,
/**
* Reference to dropped cloned element
*
* @property clonedTo
* @type {HTMLElement}
*/
clonedTo: null
clonedTo: NULL,
},
dragsterEventInfo,
key,
Expand Down Expand Up @@ -205,8 +205,8 @@
wrapDraggableElements = function (elements) {
if (finalParams.wrapDraggableElements === FALSE) {
console.warn(
'You have disabled the default behavior of wrapping the draggable elements, ' +
'if you want dragster to work properly you still will have to do this manually.\n' +
'You have disabled the default behavior of wrapping the draggable elements. ' +
'If you want Dragster.js to work properly you still will have to do this manually.\n' +
'\n' +
'More info: https://github.com/sunpietro/dragster/blob/master/README.md#user-content-wrapdraggableelements---boolean'
);
Expand Down Expand Up @@ -337,7 +337,6 @@
createElementWrapper = function () {
var wrapper = document.createElement(DIV);

wrapper.setAttribute(draggableAttrName, TRUE);
wrapper.classList.add(CLASS_DRAGGABLE);

return wrapper;
Expand Down
6 changes: 3 additions & 3 deletions dragster.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file modified dragster.min.js.gz
Binary file not shown.
4 changes: 2 additions & 2 deletions dragster.style.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Dragster - drag'n'drop library v1.3.4
* Dragster - drag'n'drop library v1.3.5
* https://github.com/sunpietro/dragster
*
* Copyright 2015-2016 Piotr Nalepa
Expand All @@ -8,7 +8,7 @@
* Released under the MIT license
* https://github.com/sunpietro/dragster/blob/master/LICENSE
*
* Date: 2016-11-25T07:00Z
* Date: 2016-12-12T07:00Z
*/
* {
box-sizing: border-box;
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "dragsterjs",
"version": "1.3.4",
"version": "1.3.5",
"description": "Tiny vanilla JS plugin that enables drag'n'drop interactions to a user of your website",
"main": "dragster.js",
"scripts": {
Expand Down

0 comments on commit 0f3f426

Please sign in to comment.