Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
x649585723
incubator-echarts
提交
800ba5b8
I
incubator-echarts
项目概览
x649585723
/
incubator-echarts
与 Fork 源项目一致
从无法访问的项目Fork
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
I
incubator-echarts
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
800ba5b8
编写于
7月 04, 2020
作者:
P
pissang
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'next' into label-enhancement
上级
1cfa45d6
196935f8
变更
9
展开全部
隐藏空白更改
内联
并排
Showing
9 changed file
with
828 addition
and
174 deletion
+828
-174
src/chart/custom.ts
src/chart/custom.ts
+177
-99
src/chart/helper/Symbol.ts
src/chart/helper/Symbol.ts
+1
-1
src/chart/line/LineView.ts
src/chart/line/LineView.ts
+1
-1
src/component/timeline/SliderTimelineView.ts
src/component/timeline/SliderTimelineView.ts
+1
-1
src/echarts.ts
src/echarts.ts
+1
-1
src/export.ts
src/export.ts
+1
-0
src/util/graphic.ts
src/util/graphic.ts
+3
-0
test/custom-transition.html
test/custom-transition.html
+51
-43
test/custom-transition2.html
test/custom-transition2.html
+592
-28
未找到文件。
src/chart/custom.ts
浏览文件 @
800ba5b8
此差异已折叠。
点击以展开。
src/chart/helper/Symbol.ts
浏览文件 @
800ba5b8
...
...
@@ -95,7 +95,7 @@ class Symbol extends graphic.Group {
* @param {boolean} toLastFrame
*/
stopSymbolAnimation
(
toLastFrame
:
boolean
)
{
this
.
childAt
(
0
).
stopAnimation
(
''
,
toLastFrame
);
this
.
childAt
(
0
).
stopAnimation
(
null
,
toLastFrame
);
}
/**
...
...
src/chart/line/LineView.ts
浏览文件 @
800ba5b8
...
...
@@ -501,7 +501,7 @@ class LineView extends ChartView {
// Stop symbol animation and sync with line points
// FIXME performance?
data
.
eachItemGraphicEl
(
function
(
el
)
{
el
.
stopAnimation
(
''
,
true
);
el
.
stopAnimation
(
null
,
true
);
});
// In the case data zoom triggerred refreshing frequently
...
...
src/component/timeline/SliderTimelineView.ts
浏览文件 @
800ba5b8
...
...
@@ -795,7 +795,7 @@ function pointerMoveTo(
pointer
.
y
=
0
;
}
else
{
pointer
.
stopAnimation
(
''
,
true
);
pointer
.
stopAnimation
(
null
,
true
);
pointer
.
animateTo
({
x
:
toCoord
,
y
:
0
...
...
src/echarts.ts
浏览文件 @
800ba5b8
...
...
@@ -554,7 +554,7 @@ class ECharts extends Eventful {
const
list
=
zr
.
storage
.
getDisplayList
();
// Stop animations
zrUtil
.
each
(
list
,
function
(
el
:
Element
)
{
el
.
stopAnimation
(
''
,
true
);
el
.
stopAnimation
(
null
,
true
);
});
return
(
zr
.
painter
as
SVGPainter
).
toDataURL
();
...
...
src/export.ts
浏览文件 @
800ba5b8
...
...
@@ -74,6 +74,7 @@ const GRAPHIC_KEYS = [
'
Image
'
,
'
Text
'
,
'
Circle
'
,
'
Ellipse
'
,
'
Sector
'
,
'
Ring
'
,
'
Polygon
'
,
...
...
src/util/graphic.ts
浏览文件 @
800ba5b8
...
...
@@ -27,6 +27,7 @@ import ZRImage, { ImageStyleProps } from 'zrender/src/graphic/Image';
import
Group
from
'
zrender/src/graphic/Group
'
;
import
ZRText
,
{
TextStyleProps
}
from
'
zrender/src/graphic/Text
'
;
import
Circle
from
'
zrender/src/graphic/shape/Circle
'
;
import
Ellipse
from
'
zrender/src/graphic/shape/Ellipse
'
;
import
Sector
from
'
zrender/src/graphic/shape/Sector
'
;
import
Ring
from
'
zrender/src/graphic/shape/Ring
'
;
import
Polygon
from
'
zrender/src/graphic/shape/Polygon
'
;
...
...
@@ -1664,6 +1665,7 @@ export const getECData = makeInner<ECData, Element>();
// Register built-in shapes. These shapes might be overwirtten
// by users, although we do not recommend that.
registerShape
(
'
circle
'
,
Circle
);
registerShape
(
'
ellipse
'
,
Ellipse
);
registerShape
(
'
sector
'
,
Sector
);
registerShape
(
'
ring
'
,
Ring
);
registerShape
(
'
polygon
'
,
Polygon
);
...
...
@@ -1678,6 +1680,7 @@ export {
ZRImage
as
Image
,
ZRText
as
Text
,
Circle
,
Ellipse
,
Sector
,
Ring
,
Polygon
,
...
...
test/custom-transition.html
浏览文件 @
800ba5b8
...
...
@@ -177,9 +177,11 @@ under the License.
children
.
push
({
type
:
'
polygon
'
,
shape
:
{
points
:
makeShapePoints
(
api
,
valOnRadius
,
valOnAngle
),
points
:
makeShapePoints
(
api
,
valOnRadius
,
valOnAngle
)
},
extra
:
{
valOnAngle
:
valOnAngle
,
$
transition
:
'
valOnAngle
'
transition
:
'
valOnAngle
'
},
style
:
{
lineWidth
:
1
,
...
...
@@ -188,7 +190,7 @@ under the License.
},
during
:
function
(
apiDuring
)
{
apiDuring
.
setShape
(
'
points
'
,
makeShapePoints
(
api
,
valOnRadius
,
apiDuring
.
get
Shape
(
'
valOnAngle
'
)
api
,
valOnRadius
,
apiDuring
.
get
Extra
(
'
valOnAngle
'
)
));
}
});
...
...
@@ -217,9 +219,10 @@ under the License.
type
:
'
text
'
,
x
:
point
[
0
],
y
:
point
[
1
],
shape
:
{
transition
:
[],
extra
:
{
valOnAngle
:
valOnAngle
,
$
transition
:
'
valOnAngle
'
transition
:
'
valOnAngle
'
},
style
:
{
text
:
getText
(
valOnAngle
),
...
...
@@ -232,7 +235,7 @@ under the License.
},
z2
:
50
,
during
:
function
(
apiDuring
)
{
var
iValOnAngle
=
apiDuring
.
get
Shape
(
'
valOnAngle
'
);
var
iValOnAngle
=
apiDuring
.
get
Extra
(
'
valOnAngle
'
);
var
point
=
makeLabelPosition
(
api
,
valOnRadius
,
iValOnAngle
);
apiDuring
.
setTransform
(
'
x
'
,
point
[
0
]).
setTransform
(
'
y
'
,
point
[
1
]);
apiDuring
.
setStyle
(
'
text
'
,
getText
(
iValOnAngle
));
...
...
@@ -403,11 +406,13 @@ under the License.
children
.
push
({
type
:
'
polygon
'
,
shape
:
{
points
:
makeShapePoints
(
params
,
widthRadius
,
startRadius
,
endRadian
),
points
:
makeShapePoints
(
params
,
widthRadius
,
startRadius
,
endRadian
)
},
extra
:
{
widthRadius
:
widthRadius
,
startRadius
:
startRadius
,
endRadian
:
endRadian
,
$
transition
:
[
'
widthRadius
'
,
'
startRadius
'
,
'
endRadian
'
]
transition
:
[
'
widthRadius
'
,
'
startRadius
'
,
'
endRadian
'
]
},
style
:
{
lineWidth
:
1
,
...
...
@@ -417,9 +422,9 @@ under the License.
during
:
function
(
apiDuring
)
{
apiDuring
.
setShape
(
'
points
'
,
makeShapePoints
(
params
,
apiDuring
.
get
Shape
(
'
widthRadius
'
),
apiDuring
.
get
Shape
(
'
startRadius
'
),
apiDuring
.
get
Shape
(
'
endRadian
'
)
apiDuring
.
get
Extra
(
'
widthRadius
'
),
apiDuring
.
get
Extra
(
'
startRadius
'
),
apiDuring
.
get
Extra
(
'
endRadian
'
)
));
}
});
...
...
@@ -460,11 +465,12 @@ under the License.
type
:
'
text
'
,
x
:
point
[
0
],
y
:
point
[
1
],
shape
:
{
transition
:
[],
extra
:
{
startRadius
:
startRadius
,
endRadian
:
endRadian
,
widthRadius
:
widthRadius
,
$
transition
:
[
'
startRadius
'
,
'
endRadian
'
,
'
widthRadius
'
]
transition
:
[
'
startRadius
'
,
'
endRadian
'
,
'
widthRadius
'
]
},
style
:
{
text
:
makeText
(
endRadian
),
...
...
@@ -481,11 +487,11 @@ under the License.
},
z2
:
50
,
during
:
function
(
apiDuring
)
{
var
endRadian
=
apiDuring
.
get
Shape
(
'
endRadian
'
);
var
endRadian
=
apiDuring
.
get
Extra
(
'
endRadian
'
);
var
point
=
makeLabelPosition
(
params
,
apiDuring
.
get
Shape
(
'
widthRadius
'
),
apiDuring
.
get
Shape
(
'
startRadius
'
),
apiDuring
.
get
Extra
(
'
widthRadius
'
),
apiDuring
.
get
Extra
(
'
startRadius
'
),
endRadian
);
apiDuring
.
setTransform
(
'
x
'
,
point
[
0
]).
setTransform
(
'
y
'
,
point
[
1
]);
...
...
@@ -652,8 +658,8 @@ under the License.
// polor: anticlockwise-positive radian
// sector: clockwise-positive radian
endAngle
:
-
polarEndRadian
,
$
transition
:
'
endAngle
'
,
$
enterFrom
:
{
endAngle
:
0
}
transition
:
'
endAngle
'
,
enterFrom
:
{
endAngle
:
0
}
}
}
},
{
...
...
@@ -663,14 +669,16 @@ under the License.
type
:
'
polygon
'
,
shape
:
{
points
:
makePionterPoints
(
params
,
polarEndRadian
),
},
extra
:
{
polarEndRadian
:
polarEndRadian
,
$
transition
:
'
polarEndRadian
'
,
$
enterFrom
:
{
polarEndRadian
:
0
}
transition
:
'
polarEndRadian
'
,
enterFrom
:
{
polarEndRadian
:
0
}
},
during
:
function
(
apiDuring
)
{
apiDuring
.
setShape
(
'
points
'
,
makePionterPoints
(
params
,
apiDuring
.
get
Shape
(
'
polarEndRadian
'
))
makePionterPoints
(
params
,
apiDuring
.
get
Extra
(
'
polarEndRadian
'
))
);
}
},
...
...
@@ -690,10 +698,10 @@ under the License.
}
},
{
type
:
'
text
'
,
shape
:
{
extra
:
{
valOnRadian
:
valOnRadian
,
$
transition
:
'
valOnRadian
'
,
$
enterFrom
:
{
valOnRadian
:
0
}
transition
:
'
valOnRadian
'
,
enterFrom
:
{
valOnRadian
:
0
}
},
style
:
{
text
:
makeText
(
valOnRadian
),
...
...
@@ -703,10 +711,10 @@ under the License.
fill
:
'
rgb(0,50,190)
'
,
align
:
'
center
'
,
verticalAlign
:
'
middle
'
,
$
enterFrom
:
{
opacity
:
0
}
enterFrom
:
{
opacity
:
0
}
},
during
:
function
(
apiDuring
)
{
apiDuring
.
setStyle
(
'
text
'
,
makeText
(
apiDuring
.
get
Shape
(
'
valOnRadian
'
)));
apiDuring
.
setStyle
(
'
text
'
,
makeText
(
apiDuring
.
get
Extra
(
'
valOnRadian
'
)));
}
}]
};
...
...
@@ -961,7 +969,7 @@ under the License.
},
style
:
{
fill
:
'
blue
'
,
//
$
enterFrom: { opacity: 0 }
// enterFrom: { opacity: 0 }
}
},
{
type
:
'
circle
'
,
...
...
@@ -972,7 +980,7 @@ under the License.
},
style
:
{
fill
:
'
green
'
,
//
$
enterFrom: { opacity: 0 }
// enterFrom: { opacity: 0 }
},
textConfig
:
{
position
:
'
bottom
'
...
...
@@ -981,7 +989,7 @@ under the License.
style
:
{
text
:
'
xxxx
'
,
fill
:
'
black
'
,
//
$
enterFrom: { opacity: 0 }
// enterFrom: { opacity: 0 }
}
}
}]
...
...
@@ -1078,7 +1086,7 @@ under the License.
type
:
'
group
'
,
x
:
pos
[
0
],
y
:
pos
[
1
],
$
enterFrom
:
{
enterFrom
:
{
y
:
0
},
children
:
[{
...
...
@@ -1164,7 +1172,7 @@ under the License.
y
:
params
.
coordSys
.
y
,
width
:
params
.
coordSys
.
width
,
height
:
params
.
coordSys
.
height
,
$
enterFrom
:
{
width
:
0
}
enterFrom
:
{
width
:
0
}
}
}
};
...
...
@@ -1225,7 +1233,7 @@ under the License.
style
:
{
image
:
weatherIcons
.
Showers
,
width
:
width
,
$
transition
:
'
width
'
transition
:
'
width
'
}
};
},
...
...
@@ -1277,7 +1285,7 @@ under the License.
x
:
pos
[
0
],
y
:
pos
[
1
],
rotation
:
pos
[
0
]
/
500
*
Math
.
PI
,
$
transition
:
[
'
rotation
'
],
transition
:
[
'
rotation
'
],
originX
:
-
50
,
originY
:
50
,
children
:
[{
...
...
@@ -1291,7 +1299,7 @@ under the License.
},
style
:
{
fill
:
'
green
'
,
$
enterFrom
:
{
opacity
:
0
}
enterFrom
:
{
opacity
:
0
}
}
},
{
type
:
'
circle
'
,
...
...
@@ -1302,7 +1310,7 @@ under the License.
},
style
:
{
fill
:
'
blue
'
,
$
enterFrom
:
{
opacity
:
0
}
enterFrom
:
{
opacity
:
0
}
},
textConfig
:
{
position
:
'
bottom
'
...
...
@@ -1311,7 +1319,7 @@ under the License.
style
:
{
text
:
'
xxxx
'
,
fill
:
'
black
'
,
$
enterFrom
:
{
opacity
:
0
}
enterFrom
:
{
opacity
:
0
}
}
}
}]
...
...
@@ -1363,7 +1371,7 @@ under the License.
return
{
type
:
'
rect
'
,
position
:
pos
,
$
transition
:
[],
transition
:
[],
shape
:
{
x
:
-
50
,
y
:
50
,
...
...
@@ -1373,7 +1381,7 @@ under the License.
},
style
:
{
fill
:
'
green
'
,
$
enterFrom
:
{
opacity
:
0
}
enterFrom
:
{
opacity
:
0
}
}
};
},
...
...
@@ -1426,10 +1434,10 @@ under the License.
x
:
pos
[
0
],
y
:
pos
[
1
],
rotation
:
pos
[
0
]
/
500
*
Math
.
PI
,
$
transition
:
[
'
x
'
,
'
y
'
,
'
rotation
'
],
transition
:
[
'
x
'
,
'
y
'
,
'
rotation
'
],
originX
:
-
50
,
originY
:
50
,
$
leaveTo
:
{
scaleX
:
0
,
scaleY
:
0
},
leaveTo
:
{
scaleX
:
0
,
scaleY
:
0
},
children
:
[{
type
:
'
rect
'
,
shape
:
{
...
...
@@ -1441,7 +1449,7 @@ under the License.
},
style
:
{
fill
:
'
green
'
,
$
enterFrom
:
{
opacity
:
0
}
enterFrom
:
{
opacity
:
0
}
}
},
{
type
:
'
circle
'
,
...
...
@@ -1452,7 +1460,7 @@ under the License.
},
style
:
{
fill
:
'
blue
'
,
$
enterFrom
:
{
opacity
:
0
}
enterFrom
:
{
opacity
:
0
}
},
textConfig
:
{
position
:
'
bottom
'
...
...
@@ -1461,7 +1469,7 @@ under the License.
style
:
{
text
:
'
xxxx
'
,
fill
:
'
black
'
,
$
enterFrom
:
{
opacity
:
0
}
enterFrom
:
{
opacity
:
0
}
}
}
}]
...
...
test/custom-transition2.html
浏览文件 @
800ba5b8
此差异已折叠。
点击以展开。
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录