Sass

Here is how the imports work in the _sass directory. The diagram should be read like a depth-first traversal of the tree. So you start at custom/custom.scss, then just-the-class/just-the-class.scss and all of its children are imported, then berkeley/berkeley.scss and so on with custom/course_overrides.scss imported last.

Flowchart showing the Sass compilation process from custom/custom.scss

Downstream files like custom/course_overrides.scss overwrite any conflicting selectors or variables previously defined in custom/custom.scss or other upstream files. For this reason, courses should primarily make changes to custom/course_overrides.scss to ensure that their changes propogate. The exception is if a class wants to change particular just-the-class files like just-the-class.module.scss for their course’s custom needs.

Some of the files shown above in turn import other files. These imports are shown below.

Flowchart: Custom setup logic
Flowchart: Dark mode logic
Flowchart: Light mode logic

Back to Top

Accessibility Nondiscrimination

Copyright ©2026, Regents of the University of California and respective authors.

This site is built following the Berkeley Class Site template, which is generously based on the Just the Class, and Just the Docs templates.