def METHOD_NAME(self, state):
    if state == RegExpValidator.Invalid:
        color = "red"
    elif state == RegExpValidator.Intermediate:
        color = "gold"
    elif state == RegExpValidator.Acceptable:
        color = "lime"
    self.scales_line.setStyleSheet(f"border: 1px solid {color}")
    QTimer.singleShot(500, lambda: self.scales_line.setStyleSheet(""))