| 740 | self.array_ok = array_ok |
| 741 | |
| 742 | def description(self): |
| 743 | desc = """\ |
| 744 | The '{plotly_name}' property is a number and may be specified as:""".format( |
| 745 | plotly_name=self.plotly_name |
| 746 | ) |
| 747 | |
| 748 | if not self.has_min_max: |
| 749 | desc = ( |
| 750 | desc |
| 751 | + """ |
| 752 | - An int or float""" |
| 753 | ) |
| 754 | |
| 755 | else: |
| 756 | desc = ( |
| 757 | desc |
| 758 | + """ |
| 759 | - An int or float in the interval [{min_val}, {max_val}]""".format( |
| 760 | min_val=self.min_val, max_val=self.max_val |
| 761 | ) |
| 762 | ) |
| 763 | |
| 764 | if self.array_ok: |
| 765 | desc = ( |
| 766 | desc |
| 767 | + """ |
| 768 | - A tuple, list, or one-dimensional numpy array of the above""" |
| 769 | ) |
| 770 | |
| 771 | return desc |
| 772 | |
| 773 | def validate_coerce(self, v): |
| 774 | if is_none_or_typed_array_spec(v): |