app/presenters/hyrax/iiif_manifest_presenter.rb
##
# IIIF metadata for inclusion in the manifest
#  Called by the `iiif_manifest` gem to add metadata
#
# @todo should this use the simple_form i18n keys?! maybe the manifest
#   needs its own?
#
# @return [Array<Hash{String => String}>] array of metadata hashes
IIIF metadata for inclusion in the manifest
Called by the `iiif_manifest` gem to add metadata
IIIF metadata for inclusion in the manifest Called by the ` iiif_manifest ` gem to add metadata
def manifest_metadata
      metadata = []
      metadata_fields.each_with_object(metadata) do |field_name|
        unless get_metadata_value(field_name).blank?
          metadata << {
              'label' => I18n.t("simple_form.labels.defaults.#{field_name}"),
              'value' => Array(self[field_name]).map { |value| scrub(value.to_s) }
          }
        end
      end
      metadata
    end
def manifest_metadata metadata = [ ] metadata_fields . each_with_object ( metadata ) do | field_name | unless get_metadata_value ( field_name ) . blank? metadata << { 'label' => I18n . t ( "simple_form.labels.defaults.#{field_name}" ) , 'value' => Array ( self [ field_name ] ) . map { | value | scrub ( value . to_s ) } } end end metadata end
IIIF metadata for inclusion in the manifest
Called by the `iiif_manifest` gem to add metadata
IIIF metadata for inclusion in the manifest Called by the ` iiif_manifest ` gem to add metadata
array of metadata hashes
array of metadata hashes
Array<Hash{String => String}>
todo
None