New returns a new HeatMap widget.
(opts ...Option)
| 69 | |
| 70 | // New returns a new HeatMap widget. |
| 71 | func New(opts ...Option) (*HeatMap, error) { |
| 72 | opt := newOptions(opts...) |
| 73 | if err := opt.validate(); err != nil { |
| 74 | return nil, err |
| 75 | } |
| 76 | return &HeatMap{ |
| 77 | opts: opt, |
| 78 | }, nil |
| 79 | } |
| 80 | |
| 81 | // Values sets the values to be displayed by the HeatMap. |
| 82 | // |