What is the right way to color a submolecule defined by \definesubmol
?
MWE
\documentclass[12pt]{article}
\usepackage{float}
\usepackage{chemfig}
\usepackage{chemmacros}
\chemsetup{
modules = all,
}
\begin{document}
\begin{figure}[H]
\centering
\definesubmol{pvc}{CH_2-CH(-[:90]Cl)}
\chemfig{-!{pvc}- \color{green}{!{pvc}} -!{pvc}-}
\end{figure}
\end{document}