L i5JUddlmZddlZddlmZmZddlZddlmZm Z edZ edZ ejdZ ejdZejd Zejd Ze eeedZd ed < d dd Zy)) annotationsN)AnyLiteral)import_vl_convertvl_version_for_vl_convert)standard universalinlineolli)vega vega-litea {%- if fullhtml -%} {%- endif %} {%- if not requirejs %} {%- if mode == 'vega-lite' %} {%- endif %} {%- endif %} {%- if fullhtml %} {%- if requirejs %} {%- endif %} {%- endif %}
{%- if fullhtml %} {%- endif %} a
a
a
z#dict[TemplateName, jinja2.Template] TEMPLATESc 8|xsi}|xsi}|jd|}|dvr d} t| | d} t| | d} t| |dk(r| d} t| i} | dk(r*t}t}|j | | d <n| d k(rd }d }|| d <|| d<t j | | }t|dsd|} t| |jdtj|fi|tj|||||||| | d | S)a Embed a Vega/Vega-Lite spec into an HTML page. Parameters ---------- spec : dict a dictionary representing a vega-lite plot spec. mode : string {'vega' | 'vega-lite'} The rendering mode. This value is overridden by embed_options['mode'], if it is present. vega_version : string For html output, the version of vega.js to use. vegalite_version : string For html output, the version of vegalite.js to use. vegaembed_version : string For html output, the version of vegaembed.js to use. base_url : string (optional) The base url from which to load the javascript libraries. output_div : string (optional) The id of the div element where the plot will be shown. embed_options : dict (optional) Dictionary of options to pass to the vega-embed script. Default entry is {'mode': mode}. json_kwds : dict (optional) Dictionary of keywords to pass to json.dumps(). fullhtml : boolean (optional) If True (default) then return a full html page. If False, then return an HTML snippet that can be embedded into an HTML page. requirejs : boolean (optional) If False (default) then load libraries from base_url using