Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

angular-gridster2

Package Overview
Dependencies
Maintainers
1
Versions
245
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

angular-gridster2 - npm Package Compare versions

Comparing version 5.0.1 to 5.1.0

7

dist/gridsterConfig.constant.js

@@ -116,3 +116,8 @@ "use strict";

// callback when dragging an item stops. Accepts Promise return to cancel/approve drag.
start: undefined // callback when dragging an item starts.
start: undefined,
// callback when dragging an item starts.
// Arguments: item, gridsterItem, event
dropOverItems: false,
// enable drop items on top other item
dropOverItemsCallback: undefined // callback on drop over another item
},

@@ -119,0 +124,0 @@ resizable: {

2

dist/gridsterConfig.constant.metadata.json

@@ -1,1 +0,1 @@

[{"__symbolic":"module","version":4,"metadata":{"GridsterConfigService":{"gridType":{"__symbolic":"select","expression":{"__symbolic":"reference","module":"./gridsterConfig.interface","name":"GridType","line":3,"character":12},"member":"Fit"},"fixedColWidth":250,"fixedRowHeight":250,"keepFixedHeightInMobile":false,"keepFixedWidthInMobile":false,"compactType":{"__symbolic":"select","expression":{"__symbolic":"reference","module":"./gridsterConfig.interface","name":"CompactType","line":13,"character":15},"member":"None"},"mobileBreakpoint":640,"minCols":1,"maxCols":100,"minRows":1,"maxRows":100,"defaultItemCols":1,"defaultItemRows":1,"maxItemCols":50,"maxItemRows":50,"minItemCols":1,"minItemRows":1,"minItemArea":1,"maxItemArea":2500,"margin":10,"outerMargin":true,"outerMarginTop":null,"outerMarginRight":null,"outerMarginBottom":null,"outerMarginLeft":null,"scrollSensitivity":10,"scrollSpeed":20,"initCallback":{"__symbolic":"reference","name":"undefined"},"destroyCallback":{"__symbolic":"reference","name":"undefined"},"itemChangeCallback":{"__symbolic":"reference","name":"undefined"},"itemResizeCallback":{"__symbolic":"reference","name":"undefined"},"itemInitCallback":{"__symbolic":"reference","name":"undefined"},"itemRemovedCallback":{"__symbolic":"reference","name":"undefined"},"enableEmptyCellClick":false,"enableEmptyCellContextMenu":false,"enableEmptyCellDrop":false,"enableEmptyCellDrag":false,"emptyCellClickCallback":{"__symbolic":"reference","name":"undefined"},"emptyCellContextMenuCallback":{"__symbolic":"reference","name":"undefined"},"emptyCellDropCallback":{"__symbolic":"reference","name":"undefined"},"emptyCellDragCallback":{"__symbolic":"reference","name":"undefined"},"emptyCellDragMaxCols":50,"emptyCellDragMaxRows":50,"ignoreMarginInRow":false,"draggable":{"delayStart":0,"enabled":false,"ignoreContentClass":"gridster-item-content","ignoreContent":false,"dragHandleClass":"drag-handler","stop":{"__symbolic":"reference","name":"undefined"},"start":{"__symbolic":"reference","name":"undefined"}},"resizable":{"delayStart":0,"enabled":false,"handles":{"s":true,"e":true,"n":true,"w":true,"se":true,"ne":true,"sw":true,"nw":true},"stop":{"__symbolic":"reference","name":"undefined"},"start":{"__symbolic":"reference","name":"undefined"}},"swap":true,"pushItems":false,"disablePushOnDrag":false,"disablePushOnResize":false,"pushDirections":{"north":true,"east":true,"south":true,"west":true},"pushResizeItems":false,"displayGrid":{"__symbolic":"select","expression":{"__symbolic":"reference","module":"./gridsterConfig.interface","name":"DisplayGrid","line":90,"character":15},"member":"OnDragAndResize"},"disableWindowResize":false,"disableWarnings":false,"scrollToNewItems":false}}}]
[{"__symbolic":"module","version":4,"metadata":{"GridsterConfigService":{"gridType":{"__symbolic":"select","expression":{"__symbolic":"reference","module":"./gridsterConfig.interface","name":"GridType","line":3,"character":12},"member":"Fit"},"fixedColWidth":250,"fixedRowHeight":250,"keepFixedHeightInMobile":false,"keepFixedWidthInMobile":false,"compactType":{"__symbolic":"select","expression":{"__symbolic":"reference","module":"./gridsterConfig.interface","name":"CompactType","line":13,"character":15},"member":"None"},"mobileBreakpoint":640,"minCols":1,"maxCols":100,"minRows":1,"maxRows":100,"defaultItemCols":1,"defaultItemRows":1,"maxItemCols":50,"maxItemRows":50,"minItemCols":1,"minItemRows":1,"minItemArea":1,"maxItemArea":2500,"margin":10,"outerMargin":true,"outerMarginTop":null,"outerMarginRight":null,"outerMarginBottom":null,"outerMarginLeft":null,"scrollSensitivity":10,"scrollSpeed":20,"initCallback":{"__symbolic":"reference","name":"undefined"},"destroyCallback":{"__symbolic":"reference","name":"undefined"},"itemChangeCallback":{"__symbolic":"reference","name":"undefined"},"itemResizeCallback":{"__symbolic":"reference","name":"undefined"},"itemInitCallback":{"__symbolic":"reference","name":"undefined"},"itemRemovedCallback":{"__symbolic":"reference","name":"undefined"},"enableEmptyCellClick":false,"enableEmptyCellContextMenu":false,"enableEmptyCellDrop":false,"enableEmptyCellDrag":false,"emptyCellClickCallback":{"__symbolic":"reference","name":"undefined"},"emptyCellContextMenuCallback":{"__symbolic":"reference","name":"undefined"},"emptyCellDropCallback":{"__symbolic":"reference","name":"undefined"},"emptyCellDragCallback":{"__symbolic":"reference","name":"undefined"},"emptyCellDragMaxCols":50,"emptyCellDragMaxRows":50,"ignoreMarginInRow":false,"draggable":{"delayStart":0,"enabled":false,"ignoreContentClass":"gridster-item-content","ignoreContent":false,"dragHandleClass":"drag-handler","stop":{"__symbolic":"reference","name":"undefined"},"start":{"__symbolic":"reference","name":"undefined"},"dropOverItems":false,"dropOverItemsCallback":{"__symbolic":"reference","name":"undefined"}},"resizable":{"delayStart":0,"enabled":false,"handles":{"s":true,"e":true,"n":true,"w":true,"se":true,"ne":true,"sw":true,"nw":true},"stop":{"__symbolic":"reference","name":"undefined"},"start":{"__symbolic":"reference","name":"undefined"}},"swap":true,"pushItems":false,"disablePushOnDrag":false,"disablePushOnResize":false,"pushDirections":{"north":true,"east":true,"south":true,"west":true},"pushResizeItems":false,"displayGrid":{"__symbolic":"select","expression":{"__symbolic":"reference","module":"./gridsterConfig.interface","name":"DisplayGrid","line":93,"character":15},"member":"OnDragAndResize"},"disableWindowResize":false,"disableWarnings":false,"scrollToNewItems":false}}}]

@@ -103,2 +103,4 @@ import { GridsterItem } from './gridsterItem.interface';

dragHandleClass?: string;
dropOverItems?: boolean;
dropOverItemsCallback?: (source: GridsterItem, target: GridsterItem, grid?: GridsterComponentInterface) => void;
}

