Under a Front Range Community College President’s Innovation Grant, I wrote open source textbooks for Calculus 1 and 2, along with my former student Jenna Allen who illustrated them in glorious Asymptote. You can view and download them for free here.
These were built using Overleaf, a shared editing editing platform for LaTeX. As they are shared under a Creative Commons license, you are welcome to view the source code and even copy the entire project for your own editing and use. Here are links to the projects: Calculus 1 Textbook Overleaf Project and Calculus 2 Textbook Overleaf Project.
If you like the idea of great quality, free, editable mathematics textbooks, check out some my colleague’s works!