From 544723726c6f085e57ea8c4fcd6284b47f387103 Mon Sep 17 00:00:00 2001 From: Zach Date: Fri, 4 Sep 2015 19:31:28 -0700 Subject: [PATCH 1/2] tested and working with react .14 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index cd623fc..142fa2f 100755 --- a/package.json +++ b/package.json @@ -33,6 +33,6 @@ }, "homepage": "https://github.com/zackify/simple-modal", "dependencies": { - "react": "^0.13.3" + "react": "^0.14.0-beta1" } } From 27a9a911aa9de6adb072982652c671bc5689cc8a Mon Sep 17 00:00:00 2001 From: Zach Date: Mon, 21 Sep 2015 10:06:16 -0700 Subject: [PATCH 2/2] fixed variable declaration --- build/simple-modal.js | 6 ++++-- dist/simple-react-modal.js | 6 ++++-- dist/simple-react-modal.min.js | 2 +- package.json | 2 +- src/simple-modal.js | 5 +++-- 5 files changed, 13 insertions(+), 8 deletions(-) diff --git a/build/simple-modal.js b/build/simple-modal.js index 2719279..4f7ac16 100755 --- a/build/simple-modal.js +++ b/build/simple-modal.js @@ -98,13 +98,15 @@ var Modal = (function (_React$Component) { key: 'render', value: function render() { if (!this.state.show) return null; + var modalStyle = undefined, + containerStyle = undefined; //completely overwrite if they use a class if (this.props.className) { modalStyle = this.props.style; containerStyle = this.props.containerStyle; } else { - var modalStyle = _extends({}, _styles2['default'].modal, this.props.style); - var containerStyle = _extends({}, _styles2['default'].container, this.props.containerStyle); + modalStyle = _extends({}, _styles2['default'].modal, this.props.style); + containerStyle = _extends({}, _styles2['default'].container, this.props.containerStyle); } if (this.props.transitionSpeed) modalStyle = _extends({}, this.state, modalStyle); diff --git a/dist/simple-react-modal.js b/dist/simple-react-modal.js index 84979db..df4ea1e 100644 --- a/dist/simple-react-modal.js +++ b/dist/simple-react-modal.js @@ -100,13 +100,15 @@ var Modal = (function (_React$Component) { key: 'render', value: function render() { if (!this.state.show) return null; + var modalStyle = undefined, + containerStyle = undefined; //completely overwrite if they use a class if (this.props.className) { modalStyle = this.props.style; containerStyle = this.props.containerStyle; } else { - var modalStyle = _extends({}, _styles2['default'].modal, this.props.style); - var containerStyle = _extends({}, _styles2['default'].container, this.props.containerStyle); + modalStyle = _extends({}, _styles2['default'].modal, this.props.style); + containerStyle = _extends({}, _styles2['default'].container, this.props.containerStyle); } if (this.props.transitionSpeed) modalStyle = _extends({}, this.state, modalStyle); diff --git a/dist/simple-react-modal.min.js b/dist/simple-react-modal.min.js index 29f4679..e2af28e 100644 --- a/dist/simple-react-modal.min.js +++ b/dist/simple-react-modal.min.js @@ -1 +1 @@ -!function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var t;t="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this,t.simpleModal=e()}}(function(){return function e(t,o,n){function i(s,a){if(!o[s]){if(!t[s]){var u="function"==typeof require&&require;if(!a&&u)return u(s,!0);if(r)return r(s,!0);var l=new Error("Cannot find module '"+s+"'");throw l.code="MODULE_NOT_FOUND",l}var f=o[s]={exports:{}};t[s][0].call(f.exports,function(e){var o=t[s][1][e];return i(o?o:e)},f,f.exports,e,t,o,n)}return o[s].exports}for(var r="function"==typeof require&&require,s=0;s