()
| 51 | } |
| 52 | |
| 53 | func (l Label) Validate() error { |
| 54 | str := string(l) |
| 55 | |
| 56 | if text.Empty(str) { |
| 57 | return fmt.Errorf("empty") |
| 58 | } |
| 59 | |
| 60 | if !text.SafeOneLine(str) { |
| 61 | return fmt.Errorf("label has unsafe characters") |
| 62 | } |
| 63 | |
| 64 | return nil |
| 65 | } |
| 66 | |
| 67 | type LabelColor color.RGBA |
| 68 |
nothing calls this directly
no test coverage detected