Alternatives and repetition
Nested alternatives and optional repeated suffixes.
Scope: Regex syntax and structural exploration only. Match evidence requires an external engine.
Preview
Source
regex-alternatives.puml
text/plain
@startregex
title Colour tags
(?:red|green|blue)(?:-(?:light|dark))?(?:,[a-z]+)*
@endregex