Skip to content

Commit a842789

Browse files
committed
Stop generating movie-parameter (now required only by unsupported browsers).
1 parent 609eac5 commit a842789

File tree

7 files changed

+13
-47
lines changed

7 files changed

+13
-47
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
Shockwave Flash Player component for React. GCC `ADVANCED` optimizations compatible.
44

5-
Supports all browsers supported by React.
5+
Supports all browsers supported by React except for IE8-9 (due to a React/DOM incompatibility).
66

77
Depends on [`Object.is()`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is#Polyfill_for_non-ES6_browsers) and [`Object.assign()`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/assign#Polyfill)
88

bower.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "react-swf",
3-
"version": "0.13.2",
3+
"version": "1.0.0",
44
"license": "MIT",
55
"description": "Shockwave Flash Player component for React",
66
"authors": ["Andreas Svensson <[email protected]>"],
@@ -12,7 +12,7 @@
1212
"url": "https://github.com/syranide/react-swf"
1313
},
1414
"dependencies": {
15-
"react": "^0.14.0 || ^15.0.0-0"
15+
"react": "^15.0.0-0 || ^16.0.0-0"
1616
},
1717
"keywords": [
1818
"react",

npm-react-swf/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "react-swf",
3-
"version": "0.13.2",
3+
"version": "1.0.0",
44
"license": "MIT",
55
"description": "Shockwave Flash Player component for React",
66
"author": "Andreas Svensson <[email protected]>",
@@ -12,7 +12,7 @@
1212
"url": "https://github.com/syranide/react-swf"
1313
},
1414
"peerDependencies": {
15-
"react": "^0.14.0 || ^15.0.0-0"
15+
"react": "^15.0.0-0 || ^16.0.0-0"
1616
},
1717
"keywords": [
1818
"react",

npm-react-swf/react-swf.js

Lines changed: 2 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/*! react-swf v0.13.2 | @syranide | MIT license */
1+
/*! react-swf v1.0.0 | @syranide | MIT license */
22

33
'use strict';
44

@@ -111,10 +111,7 @@ function ReactSWF(props) {
111111
// the key of the ReactSWF element. This unmounts the previous instance and
112112
// reloads the movie. Store initial values to keep the DOM consistent.
113113

114-
var params = {
115-
// IE8 requires the `movie` parameter.
116-
'movie': props.src
117-
};
114+
var params = {};
118115

119116
for (var key in supportedFPParamNames) {
120117
if (supportedFPParamNames.hasOwnProperty(key) &&
@@ -199,20 +196,6 @@ ReactSWF.prototype.shouldComponentUpdate = function(nextProps) {
199196
return false;
200197
};
201198

202-
ReactSWF.prototype.componentWillUnmount = function() {
203-
// IE8 leaks nodes if AS3 `ExternalInterface.addCallback`-functions remain.
204-
if (document.documentMode < 9) {
205-
var node = this._node;
206-
207-
// Node-methods are not enumerable in IE8, but properties are.
208-
for (var key in node) {
209-
if (typeof node[key] === 'function') {
210-
node[key] = null;
211-
}
212-
}
213-
}
214-
};
215-
216199
ReactSWF.prototype.render = function() {
217200
var props = this.props;
218201
var state = this.state;

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "react-swf",
3-
"version": "0.13.2",
3+
"version": "1.0.0",
44
"license": "MIT",
55
"description": "Shockwave Flash Player component for React",
66
"author": "Andreas Svensson <[email protected]>",
@@ -12,7 +12,7 @@
1212
"url": "https://github.com/syranide/react-swf"
1313
},
1414
"peerDependencies": {
15-
"react": "^0.14.0 || ^15.0.0-0"
15+
"react": "^15.0.0-0 || ^16.0.0-0"
1616
},
1717
"keywords": [
1818
"react",

react-swf.js

Lines changed: 2 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/*! react-swf v0.13.2 | @syranide | MIT license */
1+
/*! react-swf v1.0.0 | @syranide | MIT license */
22

33
(function(root, factory) {
44
if (typeof define === 'function' && define.amd) {
@@ -119,10 +119,7 @@
119119
// the key of the ReactSWF element. This unmounts the previous instance and
120120
// reloads the movie. Store initial values to keep the DOM consistent.
121121

122-
var params = {
123-
// IE8 requires the `movie` parameter.
124-
'movie': props.src
125-
};
122+
var params = {};
126123

127124
for (var key in supportedFPParamNames) {
128125
if (supportedFPParamNames.hasOwnProperty(key) &&
@@ -207,20 +204,6 @@
207204
return false;
208205
};
209206

210-
ReactSWF.prototype.componentWillUnmount = function() {
211-
// IE8 leaks nodes if AS3 `ExternalInterface.addCallback`-functions remain.
212-
if (document.documentMode < 9) {
213-
var node = this._node;
214-
215-
// Node-methods are not enumerable in IE8, but properties are.
216-
for (var key in node) {
217-
if (typeof node[key] === 'function') {
218-
node[key] = null;
219-
}
220-
}
221-
}
222-
};
223-
224207
ReactSWF.prototype.render = function() {
225208
var props = this.props;
226209
var state = this.state;

react-swf.min.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)