Class: Slideck::MetadataWrapper Private
- Inherits:
-
Object
- Object
- Slideck::MetadataWrapper
- Defined in:
- lib/slideck/metadata_wrapper.rb
Overview
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Responsible for wrapping parsed global and slide metadata
Instance Method Summary collapse
-
#initialize(metadata, metadata_converter, metadata_defaults) ⇒ MetadataWrapper
constructor
Create a MetadataWrapper instance.
-
#wrap(deck) ⇒ Array<Slideck::Metadata, Hash>
Wrap parsed global and slide metadata.
Constructor Details
#initialize(metadata, metadata_converter, metadata_defaults) ⇒ MetadataWrapper
Create a MetadataWrapper instance
21 22 23 24 25 |
# File 'lib/slideck/metadata_wrapper.rb', line 21 def initialize(, , ) @metadata = @metadata_converter = @metadata_defaults = end |
Instance Method Details
#wrap(deck) ⇒ Array<Slideck::Metadata, Hash>
Wrap parsed global and slide metadata
38 39 40 41 42 43 44 45 46 47 48 |
# File 'lib/slideck/metadata_wrapper.rb', line 38 def wrap(deck) [ (deck[:metadata], @metadata_defaults), deck[:slides].map do || { content: [:content], metadata: ([:metadata], {}) } end ] end |