We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents f0ede57 + 2409a57 commit e3b4105Copy full SHA for e3b4105
apps/client/src/pages/builder/sidebars/left/sections/picture/options.tsx
@@ -52,6 +52,7 @@ export const PictureOptions = () => {
52
}, [picture.aspectRatio]);
53
54
const onAspectRatioChange = (value: AspectRatio) => {
55
+ if (!value) return
56
setValue("basics.picture.aspectRatio", stringToRatioMap[value]);
57
};
58
@@ -117,6 +118,8 @@ export const PictureOptions = () => {
117
118
id="picture.aspectRatio"
119
value={picture.aspectRatio}
120
onChange={(event) => {
121
+ if (!event.target.valueAsNumber) return
122
+ if (isNaN(event.target.valueAsNumber)) return
123
setValue("basics.picture.aspectRatio", event.target.valueAsNumber);
124
}}
125
/>
0 commit comments