fix(ivy): reset style property value defined using [style.prop.px] (#33780)
Prior to this change, setting style prop value to undefined or empty string would not result in resetting prop value in case the style prop is defined using [style.prop.px] syntax. The problem is that the check for empty value (and thus reseting the value) considered successful only in case of `null` value. This commit updates the check to use `isStylingValueDefined` function that also checks for undefined and empty string. PR Close #33780
This commit is contained in:

committed by
Kara Erickson

parent
f1b32840d0
commit
0fecea1427
@ -585,7 +585,7 @@ function resolveStylePropValue(
|
||||
if (value === NO_CHANGE) return value;
|
||||
|
||||
let resolvedValue: string|null = null;
|
||||
if (value !== null) {
|
||||
if (isStylingValueDefined(value)) {
|
||||
if (suffix) {
|
||||
// when a suffix is applied then it will bypass
|
||||
// sanitization entirely (b/c a new string is created)
|
||||
|
Reference in New Issue
Block a user