Regex to match a Map from literal value:
Map<...,...>
final mapRegex = RegExp(r"""^(Map)(<(.+?),(.+?)>|)$""");