Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions 2.1.0/demo/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<link rel="stylesheet" href="http://a.tbcdn.cn/s/kissy/1.3.0/css/dpl/??base-min.css">
<style type="text/css">
ol{
width:950px;
width:500px;
}
</style>
<script>var S = KISSY;S.config({packages:[{name:"kg",path:"http://g.tbcdn.cn/kg/",charset:"utf-8",ignorePackageNameInUri:true}]});if (S.Config.debug){var srcPath = "../";S.config({packages:[{name:"kg/stepbar/2.1.0",path:srcPath,charset:"utf-8",ignorePackageNameInUri:true}]});}</script></head>
Expand Down Expand Up @@ -60,7 +60,7 @@ <h4>示例3:监听激活后、改变颜色后事件</h4>
]
});
}
S.use('node,kg/stepbar/2.1.0/index,kg/stepbar/2.1.0/stepbar.css', function (S,Node,Stepbar) {
S.use('node,../index,kg/stepbar/2.1.0/stepbar.css', function (S,Node,Stepbar) {
var $ = Node.all;
//示例1
var step1 = new Stepbar('#steps-demo-1');
Expand Down
3 changes: 2 additions & 1 deletion 2.1.0/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,8 @@ KISSY.add(function (S,Node, Base) {
var ret = containerWidth % itemLen;
width = Number( (containerWidth - ret) / itemLen);
}
$steps.width(width);
for(var i = 0;i<itemLen;i++)
$steps[i].width(width);

if (ret) {
$steps.item(itemLen - 1).width(width + ret);
Expand Down