mirror of
https://github.com/stylersnico/librenms.git
synced 2026-07-27 16:08:55 +02:00
updated dist
This commit is contained in:
Vendored
+31
-4
@@ -1129,12 +1129,21 @@
|
||||
*
|
||||
* @method remove_widget
|
||||
* @param {HTMLElement} el The jQuery wrapped HTMLElement you want to remove.
|
||||
* @param {Boolean|Function} silent If true, widgets below the removed one
|
||||
* will not move up. If a Function is passed it will be used as callback.
|
||||
* @param {Function} callback Function executed when the widget is removed.
|
||||
* @return {Class} Returns the instance of the Gridster Class.
|
||||
*/
|
||||
fn.remove_widget = function(el, callback) {
|
||||
fn.remove_widget = function(el, silent, callback) {
|
||||
var $el = el instanceof jQuery ? el : $(el);
|
||||
var wgd = $el.coords().grid;
|
||||
|
||||
// if silent is a function assume it's a callback
|
||||
if ($.isFunction(silent)) {
|
||||
callback = silent;
|
||||
silent = false;
|
||||
}
|
||||
|
||||
this.cells_occupied_by_placeholder = {};
|
||||
this.$widgets = this.$widgets.not($el);
|
||||
|
||||
@@ -1145,9 +1154,11 @@
|
||||
$el.fadeOut($.proxy(function() {
|
||||
$el.remove();
|
||||
|
||||
$nexts.each($.proxy(function(i, widget) {
|
||||
this.move_widget_up( $(widget), wgd.size_y );
|
||||
}, this));
|
||||
if (!silent) {
|
||||
$nexts.each($.proxy(function(i, widget) {
|
||||
this.move_widget_up( $(widget), wgd.size_y );
|
||||
}, this));
|
||||
}
|
||||
|
||||
this.set_dom_grid_height();
|
||||
|
||||
@@ -1158,6 +1169,22 @@
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Remove all widgets from the grid.
|
||||
*
|
||||
* @method remove_all_widgets
|
||||
* @param {Function} callback Function executed for each widget removed.
|
||||
* @return {Class} Returns the instance of the Gridster Class.
|
||||
*/
|
||||
fn.remove_all_widgets = function(callback) {
|
||||
this.$widgets.each($.proxy(function(i, el){
|
||||
this.remove_widget(el, true, callback);
|
||||
}, this));
|
||||
|
||||
return this;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Returns a serialized array of the widgets in the grid.
|
||||
*
|
||||
|
||||
Vendored
+1
-1
@@ -1,3 +1,3 @@
|
||||
/*! gridster.js - v0.1.0 - 2012-10-15
|
||||
/*! gridster.js - v0.1.0 - 2012-10-20
|
||||
* http://gridster.net/
|
||||
* Copyright (c) 2012 ducksboard; Licensed MIT */.gridster{position:relative}.gridster>*{margin:0 auto;-webkit-transition:height .4s;-moz-transition:height .4s;-o-transition:height .4s;-ms-transition:height .4s;transition:height .4s}.gridster .gs_w{z-index:2;position:absolute}.ready .gs_w:not(.preview-holder){-webkit-transition:opacity .3s,left .3s,top .3s;-moz-transition:opacity .3s,left .3s,top .3s;-o-transition:opacity .3s,left .3s,top .3s;transition:opacity .3s,left .3s,top .3s}.ready .gs_w:not(.preview-holder){-webkit-transition:opacity .3s,left .3s,top .3s,width .3s,height .3s;-moz-transition:opacity .3s,left .3s,top .3s,width .3s,height .3s;-o-transition:opacity .3s,left .3s,top .3s,width .3s,height .3s;transition:opacity .3s,left .3s,top .3s,width .3s,height .3s}.gridster .preview-holder{z-index:1;position:absolute;background-color:#fff;border-color:#fff;opacity:.3}.gridster .player-revert{z-index:10!important;-webkit-transition:left .3s,top .3s!important;-moz-transition:left .3s,top .3s!important;-o-transition:left .3s,top .3s!important;transition:left .3s,top .3s!important}.gridster .dragging{z-index:10!important;-webkit-transition:all 0s!important;-moz-transition:all 0s!important;-o-transition:all 0s!important;transition:all 0s!important}
|
||||
Vendored
+1
-1
File diff suppressed because one or more lines are too long
Vendored
+31
-4
@@ -1129,12 +1129,21 @@
|
||||
*
|
||||
* @method remove_widget
|
||||
* @param {HTMLElement} el The jQuery wrapped HTMLElement you want to remove.
|
||||
* @param {Boolean|Function} silent If true, widgets below the removed one
|
||||
* will not move up. If a Function is passed it will be used as callback.
|
||||
* @param {Function} callback Function executed when the widget is removed.
|
||||
* @return {Class} Returns the instance of the Gridster Class.
|
||||
*/
|
||||
fn.remove_widget = function(el, callback) {
|
||||
fn.remove_widget = function(el, silent, callback) {
|
||||
var $el = el instanceof jQuery ? el : $(el);
|
||||
var wgd = $el.coords().grid;
|
||||
|
||||
// if silent is a function assume it's a callback
|
||||
if ($.isFunction(silent)) {
|
||||
callback = silent;
|
||||
silent = false;
|
||||
}
|
||||
|
||||
this.cells_occupied_by_placeholder = {};
|
||||
this.$widgets = this.$widgets.not($el);
|
||||
|
||||
@@ -1145,9 +1154,11 @@
|
||||
$el.fadeOut($.proxy(function() {
|
||||
$el.remove();
|
||||
|
||||
$nexts.each($.proxy(function(i, widget) {
|
||||
this.move_widget_up( $(widget), wgd.size_y );
|
||||
}, this));
|
||||
if (!silent) {
|
||||
$nexts.each($.proxy(function(i, widget) {
|
||||
this.move_widget_up( $(widget), wgd.size_y );
|
||||
}, this));
|
||||
}
|
||||
|
||||
this.set_dom_grid_height();
|
||||
|
||||
@@ -1158,6 +1169,22 @@
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Remove all widgets from the grid.
|
||||
*
|
||||
* @method remove_all_widgets
|
||||
* @param {Function} callback Function executed for each widget removed.
|
||||
* @return {Class} Returns the instance of the Gridster Class.
|
||||
*/
|
||||
fn.remove_all_widgets = function(callback) {
|
||||
this.$widgets.each($.proxy(function(i, el){
|
||||
this.remove_widget(el, true, callback);
|
||||
}, this));
|
||||
|
||||
return this;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Returns a serialized array of the widgets in the grid.
|
||||
*
|
||||
|
||||
+1
-1
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user