From e262ec7109c4cbe98ffe9546cdcef1289db75f3a Mon Sep 17 00:00:00 2001 From: JackBarker7 Date: Fri, 1 Jul 2022 11:54:39 +0100 Subject: [PATCH 1/2] added options to Network.add_nodes to match Network.add_node --- pyvis/network.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/pyvis/network.py b/pyvis/network.py index d50c3f4..eaac7ae 100644 --- a/pyvis/network.py +++ b/pyvis/network.py @@ -239,8 +239,9 @@ def add_nodes(self, nodes, **kwargs): :type nodes: list """ - valid_args = ["size", "value", "title", - "x", "y", "label", "color", "shape"] + valid_args = ["label", "borderWidth", "borderWidthSelected", + "brokenImage", "group", "hidden", "image", "labelHighlightBold", + "level", "mass", "physics", "shape", "size", "title", "value", "x", "y"] for k in kwargs: assert k in valid_args, "invalid arg '" + k + "'" From 5bf5cf9b614df7b2f60b748ec3bd9395f8d7cab0 Mon Sep 17 00:00:00 2001 From: Jack Barker Date: Thu, 10 Aug 2023 14:25:50 +0100 Subject: [PATCH 2/2] Update network.py Added "color" parameter as requested --- pyvis/network.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyvis/network.py b/pyvis/network.py index eaac7ae..f88a255 100644 --- a/pyvis/network.py +++ b/pyvis/network.py @@ -239,7 +239,7 @@ def add_nodes(self, nodes, **kwargs): :type nodes: list """ - valid_args = ["label", "borderWidth", "borderWidthSelected", + valid_args = ["label", "color", "borderWidth", "borderWidthSelected", "brokenImage", "group", "hidden", "image", "labelHighlightBold", "level", "mass", "physics", "shape", "size", "title", "value", "x", "y"] for k in kwargs: