mirror of
https://iceshrimp.dev/crimekillz/trashposs
synced 2024-11-23 17:29:05 +01:00
add perspective
This commit is contained in:
parent
9e46f040a1
commit
4c37e9f80d
@ -178,12 +178,12 @@ export default defineComponent({
|
||||
return h(MkSparkle, {}, genEl(token.children));
|
||||
}
|
||||
case 'rotate': {
|
||||
const rotateDir =
|
||||
token.props.args.x ? 'X' :
|
||||
token.props.args.y ? 'Y' :
|
||||
'';
|
||||
const rotate =
|
||||
token.props.args.x ? 'perspective(128px) rotateX' :
|
||||
token.props.args.y ? 'perspective(128px) rotateY' :
|
||||
'rotate';
|
||||
const degrees = parseInt(token.props.args.deg) || '90';
|
||||
style = `transform: rotate${rotateDir}(${degrees}deg); transform-origin: center center;`;
|
||||
style = `transform: ${rotate}(${degrees}deg); transform-origin: center center;`;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user