2008-10-12 22:03:06 -04:00
|
|
|
require 'sass/script/literal'
|
2008-08-09 00:17:58 -04:00
|
|
|
|
2008-10-12 22:03:06 -04:00
|
|
|
module Sass::Script
|
2009-04-24 22:36:14 -04:00
|
|
|
# A SassScript object representing a boolean (true or false) value.
|
|
|
|
class Bool < Literal
|
|
|
|
# The Ruby value of the boolean.
|
|
|
|
#
|
|
|
|
# @return [Boolean]
|
|
|
|
attr_reader :value
|
|
|
|
alias_method :to_bool, :value
|
|
|
|
|
|
|
|
# @return [String] "true" or "false"
|
2010-04-03 17:43:12 -04:00
|
|
|
def to_s(opts = {})
|
2008-08-09 00:17:58 -04:00
|
|
|
@value.to_s
|
|
|
|
end
|
2010-02-16 19:22:03 -05:00
|
|
|
alias_method :to_sass, :to_s
|
2008-08-09 00:17:58 -04:00
|
|
|
end
|
|
|
|
end
|