from typing import Union
from typing import List


def normalize_swc_list(swc_list: Union[str, List[str], None]) -> List[str]:
    """Normalize a list of SWC IDs.

    This method normalizes a list of SWC ID definitions, making SWC-101, swc-101,
    and 101 equivalent.
    :param swc_list: The list of SWC IDs as strings
    :return: The normalized SWC ID list as SWC-XXX
    """
    if not swc_list:
        return []
    if type(swc_list) == str:
        swc_list = swc_list.split(",")
    swc_list = [str(x).strip().upper() for x in swc_list]
    swc_list = ["SWC-{}".format(x) if not x.startswith("SWC") else x for x in swc_list]

    return swc_list