pissang commented on a change in pull request #15510:
URL: https://github.com/apache/echarts/pull/15510#discussion_r700696021



##########
File path: src/label/labelLayoutHelper.ts
##########
@@ -362,4 +372,318 @@ export function hideOverlap(labelList: LabelLayoutInfo[]) 
{
             displayedLabels.push(labelItem);
         }
     }
+}
+
+/**
+ * remove label overlaps
+ */
+export function removeOverlap(

Review comment:
       This method can be moved out to an individual file and named with a 
specific algorithm.

##########
File path: src/util/types.ts
##########
@@ -1198,6 +1198,11 @@ export interface LabelLayoutOption {
      * @default 'none'
      */
     hideOverlap?: boolean
+    /**
+     * If labels overlap. It will Remove overlaps;
+     * @default 'none'
+     */
+    removeOverlap?: boolean

Review comment:
       `moveOverlap` is used for different label layout algorithms. Perhaps we 
can add a value to it to represent this default layout algorithm.
   ```ts
   // Apply default layout algorithm. Which will be this one I think.
   moveOverlap: true
   // Or name of this specific layout algorithm.
   moverOverlap: 'xxx'
   ```




-- 
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-unsubscr...@echarts.apache.org

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



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

Reply via email to