From addf9d44668dbba62b2d4065d1cd6a60f6af94d5 Mon Sep 17 00:00:00 2001 From: sergio Date: Wed, 31 May 2023 15:31:33 -0700 Subject: [PATCH] add transparent parameter --- datawrapper/__main__.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/datawrapper/__main__.py b/datawrapper/__main__.py index 051c193..1a97835 100644 --- a/datawrapper/__main__.py +++ b/datawrapper/__main__.py @@ -474,6 +474,7 @@ def export_chart( zoom: int = 2, scale: int = 1, border_width: int = 20, + transparent: bool = False, output: str = "png", filepath: str = "./image.png", display: bool = False, @@ -498,6 +499,8 @@ def export_chart( Defines the multiplier for the pdf size, by default 1 border_width : int, optional Margin arouund the visualization, by default 20 + transparent : bool, optional + Set to `True` to export your visualization with a transparent background. output : str, optional One of png, pdf, or svg, by default "png" filepath : str, optional @@ -523,6 +526,7 @@ def export_chart( "zoom": zoom, "scale": scale, "borderWidth": border_width, + "transparent": transparent } _header = self._auth_header