Android 10's system-wide dark theme was one of the most highly anticipated features, allowing users to make apps completely dark or black with a single toggle. However, the big issue with this feature is that it is only supported on Android 10, and while certain apps do include a manual toggle for switching dark mode on and off independently of the system value, most don't. Gmail supports dark mode, but only Android 10 users can see the toggle. That is unless you have Xposed.

Xposed Framework XDA Forums

This Xposed module, called Gmail Dark Theme Enabler, only does one thing: it makes the theme toggle visible whether you have Android 10 or not. It should work just fine on Android Pie and lower, again, as long as you have Xposed or EdXposed installed. If you're not familiar with EdXposed, it is an unofficial version of the Xposed Framework that works with newer Android versions and phones, and you can refer to this post for more information on it.

You can download this module from the Xposed Repository right now. Check it out!

Download Gmail Dark Theme Enabler!