tether-select
Advanced tools
Comparing version 0.6.2 to 1.0.0
{ | ||
"name": "tether-select", | ||
"version": "0.6.2", | ||
"version": "1.0.0", | ||
"homepage": "https://github.com/HubSpot/select", | ||
@@ -9,2 +9,5 @@ "authors": [ | ||
], | ||
"maintainers": [ | ||
"Nicholas Hwang <nick.joosung.hwang@gmail.com>" | ||
], | ||
"description": "Styleable select elements built on Tether", | ||
@@ -18,3 +21,3 @@ "keywords": [ | ||
"license": "MIT", | ||
"main": "select.js", | ||
"main": "dist/js/select.js", | ||
"ignore": [ | ||
@@ -21,0 +24,0 @@ "**/.*", |
@@ -1,2 +0,91 @@ | ||
require('coffee-script') | ||
require('./gulpfile.coffee') | ||
var del = require('del'); | ||
var gulp = require('gulp'); | ||
var babel = require('gulp-babel'); | ||
var bump = require('gulp-bump'); | ||
var filter = require('gulp-filter'); | ||
var header = require('gulp-header'); | ||
var prefixer = require('gulp-autoprefixer'); | ||
var rename = require('gulp-rename'); | ||
var uglify = require('gulp-uglify'); | ||
var sass = require('gulp-sass'); | ||
var tagVersion = require('gulp-tag-version'); | ||
var umd = require('gulp-wrap-umd'); | ||
// Variables | ||
var distDir = './dist'; | ||
var pkg = require('./package.json'); | ||
var banner = ['/*!', pkg.name, pkg.version, '*/\n'].join(' '); | ||
var umdOptions = { | ||
exports: 'Select', | ||
namespace: 'Select', | ||
deps: [{ | ||
name: 'Tether', | ||
globalName: 'Tether', | ||
paramName: 'Tether', | ||
amdName: 'tether', | ||
cjsName: 'tether' | ||
}] | ||
}; | ||
// Clean | ||
gulp.task('clean', function() { | ||
del.sync([distDir]); | ||
}); | ||
// Javascript | ||
gulp.task('js', ['clean'], function() { | ||
gulp.src('./src/js/select.js') | ||
.pipe(babel()) | ||
.pipe(umd(umdOptions)) | ||
.pipe(header(banner)) | ||
// Original | ||
.pipe(gulp.dest(distDir + '/js')) | ||
// Minified | ||
.pipe(uglify()) | ||
.pipe(rename({suffix: '.min'})) | ||
.pipe(gulp.dest(distDir + '/js')); | ||
}); | ||
// CSS | ||
gulp.task('css', function() { | ||
gulp.src('./src/css/**/*.sass') | ||
.pipe(sass({ | ||
includePaths: ['./bower_components'] | ||
})) | ||
.pipe(prefixer()) | ||
.pipe(gulp.dest(distDir + '/css')); | ||
}); | ||
// Version bump | ||
var VERSIONS = ['patch', 'minor', 'major']; | ||
for (var i = 0; i < VERSIONS.length; ++i){ | ||
(function(version) { | ||
var pkgFilter = filter('package.json'); | ||
gulp.task('version:' + version, function() { | ||
gulp.src(['package.json', 'bower.json']) | ||
.pipe(bump({type: version})) | ||
.pipe(pkgFilter) | ||
.pipe(tagVersion()) | ||
.pipe(pkgFilter.restore()) | ||
.pipe(gulp.dest('.')) | ||
}); | ||
})(VERSIONS[i]); | ||
} | ||
// Watch | ||
gulp.task('watch', ['js', 'css'], function() { | ||
gulp.watch('./src/js/**/*', ['js']); | ||
gulp.watch('./src/css/**/*', ['css']); | ||
}); | ||
// Defaults | ||
gulp.task('build', ['js', 'css']) | ||
gulp.task('default', ['build']) |
{ | ||
"name": "tether-select", | ||
"version": "0.6.2", | ||
"version": "1.0.0", | ||
"description": "Styleable select elements built on Tether", | ||
@@ -9,16 +9,29 @@ "authors": [ | ||
], | ||
"maintainers": [ | ||
"Nicholas Hwang <nick.joosung.hwang@gmail.com>" | ||
], | ||
"scripts": { | ||
"install": "bower install", | ||
"build": "gulp build" | ||
}, | ||
"license": "MIT", | ||
"main": "select.js", | ||
"main": "dist/js/select.js", | ||
"devDependencies": { | ||
"coffee-script": "~1.6.3", | ||
"gulp": "~3.3.0", | ||
"bower": "^1.4.1", | ||
"del": "^1.1.1", | ||
"gulp": "^3.8.11", | ||
"gulp-autoprefixer": "^2.2.0", | ||
"gulp-coffee": "~1.2.5", | ||
"gulp-concat": "~2.1.7", | ||
"gulp-header": "~1.0.2", | ||
"gulp-rename": "~0.2.1", | ||
"gulp-babel": "^5.1.0", | ||
"gulp-bump": "^0.3.0", | ||
"gulp-filter": "^2.0.2", | ||
"gulp-header": "^1.2.2", | ||
"gulp-rename": "^1.2.2", | ||
"gulp-sass": "^2.0.0", | ||
"gulp-uglify": "~0.1.0", | ||
"gulp-util": "~2.2.9" | ||
"gulp-tag-version": "^1.2.1", | ||
"gulp-uglify": "^1.2.0", | ||
"gulp-wrap-umd": "^0.2.1" | ||
}, | ||
"dependencies": { | ||
"tether": "^0.7.2" | ||
} | ||
} |
@@ -5,2 +5,42 @@ ## Select | ||
### [Demo](http://github.hubspot.com/select/docs/welcome) [Documentation](http://github.hubspot.com/select) | ||
## Install | ||
__Dependencies__ | ||
* __[Tether](https://github.com/HubSpot/tether)__ | ||
Installing via `npm` and `bower` will bring in the above dependencies as well. | ||
__npm__ | ||
```sh | ||
$ npm install tether-select | ||
``` | ||
__bower__ | ||
```sh | ||
$ bower install tether-select | ||
``` | ||
## Usage | ||
```javascript | ||
let selectInstance = new Select({ | ||
el: document.querySelector('select.select-target'), | ||
className: 'select-theme-default' | ||
}) | ||
``` | ||
[API Documentation](http://github.hubspot.com/select) | ||
[Demo](http://github.hubspot.com/select/docs/welcome) | ||
## Contributing | ||
We encourage contributions of all kinds. If you would like to contribute in some way, please review our [guidelines for contributing](CONTRIBUTING.md). | ||
## License | ||
Copyright © 2015 HubSpot - [MIT License](LICENSE) |
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
Install scripts
Supply chain riskInstall scripts are run when the package is installed. The majority of malware in npm is hidden in install scripts.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
Minified code
QualityThis package contains minified code. This may be harmless in some cases where minified code is included in packaged libraries, however packages on npm should not minify code.
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
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
46
246088
1
13
1867
1
1
+ Addedtether@^0.7.2
+ Addedtether@0.7.2(transitive)