2017-10-24 01:01:08 +00:00
|
|
|
# frozen_string_literal: true
|
2011-12-04 13:57:12 +00:00
|
|
|
module SimpleForm
|
|
|
|
module Helpers
|
|
|
|
module Disabled
|
2011-12-10 18:07:28 +00:00
|
|
|
private
|
|
|
|
|
2011-12-04 13:57:12 +00:00
|
|
|
def has_disabled?
|
|
|
|
options[:disabled] == true
|
|
|
|
end
|
|
|
|
|
|
|
|
def disabled_class
|
2011-12-05 09:44:02 +00:00
|
|
|
:disabled if has_disabled?
|
2011-12-04 13:57:12 +00:00
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
2011-12-10 18:07:28 +00:00
|
|
|
end
|