Version 2.7.5

This commit is contained in:
Josh Johnson 2017-03-01 19:10:46 +00:00
parent 7de4be283a
commit fbb456f9b5
7 changed files with 20 additions and 64 deletions

View file

@ -1,4 +1,4 @@
/*! choices.js v2.7.4 | (c) 2017 Josh Johnson | https://github.com/jshjohnson/Choices#readme */
/*! choices.js v2.7.5 | (c) 2017 Josh Johnson | https://github.com/jshjohnson/Choices#readme */
(function webpackUniversalModuleDefinition(root, factory) {
if(typeof exports === 'object' && typeof module === 'object')
module.exports = factory();
@ -566,12 +566,14 @@ return /******/ (function(modules) { // webpackBootstrap
(0, _utils.triggerEvent)(this.passedElement, 'highlightItem', {
id: id,
value: item.value,
label: item.label,
groupValue: group.value
});
} else {
(0, _utils.triggerEvent)(this.passedElement, 'highlightItem', {
id: id,
value: item.value
value: item.value,
label: item.label
});
}
}
@ -600,12 +602,14 @@ return /******/ (function(modules) { // webpackBootstrap
(0, _utils.triggerEvent)(this.passedElement, 'unhighlightItem', {
id: id,
value: item.value,
label: item.label,
groupValue: group.value
});
} else {
(0, _utils.triggerEvent)(this.passedElement, 'unhighlightItem', {
id: id,
value: item.value
value: item.value,
label: item.label
});
}
@ -2662,7 +2666,10 @@ return /******/ (function(modules) { // webpackBootstrap
* @param {!Object<string, *>} options
*/
function Fuse (list, options) {
var i
var len
var key
var keys
this.list = list
this.options = options = options || {}
@ -2681,7 +2688,7 @@ return /******/ (function(modules) { // webpackBootstrap
}
}
Fuse.VERSION = '2.6.2'
Fuse.VERSION = '2.6.0'
/**
* Sets a new list for Fuse to match against.

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View file

@ -1,6 +1,6 @@
{
"name": "choices.js",
"version": "2.7.4",
"version": "2.7.5",
"description": "A vanilla JS customisable text input/select box plugin",
"main": [
"./assets/scripts/dist/choices.js",

View file

@ -1,51 +0,0 @@
const fs = require('fs'),
path = require('path'),
config = {
files: ['bower.json', 'package.json', 'index.html']
};
/**
* Convert node arguments into an object
* @return {Object} Arguments
*/
const argvToObject = () => {
const args = {};
let arg = null;
process.argv.forEach((val, index) => {
if(/^--/.test(val)) {
arg = {
index: index,
name: val.replace(/^--/, '')
}
return;
}
if(arg && ((arg.index+1 === index ))) {
args[arg.name] = val;
}
});
return args;
};
/**
* Loop through passed files updating version number
* @param {Object} config
*/
const updateVersion = (config) => {
const args = argvToObject();
const currentVersion = args.current;
const newVersion = args.new;
config.files.forEach((file) => {
const filePath = path.join(__dirname, file);
const regex = new RegExp(currentVersion, 'g');
let contents = fs.readFileSync(filePath, 'utf-8');
contents = contents.replace(regex, newVersion);
fs.writeFileSync(filePath, contents);
});
console.log(`Updated version to ${newVersion}`);
};
updateVersion(config);

View file

@ -15,7 +15,7 @@
<meta name="theme-color" content="#ffffff">
<!-- Ignore these -->
<link rel="stylesheet" href="assets/styles/css/base.min.css?version=2.7.4">
<link rel="stylesheet" href="assets/styles/css/base.min.css?version=2.7.5">
<!-- End ignore these -->
<!-- Optional includes -->
@ -23,8 +23,8 @@
<!-- End optional includes -->
<!-- Choices includes -->
<link rel="stylesheet" href="assets/styles/css/choices.min.css?version=2.7.4">
<script src="assets/scripts/dist/choices.min.js?version=2.7.4"></script>
<link rel="stylesheet" href="assets/styles/css/choices.min.css?version=2.7.5">
<script src="assets/scripts/dist/choices.min.js?version=2.7.5"></script>
<!-- End Choices includes -->
<!--[if lt IE 9]>

View file

@ -1,6 +1,6 @@
{
"name": "choices.js",
"version": "2.7.4",
"version": "2.7.5",
"description": "A vanilla JS customisable text input/select box plugin",
"main": "./assets/scripts/dist/choices.min.js",
"scripts": {