ダーク(またはライト)モードに特定のbodyクラスを追加する方法は?

Would you mind explaining why you need specific classes added to the body for dark or light mode?

Does this core feature not allow what you are needing?