文章详情页
css3 - css @keyframe 能带小数吗
浏览:101日期:2023-07-29 18:11:15
问题描述
比如 10.3% 如果可以精确度是多少?
问题解答
回答1:可以,但是最多只能保持2为小数点。
@keyframes myAnimation { 0% { height: 100px; } 33.3% { height: 120px; } 66.6% { height: 140px; } 100% { height: 200px; }}
When it comes to CSS it takes notice of percentages down to 2 decimal places and then stops. So you would be able to get 33.34% but not 33.3457% for use in your keyframes
SO上的相关链接:
Is it allowed to use any decimal value in CSS keyframe animations?
Can you use more than a whole number with @keyframe percents?
标签:
CSS
相关文章:
1. 前端 - html5 audio不能播放2. java固定键值转换,使用枚举实现字典?3. vim - win10无法打开markdown编辑器4. mysql - 千万数据 分页,当偏移量 原来越大时,怎么优化速度5. 如何解决tp6在zend中无代码提示6. javascript - 有没有类似高铁管家的时间选择插件7. 这是什么情况???8. python - flask学习,user_syy添加报role is invalid keyword for User.9. css - BEM 中块(Block)有木有什么标准 何时决定一个部分提取为块而不是其父级的元素呢(Element)?~10. javascript - 微信网页开发从菜单进入页面后,按返回键没有关闭浏览器而是刷新当前页面,求解决?
排行榜
