Skip to content

Commit 089b4c7

Browse files
committed
moveup
1 parent ab7752f commit 089b4c7

File tree

1 file changed

+5
-11
lines changed

1 file changed

+5
-11
lines changed

packages/runtime-dom/src/patchProp.ts

Lines changed: 5 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -79,13 +79,13 @@ function shouldSetAsProp(
7979
return false
8080
}
8181

82-
// spellcheck and draggable are numerated attrs, however their
83-
// corresponding DOM properties are actually booleans - this leads to
84-
// setting it with a string "false" value leading it to be coerced to
85-
// `true`, so we need to always treat them as attributes.
82+
// these are enumerated attrs, however their corresponding DOM properties
83+
// are actually booleans - this leads to setting it with a string "false"
84+
// value leading it to be coerced to `true`, so we need to always treat
85+
// them as attributes.
8686
// Note that `contentEditable` doesn't have this problem: its DOM
8787
// property is also enumerated string values.
88-
if (key === 'spellcheck' || key === 'draggable') {
88+
if (key === 'spellcheck' || key === 'draggable' || key === 'translate') {
8989
return false
9090
}
9191

@@ -105,12 +105,6 @@ function shouldSetAsProp(
105105
return false
106106
}
107107

108-
// #5462 translate is an enumerated attr, however its
109-
// corresponding DOM property are actually boolean.
110-
if (key === 'translate') {
111-
return false
112-
}
113-
114108
// native onclick with string value, must be set as attribute
115109
if (nativeOnRE.test(key) && isString(value)) {
116110
return false

0 commit comments

Comments
 (0)