From 11ac900e4e094327a979db2849e12b34c913a072 Mon Sep 17 00:00:00 2001 From: Nathan Hunzaker Date: Mon, 25 Sep 2017 18:54:37 -0400 Subject: [PATCH 1/5] Remove allowTransparency attribute `allowtransparency` is an Internet Explorer-only attribute that controls the background transparency of an iFrame. When set to true, it respects the background color of the iFrame. When set to false, it sets the background color to that of the document. This feature was removed in IE9 - falling out of React's support commitment. Developers that have somehow figured out how to get IE8 to work with React 16.x can still use `allowtransparency="true"`, since React now supports unrecognized attributes. --- .../AttributeTableSnapshot.md | 51 +++++-------------- fixtures/attribute-behavior/src/attributes.js | 6 --- .../dom/shared/HTMLDOMPropertyConfig.js | 3 -- .../dom/shared/hooks/possibleStandardNames.js | 1 - 4 files changed, 13 insertions(+), 48 deletions(-) diff --git a/fixtures/attribute-behavior/AttributeTableSnapshot.md b/fixtures/attribute-behavior/AttributeTableSnapshot.md index 69e717a24aef..3a5dcc7afef1 100644 --- a/fixtures/attribute-behavior/AttributeTableSnapshot.md +++ b/fixtures/attribute-behavior/AttributeTableSnapshot.md @@ -473,31 +473,6 @@ | `allowReorder=(null)`| (initial)| `` | | `allowReorder=(undefined)`| (initial)| `` | -## `allowTransparency` (on `` inside ``) -| Test Case | Flags | Result | -| --- | --- | --- | -| `allowTransparency=(string)`| (changed)| `"a string"` | -| `allowTransparency=(empty string)`| (changed)| `` | -| `allowTransparency=(array with string)`| (changed)| `"string"` | -| `allowTransparency=(empty array)`| (changed)| `` | -| `allowTransparency=(object)`| (changed)| `"result of toString()"` | -| `allowTransparency=(numeric string)`| (changed)| `"42"` | -| `allowTransparency=(-1)`| (changed)| `"-1"` | -| `allowTransparency=(0)`| (changed)| `"0"` | -| `allowTransparency=(integer)`| (changed)| `"1"` | -| `allowTransparency=(NaN)`| (changed, warning)| `"NaN"` | -| `allowTransparency=(float)`| (changed)| `"99.99"` | -| `allowTransparency=(true)`| (changed)| `"true"` | -| `allowTransparency=(false)`| (changed)| `"false"` | -| `allowTransparency=(string 'true')`| (changed)| `"true"` | -| `allowTransparency=(string 'false')`| (changed)| `"false"` | -| `allowTransparency=(string 'on')`| (changed)| `"on"` | -| `allowTransparency=(string 'off')`| (changed)| `"off"` | -| `allowTransparency=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `` | -| `allowTransparency=(function)`| (initial, warning, ssr mismatch)| `` | -| `allowTransparency=(null)`| (initial)| `` | -| `allowTransparency=(undefined)`| (initial)| `` | - ## `alphabetic` (on `` inside ``) | Test Case | Flags | Result | | --- | --- | --- | @@ -701,23 +676,23 @@ ## `as` (on `` inside `
`) | Test Case | Flags | Result | | --- | --- | --- | -| `as=(string)`| (initial)| `` | +| `as=(string)`| (changed)| `"a string"` | | `as=(empty string)`| (initial)| `` | -| `as=(array with string)`| (initial)| `` | +| `as=(array with string)`| (changed)| `"string"` | | `as=(empty array)`| (initial)| `` | -| `as=(object)`| (initial)| `` | -| `as=(numeric string)`| (initial)| `` | -| `as=(-1)`| (initial)| `` | -| `as=(0)`| (initial)| `` | -| `as=(integer)`| (initial)| `` | -| `as=(NaN)`| (initial, warning)| `` | -| `as=(float)`| (initial)| `` | +| `as=(object)`| (changed)| `"result of toString()"` | +| `as=(numeric string)`| (changed)| `"42"` | +| `as=(-1)`| (changed)| `"-1"` | +| `as=(0)`| (changed)| `"0"` | +| `as=(integer)`| (changed)| `"1"` | +| `as=(NaN)`| (changed, warning)| `"NaN"` | +| `as=(float)`| (changed)| `"99.99"` | | `as=(true)`| (initial, warning)| `` | | `as=(false)`| (initial, warning)| `` | -| `as=(string 'true')`| (initial)| `` | -| `as=(string 'false')`| (initial)| `` | -| `as=(string 'on')`| (initial)| `` | -| `as=(string 'off')`| (initial)| `` | +| `as=(string 'true')`| (changed)| `"true"` | +| `as=(string 'false')`| (changed)| `"false"` | +| `as=(string 'on')`| (changed)| `"on"` | +| `as=(string 'off')`| (changed)| `"off"` | | `as=(symbol)`| (initial, warning)| `` | | `as=(function)`| (initial, warning)| `` | | `as=(null)`| (initial)| `` | diff --git a/fixtures/attribute-behavior/src/attributes.js b/fixtures/attribute-behavior/src/attributes.js index 6e7462bc9a97..736b47afd01f 100644 --- a/fixtures/attribute-behavior/src/attributes.js +++ b/fixtures/attribute-behavior/src/attributes.js @@ -92,12 +92,6 @@ const attributes = [ tagName: 'switch', read: getSVGAttribute('allowReorder'), }, - { - name: 'allowTransparency', - containerTagName: 'svg', - tagName: 'path', - read: getSVGAttribute('allowtransparency'), - }, { name: 'alphabetic', containerTagName: 'svg', diff --git a/src/renderers/dom/shared/HTMLDOMPropertyConfig.js b/src/renderers/dom/shared/HTMLDOMPropertyConfig.js index 98b92fe6f689..6b99daf81ccc 100644 --- a/src/renderers/dom/shared/HTMLDOMPropertyConfig.js +++ b/src/renderers/dom/shared/HTMLDOMPropertyConfig.js @@ -26,9 +26,6 @@ var HTMLDOMPropertyConfig = { // name warnings. Properties: { allowFullScreen: HAS_BOOLEAN_VALUE, - // IE only true/false iFrame attribute - // https://msdn.microsoft.com/en-us/library/ms533072(v=vs.85).aspx - allowTransparency: HAS_STRING_BOOLEAN_VALUE, // specifies target context for links with `preload` type async: HAS_BOOLEAN_VALUE, // autoFocus is polyfilled/normalized by AutoFocusUtils diff --git a/src/renderers/dom/shared/hooks/possibleStandardNames.js b/src/renderers/dom/shared/hooks/possibleStandardNames.js index 3f1b7c620e76..236de2e0e9ae 100644 --- a/src/renderers/dom/shared/hooks/possibleStandardNames.js +++ b/src/renderers/dom/shared/hooks/possibleStandardNames.js @@ -18,7 +18,6 @@ var possibleStandardNames = { accesskey: 'accessKey', action: 'action', allowfullscreen: 'allowFullScreen', - allowtransparency: 'allowTransparency', alt: 'alt', as: 'as', async: 'async', From 5cb954236684f4aff87eb27b23465e57188efce0 Mon Sep 17 00:00:00 2001 From: Nathan Hunzaker Date: Mon, 25 Sep 2017 18:59:55 -0400 Subject: [PATCH 2/5] Use correct attribute script location --- fixtures/attribute-behavior/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fixtures/attribute-behavior/README.md b/fixtures/attribute-behavior/README.md index 5b6be37496ba..cae4bbba7503 100644 --- a/fixtures/attribute-behavior/README.md +++ b/fixtures/attribute-behavior/README.md @@ -8,7 +8,7 @@ ## Instructions -`cd scripts/attribute-behavior && yarn install && yarn start` +`cd fixtures/attribute-behavior && yarn install && yarn start` ## Interpretation From 6b6a31c990fa2792a2c26c543e3022a8053aaa5e Mon Sep 17 00:00:00 2001 From: Nathan Hunzaker Date: Wed, 27 Sep 2017 12:21:18 -0400 Subject: [PATCH 3/5] Use new UMD bundles in attribute fixtures --- fixtures/attribute-behavior/src/App.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/fixtures/attribute-behavior/src/App.js b/fixtures/attribute-behavior/src/App.js index b10a57d272ad..c682b73aae67 100644 --- a/fixtures/attribute-behavior/src/App.js +++ b/fixtures/attribute-behavior/src/App.js @@ -753,9 +753,9 @@ class App extends React.Component { async componentDidMount() { const sources = { - ReactStable: 'https://unpkg.com/react@latest/dist/react.js', - ReactDOMStable: 'https://unpkg.com/react-dom@latest/dist/react-dom.js', - ReactDOMServerStable: 'https://unpkg.com/react-dom@latest/dist/react-dom-server.js', + ReactStable: 'https://unpkg.com/react@latest/umd/react.development.js', + ReactDOMStable: 'https://unpkg.com/react-dom@latest/umd/react-dom.development.js', + ReactDOMServerStable: 'https://unpkg.com/react-dom@latest/umd/react-dom-server.browser.development.js', ReactNext: '/react.development.js', ReactDOMNext: '/react-dom.development.js', ReactDOMServerNext: '/react-dom-server.browser.development.js', From f93864026f4d0d380e972dd5d950912fc9c027ba Mon Sep 17 00:00:00 2001 From: Nathan Hunzaker Date: Wed, 27 Sep 2017 12:26:11 -0400 Subject: [PATCH 4/5] Update attribute snapshot --- .../AttributeTableSnapshot.md | 26 +++++++++---------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/fixtures/attribute-behavior/AttributeTableSnapshot.md b/fixtures/attribute-behavior/AttributeTableSnapshot.md index 3a5dcc7afef1..d9c792897daa 100644 --- a/fixtures/attribute-behavior/AttributeTableSnapshot.md +++ b/fixtures/attribute-behavior/AttributeTableSnapshot.md @@ -676,23 +676,23 @@ ## `as` (on `` inside `
`) | Test Case | Flags | Result | | --- | --- | --- | -| `as=(string)`| (changed)| `"a string"` | +| `as=(string)`| (initial)| `` | | `as=(empty string)`| (initial)| `` | -| `as=(array with string)`| (changed)| `"string"` | +| `as=(array with string)`| (initial)| `` | | `as=(empty array)`| (initial)| `` | -| `as=(object)`| (changed)| `"result of toString()"` | -| `as=(numeric string)`| (changed)| `"42"` | -| `as=(-1)`| (changed)| `"-1"` | -| `as=(0)`| (changed)| `"0"` | -| `as=(integer)`| (changed)| `"1"` | -| `as=(NaN)`| (changed, warning)| `"NaN"` | -| `as=(float)`| (changed)| `"99.99"` | +| `as=(object)`| (initial)| `` | +| `as=(numeric string)`| (initial)| `` | +| `as=(-1)`| (initial)| `` | +| `as=(0)`| (initial)| `` | +| `as=(integer)`| (initial)| `` | +| `as=(NaN)`| (initial, warning)| `` | +| `as=(float)`| (initial)| `` | | `as=(true)`| (initial, warning)| `` | | `as=(false)`| (initial, warning)| `` | -| `as=(string 'true')`| (changed)| `"true"` | -| `as=(string 'false')`| (changed)| `"false"` | -| `as=(string 'on')`| (changed)| `"on"` | -| `as=(string 'off')`| (changed)| `"off"` | +| `as=(string 'true')`| (initial)| `` | +| `as=(string 'false')`| (initial)| `` | +| `as=(string 'on')`| (initial)| `` | +| `as=(string 'off')`| (initial)| `` | | `as=(symbol)`| (initial, warning)| `` | | `as=(function)`| (initial, warning)| `` | | `as=(null)`| (initial)| `` | From ef82f0985bb41cb4b64e40f8dc9e3616115b2482 Mon Sep 17 00:00:00 2001 From: Nathan Hunzaker Date: Wed, 27 Sep 2017 21:26:06 -0400 Subject: [PATCH 5/5] Blank for CI