sass

Sass problem: >sass --watch style.scss:style.css invalid option: --watch

When I run: sass --watch style.scss:style.css gives me invalid option: --watch why? this is good: sass -v gives me: Haml/Sass 2.2.24 (Powerful Penny) ...

Rails3 and Sass::Plugin::options

When I try to add "Sass::Plugin.options[:style] = :compact" to environment.rb I get "uninitialized constant Sass (NameError)" when I try to start up my server. I have added "gem 'haml', '3.0.0'" to my Gemfile. Anybody ran into this? ...

Displaying large forms on the iPhone

I'm currently in the process of toying with a few things at the same time: Heroku, Sinatra, HAML/SASS, and of course the glue: Ruby. I'm loving that, and it all goes well with DataMapper. However, my current "project to learn by" seems to be pretty data-intensive. Though it is also something I want to have. I've been a bit of an amat...

What is the correct usage of blueprint-typography-body([$font-size])?

Recent convert to RoR and I've been using Compass w/ Blueprint to dip into the proverbial pool. Compass has been fantastic, but I've come across something strange within the Typography library. The blueprint-typography-body mixin contains the following: =blueprint-typography-body($font-size: $blueprint-font-size) line-height: 1.5 +...

Store CSS font-size/line-height in Sass variable

Is there a way to store the font-size/line-height in a Sass variable like this: $font-normal: 14px/21px; Using this declaration I get a division as described in the documentation. Is there a way to avoid the division? Note: I use the scss syntax. ...

nested columns in compass/sass

I've been studying compass and while it is a fun thing to play with and use, one thing bothers me(besides being unable to add padding as it wrecks the grid), how do I nest columns? I want to be able to do what blueprint does: nest containers like say, I have a 24-column page divided in two(17 and 7 columns). In the right part of that pa...

rails + compass: advantages vs using haml + blueprint directly

I've got some experience using haml (+sass) on rails projects. I recently started using them with blueprintcss - the only thing I did was transform blueprint.css into a sass file, and started coding from there. I even have a rails generator that includes all this by default. It seems that Compass does what I do, and other things. I'm tr...

Sass mixin not compiling?

I have previously made a mixin in sass 2.2.22 for my font sizes(it's a font converter), like so: =6.5pts :font :size 9px It has been working ever since i first made it a year ago. We just upgraded to haml/sass 3 and now whenever I try to refresh the page im working on, a sass compile error appears like so: http://grab.by/4yFE ...

using the :sass filter with :css

We are currently making a widget that requires some default declared styles along with it(widget html is included by javasacript, along with the default css in style tags) but the problem is i can't "chain" haml filters. What I'm trying to do is to add an internal stylesheet along with the widget like so: <style type="text/css"> p {c...

How to specify custom Sass directory with sinatra

Instead of serving my Sass files from the default 'views' directory I'd like to change this to /assets/sass The following attempts are in my main ruby root file in the app: Attempt 1 set :sass, Proc.new { File.join(root, "assets/sass") } get '/stylesheet.css' do sass :core end With this I get the following error: myapp.rb:17 ...

Reopen SASS Mixins

Hi, Is there a way to redefine SASS mixins. I want to override SASS mixins for site specific styling needs. Is there a way to do it ? ...

accessing Ruby variable(from model or controller) in SASS

Is there a way to access Ruby variables in SASS or do I have to make a custom function for it? What I'm trying to do is to generate a stylesheet for each user so in the controller, I do something like: def show respond_to do |format| format.css{render :partial => "styles"} end end then in the view name _styles.haml I do this...

Can Ruby on Rails cache a Controller "as long as code is not changed"?

At work, we have a situation where when script/server is run, then all the controller code is cached. This is to speed up the development server. But that will mean that whenever we change the controller code, we need to restart the server. So we can turn off the caching of controller code all together. But can't there be mechanis...

Why was the SASS deprecated in favour of SCSS?

Basically, why SCSS, instead of SASS? The shorthand of SASS was the main reason why I picked up SASS, I recently came back to it and realised that it is no longer in favour. Any reasons why? ...

How to watch for changes to HAML files and save them

Hi I want to run HAML command every time i save a particular file I now this can be done by compass but only for sass not HAML has anyone done this or guide me how to. Thanks in advance ...

Using sass, how do you style "#div1 img, #div2 img { height: 80px }" ?

Using sass, how do you style #box1 img, #anotherbox img { height: 80px } ? Is using mixins the only way? ...

In CSS, does it make sense or is it legal to nest an id in another id -- such as "#main #display img { ... }"

In CSS, if it is #main #display img { height: 80px } that means all images within an element with id display that is within another element with id main. But does it make sense or is it legal since id seems to be just global names. It is because SASS actually allows nesting and some code may nest it like #main width: 700px #di...

In HAML on Ruby on Rails, how to use the :sass filter?

If using HAML on Ruby on Rails, then :sass #someDiv border: 3px dashed orange won't have any <style> tag around them. and then :css :sass #someDiv border: 3px dashed orange won't kick on the :sass filter, but :css :sass #someDiv border: 3px dashed orange will kick on the :sass filter, but it is outside o...

Auto update CSS from SASS/SCSS in Rails?

Maybe I'm confused on how SASS/SCSS works within Rails (2.3.8.) but I was under the impression that if I included the option Sass::Plugin.options[:always_update] = true that whenever I changed my SCSS file and then hit the page (controller) again, the SCSS would recompile. I can't seem to get this to work, and can't seem to find a go...

In CSS, can "#footer #caption" coexist with "#content #caption"?

I was going to "nest" the CSS ids like this #content #caption { color: teal } ... #footer #caption { margin: 2em 1em } because that's the way SASS (a CSS generator) can do nesting for... but then in one HTML document, we cannot have two ids with the same name, isn't that true, so the above nesting won't work or won't work well. (e...