Skip to content
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

ms-css-flex无效的问题 #926

Closed
taoliujun opened this issue Jul 21, 2015 · 2 comments
Closed

ms-css-flex无效的问题 #926

taoliujun opened this issue Jul 21, 2015 · 2 comments

Comments

@taoliujun
Copy link

版本是avalon.modern 1.4.5
ms-css-flex="{{t1}}" //t1是12

被解析成12px

看了下avalon源码,有一段变量定义:
avalon.cssNumber = oneObject("columnCount,order,fillOpacity,fontWeight,lineHeight,opacity,orphans,widows,zIndex,zoom")

然后判断flex是否在其中,如果不再,就加上px

有点不科学,希望要求显示传递px,

@RubyLouvre
Copy link
Owner

<!DOCTYPE HTML>
<html>
    <head>
        <title>TEST</title>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <script src="avalon.js" ></script>
        <script >
                var vm = avalon.define({
                    $id:"test",
                    aaa: "avalon",
                    t1: 12
                })
        </script>

    </head>
    <body ms-controller="test" ms-css-flex="t1" >
       {{aaa}}
    </body>
</html>

已修
image

@RubyLouvre
Copy link
Owner

avalon.cssNumber = oneObject("columnCount,order,flex,flexGrow,flexShrink,fillOpacity,fontWeight,lineHeight,opacity,orphans,widows,zIndex,zoom")

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants