@@ -35,19 +35,9 @@ interface FormattedOptions extends FruchtermanLayoutOptions {
3535}
3636
3737/**
38- * Layout with fructherman force model
38+ * <zh/> Fruchterman 力导向布局(GPU 版)
3939 *
40- * @example
41- * // Assign layout options when initialization.
42- * const layout = new FruchtermanLayout({ center: [100, 100] });
43- * const positions = await layout.execute(graph); // { nodes: [], edges: [] }
44- *
45- * // Or use different options later.
46- * const layout = new FruchtermanLayout({ center: [100, 100] });
47- * const positions = await layout.execute(graph, { center: [100, 100] }); // { nodes: [], edges: [] }
48- *
49- * // If you want to assign the positions directly to the nodes, use assign method.
50- * await layout.assign(graph, { center: [100, 100] });
40+ * <en/> Fruchterman force-directed layout(GPU)
5141 */
5242export class FruchtermanLayout implements Layout < FruchtermanLayoutOptions > {
5343 id = 'fruchtermanGPU' ;
@@ -71,7 +61,7 @@ export class FruchtermanLayout implements Layout<FruchtermanLayoutOptions> {
7161 * To directly assign the positions to the nodes.
7262 */
7363 async assign ( graph : Graph , options ?: FruchtermanLayoutOptions ) {
74- await this . genericFruchtermanLayout ( true , graph , options ) ;
64+ await this . genericFruchtermanLayout ( true , graph , options ) ;
7565 }
7666
7767 private async genericFruchtermanLayout (
0 commit comments