fix: 0 is falsy

This commit is contained in:
naskya 2023-10-20 07:20:16 +00:00
parent 0bc6d7e753
commit b4c0c4e5c6

View File

@ -264,7 +264,7 @@ export default defineComponent({
: token.props.args.y
? "perspective(128px) rotateY"
: "rotate";
const degrees = parseInt(token.props.args.deg) || "90";
const degrees = parseFloat(token.props.args.deg) ?? "90";
style = `transform: ${rotate}(${degrees}deg); transform-origin: center center;`;
break;
}