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

fuelux

Package Overview
Dependencies
Maintainers
3
Versions
37
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fuelux - npm Package Compare versions

Comparing version 3.11.5 to 3.12.0

4

DETAILS.md

@@ -32,3 +32,3 @@ Additional details to supplement the brief nature of the README file.

* Download a .zip archive of the [latest release](http://www.fuelcdn.com/fuelux/3.11.4/fuelux.zip).
* Download a .zip archive of the [latest release](http://www.fuelcdn.com/fuelux/3.11.5/fuelux.zip).

@@ -43,3 +43,3 @@ ## AMD support

paths: {
'fuelux': 'http://www.fuelcdn.com/fuelux/3.11.4/'
'fuelux': 'http://www.fuelcdn.com/fuelux/3.11.5/'
//...

@@ -46,0 +46,0 @@ }

@@ -613,6 +613,2 @@ define(function (require) {

// if(options.search){
// resp.items = [];
// }
// call and simulate latency

@@ -626,2 +622,3 @@ setTimeout(function () {

$('#myRepeater').repeater({
searchOnKeyPress: true,
dataSource: function (options, callback) {

@@ -862,2 +859,5 @@ if (options.view === 'list') {

});
$('#mySearch').on('cleared.fu.search', function (event, text) {
log('cleared search');
});

@@ -1213,2 +1213,14 @@

var mostRecentlyOpenedFolderId = null;
$('#btnTreeRefresh').click(function () {
if (mostRecentlyOpenedFolderId === null) {
log('Please open a folder first. This is only needed for already opened and "DOM cached" folders.');
}
else {
var $itemToRefresh = $('#'+mostRecentlyOpenedFolderId)
$('#myTree1').tree('refreshFolder', $itemToRefresh);
}
});
// events

@@ -1230,2 +1242,3 @@ $('#myTree1').on('loaded.fu.tree', function (e) {

$('#myTree1').on('disclosedFolder.fu.tree', function (event, parentData) {
mostRecentlyOpenedFolderId = parentData.attr.id;
log('Opened Event, parent data: ', parentData);

@@ -1248,2 +1261,5 @@ });

});
$('#myTree1').on('refreshedFolder.fu.tree', function (event, parentData) {
log('Refreshed Folder Event: ', parentData);
});

@@ -1250,0 +1266,0 @@ /* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

@@ -100,22 +100,29 @@ /*

function _getContainer(element) {
var containerElement, isWindow;
if (element.attr('data-target')) {
containerElement = element.attr('data-target');
var targetSelector = element.attr('data-target');
var isWindow = true;
var containerElement;
if(!targetSelector) {
// no selection so find the relevant ancestor
$.each(element.parents(), function (index, parentElement) {
if ($(parentElement).css('overflow') !== 'visible') {
containerElement = parentElement;
isWindow = false;
return false;
}
});
}
else if (targetSelector !== 'window') {
containerElement = $(targetSelector);
isWindow = false;
} else {
}
// fallback to window
if (isWindow) {
containerElement = window;
isWindow = true;
}
$.each(element.parents(), function (index, value) {
if ($(value).css('overflow') !== 'visible') {
containerElement = value;
isWindow = false;
return false;
}
});
return {
overflowElement: $(containerElement),
isWindow: isWindow
overflowElement: $(containerElement),
isWindow: isWindow
};

@@ -122,0 +129,0 @@ }

@@ -273,7 +273,7 @@ /*

var $labelOverlay = $('<div class="repeater-list-heading empty">' + labelText + '</div>');
var $labelOverlay = $('<div class="repeater-list-heading">' + labelText + '</div>');
// repeater-list.less:302 has `margin-left: -9px;` which shifts this over and makes it not actually cover what it is supposed to cover. Make it wider to compensate.
var negative_maring_accomodation = 9;
$labelOverlay.data('forced-width', this.list_actions_width + negative_maring_accomodation);
var negative_margin_accomodation = 9;
$labelOverlay.data('forced-width', this.list_actions_width + negative_margin_accomodation);

@@ -283,3 +283,3 @@ var $th = $('<th>' + labelText + '</th>');

$actionsColumn.find('thead tr').addClass('empty-heading').append($th);
$actionsColumn.find('thead tr').addClass('empty-heading').html($th);
}

@@ -286,0 +286,0 @@

@@ -75,3 +75,5 @@ /*

this.$primaryPaging.find('.combobox').combobox();
this.$search.search();
this.$search.search({
searchOnKeyPress: this.options.searchOnKeyPress
});

@@ -797,3 +799,4 @@ this.$filters.on('changed.fu.selectlist', function (e, value) {

staticHeight: -1, //normally true or false. -1 means it will look for data-staticheight on the element
views: null //can be set to an object to configure multiple views of the same type
views: null, //can be set to an object to configure multiple views of the same type,
searchOnKeyPress: false
};

@@ -800,0 +803,0 @@

@@ -38,2 +38,6 @@ /*

if (this.$element.attr('data-searchOnKeyPress') === 'true'){
this.options.searchOnKeyPress = true;
}
this.$button = this.$element.find('button');

@@ -44,4 +48,3 @@ this.$input = this.$element.find('input');

this.$button.on('click.fu.search', $.proxy(this.buttonclicked, this));
this.$input.on('keydown.fu.search', $.proxy(this.keypress, this));
this.$input.on('keyup.fu.search', $.proxy(this.keypressed, this));
this.$input.on('keyup.fu.search', $.proxy(this.keypress, this));

@@ -92,9 +95,8 @@ this.activeSearch = '';

var val = this.$input.val();
var inputEmptyOrUnchanged = (val === '' || val === this.activeSearch);
if (this.activeSearch && inputEmptyOrUnchanged) {
this.clear();
} else if (val) {
if (val && val.length > 0) {
this.search(val);
}
else {
this.clear();
}
},

@@ -105,37 +107,31 @@

if ($(e.currentTarget).is('.disabled, :disabled')) return;
this.action();
},
keypress: function (e) {
if (e.which === 13) {
e.preventDefault();
if(this.$element.hasClass('searched')) {
this.clear();
}
else {
this.action();
}
},
keypressed: function (e) {
var remove = 'glyphicon-remove';
var search = 'glyphicon-search';
var val;
keypress: function (e) {
var ENTER_KEY_CODE = 13;
var TAB_KEY_CODE = 9;
var ESC_KEY_CODE = 27;
if (e.which === 13) {
if (e.which === ENTER_KEY_CODE) {
e.preventDefault();
this.action();
} else if (e.which === 9) {
}
else if(e.which === TAB_KEY_CODE) {
e.preventDefault();
} else {
val = this.$input.val();
if (val !== this.activeSearch || !val) {
this.$icon.removeClass(remove).addClass(search);
if (val) {
this.$element.removeClass('searched');
} else if (this.options.clearOnEmpty) {
this.clear();
}
} else {
this.$icon.removeClass(search).addClass(remove);
}
}
else if(e.which === ESC_KEY_CODE) {
e.preventDefault();
this.clear();
}
else if(this.options.searchOnKeyPress) {
// search on other keypress
this.action();
}
},

@@ -181,3 +177,4 @@

$.fn.search.defaults = {
clearOnEmpty: false
clearOnEmpty: false,
searchOnKeyPress: false
};

@@ -184,0 +181,0 @@

@@ -90,3 +90,3 @@ /*

populate: function populate($el) {
populate: function populate($el, isBackgroundProcess) {
var self = this;

@@ -96,4 +96,7 @@ var $parent = ($el.hasClass('tree')) ? $el : $el.parent();

var treeData = $parent.data();
isBackgroundProcess = isBackgroundProcess || false; // no user affordance needed (ex.- "loading")
loader.removeClass('hide hidden'); // hide is deprecated
if (isBackgroundProcess === false) {
loader.removeClass('hide hidden'); // hide is deprecated
}
this.options.dataSource(treeData ? treeData : {}, function (items) {

@@ -428,6 +431,24 @@ loader.addClass('hidden');

}
},
// This refreshes the children of a folder. Please destroy and re-initilize for "root level" refresh.
// The data of the refreshed folder is not updated. This control's architecture only allows updating of children.
// Folder renames should probably be handled directly on the node.
refreshFolder: function refreshFolder($el) {
var $treeFolder = $el.closest('.tree-branch');
var $treeFolderChildren = $treeFolder.find('.tree-branch-children');
$treeFolderChildren.eq(0).empty();
if ($treeFolder.hasClass('tree-open')) {
this.populate($treeFolderChildren, false);
}
else {
this.populate($treeFolderChildren, true);
}
this.$element.trigger('refreshedFolder.fu.tree', $treeFolder.data());
}
};
// ALIASES

@@ -434,0 +455,0 @@

@@ -9,3 +9,3 @@ // package metadata file for Meteor.js

summary: 'Base Fuel UX styles and controls',
version: '3.11.3',
version: '3.11.5',
git: 'https://github.com/ExactTarget/fuelux.git'

@@ -12,0 +12,0 @@ });

@@ -43,5 +43,5 @@ {

"grunt-zip": "0.17.1",
"load-grunt-config": "0.17.2",
"load-grunt-config": "0.19.0",
"load-grunt-tasks": "3.3.0",
"qunitjs": "1.19.0",
"qunitjs": "1.20.0",
"semver": "5.0.3",

@@ -87,3 +87,3 @@ "serve-static": "1.10.0"

"title": "Fuel UX",
"version": "3.11.5",
"version": "3.12.0",
"volo": {

@@ -90,0 +90,0 @@ "baseDir": "lib",

@@ -37,7 +37,7 @@ #[Fuel UX](http://getfuelux.com/)

<link href="//maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css" rel="stylesheet">
<link href="//www.fuelcdn.com/fuelux/3.11.4/css/fuelux.min.css" rel="stylesheet">
<link href="//www.fuelcdn.com/fuelux/3.11.5/css/fuelux.min.css" rel="stylesheet">
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.js"></script>
<script src="//maxcdn.bootstrapcdn.com/bootstrap/3.2.1/js/bootstrap.min.js"></script>
<script src="//www.fuelcdn.com/fuelux/3.11.4/js/fuelux.min.js"></script>
<script src="//www.fuelcdn.com/fuelux/3.11.5/js/fuelux.min.js"></script>

@@ -49,3 +49,3 @@ ```

- Request files from [the Fuel UX CDN](http://www.fuelcdn.com/fuelux/3.11.4/)
- Request files from [the Fuel UX CDN](http://www.fuelcdn.com/fuelux/3.11.5/)
- Install with [NPM](https://www.npmjs.com/package/fuelux): `npm install fuelux`.

@@ -52,0 +52,0 @@ - [Download the latest release](https://github.com/exacttarget/fuelux/archive/3.4.0.zip).

@@ -73,23 +73,2 @@ /*global QUnit:false, module:false, test:false, asyncTest:false, expect:false*/

test("should process sequential searches", function () {
var $search = $(html);
var searchText = '';
$search.search().on('searched.fu.search', function (e, text) { searchText = text; });
$search.find('input').val('search text');
$search.find('button').click();
equal($search.find('.glyphicon').attr('class'), 'glyphicon glyphicon-remove', 'search icon has changed');
equal(searchText, 'search text', 'search text was provided in event');
$search.find('input').val('search text 2').keyup();
equal($search.find('.glyphicon').attr('class'), 'glyphicon glyphicon-search', 'search icon has returned');
$search.find('button').click();
equal($search.find('.glyphicon').attr('class'), 'glyphicon glyphicon-remove', 'search icon has changed');
equal(searchText, 'search text 2', 'search text was provided in event');
});
test("should correctly respond to disable and enable methods", function () {

@@ -96,0 +75,0 @@ var $search = $(html);

@@ -18,2 +18,11 @@ /*global QUnit:false, module:false, test:false, asyncTest:false, expect:false*/

function guid () {
function s4 () {
return Math.floor((1 + Math.random()) * 0x10000)
.toString(16)
.substring(1);
}
return s4() + s4() + '-' + s4() + '-' + s4() + '-' + s4() + '-' + s4() + s4() + s4();
}
this.dataSource = function (options, callback) {

@@ -43,3 +52,3 @@ if (callCount >= callLimit) {

attr: {
id: 'folder1'
id: 'folder' + guid(),
}

@@ -51,3 +60,3 @@ },

attr: {
id: 'item1',
id: 'folder' + guid(),
'data-icon': 'glyphicon glyphicon-file'

@@ -60,3 +69,3 @@ }

attr: {
id: 'folder2',
id: 'folder' + guid(),
'data-children': false

@@ -76,3 +85,3 @@ }

attr: {
id: 'folder3'
id: 'folder' + guid(),
}

@@ -92,3 +101,3 @@ },

attr: {
id: 'folder4'
id: 'folder' + guid(),
}

@@ -120,2 +129,3 @@ },

};
}

@@ -375,3 +385,24 @@ });

test("should refresh an already opened/cached folder with new nodes", function () {
var $tree = $(html).find('#MyTree');
var $folderToRefresh;
var initialLoadedFolderId, refreshedLoadedFolderId;
var selector = '.tree-branch-children > li:eq(0)';
$tree.tree({
dataSource: this.dataSource
});
$folderToRefresh = $tree.find('.tree-branch:eq(1)');
// open folder
$tree.tree('discloseFolder', $folderToRefresh.find('.tree-branch-name'));
equal($folderToRefresh.find('.tree-branch-children > li').length, 8, 'Folder has been populated with items/sub-folders');
initialLoadedFolderId = $folderToRefresh.find(selector).attr('id');
// refresh and see if it's the same ID
$tree.tree('refreshFolder', $folderToRefresh);
refreshedLoadedFolderId = $folderToRefresh.find('.tree-branch-children > li:eq(0)').attr('id');
notEqual(refreshedLoadedFolderId, initialLoadedFolderId, 'Folder has been refreshed and populated with different items/sub-folders');
});
test("should destroy control", function () {

@@ -378,0 +409,0 @@ var $tree = $(html).find('#MyTree');

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

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