mirror of
https://github.com/Choices-js/Choices.git
synced 2024-06-26 09:20:10 +02:00
Rename duplicateItems to duplicateItemsAllowed for clarity
This commit is contained in:
parent
2a3ea24285
commit
b2971ae56b
|
@ -1,4 +1,4 @@
|
|||
/*! choices.js v4.0.0 | (c) 2018 Josh Johnson | https://github.com/jshjohnson/Choices#readme */
|
||||
/*! choices.js v4.0.0 | (c) 2018 Josh Johnson | https://github.com/jshjohnson/Choices#readme */
|
||||
(function webpackUniversalModuleDefinition(root, factory) {
|
||||
//CommonJS2
|
||||
if(typeof exports === 'object' && typeof module === 'object')
|
||||
|
@ -577,7 +577,7 @@ var DEFAULT_CONFIG = exports.DEFAULT_CONFIG = {
|
|||
removeItems: true,
|
||||
removeItemButton: false,
|
||||
editItems: false,
|
||||
duplicateItems: true,
|
||||
duplicateItemsAllowed: true,
|
||||
delimiter: ',',
|
||||
paste: true,
|
||||
searchEnabled: true,
|
||||
|
@ -1843,27 +1843,27 @@ if (false) {
|
|||
/* 31 */
|
||||
/***/ (function(module, exports) {
|
||||
|
||||
var g;
|
||||
|
||||
// This works in non-strict mode
|
||||
g = (function() {
|
||||
return this;
|
||||
})();
|
||||
|
||||
try {
|
||||
// This works if eval is allowed (see CSP)
|
||||
g = g || Function("return this")() || (1,eval)("this");
|
||||
} catch(e) {
|
||||
// This works if the window reference is available
|
||||
if(typeof window === "object")
|
||||
g = window;
|
||||
}
|
||||
|
||||
// g can still be undefined, but nothing to do about it...
|
||||
// We return undefined, instead of nothing here, so it's
|
||||
// easier to handle this case. if(!global) { ...}
|
||||
|
||||
module.exports = g;
|
||||
var g;
|
||||
|
||||
// This works in non-strict mode
|
||||
g = (function() {
|
||||
return this;
|
||||
})();
|
||||
|
||||
try {
|
||||
// This works if eval is allowed (see CSP)
|
||||
g = g || Function("return this")() || (1,eval)("this");
|
||||
} catch(e) {
|
||||
// This works if the window reference is available
|
||||
if(typeof window === "object")
|
||||
g = window;
|
||||
}
|
||||
|
||||
// g can still be undefined, but nothing to do about it...
|
||||
// We return undefined, instead of nothing here, so it's
|
||||
// easier to handle this case. if(!global) { ...}
|
||||
|
||||
module.exports = g;
|
||||
|
||||
|
||||
/***/ }),
|
||||
|
@ -2975,7 +2975,7 @@ var Choices = function () {
|
|||
canAddItem = (0, _utils.regexFilter)(value, this.config.regexFilter);
|
||||
}
|
||||
|
||||
if (!this.config.duplicateItems && !valueAlreadyExists && canAddItem) {
|
||||
if (!this.config.duplicateItemsAllowed && !valueAlreadyExists && canAddItem) {
|
||||
canAddItem = false;
|
||||
notice = (0, _utils.isType)('Function', this.config.uniqueItemText) ? this.config.uniqueItemText(value) : this.config.uniqueItemText;
|
||||
}
|
||||
|
@ -4113,10 +4113,10 @@ module.exports = Choices;
|
|||
|
||||
/*!
|
||||
* Fuse.js v3.2.0 - Lightweight fuzzy-search (http://fusejs.io)
|
||||
*
|
||||
*
|
||||
* Copyright (c) 2012-2017 Kirollos Risk (http://kiro.me)
|
||||
* All Rights Reserved. Apache Software License 2.0
|
||||
*
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*/
|
||||
(function webpackUniversalModuleDefinition(root, factory) {
|
||||
|
@ -5987,30 +5987,30 @@ var result = Object(__WEBPACK_IMPORTED_MODULE_0__ponyfill_js__["a" /* default */
|
|||
/* 66 */
|
||||
/***/ (function(module, exports) {
|
||||
|
||||
module.exports = function(originalModule) {
|
||||
if(!originalModule.webpackPolyfill) {
|
||||
var module = Object.create(originalModule);
|
||||
// module.parent = undefined by default
|
||||
if(!module.children) module.children = [];
|
||||
Object.defineProperty(module, "loaded", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return module.l;
|
||||
}
|
||||
});
|
||||
Object.defineProperty(module, "id", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return module.i;
|
||||
}
|
||||
});
|
||||
Object.defineProperty(module, "exports", {
|
||||
enumerable: true,
|
||||
});
|
||||
module.webpackPolyfill = 1;
|
||||
}
|
||||
return module;
|
||||
};
|
||||
module.exports = function(originalModule) {
|
||||
if(!originalModule.webpackPolyfill) {
|
||||
var module = Object.create(originalModule);
|
||||
// module.parent = undefined by default
|
||||
if(!module.children) module.children = [];
|
||||
Object.defineProperty(module, "loaded", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return module.l;
|
||||
}
|
||||
});
|
||||
Object.defineProperty(module, "id", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return module.i;
|
||||
}
|
||||
});
|
||||
Object.defineProperty(module, "exports", {
|
||||
enumerable: true,
|
||||
});
|
||||
module.webpackPolyfill = 1;
|
||||
}
|
||||
return module;
|
||||
};
|
||||
|
||||
|
||||
/***/ }),
|
||||
|
|
File diff suppressed because one or more lines are too long
2
assets/scripts/choices.min.js
vendored
2
assets/scripts/choices.min.js
vendored
File diff suppressed because one or more lines are too long
|
@ -316,13 +316,13 @@
|
|||
|
||||
var textUniqueVals = new Choices('#choices-text-unique-values', {
|
||||
paste: false,
|
||||
duplicateItems: false,
|
||||
duplicateItemsAllowed: false,
|
||||
editItems: true,
|
||||
});
|
||||
|
||||
var texti18n = new Choices('#choices-text-i18n', {
|
||||
paste: false,
|
||||
duplicateItems: false,
|
||||
duplicateItemsAllowed: false,
|
||||
editItems: true,
|
||||
maxItemCount: 5,
|
||||
addItemText: function(value) {
|
||||
|
|
Loading…
Reference in a new issue