Skip to content

Commit

Permalink
Updated dev dependencies. Added ES exports
Browse files Browse the repository at this point in the history
  • Loading branch information
zewish committed Jan 13, 2017
1 parent ccbc3b5 commit 85220ac
Show file tree
Hide file tree
Showing 10 changed files with 39 additions and 38 deletions.
4 changes: 2 additions & 2 deletions bower.json
@@ -1,7 +1,7 @@
{
"name": "rmodal",
"main": "rmodal.js",
"version": "1.0.23",
"version": "1.0.24",
"authors": [
"Iskren Slavov <iskren.s@gmail.com>"
],
Expand All @@ -25,4 +25,4 @@
"test",
"tests"
]
}
}
11 changes: 5 additions & 6 deletions dist/rmodal.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/rmodal.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/rmodal.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/rmodal.min.js.map

Large diffs are not rendered by default.

5 changes: 3 additions & 2 deletions gulpfile.js
Expand Up @@ -29,7 +29,7 @@ let bundle = (format) => {
/@@VERSION@@/g
, require('./package.json').version
));
}
};

gulp.task('lint', () => {
return gulp.src('src/*.js')
Expand All @@ -52,7 +52,8 @@ gulp.task('cjs', () => {
}))
.pipe(sourcemaps.write('.'))
.pipe(gulp.dest('./'));
})
});


gulp.task('js', [ 'cjs' ], () => {
return bundle('umd')
Expand Down
11 changes: 5 additions & 6 deletions index.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion index.js.map

Large diffs are not rendered by default.

26 changes: 14 additions & 12 deletions package.json
@@ -1,8 +1,10 @@
{
"name": "rmodal",
"version": "1.0.23",
"version": "1.0.24",
"description": "A simple modal dialog with no external dependencies. IE9+ supported.",
"main": "index.js",
"module": "src/rmodal.js",
"jsnext:main": "src/rmodal.js",
"scripts": {
"test": "./node_modules/.bin/gulp test"
},
Expand All @@ -26,14 +28,14 @@
},
"homepage": "http://rmodal.js.org/",
"devDependencies": {
"buble": "^0.14.0",
"buble": "^0.15.2",
"chai": "^3.5.0",
"eslint": "^3.2.0",
"eslint": "^3.13.1",
"gulp": "^3.9.1",
"gulp-eslint": "^3.0.1",
"gulp-rename": "^1.2.2",
"gulp-replace": "^0.5.4",
"gulp-sourcemaps": "^1.6.0",
"gulp-sourcemaps": "^2.4.0",
"gulp-uglify": "^2.0.0",
"istanbul": "^0.4.5",
"istanbul-coveralls": "^1.0.3",
Expand All @@ -42,16 +44,16 @@
"karma-commonjs": "^1.0.0",
"karma-coverage": "^1.1.1",
"karma-coveralls": "^1.1.2",
"karma-mocha": "^1.2.0",
"karma-mocha": "^1.3.0",
"karma-phantomjs-launcher": "^1.0.2",
"karma-sinon": "^1.0.5",
"mocha": "^3.1.1",
"phantomjs-prebuilt": "^2.1.13",
"rollup": "^0.36.3",
"rollup-plugin-buble": "^0.14.0",
"rollup-stream": "^1.14.0",
"sinon": "^1.17.6",
"mocha": "^3.2.0",
"phantomjs-prebuilt": "^2.1.14",
"rollup": "^0.41.1",
"rollup-plugin-buble": "^0.15.0",
"rollup-stream": "^1.18.0",
"sinon": "^1.17.7",
"vinyl-buffer": "^1.0.0",
"vinyl-source-stream": "^1.1.0"
}
}
}
12 changes: 6 additions & 6 deletions src/rmodal.js
Expand Up @@ -10,14 +10,14 @@ let addClass = (el, cls) => {
if (!arr.length) {
el.className += ` ${cls}`;
}
}
};

let removeClass = (el, cls) => {
el.className = el.className
.split(/\s+/)
.filter((c) => !!c && c != cls)
.join(' ');
}
};

class RModal {
constructor(el, opts) {
Expand Down Expand Up @@ -119,12 +119,12 @@ class RModal {
}, this.opts.closeTimeout);
}

content(content) {
if (content === undefined) {
content(html) {
if (html === undefined) {
return this.dialog.innerHTML;
}

this.dialog.innerHTML = content;
this.dialog.innerHTML = html;
}

elements(selector, fallback) {
Expand Down Expand Up @@ -185,4 +185,4 @@ class RModal {
RModal.prototype.version = '@@VERSION@@';
RModal.version = '@@VERSION@@';

export default RModal;
export default RModal;

0 comments on commit 85220ac

Please sign in to comment.