Browse Source

KERNEL-2019 feat:新增lodash的set方法

es6
zsmj1994 5 years ago
parent
commit
e01c880292
  1. 3
      changelog.md
  2. 612
      dist/2.0/fineui.ie.js
  3. 2
      dist/2.0/fineui.ie.js.map
  4. 96
      dist/2.0/fineui.ie.min.js
  5. 2
      dist/2.0/fineui.ie.min.js.map
  6. 634
      dist/2.0/fineui.js
  7. 2
      dist/2.0/fineui.js.map
  8. 96
      dist/2.0/fineui.min.js
  9. 2
      dist/2.0/fineui.min.js.map
  10. 612
      dist/bundle.ie.js
  11. 2
      dist/bundle.ie.js.map
  12. 96
      dist/bundle.ie.min.js
  13. 2
      dist/bundle.ie.min.js.map
  14. 634
      dist/bundle.js
  15. 2
      dist/bundle.js.map
  16. 96
      dist/bundle.min.js
  17. 2
      dist/bundle.min.js.map
  18. 7
      dist/case.js
  19. 2
      dist/case.js.map
  20. 571
      dist/core.js
  21. 2
      dist/core.js.map
  22. 612
      dist/fineui.ie.js
  23. 2
      dist/fineui.ie.js.map
  24. 94
      dist/fineui.ie.min.js
  25. 2
      dist/fineui.ie.min.js.map
  26. 634
      dist/fineui.js
  27. 2
      dist/fineui.js.map
  28. 94
      dist/fineui.min.js
  29. 2
      dist/fineui.min.js.map
  30. 630
      dist/fineui_without_jquery_polyfill.js
  31. 2
      dist/fineui_without_jquery_polyfill.js.map
  32. 22
      dist/fix/fix.compact.js
  33. 556
      dist/utils.js
  34. 2
      dist/utils.js.map
  35. 12
      dist/utils.min.js
  36. 2
      dist/utils.min.js.map
  37. 34
      dist/widget.js
  38. 2
      dist/widget.js.map
  39. 2
      lodash.md
  40. 10
      src/core/base.js
  41. 493
      src/core/lodash.js
  42. 3
      src/core/utils/tree.js

3
changelog.md

@ -1,4 +1,7 @@
# 更新日志 # 更新日志
2.0(2019-11)
-新增BI.set(object, path, value)方法
2.0(2019-10) 2.0(2019-10)
- 修改了下拉树展开图标模糊的问题 - 修改了下拉树展开图标模糊的问题
- 修复了下拉树搜索高亮字符与正常字符间存在间距的问题 - 修复了下拉树搜索高亮字符与正常字符间存在间距的问题

612
dist/2.0/fineui.ie.js vendored

File diff suppressed because it is too large Load Diff

2
dist/2.0/fineui.ie.js.map vendored

File diff suppressed because one or more lines are too long

96
dist/2.0/fineui.ie.min.js vendored

File diff suppressed because one or more lines are too long

2
dist/2.0/fineui.ie.min.js.map vendored

File diff suppressed because one or more lines are too long

634
dist/2.0/fineui.js vendored

File diff suppressed because it is too large Load Diff

2
dist/2.0/fineui.js.map vendored

File diff suppressed because one or more lines are too long

96
dist/2.0/fineui.min.js vendored

File diff suppressed because one or more lines are too long

2
dist/2.0/fineui.min.js.map vendored

File diff suppressed because one or more lines are too long

612
dist/bundle.ie.js vendored

File diff suppressed because it is too large Load Diff

2
dist/bundle.ie.js.map vendored

File diff suppressed because one or more lines are too long

96
dist/bundle.ie.min.js vendored

File diff suppressed because one or more lines are too long

2
dist/bundle.ie.min.js.map vendored

File diff suppressed because one or more lines are too long

634
dist/bundle.js vendored

File diff suppressed because it is too large Load Diff

2
dist/bundle.js.map vendored

File diff suppressed because one or more lines are too long

96
dist/bundle.min.js vendored

File diff suppressed because one or more lines are too long

2
dist/bundle.min.js.map vendored

File diff suppressed because one or more lines are too long

7
dist/case.js vendored

@ -2925,11 +2925,11 @@ BI.ColorPicker = BI.inherit(BI.Widget, {
}, { }, {
value: "#c3d825" value: "#c3d825"
}, { }, {
value: "#bce2e8" value: "#bbe2e7"
}, { }, {
value: "#85d3cd" value: "#85d3cd"
}, { }, {
value: "#bce2e8" value: "#bde1e6"
}, { }, {
value: "#a0d8ef" value: "#a0d8ef"
}, { }, {
@ -5624,7 +5624,6 @@ BI.ShelterEditor = BI.inherit(BI.Widget, {
}); });
this._showHint(); this._showHint();
self._checkText(); self._checkText();
BI.isKey(o.keyword) && this.text.doRedMark(o.keyword);
}, },
_checkText: function () { _checkText: function () {
@ -5636,6 +5635,7 @@ BI.ShelterEditor = BI.inherit(BI.Widget, {
this.text.setValue(this.editor.getValue()); this.text.setValue(this.editor.getValue());
this.text.element.removeClass("bi-water-mark"); this.text.element.removeClass("bi-water-mark");
} }
BI.isKey(o.keyword) && this.text.doRedMark(o.keyword);
}, },
_showInput: function () { _showInput: function () {
@ -5726,7 +5726,6 @@ BI.ShelterEditor = BI.inherit(BI.Widget, {
var o = this.options; var o = this.options;
this.editor.setValue(k); this.editor.setValue(k);
this._checkText(); this._checkText();
BI.isKey(o.keyword) && this.text.doRedMark(o.keyword);
}, },
getValue: function () { getValue: function () {

2
dist/case.js.map vendored

File diff suppressed because one or more lines are too long

571
dist/core.js vendored

File diff suppressed because it is too large Load Diff

2
dist/core.js.map vendored

File diff suppressed because one or more lines are too long

612
dist/fineui.ie.js vendored

File diff suppressed because it is too large Load Diff

2
dist/fineui.ie.js.map vendored

File diff suppressed because one or more lines are too long

94
dist/fineui.ie.min.js vendored

File diff suppressed because one or more lines are too long

2
dist/fineui.ie.min.js.map vendored

File diff suppressed because one or more lines are too long

634
dist/fineui.js vendored

File diff suppressed because it is too large Load Diff

2
dist/fineui.js.map vendored

File diff suppressed because one or more lines are too long

94
dist/fineui.min.js vendored

File diff suppressed because one or more lines are too long

2
dist/fineui.min.js.map vendored

File diff suppressed because one or more lines are too long

630
dist/fineui_without_jquery_polyfill.js vendored

File diff suppressed because it is too large Load Diff

2
dist/fineui_without_jquery_polyfill.js.map vendored

File diff suppressed because one or more lines are too long

22
dist/fix/fix.compact.js vendored

@ -100,11 +100,12 @@
pushContext(context); pushContext(context);
pushed = true; pushed = true;
} }
try { var result = _create.apply(this, arguments);
var result = _create.apply(this, arguments); // try {
} catch (e) { // var result = _create.apply(this, arguments);
console.error(e); // } catch (e) {
} // console.error(e);
// }
pushed && popContext(); pushed && popContext();
return result; return result;
}; };
@ -166,11 +167,12 @@
pushTarget(this.store); pushTarget(this.store);
initWatch(this, this.watch); initWatch(this, this.watch);
} }
try { _render.apply(this, arguments);
_render.apply(this, arguments); // try {
} catch (e) { // _render.apply(this, arguments);
console.error(e); // } catch (e) {
} // console.error(e);
// }
needPop && popTarget(); needPop && popTarget();
}; };

