You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by GitBox <gi...@apache.org> on 2022/07/04 09:16:55 UTC

[GitHub] [echarts] ahuiiiiiii opened a new issue, #17310: [Bug]

ahuiiiiiii opened a new issue, #17310:
URL: https://github.com/apache/echarts/issues/17310

   ### Version
   
   5.3.3
   
   ### Link to Minimal Reproduction
   
   _No response_
   
   ### Steps to Reproduce
   
   option:{
         name: "组织架构资产一览图",
         tooltip: { trigger: "item", triggerOn: "mousemove" },
         //提供数据视图、还原、下载的工具
         toolbox: {
           show: true,
           feature: {
             mark: { show: true },
             // dataView : {show: true, readOnly: false},
             restore: { show: true },
             saveAsImage: { show: true },
           },
         },
         series: [
           {
             name: "医院组织架构图",
             type: "tree",
             orient: "vertical", //竖向或水平   TB代表竖向  LR代表水平
             edgeShape: "curve", //控制折线的形式
             edgeForkPosition: "60%",
             top: "10%",
             bottom: "10%",
             left: "1",
             right: "1",
             initialTreeDepth: 10, //树图初始展开的层级(深度)
             expandAndCollapse: true, //点击节点时不收起子节点,default: true
             //   symbolSize: [135, 42],
             //   itemStyle: {
             //     color: "transparent",
             //     borderWidth: 0,
             //   },
             lineStyle: {
               color: "#D5D5D5",
               width: 1,
               // curveness: 0.7,
             },
             animationDuration: 0, //防止图片第一次加载不显示
             leaves: {
               label: {
                 show: true,
               },
             },
             data: [
               {
                 label: {
                   backgroundColor: "#F4F4F4",
                   borderRadius: [5, 5, 5, 5],
                   formatter: ["{first|党总书记/院长}", "{second|测试}"].join(
                     "\n"
                   ),
                   rich: {
                     first: {
                       backgroundColor: "#4dc4ff",
                       fontSize: 17,
                       color: "#fff",
                       align: "center",
                       width: 150,
                       height: 40,
                       borderRadius: [5, 5, 0, 0],
                     },
                     second: {
                       fontSize: 16,
                       color: "#888",
                       align: "center",
                       lineHeight: 30,
                     },
                   },
                 },
                 children: [
                   {
                     label: {
                       backgroundColor: "#F4F4F4",
                       borderRadius: [5, 5, 5, 5],
                       formatter: ["{first|副院长}", "{second|测试}"].join("\n"),
                       rich: {
                         first: {
                           backgroundColor: "#ff9933",
                           fontSize: 15,
                           color: "#fff",
                           align: "center",
                           width: 60,
                           height: 30,
                           borderRadius: [5, 5, 0, 0],
                         },
                         second: {
                           fontSize: 15,
                           color: "#888",
                           align: "center",
                           lineHeight: 25,
                         },
                       },
                     },
                     children: (function () {
                       const a = [];
                       const s = {
                         label: {
                           backgroundColor: "#ff9933",
                           borderRadius: [5, 5, 5, 5],
                           verticalAlign: "middle",
                           align: "center",
                           formatter: [
                             "{first|内}",
                             "{first|四}",
                             "{first|科}",
                             "{first|病}",
                             "{first|房}",
                           ].join("\n"),
                           rich: {
                             first: {
                               width: 21,
                               height: 19,
                               fontSize: 15,
                               color: "#fff",
                               padding: [1, 0, 0, 0],
                             },
                           },
                         },
                       };
   
                       for (let i = 0; i < 20; i++) {
                         a.push(s);
                       }
                       return a;
                     })(),
                   },
                 
                   {
                     label: {
                       backgroundColor: "#F4F4F4",
                       borderRadius: [5, 5, 5, 5],
                       formatter: ["{first|副院长}", "{second|测试}"].join("\n"),
                       rich: {
                         first: {
                           backgroundColor: "#ff9933",
                           fontSize: 15,
                           color: "#fff",
                           align: "center",
                           width: 60,
                           height: 30,
                           borderRadius: [5, 5, 0, 0],
                         },
                         second: {
                           fontSize: 15,
                           color: "#888",
                           align: "center",
                           lineHeight: 25,
                         },
                       },
                     },
                     children: (function () {
                       const a = [];
                       const s = {
                         label: {
                           backgroundColor: "#ff9933",
                           borderRadius: [5, 5, 5, 5],
                           verticalAlign: "middle",
                           align: "center",
                           formatter: [
                             "{first|内}",
                             "{first|四}",
                             "{first|科}",
                             "{first|病}",
                             "{first|房}",
                           ].join("\n"),
                           rich: {
                             first: {
                               width: 21,
                               height: 19,
                               fontSize: 15,
                               color: "#fff",
                               padding: [1, 0, 0, 0],
                             },
                           },
                         },
                       };
   
                       for (let i = 0; i < 20; i++) {
                         a.push(s);
                       }
                       return a;
                     })(),
                   },
                   {
                     name: "控感办",
                     value: "控感办",
                     label: {
                       backgroundColor: "#ff9933",
                       borderRadius: [5, 5, 5, 5],
                       width: 30,
                       height: 90,
                       verticalAlign: "middle",
                       align: "center",
                       formatter: ["{first|控}", "{first|感}", "{first|办}"].join(
                         "\n"
                       ),
                       rich: {
                         first: {
                           fontSize: 17,
                           color: "#fff",
                           padding: [10, 0, 0, 0],
                         },
                       },
                     },
                   },
                   {
                     label: {
                       backgroundColor: "#F4F4F4",
                       borderRadius: [5, 5, 5, 5],
                       formatter: ["{first|副院长}", "{second|测试}"].join("\n"),
                       rich: {
                         first: {
                           backgroundColor: "#ff9933",
                           fontSize: 15,
                           color: "#fff",
                           align: "center",
                           width: 60,
                           height: 30,
                           borderRadius: [5, 5, 0, 0],
                         },
                         second: {
                           fontSize: 15,
                           color: "#888",
                           align: "center",
                           lineHeight: 25,
                         },
                       },
                     },
                     children: (function () {
                       const a = [];
                       const s = {
                         label: {
                           backgroundColor: "#ff9933",
                           borderRadius: [5, 5, 5, 5],
   
                           verticalAlign: "middle",
                           align: "center",
                           formatter: [
                             "{first|内}",
                             "{first|四}",
                             "{first|科}",
                             "{first|病}",
                             "{first|房}",
                           ].join("\n"),
                           rich: {
                             first: {
                               width: 21,
                               height: 19,
                               fontSize: 15,
                               color: "#fff",
                               padding: [1, 0, 0, 0],
                             },
                           },
                         },
                       };
   
                       for (let i = 0; i < 10; i++) {
                         a.push(s);
                       }
                       return a;
                     })(),
                   },
                     {
                     name: "党办",
                     value: "党办",
                     label: {
                       backgroundColor: "#ff9933",
                       borderRadius: [5, 5, 5, 5],
                       // offset: [-20, 0],
                       width: 30,
                       height: 60,
                       verticalAlign: "middle",
                       align: "center",
                       formatter: ["{first|党}", "{first|办}"].join("\n"),
                       rich: {
                         first: {
                           fontSize: 17,
                           color: "#fff",
                           padding: [10, 0, 0, 0],
                         },
                       },
                     },
                   },
                   {
                     name: "工会",
                     value: "工会",
                     label: {
                       backgroundColor: "#ff9933",
                       borderRadius: [5, 5, 5, 5],
                       width: 30,
                       height: 60,
                       verticalAlign: "middle",
                       align: "center",
                       formatter: ["{first|工}", "{first|会}"].join("\n"),
                       rich: {
                         first: {
                           fontSize: 17,
                           color: "#fff",
                           padding: [10, 0, 0, 0],
                         },
                       },
                     },
                   },
                 ],
               },
             ],
           },
         ],
       };
   
   ### Current Behavior
   
   ![image](https://user-images.githubusercontent.com/49714450/177123119-9b350cea-b84f-4259-8a92-b12f055f6d3f.png)
   如图所示,当我第三层数据很多时,第二层没有子树的节点被重叠。
   
   ### Expected Behavior
   
   能够提供节点间的间距设置,或者优化节点间间距计算方法。
   
   ### Environment
   
   ```markdown
   - OS:windows11
   - Browser:edge
   - Framework:vue@2
   ```
   
   
   ### Any additional comments?
   
   _No response_


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


[GitHub] [echarts] echarts-bot[bot] commented on issue #17310: [Bug]

Posted by GitBox <gi...@apache.org>.
echarts-bot[bot] commented on issue #17310:
URL: https://github.com/apache/echarts/issues/17310#issuecomment-1173568880

   I'm sorry to close this issue for it lacks the necessary title. Please provide **a _descriptive_ and as _concise_ as possible title to describe your problems or requests** and then the maintainers or I will reopen this issue.
   
   Every good bug report or feature request starts with a title. Your issue title is a critical element as it's the first thing maintainers see.
   
   A good issue title makes it easier for maintainers to understand what the issue is, easily locate it, and know what steps they'll need to take to fix it.
   
   Moreover, it's better to include keywords, as this makes it easier to find the issue self and similar issues in searches.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


[GitHub] [echarts] echarts-bot[bot] closed issue #17310: [Bug]

Posted by GitBox <gi...@apache.org>.
echarts-bot[bot] closed issue #17310: [Bug] 
URL: https://github.com/apache/echarts/issues/17310


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org