@@ -24,6 +24,7 @@ class Bar(_BaseTraceType):
2424 "hoverinfosrc" ,
2525 "hoverlabel" ,
2626 "hovertemplate" ,
27+ "hovertemplatefallback" ,
2728 "hovertemplatesrc" ,
2829 "hovertext" ,
2930 "hovertextsrc" ,
@@ -57,6 +58,7 @@ class Bar(_BaseTraceType):
5758 "textpositionsrc" ,
5859 "textsrc" ,
5960 "texttemplate" ,
61+ "texttemplatefallback" ,
6062 "texttemplatesrc" ,
6163 "type" ,
6264 "uid" ,
@@ -379,16 +381,20 @@ def hovertemplate(self):
379381 d3-time-format's syntax %{variable|d3-time-format}, for example
380382 "Day: %{2019-01-01|%A}". https://github.com/d3/d3-time-
381383 format/tree/v2.2.3#locale_format for details on the date
382- formatting syntax. The variables available in `hovertemplate`
383- are the ones emitted as event data described at this link
384- https://plotly.com/javascript/plotlyjs-events/#event-data.
385- Additionally, every attributes that can be specified per-point
386- (the ones that are `arrayOk: true`) are available. Finally, the
387- template string has access to variables `value` and `label`.
388- Anything contained in tag `<extra>` is displayed in the
389- secondary box, for example `<extra>%{fullData.name}</extra>`.
390- To hide the secondary box completely, use an empty tag
391- `<extra></extra>`.
384+ formatting syntax. Variables that can't be found will be
385+ replaced with the specifier. For example, a template of "data:
386+ %{x}, %{y}" will result in a value of "data: 1, %{y}" if x is 1
387+ and y is missing. Variables with an undefined value will be
388+ replaced with the fallback value. The variables available in
389+ `hovertemplate` are the ones emitted as event data described at
390+ this link https://plotly.com/javascript/plotlyjs-events/#event-
391+ data. Additionally, all attributes that can be specified per-
392+ point (the ones that are `arrayOk: true`) are available.
393+ Finally, the template string has access to variables `value`
394+ and `label`. Anything contained in tag `<extra>` is displayed
395+ in the secondary box, for example
396+ `<extra>%{fullData.name}</extra>`. To hide the secondary box
397+ completely, use an empty tag `<extra></extra>`.
392398
393399 The 'hovertemplate' property is a string and must be specified as:
394400 - A string
@@ -405,6 +411,25 @@ def hovertemplate(self):
405411 def hovertemplate (self , val ):
406412 self ["hovertemplate" ] = val
407413
414+ @property
415+ def hovertemplatefallback (self ):
416+ """
417+ Fallback string that's displayed when a variable referenced in
418+ a template is missing. If the boolean value 'false' is passed
419+ in, the specifier with the missing variable will be displayed.
420+
421+ The 'hovertemplatefallback' property accepts values of any type
422+
423+ Returns
424+ -------
425+ Any
426+ """
427+ return self ["hovertemplatefallback" ]
428+
429+ @hovertemplatefallback .setter
430+ def hovertemplatefallback (self , val ):
431+ self ["hovertemplatefallback" ] = val
432+
408433 @property
409434 def hovertemplatesrc (self ):
410435 """
@@ -1071,7 +1096,7 @@ def textsrc(self, val):
10711096 def texttemplate (self ):
10721097 """
10731098 Template string used for rendering the information text that
1074- appear on points. Note that this will override `textinfo`.
1099+ appears on points. Note that this will override `textinfo`.
10751100 Variables are inserted using %{variable}, for example "y:
10761101 %{y}". Numbers are formatted using d3-format's syntax
10771102 %{variable:d3-format}, for example "Price: %{y:$.2f}".
@@ -1080,10 +1105,14 @@ def texttemplate(self):
10801105 d3-time-format's syntax %{variable|d3-time-format}, for example
10811106 "Day: %{2019-01-01|%A}". https://github.com/d3/d3-time-
10821107 format/tree/v2.2.3#locale_format for details on the date
1083- formatting syntax. Every attributes that can be specified per-
1084- point (the ones that are `arrayOk: true`) are available.
1085- Finally, the template string has access to variables `value`
1086- and `label`.
1108+ formatting syntax. Variables that can't be found will be
1109+ replaced with the specifier. For example, a template of "data:
1110+ %{x}, %{y}" will result in a value of "data: 1, %{y}" if x is 1
1111+ and y is missing. Variables with an undefined value will be
1112+ replaced with the fallback value. All attributes that can be
1113+ specified per-point (the ones that are `arrayOk: true`) are
1114+ available. Finally, the template string has access to variables
1115+ `value` and `label`.
10871116
10881117 The 'texttemplate' property is a string and must be specified as:
10891118 - A string
@@ -1100,6 +1129,25 @@ def texttemplate(self):
11001129 def texttemplate (self , val ):
11011130 self ["texttemplate" ] = val
11021131
1132+ @property
1133+ def texttemplatefallback (self ):
1134+ """
1135+ Fallback string that's displayed when a variable referenced in
1136+ a template is missing. If the boolean value 'false' is passed
1137+ in, the specifier with the missing variable will be displayed.
1138+
1139+ The 'texttemplatefallback' property accepts values of any type
1140+
1141+ Returns
1142+ -------
1143+ Any
1144+ """
1145+ return self ["texttemplatefallback" ]
1146+
1147+ @texttemplatefallback .setter
1148+ def texttemplatefallback (self , val ):
1149+ self ["texttemplatefallback" ] = val
1150+
11031151 @property
11041152 def texttemplatesrc (self ):
11051153 """
@@ -1722,18 +1770,28 @@ def _prop_descriptions(self):
17221770 %{variable|d3-time-format}, for example "Day:
17231771 %{2019-01-01|%A}". https://github.com/d3/d3-time-
17241772 format/tree/v2.2.3#locale_format for details on the
1725- date formatting syntax. The variables available in
1773+ date formatting syntax. Variables that can't be found
1774+ will be replaced with the specifier. For example, a
1775+ template of "data: %{x}, %{y}" will result in a value
1776+ of "data: 1, %{y}" if x is 1 and y is missing.
1777+ Variables with an undefined value will be replaced with
1778+ the fallback value. The variables available in
17261779 `hovertemplate` are the ones emitted as event data
17271780 described at this link
17281781 https://plotly.com/javascript/plotlyjs-events/#event-
1729- data. Additionally, every attributes that can be
1782+ data. Additionally, all attributes that can be
17301783 specified per-point (the ones that are `arrayOk: true`)
17311784 are available. Finally, the template string has access
17321785 to variables `value` and `label`. Anything contained in
17331786 tag `<extra>` is displayed in the secondary box, for
17341787 example `<extra>%{fullData.name}</extra>`. To hide the
17351788 secondary box completely, use an empty tag
17361789 `<extra></extra>`.
1790+ hovertemplatefallback
1791+ Fallback string that's displayed when a variable
1792+ referenced in a template is missing. If the boolean
1793+ value 'false' is passed in, the specifier with the
1794+ missing variable will be displayed.
17371795 hovertemplatesrc
17381796 Sets the source reference on Chart Studio Cloud for
17391797 `hovertemplate`.
@@ -1878,7 +1936,7 @@ def _prop_descriptions(self):
18781936 `text`.
18791937 texttemplate
18801938 Template string used for rendering the information text
1881- that appear on points. Note that this will override
1939+ that appears on points. Note that this will override
18821940 `textinfo`. Variables are inserted using %{variable},
18831941 for example "y: %{y}". Numbers are formatted using
18841942 d3-format's syntax %{variable:d3-format}, for example
@@ -1889,10 +1947,20 @@ def _prop_descriptions(self):
18891947 %{variable|d3-time-format}, for example "Day:
18901948 %{2019-01-01|%A}". https://github.com/d3/d3-time-
18911949 format/tree/v2.2.3#locale_format for details on the
1892- date formatting syntax. Every attributes that can be
1950+ date formatting syntax. Variables that can't be found
1951+ will be replaced with the specifier. For example, a
1952+ template of "data: %{x}, %{y}" will result in a value
1953+ of "data: 1, %{y}" if x is 1 and y is missing.
1954+ Variables with an undefined value will be replaced with
1955+ the fallback value. All attributes that can be
18931956 specified per-point (the ones that are `arrayOk: true`)
18941957 are available. Finally, the template string has access
18951958 to variables `value` and `label`.
1959+ texttemplatefallback
1960+ Fallback string that's displayed when a variable
1961+ referenced in a template is missing. If the boolean
1962+ value 'false' is passed in, the specifier with the
1963+ missing variable will be displayed.
18961964 texttemplatesrc
18971965 Sets the source reference on Chart Studio Cloud for
18981966 `texttemplate`.
@@ -2046,6 +2114,7 @@ def __init__(
20462114 hoverinfosrc = None ,
20472115 hoverlabel = None ,
20482116 hovertemplate = None ,
2117+ hovertemplatefallback = None ,
20492118 hovertemplatesrc = None ,
20502119 hovertext = None ,
20512120 hovertextsrc = None ,
@@ -2079,6 +2148,7 @@ def __init__(
20792148 textpositionsrc = None ,
20802149 textsrc = None ,
20812150 texttemplate = None ,
2151+ texttemplatefallback = None ,
20822152 texttemplatesrc = None ,
20832153 uid = None ,
20842154 uirevision = None ,
@@ -2188,18 +2258,28 @@ def __init__(
21882258 %{variable|d3-time-format}, for example "Day:
21892259 %{2019-01-01|%A}". https://github.com/d3/d3-time-
21902260 format/tree/v2.2.3#locale_format for details on the
2191- date formatting syntax. The variables available in
2261+ date formatting syntax. Variables that can't be found
2262+ will be replaced with the specifier. For example, a
2263+ template of "data: %{x}, %{y}" will result in a value
2264+ of "data: 1, %{y}" if x is 1 and y is missing.
2265+ Variables with an undefined value will be replaced with
2266+ the fallback value. The variables available in
21922267 `hovertemplate` are the ones emitted as event data
21932268 described at this link
21942269 https://plotly.com/javascript/plotlyjs-events/#event-
2195- data. Additionally, every attributes that can be
2270+ data. Additionally, all attributes that can be
21962271 specified per-point (the ones that are `arrayOk: true`)
21972272 are available. Finally, the template string has access
21982273 to variables `value` and `label`. Anything contained in
21992274 tag `<extra>` is displayed in the secondary box, for
22002275 example `<extra>%{fullData.name}</extra>`. To hide the
22012276 secondary box completely, use an empty tag
22022277 `<extra></extra>`.
2278+ hovertemplatefallback
2279+ Fallback string that's displayed when a variable
2280+ referenced in a template is missing. If the boolean
2281+ value 'false' is passed in, the specifier with the
2282+ missing variable will be displayed.
22032283 hovertemplatesrc
22042284 Sets the source reference on Chart Studio Cloud for
22052285 `hovertemplate`.
@@ -2344,7 +2424,7 @@ def __init__(
23442424 `text`.
23452425 texttemplate
23462426 Template string used for rendering the information text
2347- that appear on points. Note that this will override
2427+ that appears on points. Note that this will override
23482428 `textinfo`. Variables are inserted using %{variable},
23492429 for example "y: %{y}". Numbers are formatted using
23502430 d3-format's syntax %{variable:d3-format}, for example
@@ -2355,10 +2435,20 @@ def __init__(
23552435 %{variable|d3-time-format}, for example "Day:
23562436 %{2019-01-01|%A}". https://github.com/d3/d3-time-
23572437 format/tree/v2.2.3#locale_format for details on the
2358- date formatting syntax. Every attributes that can be
2438+ date formatting syntax. Variables that can't be found
2439+ will be replaced with the specifier. For example, a
2440+ template of "data: %{x}, %{y}" will result in a value
2441+ of "data: 1, %{y}" if x is 1 and y is missing.
2442+ Variables with an undefined value will be replaced with
2443+ the fallback value. All attributes that can be
23592444 specified per-point (the ones that are `arrayOk: true`)
23602445 are available. Finally, the template string has access
23612446 to variables `value` and `label`.
2447+ texttemplatefallback
2448+ Fallback string that's displayed when a variable
2449+ referenced in a template is missing. If the boolean
2450+ value 'false' is passed in, the specifier with the
2451+ missing variable will be displayed.
23622452 texttemplatesrc
23632453 Sets the source reference on Chart Studio Cloud for
23642454 `texttemplate`.
@@ -2532,6 +2622,7 @@ def __init__(
25322622 self ._set_property ("hoverinfosrc" , arg , hoverinfosrc )
25332623 self ._set_property ("hoverlabel" , arg , hoverlabel )
25342624 self ._set_property ("hovertemplate" , arg , hovertemplate )
2625+ self ._set_property ("hovertemplatefallback" , arg , hovertemplatefallback )
25352626 self ._set_property ("hovertemplatesrc" , arg , hovertemplatesrc )
25362627 self ._set_property ("hovertext" , arg , hovertext )
25372628 self ._set_property ("hovertextsrc" , arg , hovertextsrc )
@@ -2565,6 +2656,7 @@ def __init__(
25652656 self ._set_property ("textpositionsrc" , arg , textpositionsrc )
25662657 self ._set_property ("textsrc" , arg , textsrc )
25672658 self ._set_property ("texttemplate" , arg , texttemplate )
2659+ self ._set_property ("texttemplatefallback" , arg , texttemplatefallback )
25682660 self ._set_property ("texttemplatesrc" , arg , texttemplatesrc )
25692661 self ._set_property ("uid" , arg , uid )
25702662 self ._set_property ("uirevision" , arg , uirevision )
0 commit comments