It would be nice to support rgba format in CSS linear gradients which is more commonly used than HEXa.
Currently I had to implement this parsing before using this lib:
```
import rgb2hex from "rgb2hex"
const addAlpha = (color: string, opacity: number) => {
const _opacity = Math.floor(opacity * 255)
.toString(16)
.padStart(2, "0")
return color + _opacity
}
const gradientString = "linear-gradient(88.56deg, rgba(159, 130, 255, 1.0) 0%, rgba(246, 136, 208, 1.0) 100%)"
const rgbaRegex = /rgba?\((\d+),\s*(\d+),\s*(\d+)(?:,\s*(\d+(?:\.\d+)?))?\)/g
const rgbaMatches = [...gradientString.matchAll(rgbaRegex)]
rgbaMatches.forEach(match => {
const hexObj = rgb2hex(match[0])
gradientString = gradientString.replace(match[0], addAlpha(hexObj.hex, hexObj.alpha))
})
```