@@ -105,0 +107,0 @@ export interface Resizable extends DragBase {

import { compactTypes, displayGrids, gridTypes } from './gridsterConfig.interface';
import { GridsterItem } from './gridsterItem.interface';
import { GridsterComponentInterface } from './gridster.interface';
export interface GridsterConfigS {

@@ -68,2 +69,4 @@ gridType: gridTypes;

dragHandleClass: string;
dropOverItems: boolean;
dropOverItemsCallback: (source: GridsterItem, target: GridsterItem, grid?: GridsterComponentInterface) => void;
}

@@ -70,0 +73,0 @@ export interface Resizable extends DragBase {

@@ -45,2 +45,3 @@ import { NgZone } from '@angular/core';

}>;
collision: GridsterItemComponentInterface | boolean;
constructor(gridsterItem: GridsterItemComponentInterface, gridster: GridsterComponentInterface, zone: NgZone);

@@ -47,0 +48,0 @@ destroy(): void;

@@ -28,2 +28,3 @@ "use strict";

delete this.gridster;
delete this.collision;
if (this.mousedown) {

@@ -139,2 +140,8 @@ this.mousedown();

GridsterDraggable.prototype.makeDrag = function () {
if (this.gridster.$options.draggable.dropOverItems && this.gridster.options.draggable
&& this.gridster.options.draggable.dropOverItemsCallback
&& this.collision !== true && this.collision !== false && this.collision.$item) {
this.gridster.options.draggable.dropOverItemsCallback(this.gridsterItem.item, this.collision.item, this.gridster);
}
delete this.collision;
this.gridsterItem.setSize();

@@ -150,2 +157,3 @@ this.gridsterItem.checkItemChanges(this.gridsterItem.$item, this.gridsterItem.item);

GridsterDraggable.prototype.calculateItemPosition = function () {
this.gridster.movingItem = this.gridsterItem.$item;
this.positionX = this.gridster.pixelsToPositionX(this.left, Math.round);

@@ -182,12 +190,16 @@ this.positionY = this.gridster.pixelsToPositionY(this.top, Math.round);

this.swap.swapItems();
if (this.gridster.checkCollision(this.gridsterItem.$item)) {
this.collision = this.gridster.checkCollision(this.gridsterItem.$item);
if (this.collision) {
this.gridsterItem.$item.x = this.positionXBackup;
this.gridsterItem.$item.y = this.positionYBackup;
if (this.gridster.$options.draggable.dropOverItems && this.collision !== true && this.collision.$item) {
this.gridster.movingItem = null;
}
}
else {
this.path.push({ x: this.gridsterItem.$item.x, y: this.gridsterItem.$item.y });
this.gridster.previewStyle(true);
}
this.push.checkPushBack();
}
this.gridster.previewStyle(true);
};

@@ -194,0 +206,0 @@ GridsterDraggable.prototype.toggle = function () {

@@ -1,1 +0,1 @@

[{"__symbolic":"module","version":4,"metadata":{"GridsterDraggable":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable","line":9,"character":1}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","module":"./gridsterItemComponent.interface","name":"GridsterItemComponentInterface","line":46,"character":28},{"__symbolic":"reference","module":"./gridster.interface","name":"GridsterComponentInterface","line":46,"character":70},{"__symbolic":"reference","module":"@angular/core","name":"NgZone","line":46,"character":112}]}],"destroy":[{"__symbolic":"method"}],"dragStart":[{"__symbolic":"method"}],"dragMove":[{"__symbolic":"method"}],"calculateItemPositionFromMousePosition":[{"__symbolic":"method"}],"dragStop":[{"__symbolic":"method"}],"cancelDrag":[{"__symbolic":"method"}],"makeDrag":[{"__symbolic":"method"}],"calculateItemPosition":[{"__symbolic":"method"}],"toggle":[{"__symbolic":"method"}],"dragStartDelay":[{"__symbolic":"method"}]}}}}]
[{"__symbolic":"module","version":4,"metadata":{"GridsterDraggable":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable","line":9,"character":1}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","module":"./gridsterItemComponent.interface","name":"GridsterItemComponentInterface","line":47,"character":28},{"__symbolic":"reference","module":"./gridster.interface","name":"GridsterComponentInterface","line":47,"character":70},{"__symbolic":"reference","module":"@angular/core","name":"NgZone","line":47,"character":112}]}],"destroy":[{"__symbolic":"method"}],"dragStart":[{"__symbolic":"method"}],"dragMove":[{"__symbolic":"method"}],"calculateItemPositionFromMousePosition":[{"__symbolic":"method"}],"dragStop":[{"__symbolic":"method"}],"cancelDrag":[{"__symbolic":"method"}],"makeDrag":[{"__symbolic":"method"}],"calculateItemPosition":[{"__symbolic":"method"}],"toggle":[{"__symbolic":"method"}],"dragStartDelay":[{"__symbolic":"method"}]}}}}]
{
"name": "angular-gridster2",
"version": "5.0.1",
"version": "5.1.0",
"license": "MIT",

@@ -5,0 +5,0 @@ "main": "dist/index.js",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc