from .._constants import ansi_escape

class Color:
    def __init__(self, *attributes):
        self.values = attributes

    def __str__(self):
        return f"{ansi_escape}[{';'.join(str(x) for x in self.values)}m"

    def __repr__(self):
        return f"{ansi_escape}[{';'.join(str(x) for x in self.values)}m"

    def __add__(self, other):
        return str(self) + str(other)

    def apply(self):
        print(str(self), end="")
