-
-
Notifications
You must be signed in to change notification settings - Fork 112
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add scaleEffect
modifier
#424
Conversation
1f0c8f6
to
3e5568e
Compare
d75e6a8
to
4f2989c
Compare
|
||
extension _ScaleEffect: DOMViewModifier { | ||
public var attributes: [HTMLAttribute: String] { | ||
["style": "transform: scale(\(scale.width), \(scale.height));"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this mean that anchor
property has no effect in the HTML renderer?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh, yes. I'll add the transform-origin
property.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I fixed the rotationEffect modifier as well.
b4fb672
to
fdd37ec
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome, thank you!
This uses the
scale()
CSS transform in the HTML/DOM renderers.