jupyter-js-filebrowser
Advanced tools
Comparing version 0.4.1 to 0.4.2
@@ -648,7 +648,7 @@ // Copyright (c) Jupyter Development Team. | ||
var _this = this; | ||
// Make sure the source node is selected. | ||
// If the source node is not selected, use just that node. | ||
var selected = this._model.selected; | ||
var source = this._items[index]; | ||
if (!source.classList.contains(SELECTED_CLASS)) { | ||
source.classList.add(SELECTED_CLASS); | ||
this._updateSelected(); | ||
selected = [index]; | ||
} | ||
@@ -658,5 +658,5 @@ // Create the drag image. | ||
dragImage.removeChild(dragImage.lastChild); | ||
if (this._model.selected.length > 1) { | ||
if (selected.length > 1) { | ||
var text = dragImage.getElementsByClassName(ITEM_TEXT_CLASS)[0]; | ||
text.textContent = '(' + this._model.selected.length + ')'; | ||
text.textContent = '(' + selected.length + ')'; | ||
} | ||
@@ -671,4 +671,4 @@ // Set up the drag event. | ||
this._drag.mimeData.setData(utils_1.CONTENTS_MIME, null); | ||
if (this._model.selected.length == 1) { | ||
var item = this._model.items[this._model.selected[0]]; | ||
if (selected.length == 1) { | ||
var item = this._model.items[selected[0]]; | ||
if (item.type !== 'directory') { | ||
@@ -675,0 +675,0 @@ this._drag.mimeData.setData(FACTORY_MIME, index_1.FileBrowserWidget.widgetFactory); |
{ | ||
"name": "jupyter-js-filebrowser", | ||
"version": "0.4.1", | ||
"version": "0.4.2", | ||
"description": "File browser widget for Jupyter", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
111955