556
dist/utils.js vendored

File diff suppressed because it is too large Load Diff

2
dist/utils.js.map vendored

File diff suppressed because one or more lines are too long

12
dist/utils.min.js vendored

File diff suppressed because one or more lines are too long

2
dist/utils.min.js.map vendored

File diff suppressed because one or more lines are too long

34
dist/widget.js vendored

@ -6538,7 +6538,13 @@ BI.MultiLayerSelectTreeCombo = BI.inherit(BI.Widget, {
self.combo.hideView(); self.combo.hideView();
self.fireEvent(BI.MultiLayerSelectTreeCombo.EVENT_CHANGE); self.fireEvent(BI.MultiLayerSelectTreeCombo.EVENT_CHANGE);
} }
}] }],
onLoaded: function () {
BI.nextTick(function () {
self.combo.adjustWidth();
self.combo.adjustHeight();
});
}
}, },
value: o.value, value: o.value,
maxHeight: 400, maxHeight: 400,
@ -6936,7 +6942,8 @@ BI.MultiLayerSelectTreePopup = BI.inherit(BI.Widget, {
isDefaultInit: false, isDefaultInit: false,
itemsCreator: BI.emptyFn, itemsCreator: BI.emptyFn,
items: [], items: [],
value: "" value: "",
onLoaded: BI.emptyFn
}); });
}, },
@ -6952,7 +6959,11 @@ BI.MultiLayerSelectTreePopup = BI.inherit(BI.Widget, {
itemsCreator: o.itemsCreator, itemsCreator: o.itemsCreator,
keywordGetter: o.keywordGetter, keywordGetter: o.keywordGetter,
value: o.value, value: o.value,
scrollable: null scrollable: null,
onLoaded: function () {
self.tree.check();
o.onLoaded();
}
}); });
BI.createWidget({ BI.createWidget({
@ -7720,7 +7731,13 @@ BI.MultiLayerSingleTreeCombo = BI.inherit(BI.Widget, {
self.combo.hideView(); self.combo.hideView();
self.fireEvent(BI.MultiLayerSingleTreeCombo.EVENT_CHANGE); self.fireEvent(BI.MultiLayerSingleTreeCombo.EVENT_CHANGE);
} }
}] }],
onLoaded: function () {
BI.nextTick(function () {
self.combo.adjustWidth();
self.combo.adjustHeight();
});
}
}, },
value: o.value, value: o.value,
maxHeight: 400, maxHeight: 400,
@ -8117,7 +8134,8 @@ BI.MultiLayerSingleTreePopup = BI.inherit(BI.Widget, {
tipText: BI.i18nText("BI-No_Selected_Item"), tipText: BI.i18nText("BI-No_Selected_Item"),
isDefaultInit: false, isDefaultInit: false,
itemsCreator: BI.emptyFn, itemsCreator: BI.emptyFn,
items: [] items: [],
onLoaded: BI.emptyFn
}); });
}, },
@ -8133,7 +8151,11 @@ BI.MultiLayerSingleTreePopup = BI.inherit(BI.Widget, {
itemsCreator: o.itemsCreator, itemsCreator: o.itemsCreator,
keywordGetter: o.keywordGetter, keywordGetter: o.keywordGetter,
value: o.value, value: o.value,
scrollable: null scrollable: null,
onLoaded: function () {
self.tree.check();
o.onLoaded();
}
}); });
BI.createWidget({ BI.createWidget({

2
dist/widget.js.map vendored

File diff suppressed because one or more lines are too long

2
lodash.md

@ -1 +1 @@
lodash core plus="debounce,throttle,get,findIndex,findLastIndex,findKey,findLastKey,isArrayLike,invert,invertBy,uniq,uniqBy,omit,omitBy,zip,unzip,rest,range,random,reject,intersection,drop,countBy,union,zipObject,initial,cloneDeep,clamp,isPlainObject,take,takeRight,without,difference,defaultsDeep,trim,merge,groupBy,uniqBy" lodash core plus="debounce,throttle,get,set,findIndex,findLastIndex,findKey,findLastKey,isArrayLike,invert,invertBy,uniq,uniqBy,omit,omitBy,zip,unzip,rest,range,random,reject,intersection,drop,countBy,union,zipObject,initial,cloneDeep,clamp,isPlainObject,take,takeRight,without,difference,defaultsDeep,trim,merge,groupBy,uniqBy"

10
src/core/base.js

@ -162,7 +162,7 @@ if (!_global.BI) {
_.each(["where", "findWhere", "invoke", "pluck", "shuffle", "sample", "toArray", "size"], function (name) { _.each(["where", "findWhere", "invoke", "pluck", "shuffle", "sample", "toArray", "size"], function (name) {
BI[name] = _apply(name); BI[name] = _apply(name);
}); });
_.each(["get", "each", "map", "reduce", "reduceRight", "find", "filter", "reject", "every", "all", "some", "any", "max", "min", _.each(["get", "set", "each", "map", "reduce", "reduceRight", "find", "filter", "reject", "every", "all", "some", "any", "max", "min",
"sortBy", "groupBy", "indexBy", "countBy", "partition", "clamp"], function (name) { "sortBy", "groupBy", "indexBy", "countBy", "partition", "clamp"], function (name) {
if (name === "any") { if (name === "any") {
BI[name] = _applyFunc("some"); BI[name] = _applyFunc("some");
@ -441,7 +441,7 @@ if (!_global.BI) {
}; };
} }
var F = function () { var F = function () {
}, spp = sp.prototype; }, spp = sp.prototype;
F.prototype = spp; F.prototype = spp;
sb.prototype = new F(); sb.prototype = new F();
sb.superclass = spp; sb.superclass = spp;
@ -505,7 +505,7 @@ if (!_global.BI) {
}, },
isNull: function (obj) { isNull: function (obj) {
return typeof obj === "undefined" || obj === null; return typeof obj === "undefined" || obj === null;
}, },
isEmptyArray: function (arr) { isEmptyArray: function (arr) {
@ -676,7 +676,7 @@ if (!_global.BI) {
var pending = false; var pending = false;
var timerFunc; var timerFunc;
function nextTickHandler () { function nextTickHandler() {
pending = false; pending = false;
var copies = callbacks.slice(0); var copies = callbacks.slice(0);
callbacks = []; callbacks = [];
@ -709,7 +709,7 @@ if (!_global.BI) {
setTimeout(nextTickHandler, 0); setTimeout(nextTickHandler, 0);
}; };
} }
return function queueNextTick (cb) { return function queueNextTick(cb) {
var _resolve; var _resolve;
var args = [].slice.call(arguments, 1); var args = [].slice.call(arguments, 1);
callbacks.push(function () { callbacks.push(function () {

493
src/core/lodash.js

@ -1,7 +1,7 @@
/** /**
* @license * @license
* Lodash (Custom Build) <https://lodash.com/> * Lodash (Custom Build) <https://lodash.com/>
* Build: `lodash core plus="debounce,throttle,get,findIndex,findLastIndex,findKey,findLastKey,isArrayLike,invert,invertBy,uniq,uniqBy,omit,omitBy,zip,unzip,rest,range,random,reject,intersection,drop,countBy,union,zipObject,initial,cloneDeep,clamp,isPlainObject,take,takeRight,without,difference,defaultsDeep,trim,merge,groupBy,uniqBy"` * Build: `lodash core plus="debounce,throttle,get,set,findIndex,findLastIndex,findKey,findLastKey,isArrayLike,invert,invertBy,uniq,uniqBy,omit,omitBy,zip,unzip,rest,range,random,reject,intersection,drop,countBy,union,zipObject,initial,cloneDeep,clamp,isPlainObject,take,takeRight,without,difference,defaultsDeep,trim,merge,groupBy,uniqBy"`
* Copyright JS Foundation and other contributors <https://js.foundation/> * Copyright JS Foundation and other contributors <https://js.foundation/>
* Released under MIT license <https://lodash.com/license> * Released under MIT license <https://lodash.com/license>
* Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE> * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
@ -194,34 +194,34 @@
/** Used to identify `toStringTag` values of typed arrays. */ /** Used to identify `toStringTag` values of typed arrays. */
var typedArrayTags = {}; var typedArrayTags = {};
typedArrayTags[float32Tag] = typedArrayTags[float64Tag] = typedArrayTags[float32Tag] = typedArrayTags[float64Tag] =
typedArrayTags[int8Tag] = typedArrayTags[int16Tag] = typedArrayTags[int8Tag] = typedArrayTags[int16Tag] =
typedArrayTags[int32Tag] = typedArrayTags[uint8Tag] = typedArrayTags[int32Tag] = typedArrayTags[uint8Tag] =
typedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] = typedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] =
typedArrayTags[uint32Tag] = true; typedArrayTags[uint32Tag] = true;
typedArrayTags[argsTag] = typedArrayTags[arrayTag] = typedArrayTags[argsTag] = typedArrayTags[arrayTag] =
typedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] = typedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] =
typedArrayTags[dataViewTag] = typedArrayTags[dateTag] = typedArrayTags[dataViewTag] = typedArrayTags[dateTag] =
typedArrayTags[errorTag] = typedArrayTags[funcTag] = typedArrayTags[errorTag] = typedArrayTags[funcTag] =
typedArrayTags[mapTag] = typedArrayTags[numberTag] = typedArrayTags[mapTag] = typedArrayTags[numberTag] =
typedArrayTags[objectTag] = typedArrayTags[regexpTag] = typedArrayTags[objectTag] = typedArrayTags[regexpTag] =
typedArrayTags[setTag] = typedArrayTags[stringTag] = typedArrayTags[setTag] = typedArrayTags[stringTag] =
typedArrayTags[weakMapTag] = false; typedArrayTags[weakMapTag] = false;
/** Used to identify `toStringTag` values supported by `_.clone`. */ /** Used to identify `toStringTag` values supported by `_.clone`. */
var cloneableTags = {}; var cloneableTags = {};
cloneableTags[argsTag] = cloneableTags[arrayTag] = cloneableTags[argsTag] = cloneableTags[arrayTag] =
cloneableTags[arrayBufferTag] = cloneableTags[dataViewTag] = cloneableTags[arrayBufferTag] = cloneableTags[dataViewTag] =
cloneableTags[boolTag] = cloneableTags[dateTag] = cloneableTags[boolTag] = cloneableTags[dateTag] =
cloneableTags[float32Tag] = cloneableTags[float64Tag] = cloneableTags[float32Tag] = cloneableTags[float64Tag] =
cloneableTags[int8Tag] = cloneableTags[int16Tag] = cloneableTags[int8Tag] = cloneableTags[int16Tag] =
cloneableTags[int32Tag] = cloneableTags[mapTag] = cloneableTags[int32Tag] = cloneableTags[mapTag] =
cloneableTags[numberTag] = cloneableTags[objectTag] = cloneableTags[numberTag] = cloneableTags[objectTag] =
cloneableTags[regexpTag] = cloneableTags[setTag] = cloneableTags[regexpTag] = cloneableTags[setTag] =
cloneableTags[stringTag] = cloneableTags[symbolTag] = cloneableTags[stringTag] = cloneableTags[symbolTag] =
cloneableTags[uint8Tag] = cloneableTags[uint8ClampedTag] = cloneableTags[uint8Tag] = cloneableTags[uint8ClampedTag] =
cloneableTags[uint16Tag] = cloneableTags[uint32Tag] = true; cloneableTags[uint16Tag] = cloneableTags[uint32Tag] = true;
cloneableTags[errorTag] = cloneableTags[funcTag] = cloneableTags[errorTag] = cloneableTags[funcTag] =
cloneableTags[weakMapTag] = false; cloneableTags[weakMapTag] = false;
/** Used to map characters to HTML entities. */ /** Used to map characters to HTML entities. */
var htmlEscapes = { var htmlEscapes = {
@ -578,8 +578,8 @@
*/ */
function baseIndexOf(array, value, fromIndex) { function baseIndexOf(array, value, fromIndex) {
return value === value return value === value
? strictIndexOf(array, value, fromIndex) ? strictIndexOf(array, value, fromIndex)
: baseFindIndex(array, baseIsNaN, fromIndex); : baseFindIndex(array, baseIsNaN, fromIndex);
} }
/** /**
@ -635,8 +635,8 @@
function baseReduce(collection, iteratee, accumulator, initAccum, eachFunc) { function baseReduce(collection, iteratee, accumulator, initAccum, eachFunc) {
eachFunc(collection, function(value, index, collection) { eachFunc(collection, function(value, index, collection) {
accumulator = initAccum accumulator = initAccum
? (initAccum = false, value) ? (initAccum = false, value)
: iteratee(accumulator, value, index, collection); : iteratee(accumulator, value, index, collection);
}); });
return accumulator; return accumulator;
} }
@ -889,8 +889,8 @@
*/ */
function safeGet(object, key) { function safeGet(object, key) {
return key == '__proto__' return key == '__proto__'
? undefined ? undefined
: object[key]; : object[key];
} }
/** /**
@ -941,8 +941,8 @@
*/ */
function stringSize(string) { function stringSize(string) {
return hasUnicode(string) return hasUnicode(string)
? unicodeSize(string) ? unicodeSize(string)
: asciiSize(string); : asciiSize(string);
} }
/** /**
@ -954,8 +954,8 @@
*/ */
function stringToArray(string) { function stringToArray(string) {
return hasUnicode(string) return hasUnicode(string)
? unicodeToArray(string) ? unicodeToArray(string)
: asciiToArray(string); : asciiToArray(string);
} }
/** /**
@ -1024,8 +1024,8 @@
/** Used to detect if a method is native. */ /** Used to detect if a method is native. */
var reIsNative = RegExp('^' + var reIsNative = RegExp('^' +
funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\$&') funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\$&')
.replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$' .replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$'
); );
/** Built-in value references. */ /** Built-in value references. */
@ -1362,30 +1362,30 @@
var result = []; var result = [];
outer: outer:
while (length-- && resIndex < takeCount) { while (length-- && resIndex < takeCount) {
index += dir; index += dir;
var iterIndex = -1, var iterIndex = -1,
value = array[index]; value = array[index];
while (++iterIndex < iterLength) { while (++iterIndex < iterLength) {
var data = iteratees[iterIndex], var data = iteratees[iterIndex],
iteratee = data.iteratee, iteratee = data.iteratee,
type = data.type, type = data.type,
computed = iteratee(value); computed = iteratee(value);
if (type == LAZY_MAP_FLAG) { if (type == LAZY_MAP_FLAG) {
value = computed; value = computed;
} else if (!computed) { } else if (!computed) {
if (type == LAZY_FILTER_FLAG) { if (type == LAZY_FILTER_FLAG) {
continue outer; continue outer;
} else { } else {
break outer; break outer;
}
}
} }
result[resIndex++] = value;
} }
}
result[resIndex++] = value;
}
return result; return result;
} }
@ -1893,14 +1893,14 @@
for (var key in value) { for (var key in value) {
if ((inherited || hasOwnProperty.call(value, key)) && if ((inherited || hasOwnProperty.call(value, key)) &&
!(skipIndexes && ( !(skipIndexes && (
// Safari 9 has enumerable `arguments.length` in strict mode. // Safari 9 has enumerable `arguments.length` in strict mode.
key == 'length' || key == 'length' ||
// Node.js 0.10 has enumerable non-index properties on buffers. // Node.js 0.10 has enumerable non-index properties on buffers.
(isBuff && (key == 'offset' || key == 'parent')) || (isBuff && (key == 'offset' || key == 'parent')) ||
// PhantomJS 2 has enumerable non-index properties on typed arrays. // PhantomJS 2 has enumerable non-index properties on typed arrays.
(isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset')) || (isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset')) ||
// Skip index properties. // Skip index properties.
isIndex(key, length) isIndex(key, length)
))) { ))) {
result.push(key); result.push(key);
} }
@ -2115,8 +2115,8 @@
result = (isFlat || isFunc) ? {} : initCloneObject(value); result = (isFlat || isFunc) ? {} : initCloneObject(value);
if (!isDeep) { if (!isDeep) {
return isFlat return isFlat
? copySymbolsIn(value, baseAssignIn(result, value)) ? copySymbolsIn(value, baseAssignIn(result, value))
: copySymbols(value, baseAssign(result, value)); : copySymbols(value, baseAssign(result, value));
} }
} else { } else {
if (!cloneableTags[tag]) { if (!cloneableTags[tag]) {
@ -2150,8 +2150,8 @@
} }
var keysFunc = isFull var keysFunc = isFull
? (isFlat ? getAllKeysIn : getAllKeys) ? (isFlat ? getAllKeysIn : getAllKeys)
: (isFlat ? keysIn : keys); : (isFlat ? keysIn : keys);
var props = isArr ? undefined : keysFunc(value); var props = isArr ? undefined : keysFunc(value);
arrayEach(props || value, function(subValue, key) { arrayEach(props || value, function(subValue, key) {
@ -2217,24 +2217,24 @@
values = new SetCache(values); values = new SetCache(values);
} }
outer: outer:
while (++index < length) { while (++index < length) {
var value = array[index], var value = array[index],
computed = iteratee == null ? value : iteratee(value); computed = iteratee == null ? value : iteratee(value);
value = (comparator || value !== 0) ? value : 0; value = (comparator || value !== 0) ? value : 0;
if (isCommon && computed === computed) { if (isCommon && computed === computed) {
var valuesIndex = valuesLength; var valuesIndex = valuesLength;
while (valuesIndex--) { while (valuesIndex--) {
if (values[valuesIndex] === computed) { if (values[valuesIndex] === computed) {
continue outer; continue outer;
}
}
result.push(value);
}
else if (!includes(values, computed, comparator)) {
result.push(value);
} }
} }
result.push(value);
}
else if (!includes(values, computed, comparator)) {
result.push(value);
}
}
return result; return result;
} }
@ -2285,9 +2285,9 @@
current = iteratee(value); current = iteratee(value);
if (current != null && (computed === undefined if (current != null && (computed === undefined
? (current === current && !isSymbol(current)) ? (current === current && !isSymbol(current))
: comparator(current, computed) : comparator(current, computed)
)) { )) {
var computed = current, var computed = current,
result = value; result = value;
} }
@ -2459,8 +2459,8 @@
return value === undefined ? undefinedTag : nullTag; return value === undefined ? undefinedTag : nullTag;
} }
return (symToStringTag && symToStringTag in Object(value)) return (symToStringTag && symToStringTag in Object(value))
? getRawTag(value) ? getRawTag(value)
: objectToString(value); : objectToString(value);
} }
/** /**
@ -2526,8 +2526,8 @@
} }
maxLength = nativeMin(array.length, maxLength); maxLength = nativeMin(array.length, maxLength);
caches[othIndex] = !comparator && (iteratee || (length >= 120 && array.length >= 120)) caches[othIndex] = !comparator && (iteratee || (length >= 120 && array.length >= 120))
? new SetCache(othIndex && array) ? new SetCache(othIndex && array)
: undefined; : undefined;
} }
array = arrays[0]; array = arrays[0];
@ -2535,31 +2535,31 @@
seen = caches[0]; seen = caches[0];
outer: outer:
while (++index < length && result.length < maxLength) { while (++index < length && result.length < maxLength) {
var value = array[index], var value = array[index],
computed = iteratee ? iteratee(value) : value; computed = iteratee ? iteratee(value) : value;
value = (comparator || value !== 0) ? value : 0; value = (comparator || value !== 0) ? value : 0;
if (!(seen if (!(seen
? cacheHas(seen, computed) ? cacheHas(seen, computed)
: includes(result, computed, comparator) : includes(result, computed, comparator)
)) { )) {
othIndex = othLength; othIndex = othLength;
while (--othIndex) { while (--othIndex) {
var cache = caches[othIndex]; var cache = caches[othIndex];
if (!(cache if (!(cache
? cacheHas(cache, computed) ? cacheHas(cache, computed)
: includes(arrays[othIndex], computed, comparator)) : includes(arrays[othIndex], computed, comparator))
) { ) {
continue outer; continue outer;
}
}
if (seen) {
seen.push(computed);
}
result.push(value);
} }
} }
if (seen) {
seen.push(computed);
}
result.push(value);
}
}
return result; return result;
} }
@ -2681,8 +2681,8 @@
if (isSameTag && !objIsObj) { if (isSameTag && !objIsObj) {
stack || (stack = new Stack); stack || (stack = new Stack);
return (objIsArr || isTypedArray(object)) return (objIsArr || isTypedArray(object))
? equalArrays(object, other, bitmask, customizer, equalFunc, stack) ? equalArrays(object, other, bitmask, customizer, equalFunc, stack)
: equalByTag(object, other, objTag, bitmask, customizer, equalFunc, stack); : equalByTag(object, other, objTag, bitmask, customizer, equalFunc, stack);
} }
if (!(bitmask & COMPARE_PARTIAL_FLAG)) { if (!(bitmask & COMPARE_PARTIAL_FLAG)) {
var objIsWrapped = objIsObj && hasOwnProperty.call(object, '__wrapped__'), var objIsWrapped = objIsObj && hasOwnProperty.call(object, '__wrapped__'),
@ -2736,9 +2736,9 @@
while (index--) { while (index--) {
var data = matchData[index]; var data = matchData[index];
if ((noCustomizer && data[2]) if ((noCustomizer && data[2])
? data[1] !== object[data[0]] ? data[1] !== object[data[0]]
: !(data[0] in object) : !(data[0] in object)
) { ) {
return false; return false;
} }
} }
@ -2758,9 +2758,9 @@
var result = customizer(objValue, srcValue, key, object, source, stack); var result = customizer(objValue, srcValue, key, object, source, stack);
} }
if (!(result === undefined if (!(result === undefined
? baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG, customizer, stack) ? baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG, customizer, stack)
: result : result
)) { )) {
return false; return false;
} }
} }
@ -2815,7 +2815,7 @@
*/ */
function baseIsTypedArray(value) { function baseIsTypedArray(value) {
return isObjectLike(value) && return isObjectLike(value) &&
isLength(value.length) && !!typedArrayTags[baseGetTag(value)]; isLength(value.length) && !!typedArrayTags[baseGetTag(value)];
} }
/** /**
@ -2836,8 +2836,8 @@
} }
if (typeof value == 'object') { if (typeof value == 'object') {
return isArray(value) return isArray(value)
? baseMatchesProperty(value[0], value[1]) ? baseMatchesProperty(value[0], value[1])
: baseMatches(value); : baseMatches(value);
} }
return property(value); return property(value);
} }
@ -2947,8 +2947,8 @@
return function(object) { return function(object) {
var objValue = get(object, path); var objValue = get(object, path);
return (objValue === undefined && objValue === srcValue) return (objValue === undefined && objValue === srcValue)
? hasIn(object, path) ? hasIn(object, path)
: baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG); : baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG);
}; };
} }
@ -2974,8 +2974,8 @@
} }
else { else {
var newValue = customizer var newValue = customizer
? customizer(safeGet(object, key), srcValue, (key + ''), object, source, stack) ? customizer(safeGet(object, key), srcValue, (key + ''), object, source, stack)
: undefined; : undefined;
if (newValue === undefined) { if (newValue === undefined) {
newValue = srcValue; newValue = srcValue;
@ -3010,8 +3010,8 @@
return; return;
} }
var newValue = customizer var newValue = customizer
? customizer(objValue, srcValue, (key + ''), object, source, stack) ? customizer(objValue, srcValue, (key + ''), object, source, stack)
: undefined; : undefined;
var isCommon = newValue === undefined; var isCommon = newValue === undefined;
@ -3218,8 +3218,8 @@
newValue = customizer ? customizer(objValue, key, nested) : undefined; newValue = customizer ? customizer(objValue, key, nested) : undefined;
if (newValue === undefined) { if (newValue === undefined) {
newValue = isObject(objValue) newValue = isObject(objValue)
? objValue ? objValue
: (isIndex(path[index + 1]) ? [] : {}); : (isIndex(path[index + 1]) ? [] : {});
} }
} }
assignValue(nested, key, newValue); assignValue(nested, key, newValue);
@ -3365,30 +3365,30 @@
seen = iteratee ? [] : result; seen = iteratee ? [] : result;
} }
outer: outer:
while (++index < length) { while (++index < length) {
var value = array[index], var value = array[index],
computed = iteratee ? iteratee(value) : value; computed = iteratee ? iteratee(value) : value;
value = (comparator || value !== 0) ? value : 0; value = (comparator || value !== 0) ? value : 0;
if (isCommon && computed === computed) { if (isCommon && computed === computed) {
var seenIndex = seen.length; var seenIndex = seen.length;
while (seenIndex--) { while (seenIndex--) {
if (seen[seenIndex] === computed) { if (seen[seenIndex] === computed) {
continue outer; continue outer;
}
}
if (iteratee) {
seen.push(computed);
}
result.push(value);
}
else if (!includes(seen, computed, comparator)) {
if (seen !== result) {
seen.push(computed);
}
result.push(value);
} }
} }
if (iteratee) {
seen.push(computed);
}
result.push(value);
}
else if (!includes(seen, computed, comparator)) {
if (seen !== result) {
seen.push(computed);
}
result.push(value);
}
}
return result; return result;
} }
@ -3762,8 +3762,8 @@
var key = props[index]; var key = props[index];
var newValue = customizer var newValue = customizer
? customizer(object[key], source[key], key, object, source) ? customizer(object[key], source[key], key, object, source)
: undefined; : undefined;
if (newValue === undefined) { if (newValue === undefined) {
newValue = source[key]; newValue = source[key];
@ -3833,8 +3833,8 @@
guard = length > 2 ? sources[2] : undefined; guard = length > 2 ? sources[2] : undefined;
customizer = (assigner.length > 3 && typeof customizer == 'function') customizer = (assigner.length > 3 && typeof customizer == 'function')
? (length--, customizer) ? (length--, customizer)
: undefined; : undefined;
if (guard && isIterateeCall(sources[0], sources[1], guard)) { if (guard && isIterateeCall(sources[0], sources[1], guard)) {
customizer = length < 3 ? undefined : customizer; customizer = length < 3 ? undefined : customizer;
@ -3980,14 +3980,14 @@
args[index] = arguments[index]; args[index] = arguments[index];
} }
var holders = (length < 3 && args[0] !== placeholder && args[length - 1] !== placeholder) var holders = (length < 3 && args[0] !== placeholder && args[length - 1] !== placeholder)
? [] ? []
: replaceHolders(args, placeholder); : replaceHolders(args, placeholder);
length -= holders.length; length -= holders.length;
if (length < arity) { if (length < arity) {
return createRecurry( return createRecurry(
func, bitmask, createHybrid, wrapper.placeholder, undefined, func, bitmask, createHybrid, wrapper.placeholder, undefined,
args, holders, undefined, undefined, arity - length); args, holders, undefined, undefined, arity - length);
} }
var fn = (this && this !== root && this instanceof wrapper) ? Ctor : func; var fn = (this && this !== root && this instanceof wrapper) ? Ctor : func;
return apply(fn, this, args); return apply(fn, this, args);
@ -4064,8 +4064,8 @@
if (isCurried && length < arity) { if (isCurried && length < arity) {
var newHolders = replaceHolders(args, placeholder); var newHolders = replaceHolders(args, placeholder);
return createRecurry( return createRecurry(
func, bitmask, createHybrid, wrapper.placeholder, thisArg, func, bitmask, createHybrid, wrapper.placeholder, thisArg,
args, newHolders, argPos, ary, arity - length args, newHolders, argPos, ary, arity - length
); );
} }
var thisBinding = isBind ? thisArg : this, var thisBinding = isBind ? thisArg : this,
@ -4277,8 +4277,8 @@
partials = newData[3]; partials = newData[3];
holders = newData[4]; holders = newData[4];
arity = newData[9] = newData[9] === undefined arity = newData[9] = newData[9] === undefined
? (isBindKey ? 0 : func.length) ? (isBindKey ? 0 : func.length)
: nativeMax(newData[9] - length, 0); : nativeMax(newData[9] - length, 0);
if (!arity && bitmask & (WRAP_CURRY_FLAG | WRAP_CURRY_RIGHT_FLAG)) { if (!arity && bitmask & (WRAP_CURRY_FLAG | WRAP_CURRY_RIGHT_FLAG)) {
bitmask &= ~(WRAP_CURRY_FLAG | WRAP_CURRY_RIGHT_FLAG); bitmask &= ~(WRAP_CURRY_FLAG | WRAP_CURRY_RIGHT_FLAG);
@ -4373,8 +4373,8 @@
if (customizer) { if (customizer) {
var compared = isPartial var compared = isPartial
? customizer(othValue, arrValue, index, other, array, stack) ? customizer(othValue, arrValue, index, other, array, stack)
: customizer(arrValue, othValue, index, array, other, stack); : customizer(arrValue, othValue, index, array, other, stack);
} }
if (compared !== undefined) { if (compared !== undefined) {
if (compared) { if (compared) {
@ -4386,18 +4386,18 @@
// Recursively compare arrays (susceptible to call stack limits). // Recursively compare arrays (susceptible to call stack limits).
if (seen) { if (seen) {
if (!arraySome(other, function(othValue, othIndex) { if (!arraySome(other, function(othValue, othIndex) {
if (!cacheHas(seen, othIndex) && if (!cacheHas(seen, othIndex) &&
(arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack))) { (arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack))) {
return seen.push(othIndex); return seen.push(othIndex);
} }
})) { })) {
result = false; result = false;
break; break;
} }
} else if (!( } else if (!(
arrValue === othValue || arrValue === othValue ||
equalFunc(arrValue, othValue, bitmask, customizer, stack) equalFunc(arrValue, othValue, bitmask, customizer, stack)
)) { )) {
result = false; result = false;
break; break;
} }
@ -4536,14 +4536,14 @@
if (customizer) { if (customizer) {
var compared = isPartial var compared = isPartial
? customizer(othValue, objValue, key, other, object, stack) ? customizer(othValue, objValue, key, other, object, stack)
: customizer(objValue, othValue, key, object, other, stack); : customizer(objValue, othValue, key, object, other, stack);
} }
// Recursively compare objects (susceptible to call stack limits). // Recursively compare objects (susceptible to call stack limits).
if (!(compared === undefined if (!(compared === undefined
? (objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack)) ? (objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack))
: compared : compared
)) { )) {
result = false; result = false;
break; break;
} }
@ -4557,7 +4557,7 @@
if (objCtor != othCtor && if (objCtor != othCtor &&
('constructor' in object && 'constructor' in other) && ('constructor' in object && 'constructor' in other) &&
!(typeof objCtor == 'function' && objCtor instanceof objCtor && !(typeof objCtor == 'function' && objCtor instanceof objCtor &&
typeof othCtor == 'function' && othCtor instanceof othCtor)) { typeof othCtor == 'function' && othCtor instanceof othCtor)) {
result = false; result = false;
} }
} }
@ -4656,8 +4656,8 @@
function getMapData(map, key) { function getMapData(map, key) {
var data = map.__data__; var data = map.__data__;
return isKeyable(key) return isKeyable(key)
? data[typeof key == 'string' ? 'string' : 'hash'] ? data[typeof key == 'string' ? 'string' : 'hash']
: data.map; : data.map;
} }
/** /**
@ -4854,7 +4854,7 @@
} }
length = object == null ? 0 : object.length; length = object == null ? 0 : object.length;
return !!length && isLength(length) && isIndex(key, length) && return !!length && isLength(length) && isIndex(key, length) &&
(isArray(object) || isArguments(object)); (isArray(object) || isArguments(object));
} }
/** /**
@ -4885,8 +4885,8 @@
*/ */
function initCloneObject(object) { function initCloneObject(object) {
return (typeof object.constructor == 'function' && !isPrototype(object)) return (typeof object.constructor == 'function' && !isPrototype(object))
? baseCreate(getPrototype(object)) ? baseCreate(getPrototype(object))
: {}; : {};
} }
/** /**
@ -4965,7 +4965,7 @@
*/ */
function isFlattenable(value) { function isFlattenable(value) {
return isArray(value) || isArguments(value) || return isArray(value) || isArguments(value) ||
!!(spreadableSymbol && value && value[spreadableSymbol]); !!(spreadableSymbol && value && value[spreadableSymbol]);
} }
/** /**
@ -4981,9 +4981,9 @@
length = length == null ? MAX_SAFE_INTEGER : length; length = length == null ? MAX_SAFE_INTEGER : length;
return !!length && return !!length &&
(type == 'number' || (type == 'number' ||
(type != 'symbol' && reIsUint.test(value))) && (type != 'symbol' && reIsUint.test(value))) &&
(value > -1 && value % 1 == 0 && value < length); (value > -1 && value % 1 == 0 && value < length);
} }
/** /**
@ -5002,9 +5002,9 @@
} }
var type = typeof index; var type = typeof index;
if (type == 'number' if (type == 'number'
? (isArrayLike(object) && isIndex(index, object.length)) ? (isArrayLike(object) && isIndex(index, object.length))
: (type == 'string' && index in object) : (type == 'string' && index in object)
) { ) {
return eq(object[index], value); return eq(object[index], value);
} }
return false; return false;
@ -5028,7 +5028,7 @@
return true; return true;
} }
return reIsPlainProp.test(value) || !reIsDeepProp.test(value) || return reIsPlainProp.test(value) || !reIsDeepProp.test(value) ||
(object != null && value in Object(object)); (object != null && value in Object(object));
} }
/** /**
@ -5041,8 +5041,8 @@
function isKeyable(value) { function isKeyable(value) {
var type = typeof value; var type = typeof value;
return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean') return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean')
? (value !== '__proto__') ? (value !== '__proto__')
: (value === null); : (value === null);
} }
/** /**
@ -5119,7 +5119,7 @@
return false; return false;
} }
return object[key] === srcValue && return object[key] === srcValue &&
(srcValue !== undefined || (key in Object(object))); (srcValue !== undefined || (key in Object(object)));
}; };
} }
@ -5166,9 +5166,9 @@
isCommon = newBitmask < (WRAP_BIND_FLAG | WRAP_BIND_KEY_FLAG | WRAP_ARY_FLAG); isCommon = newBitmask < (WRAP_BIND_FLAG | WRAP_BIND_KEY_FLAG | WRAP_ARY_FLAG);
var isCombo = var isCombo =
((srcBitmask == WRAP_ARY_FLAG) && (bitmask == WRAP_CURRY_FLAG)) || ((srcBitmask == WRAP_ARY_FLAG) && (bitmask == WRAP_CURRY_FLAG)) ||
((srcBitmask == WRAP_ARY_FLAG) && (bitmask == WRAP_REARG_FLAG) && (data[7].length <= source[8])) || ((srcBitmask == WRAP_ARY_FLAG) && (bitmask == WRAP_REARG_FLAG) && (data[7].length <= source[8])) ||
((srcBitmask == (WRAP_ARY_FLAG | WRAP_REARG_FLAG)) && (source[7].length <= source[8]) && (bitmask == WRAP_CURRY_FLAG)); ((srcBitmask == (WRAP_ARY_FLAG | WRAP_REARG_FLAG)) && (source[7].length <= source[8]) && (bitmask == WRAP_CURRY_FLAG));
// Exit early if metadata can't be merged. // Exit early if metadata can't be merged.
if (!(isCommon || isCombo)) { if (!(isCommon || isCombo)) {
@ -5558,8 +5558,8 @@
*/ */
var difference = baseRest(function(array, values) { var difference = baseRest(function(array, values) {
return isArrayLikeObject(array) return isArrayLikeObject(array)
? baseDifference(array, baseFlatten(values, 1, isArrayLikeObject, true)) ? baseDifference(array, baseFlatten(values, 1, isArrayLikeObject, true))
: []; : [];
}); });
/** /**
@ -5687,8 +5687,8 @@
if (fromIndex !== undefined) { if (fromIndex !== undefined) {
index = toInteger(fromIndex); index = toInteger(fromIndex);
index = fromIndex < 0 index = fromIndex < 0
? nativeMax(length + index, 0) ? nativeMax(length + index, 0)
: nativeMin(index, length - 1); : nativeMin(index, length - 1);
} }
return baseFindIndex(array, baseIteratee(predicate, 3), index, true); return baseFindIndex(array, baseIteratee(predicate, 3), index, true);
} }
@ -5827,8 +5827,8 @@
var intersection = baseRest(function(arrays) { var intersection = baseRest(function(arrays) {
var mapped = arrayMap(arrays, castArrayLikeObject); var mapped = arrayMap(arrays, castArrayLikeObject);
return (mapped.length && mapped[0] === arrays[0]) return (mapped.length && mapped[0] === arrays[0])
? baseIntersection(mapped) ? baseIntersection(mapped)
: []; : [];
}); });
/** /**
@ -6103,8 +6103,8 @@
*/ */
var without = baseRest(function(array, values) { var without = baseRest(function(array, values) {
return isArrayLikeObject(array) return isArrayLikeObject(array)
? baseDifference(array, values) ? baseDifference(array, values)
: []; : [];
}); });
/** /**
@ -7174,8 +7174,8 @@
timeWaiting = wait - timeSinceLastCall; timeWaiting = wait - timeSinceLastCall;
return maxing return maxing
? nativeMin(timeWaiting, maxWait - timeSinceLastInvoke) ? nativeMin(timeWaiting, maxWait - timeSinceLastInvoke)
: timeWaiting; : timeWaiting;
} }
function shouldInvoke(time) { function shouldInvoke(time) {
@ -7186,7 +7186,7 @@
// trailing edge, the system time has gone backwards and we're treating // trailing edge, the system time has gone backwards and we're treating
// it as the trailing edge, or we've hit the `maxWait` limit. // it as the trailing edge, or we've hit the `maxWait` limit.
return (lastCallTime === undefined || (timeSinceLastCall >= wait) || return (lastCallTime === undefined || (timeSinceLastCall >= wait) ||
(timeSinceLastCall < 0) || (maxing && timeSinceLastInvoke >= maxWait)); (timeSinceLastCall < 0) || (maxing && timeSinceLastInvoke >= maxWait));
} }
function timerExpired() { function timerExpired() {
@ -7625,7 +7625,7 @@
*/ */
var isArguments = baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) { var isArguments = baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) {
return isObjectLike(value) && hasOwnProperty.call(value, 'callee') && return isObjectLike(value) && hasOwnProperty.call(value, 'callee') &&
!propertyIsEnumerable.call(value, 'callee'); !propertyIsEnumerable.call(value, 'callee');
}; };
/** /**
@ -7730,7 +7730,7 @@
*/ */
function isBoolean(value) { function isBoolean(value) {
return value === true || value === false || return value === true || value === false ||
(isObjectLike(value) && baseGetTag(value) == boolTag); (isObjectLike(value) && baseGetTag(value) == boolTag);
} }
/** /**
@ -7810,7 +7810,7 @@
} }
if (isArrayLike(value) && if (isArrayLike(value) &&
(isArray(value) || typeof value == 'string' || typeof value.splice == 'function' || (isArray(value) || typeof value == 'string' || typeof value.splice == 'function' ||
isBuffer(value) || isTypedArray(value) || isArguments(value))) { isBuffer(value) || isTypedArray(value) || isArguments(value))) {
return !value.length; return !value.length;
} }
var tag = getTag(value); var tag = getTag(value);
@ -7945,7 +7945,7 @@
*/ */
function isLength(value) { function isLength(value) {
return typeof value == 'number' && return typeof value == 'number' &&
value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;
} }
/** /**
@ -8109,7 +8109,7 @@
*/ */
function isNumber(value) { function isNumber(value) {
return typeof value == 'number' || return typeof value == 'number' ||
(isObjectLike(value) && baseGetTag(value) == numberTag); (isObjectLike(value) && baseGetTag(value) == numberTag);
} }
/** /**
@ -8150,7 +8150,7 @@
} }
var Ctor = hasOwnProperty.call(proto, 'constructor') && proto.constructor; var Ctor = hasOwnProperty.call(proto, 'constructor') && proto.constructor;
return typeof Ctor == 'function' && Ctor instanceof Ctor && return typeof Ctor == 'function' && Ctor instanceof Ctor &&
funcToString.call(Ctor) == objectCtorString; funcToString.call(Ctor) == objectCtorString;
} }
/** /**
@ -8210,7 +8210,7 @@
*/ */
function isString(value) { function isString(value) {
return typeof value == 'string' || return typeof value == 'string' ||
(!isArray(value) && isObjectLike(value) && baseGetTag(value) == stringTag); (!isArray(value) && isObjectLike(value) && baseGetTag(value) == stringTag);
} }
/** /**
@ -8232,7 +8232,7 @@
*/ */
function isSymbol(value) { function isSymbol(value) {
return typeof value == 'symbol' || return typeof value == 'symbol' ||
(isObjectLike(value) && baseGetTag(value) == symbolTag); (isObjectLike(value) && baseGetTag(value) == symbolTag);
} }
/** /**
@ -8422,8 +8422,8 @@
value = value.replace(reTrim, ''); value = value.replace(reTrim, '');
var isBinary = reIsBinary.test(value); var isBinary = reIsBinary.test(value);
return (isBinary || reIsOctal.test(value)) return (isBinary || reIsOctal.test(value))
? freeParseInt(value.slice(2), isBinary ? 2 : 8) ? freeParseInt(value.slice(2), isBinary ? 2 : 8)
: (reIsBadHex.test(value) ? NAN : +value); : (reIsBadHex.test(value) ? NAN : +value);
} }
/** /**
@ -9164,6 +9164,38 @@
return object; return object;
} }
/**
* Sets the value at `path` of `object`. If a portion of `path` doesn't exist,
* it's created. Arrays are created for missing index properties while objects
* are created for all other missing properties. Use `_.setWith` to customize
* `path` creation.
*
* **Note:** This method mutates `object`.
*
* @static
* @memberOf _
* @since 3.7.0
* @category Object
* @param {Object} object The object to modify.
* @param {Array|string} path The path of the property to set.
* @param {*} value The value to set.
* @returns {Object} Returns `object`.
* @example
*
* var object = { 'a': [{ 'b': { 'c': 3 } }] };
*
* _.set(object, 'a[0].b.c', 4);
* console.log(object.a[0].b.c);
* // => 4
*
* _.set(object, ['x', '0', 'y', 'z'], 5);
* console.log(object.x[0].y.z);
* // => 5
*/
function set(object, path, value) {
return object == null ? object : baseSet(object, path, value);
}
/** /**
* Creates an array of the own enumerable string keyed property values of `object`. * Creates an array of the own enumerable string keyed property values of `object`.
* *
@ -9334,8 +9366,8 @@
function escape(string) { function escape(string) {
string = toString(string); string = toString(string);
return (string && reHasUnescapedHtml.test(string)) return (string && reHasUnescapedHtml.test(string))
? string.replace(reUnescapedHtml, escapeHtmlChar) ? string.replace(reUnescapedHtml, escapeHtmlChar)
: string; : string;
} }
/** /**
@ -9761,8 +9793,8 @@
*/ */
function max(array) { function max(array) {
return (array && array.length) return (array && array.length)
? baseExtremum(array, identity, baseGt) ? baseExtremum(array, identity, baseGt)
: undefined; : undefined;
} }
/** /**
@ -9785,8 +9817,8 @@
*/ */
function min(array) { function min(array) {
return (array && array.length) return (array && array.length)
? baseExtremum(array, identity, baseLt) ? baseExtremum(array, identity, baseLt)
: undefined; : undefined;
} }
/*------------------------------------------------------------------------*/ /*------------------------------------------------------------------------*/
@ -9829,6 +9861,7 @@
lodash.range = range; lodash.range = range;
lodash.reject = reject; lodash.reject = reject;
lodash.rest = rest; lodash.rest = rest;
lodash.set = set;
lodash.slice = slice; lodash.slice = slice;
lodash.sortBy = sortBy; lodash.sortBy = sortBy;
lodash.take = take; lodash.take = take;
@ -9932,8 +9965,8 @@
n = n === undefined ? 1 : nativeMax(toInteger(n), 0); n = n === undefined ? 1 : nativeMax(toInteger(n), 0);
var result = (this.__filtered__ && !index) var result = (this.__filtered__ && !index)
? new LazyWrapper(this) ? new LazyWrapper(this)
: this.clone(); : this.clone();
if (result.__filtered__) { if (result.__filtered__) {
result.__takeCount__ = nativeMin(n, result.__takeCount__); result.__takeCount__ = nativeMin(n, result.__takeCount__);

3
src/core/utils/tree.js

@ -1,4 +1,3 @@
(function () { (function () {
BI.Tree = function () { BI.Tree = function () {
this.root = new BI.Node(BI.UUID()); this.root = new BI.Node(BI.UUID());
@ -506,7 +505,7 @@
return; return;
} }
var self = this; var self = this;
BI.any(array, function (i, item) { BI.some(array, function (i, item) {
if (callback(i, item) === false) { if (callback(i, item) === false) {
return true; return true;
} }

Loading…
Cancel
Save