flutter_html_css_transform 0.2.0
flutter_html_css_transform: ^0.2.0 copied to clipboard
A flutter_html extension that renders the CSS transform and transform-origin properties, percentages included.
0.2.0 #
- Renamed from
flutter_html_css_transform_extensionon pub.flutter-io.cn. The old package stays published and is marked discontinued with this one as its replacement. Class names are unchanged.
0.1.0 #
- Initial release. Adds a
flutter_htmlextension that appliestransformandtransform-originfrom an element's inline style. Handlestranslate,translateX,translateY,scale,scaleX,scaleY,rotate,skew,skewX,skewY,matrixandnone. The functions compose left to right, and an angle takesdeg,grad,radorturn. Percentages resolve against the element's own box during paint, sotranslate(-50%, -50%)works next to a rotation. 3D functions are rejected, because the CSS around them has no equivalent here. emresolves against the element's own computed font size, andremagainst therootFontSizeargument, which defaults toflutter_html's root font size of 14. Both used to multiply by a hard-coded 16, sotranslate(0.5rem, 0)moved 8 px and now moves 7 px, and2emon an element rendering at 20 px moved 32 px and now moves 40 px. No release shipped the old numbers.kFlutterHtmlDefaultFontSizeis not exported. Four packages in the family declared the same value under that name, which made importing any two of them an ambiguous import. The fallback basis is a library-private constant here. If you want the root font size as a symbol, usekFlutterHtmlRootFontSizefromflutter_html_css_font_size, orFontSize.medium.valuefromflutter_htmlitself.