Each time i use phx.gen I end up adding dark mode to it.
I’m offering to add this to the default phx gen templates.
This would
- use tailwind
- add new tailwind customization into tailwind.config.js? or wherever you prefer.
- update core_components and each template
- put a toggle affordance in the nav
- default to local preference
- set toggle state in browser session, overriding preference
- leave the main phx home page alone
- happy to also pick up any existing template bugs since i’m in there already - e.g. index page table row hover bg color right column inconsistent height.
I hope you:
- find this proposal considerate!
- …clear
- …worth considering - dark mode feels like a nice default thing to add.
I’ve seen dark mode “how do i” threads in this forum but do not see a proposal to implement. I think LLM agents make this pretty cheap - that’s how i do it each time i start a new project and this feels like it would be similar to one of my one offs but just more extensive and more carefully tested.
I’m open to working with others but happy to just do this myself.