Sha256: 43a2f3ee16b3bbb8145d3a315beb06de7ba8583f3e60d13f8cae519c27a56f48

Contents?: true

Size: 324 Bytes

Versions: 19

Compression:

Stored size: 324 Bytes

Contents

module Lookbook
  # Set of helpers for preview layouts
  #
  # @api public
  module PreviewHelper
    def lookbook_display(key, fallback = nil)
      params.dig(:lookbook, :display, key.to_sym) || fallback
    end

    def lookbook_data(key, fallback = nil)
      Lookbook.data.fetch(key.to_sym, fallback)
    end
  end
end

Version data entries

19 entries across 19 versions & 1 rubygems

Version Path
lookbook-2.3.4 lib/lookbook/helpers/preview_helper.rb
lookbook-2.3.3 lib/lookbook/helpers/preview_helper.rb
lookbook-2.3.2 lib/lookbook/helpers/preview_helper.rb
lookbook-2.3.0 lib/lookbook/helpers/preview_helper.rb
lookbook-2.2.2 lib/lookbook/helpers/preview_helper.rb
lookbook-2.2.1 lib/lookbook/helpers/preview_helper.rb
lookbook-2.2.0 lib/lookbook/helpers/preview_helper.rb
lookbook-2.1.1 lib/lookbook/helpers/preview_helper.rb
lookbook-2.1.0 lib/lookbook/helpers/preview_helper.rb
lookbook-2.0.5 lib/lookbook/helpers/preview_helper.rb
lookbook-2.0.4 lib/lookbook/helpers/preview_helper.rb
lookbook-2.0.3 lib/lookbook/helpers/preview_helper.rb
lookbook-2.0.2 lib/lookbook/helpers/preview_helper.rb
lookbook-2.0.1 lib/lookbook/helpers/preview_helper.rb
lookbook-2.0.0 lib/lookbook/helpers/preview_helper.rb
lookbook-2.0.0.rc.3 lib/lookbook/helpers/preview_helper.rb
lookbook-2.0.0.rc.2 lib/lookbook/helpers/preview_helper.rb
lookbook-2.0.0.beta.1 lib/lookbook/helpers/preview_helper.rb
lookbook-2.0.0.beta.0 lib/lookbook/helpers/preview_helper.rb