Skip to content

Commit 7143765

Browse files
committed
Add credentialless as a recognized boolean attribute for iframes (#36148)
## Summary The `credentialless` attribute is a boolean HTML attribute for `<iframe>` elements that loads the iframe in a new, ephemeral context without access to the parent's credentials (cookies, client certificates, etc.). This change adds it to all boolean attribute switch/case lists in React DOM so it is properly handled as a boolean (set when true, removed when false) rather than being treated as an unknown string attribute. Per the [Anonymous iframe spec (WICG)](https://wicg.github.io/anonymous-iframe/): > The credentialless attribute enables loading documents hosted by the iframe with a new and ephemeral storage partition. It is a boolean value. The default is false. ``` partial interface HTMLIFrameElement { attribute boolean credentialless; }; ``` Changes: - ReactDOMComponent.js: Added to both `setProp` and `diffHydratedGenericElement` - ReactFizzConfigDOM.js: Added to `pushAttribute` for server-side rendering - ReactDOMUnknownPropertyHook.js: Added to both validation switch/case lists ## Test plan - Added unit test in DOMPropertyOperations-test.js verifying `credentialless={true}` sets the attribute to `''` and `credentialless={false}` removes it - All tests pass in source and www channels (590 tests each) - Flow type checking passes (dom-node renderer) - Prettier and lint pass DiffTrain build for [306a01b](306a01b)
1 parent 03117b3 commit 7143765

36 files changed

Lines changed: 120 additions & 86 deletions

compiled/facebook-www/REVISION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
bc249804d3c2ea6ee95bc5543c3735a65d1239b5
1+
306a01b4e0242e9379ba971c8925670651f16818
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
bc249804d3c2ea6ee95bc5543c3735a65d1239b5
1+
306a01b4e0242e9379ba971c8925670651f16818

compiled/facebook-www/React-dev.classic.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1482,7 +1482,7 @@ __DEV__ &&
14821482
exports.useTransition = function () {
14831483
return resolveDispatcher().useTransition();
14841484
};
1485-
exports.version = "19.3.0-www-classic-bc249804-20260417";
1485+
exports.version = "19.3.0-www-classic-306a01b4-20260420";
14861486
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
14871487
"function" ===
14881488
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&

compiled/facebook-www/React-dev.modern.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1482,7 +1482,7 @@ __DEV__ &&
14821482
exports.useTransition = function () {
14831483
return resolveDispatcher().useTransition();
14841484
};
1485-
exports.version = "19.3.0-www-modern-bc249804-20260417";
1485+
exports.version = "19.3.0-www-modern-306a01b4-20260420";
14861486
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
14871487
"function" ===
14881488
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&

compiled/facebook-www/React-prod.classic.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -610,4 +610,4 @@ exports.useSyncExternalStore = function (
610610
exports.useTransition = function () {
611611
return ReactSharedInternals.H.useTransition();
612612
};
613-
exports.version = "19.3.0-www-classic-bc249804-20260417";
613+
exports.version = "19.3.0-www-classic-306a01b4-20260420";

compiled/facebook-www/React-prod.modern.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -610,4 +610,4 @@ exports.useSyncExternalStore = function (
610610
exports.useTransition = function () {
611611
return ReactSharedInternals.H.useTransition();
612612
};
613-
exports.version = "19.3.0-www-modern-bc249804-20260417";
613+
exports.version = "19.3.0-www-modern-306a01b4-20260420";

compiled/facebook-www/React-profiling.classic.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -614,7 +614,7 @@ exports.useSyncExternalStore = function (
614614
exports.useTransition = function () {
615615
return ReactSharedInternals.H.useTransition();
616616
};
617-
exports.version = "19.3.0-www-classic-bc249804-20260417";
617+
exports.version = "19.3.0-www-classic-306a01b4-20260420";
618618
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
619619
"function" ===
620620
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&

compiled/facebook-www/React-profiling.modern.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -614,7 +614,7 @@ exports.useSyncExternalStore = function (
614614
exports.useTransition = function () {
615615
return ReactSharedInternals.H.useTransition();
616616
};
617-
exports.version = "19.3.0-www-modern-bc249804-20260417";
617+
exports.version = "19.3.0-www-modern-306a01b4-20260420";
618618
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
619619
"function" ===
620620
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&

compiled/facebook-www/ReactART-dev.classic.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20434,10 +20434,10 @@ __DEV__ &&
2043420434
(function () {
2043520435
var internals = {
2043620436
bundleType: 1,
20437-
version: "19.3.0-www-classic-bc249804-20260417",
20437+
version: "19.3.0-www-classic-306a01b4-20260420",
2043820438
rendererPackageName: "react-art",
2043920439
currentDispatcherRef: ReactSharedInternals,
20440-
reconcilerVersion: "19.3.0-www-classic-bc249804-20260417"
20440+
reconcilerVersion: "19.3.0-www-classic-306a01b4-20260420"
2044120441
};
2044220442
internals.overrideHookState = overrideHookState;
2044320443
internals.overrideHookStateDeletePath = overrideHookStateDeletePath;
@@ -20472,7 +20472,7 @@ __DEV__ &&
2047220472
exports.Shape = Shape;
2047320473
exports.Surface = Surface;
2047420474
exports.Text = Text;
20475-
exports.version = "19.3.0-www-classic-bc249804-20260417";
20475+
exports.version = "19.3.0-www-classic-306a01b4-20260420";
2047620476
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
2047720477
"function" ===
2047820478
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&

compiled/facebook-www/ReactART-dev.modern.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20205,10 +20205,10 @@ __DEV__ &&
2020520205
(function () {
2020620206
var internals = {
2020720207
bundleType: 1,
20208-
version: "19.3.0-www-modern-bc249804-20260417",
20208+
version: "19.3.0-www-modern-306a01b4-20260420",
2020920209
rendererPackageName: "react-art",
2021020210
currentDispatcherRef: ReactSharedInternals,
20211-
reconcilerVersion: "19.3.0-www-modern-bc249804-20260417"
20211+
reconcilerVersion: "19.3.0-www-modern-306a01b4-20260420"
2021220212
};
2021320213
internals.overrideHookState = overrideHookState;
2021420214
internals.overrideHookStateDeletePath = overrideHookStateDeletePath;
@@ -20243,7 +20243,7 @@ __DEV__ &&
2024320243
exports.Shape = Shape;
2024420244
exports.Surface = Surface;
2024520245
exports.Text = Text;
20246-
exports.version = "19.3.0-www-modern-bc249804-20260417";
20246+
exports.version = "19.3.0-www-modern-306a01b4-20260420";
2024720247
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
2024820248
"function" ===
2024920249
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&

0 commit comments

Comments
 (0)