Sha256: 19afdd833054759676c137fe615c44c9a826d740d6dc76877bd78b549a93a02f

Contents?: true

Size: 347 Bytes

Versions: 128

Compression:

Stored size: 347 Bytes

Contents

# Adds the ability to set the visibility of an item in the execution context.
module Avo
  module Concerns
    module IsVisible
      attr_accessor :visible

      def visible?
        # Default to true
        return true if visible.nil?

        Avo::ExecutionContext.new(target: visible, resource: @resource).handle
      end
    end
  end
end

Version data entries

128 entries across 128 versions & 1 rubygems

Version Path
avo-3.11.3 lib/avo/concerns/is_visible.rb
avo-3.11.2 lib/avo/concerns/is_visible.rb
avo-3.11.1 lib/avo/concerns/is_visible.rb
avo-3.11.0 lib/avo/concerns/is_visible.rb
avo-3.10.10 lib/avo/concerns/is_visible.rb
avo-3.10.9 lib/avo/concerns/is_visible.rb
avo-3.10.8 lib/avo/concerns/is_visible.rb
avo-3.10.7 lib/avo/concerns/is_visible.rb
avo-3.10.6 lib/avo/concerns/is_visible.rb
avo-3.10.5 lib/avo/concerns/is_visible.rb
avo-3.10.4 lib/avo/concerns/is_visible.rb
avo-3.10.3 lib/avo/concerns/is_visible.rb
avo-3.10.2 lib/avo/concerns/is_visible.rb
avo-3.10.1 lib/avo/concerns/is_visible.rb
avo-3.10.0 lib/avo/concerns/is_visible.rb
avo-3.9.2 lib/avo/concerns/is_visible.rb
avo-3.9.1 lib/avo/concerns/is_visible.rb
avo-3.8.2 lib/avo/concerns/is_visible.rb
avo-3.9.0 lib/avo/concerns/is_visible.rb
avo-3.8.1 lib/avo/concerns/is_visible.rb