Skip to content

Commit

Permalink
[docs] Update transform function in the sx prop sizing docs (#33850)
Browse files Browse the repository at this point in the history
  • Loading branch information
ZeeshanTamboli committed Aug 10, 2022
1 parent 0b9cae4 commit db6c358
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Expand Up @@ -108,7 +108,7 @@ The sizing properties `width`, `height`, `minHeight`, `maxHeight`, `minWidth`, a

```js
function transform(value) {
return value <= 1 ? `${value * 100}%` : value;
return value <= 1 && value !== 0 ? `${value * 100}%` : value;
}
```

Expand Down
2 changes: 1 addition & 1 deletion docs/data/system/sizing/sizing.md
Expand Up @@ -8,7 +8,7 @@ The sizing properties: `width`, `height`, `minHeight`, `maxHeight`, `minWidth`,

```js
function transform(value) {
return value <= 1 ? `${value * 100}%` : value;
return value <= 1 && value !== 0 ? `${value * 100}%` : value;
}
```

Expand Down

0 comments on commit db6c358

Please sign in to comment.