src/Types/HEX.php
private function sanitize($value)
    {
        $value = (string) $value;
        $value = ltrim($value, '#');
        $value = strtoupper($value);

        if (strlen($value) === 3) {
            $value = $value[0] . $value[0] . $value[1] . $value[1] . $value[2] . $value[2];
        }

        return $value;
    }
private function sanitize($value)
    {
        $value = (string) $value;
        $value = ltrim($value, '#');
        $value = strtoupper($value);

        if (strlen($value) === 3) {
            $value = $value[0] . $value[0] . $value[1] . $value[1] . $value[2] . $value[2];
        }

        return $value;
    }
@param string $value

@return string