import re


def parse_article(content):
    """Finds all article links with an icon indicating assessed quality in a Wikipedia page.
    Matches listings structured like:
    1. {{icon|FA}} {{Icon|FGA}} [[Article title]]
     or
    * {{icon|Start}} [[Article title|Displayed article title]]

    :param content: The content to be parsed
    :return: List of dicts of style: {title: "article_title", assessment: "Stub|C|B|A|etc.", history: None|"FFA|FGA"}
    """
    article_listing_regex = re.compile(r'''
        [*#]\s*                                         # line starts with a bullet or a number
        (?P<assessment>\{\{[Ii]con\|\w+\}\})            # assessment should always be first
        (?P<history>\s*\{\{[Ii]con\|\w+\}\})*           # option of multiple icons for FFA, or DGA
        \s*
        \'*\[\[(?P<title>[^#<>\[\]]+)\]\]               # actual title is a wikilink
    ''', re.VERBOSE)
    results = []
    for l in article_listing_regex.finditer(content):
        article = {
            "title": l.group("title").split("|")[0],
            "assessment": l.group("assessment").split("|")[-1][:-2],
            "history": None,
        }
        if l.group("history"):
            article["history"] = l.group("history").split("|")[-1][:-2]
        results.append(article)
    return results