# Docs' theme is inconsistent with books'

**URL:** <https://internals.rust-lang.org/t/docs-theme-is-inconsistent-with-books/14554>\
**Category:** Style and Formatting\
**Created:** [April 23, 2021, 3:53pm UTC](https://internals.rust-lang.org/t/docs-theme-is-inconsistent-with-books/14554 "2021-04-23T15:53:19Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![TinBryn](https://avatars.discourse-cdn.com/v4/letter/t/8c91f0/32.png) [@TinBryn](https://internals.rust-lang.org/u/TinBryn)\
**Post date:** [April 23, 2021, 3:53pm UTC](https://internals.rust-lang.org/t/docs-theme-is-inconsistent-with-books/14554/1 "2021-04-23T15:53:19Z")

</div>

I will preface this with that I'm a very new member of the Rust community.

I have read most of the learner's book and skimmed several others such as by example, the 'nomicon, the linked lists book and design patterns and noticed a consistent theme and style to them. I've noticed that there is a menu to select between 5 themes in these books, and the generated docs only allow 3 and sadly my favorite theme "rust" isn't among them.

I will also add that I would like to contribute to this community and would be willing to submit the pull request myself if and when I am familiar enough to do so, and would appreciate any guidance given in this area.

The short version, themes "rust" and "coal" are missing from docs

---

<div class="post-metadata">

**Author:** ![mbrubeck](https://sea2.discourse-cdn.com/flex002/user_avatar/internals.rust-lang.org/mbrubeck/32/174_2.png) [@mbrubeck](https://internals.rust-lang.org/u/mbrubeck)\
**Post date:** [April 23, 2021, 4:32pm UTC](https://internals.rust-lang.org/t/docs-theme-is-inconsistent-with-books/14554/2 "2021-04-23T16:32:06Z")

</div>

Welcome!

As an initial pointer, the CSS for the rustdoc themes is [here](https://github.com/rust-lang/rust/tree/master/src/librustdoc/html/static/themes) and the CSS for the mdbook themes is [here](https://github.com/rust-lang/mdBook/tree/master/src/theme), in particular [`variables.css`](https://github.com/rust-lang/mdBook/blob/master/src/theme/css/variables.css).

---

<div class="post-metadata">

**Author:** ![TinBryn](https://avatars.discourse-cdn.com/v4/letter/t/8c91f0/32.png) [@TinBryn](https://internals.rust-lang.org/u/TinBryn)\
**Post date:** [April 24, 2021, 8:20am UTC](https://internals.rust-lang.org/t/docs-theme-is-inconsistent-with-books/14554/3 "2021-04-24T08:20:34Z")

</div>

Thanks for the pointer, I could see 2 possible approaches

1. Add CSS for the missing themes to rustdoc

2. Replicate the book theme switching design into rustdoc

I think I will focus on doing 1. for now, and if any other themes get added it will make sense to unify them.

---

<div class="post-metadata">

**Author:** ![system](https://sea2.discourse-cdn.com/flex002/user_avatar/internals.rust-lang.org/system/32/14092_2.png) [@system](https://internals.rust-lang.org/u/system)\
**Post date:** [July 23, 2021, 8:21am UTC](https://internals.rust-lang.org/t/docs-theme-is-inconsistent-with-books/14554/4 "2021-07-23T08:21:12Z")

</div>

Closed on July 23, 2021, 8:21am UTC

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.
