Implement the Create new Label button

This commit is contained in:
Jackson Harper
2022-04-11 11:31:28 -07:00
parent 34d892a9a2
commit 110a503927
3 changed files with 32 additions and 9 deletions

View File

@ -44,3 +44,9 @@ export const labelColorObjects: LabelColorObjects = {
background: '#D8D7D50D',
},
}
export const randomLabelColorHex = () => {
const colorHexes = Object.keys(labelColorObjects).slice(0, -1)
const randomColorHex = colorHexes[Math.floor(Math.random() * colorHexes.length)]
return randomColorHex
}