[Bug] legend的orient设置为一个错误属性导致的特性
Version
5.4.1
Link to Minimal Reproduction
https://echarts.apache.org/examples/zh/editor.html?code=zZG_bsMgEMb3PAWiqwcMjhMsdWhVderWSh2iDARfY1TLRECUWJXfvQfGUv0GXe4P9_u-s872EowdyCP52RCibW9dQw70gTEh6poWJJZ1LWUqK61OGlIJW8EF0GOBslYF5SE0yYMQb69OA9qkjqBdGC9JxVnJcxY5Vzlvc65ny1n3ah34gBPBGQbBMbAyVhUGyf6g7wEuaQmPaLlHtJSI8ojyFfoCHlx0LbeI8uiKi2OLaLlCPyH0amiRlfuC7HY4j6SUBanYMWExTlHRwxmGdjlCB-bc4UkqNrvdTBu6Jq1MfTxJQ6jXzvY9nd-sMzCEhoJz1qW3ZHx_uhu_-GadVgHO1o1ZqZD4MPp7ofAndPbWkC_Ve0gv0-I2ZrfU4CEMYHdYmZ_UvH2Zv6nRXsPziCNnbzQ5rT_nnyiOm-kX&_source=echarts-doc-preview&enc=deflate
Steps to Reproduce
设置orient='error'(非正常值)。
Current Behavior
lengend的width和height都可以同时生效了。(如果设置为正常值就不能同时生效) 这样可以突破type=scroll,orient设置为vertical或者默认值的情况下,不能同时设置宽高的限制
Expected Behavior
支持可以同时生效的特性,或者在文档里指明无法同时生效,不然让人产生疑惑
Environment
- OS:
- Browser:
- Framework:
Any additional comments?
No response
@a1185963755 It seems you are not using English, I've helped translate the content automatically. To make your issue understood by more people and get helped, we'd like to suggest using English next time. 🤗
TRANSLATED
TITLE
[Bug] legend's orient is set to a trait caused by an incorrect attribute
BODY
Version
5.4.1
Link to Minimal Reproduction
https://echarts.apache.org/examples/zh/editor.html?code=zZG_bsMgEMb3PAWiqwcMjhMsdWhVderWSh2iDARfY1TLRECUWJXfvQfGUv0GXe4P9_u-s872EowdyCP52RCibW9dQw70gTEh6poWJJZ1LWUqK61OGlIJW8EF0GOBslYF5SE0yYMQb69OA9qkjqBdGC9JxVnJcxY5Vzlvc65ny1n3ah34gBPBGQbBMbAyVhUGyf6g7wEuaQmPaLlHtJSI8ojyFfoCHlx0LbeI8uiKi2OLaLlCPyH0amiRlfuC7HY4j6SUBanYMWExTlHRwxmGdjlCB-bc4UkqNrvdTBu6Jq1MfTxJQ6jXzvY9nd-sMzCEhoJz1qW3ZHx_uhu_-GadVgHO1o1ZqZD4MPp7ofAndPbWkC_Ve0gv0-I2ZrfU4CEMYHdYmZ_UvH2Zv6nRXsPziCNnbzQ5rT_nnyiOm-kX&_source=echarts-doc-preview&enc=deflate
Steps to Reproduce
Set orient='error' (unhealthy value).
Current Behavior
lengend's width and height can be applied at the same time. (If set to normal value, it will not take effect at the same time) This can break through the limit of type=scroll, and when orient is set to vertical or the default value, the width and height limit cannot be set at the same time
Expected Behavior
Support features that can be applied at the same time, or indicate in the documentation that they cannot be valid at the same time, otherwise it will cause doubts
Environment
- OS:
- Browser:
- Framework:
Any additional comments?
No response
Testing shows that legend width and height depend on the orientation:
for orient: "vertical" - height works, width is ignored
for orient: "horizontal" - width works, height is ignored
The bug/feature you discovered allows for setting height to horizontal scroll, but the counter (2/3) is disordered because it does not expect vertical columns of items. Demo.