【发布时间】:2013-12-13 20:37:37
【问题描述】:
在由 ActiveAdmin 生成到 app/assets/stylesheets 的 https://github.com/gregbell/active_admin/blob/master/lib/generators/active_admin/assets/templates/active_admin.css.scss 中,我可以看到 $sidebar-width: 242px; 的变化并且它会做出反应,但是如果我尝试从 https://github.com/gregbell/active_admin/blob/master/app/assets/stylesheets/active_admin/mixins/_variables.css.scss 添加任何其他变量,它只会忽略这些变量的变化。例如,下面的代码不会使 bg 颜色变黑...
// SASS variable overrides must be declared before loading up Active Admin's styles.
//
// To view the variables that Active Admin provides, take a look at
// `app/assets/stylesheets/active_admin/mixins/_variables.css.scss` in the
// Active Admin source.
//
// For example, to change the sidebar width:
$sidebar-width: 500px; // works
$body-background-color: #000; // doesn't work
我真的不知道该怎么办。提前致谢。
【问题讨论】:
标签: ruby-on-rails sass asset-pipeline activeadmin