lib/csl/style/group.rb in csl-1.0.2 vs lib/csl/style/group.rb in csl-1.1.0

- old
+ new

@@ -11,20 +11,27 @@ # Groups implicitly act as a conditionals: a Group and its child # elements are suppressed if a) at least one rendering element in # the Group calls a variable (either directly or via a macro), and # b) all variables that are called are empty. class Group < Node - attr_struct(*Schema.attr(:formatting, :affixes, :delimiter)) + attr_struct(*Schema.attr(:formatting, :delimiter)) def delimiter attributes.fetch(:delimiter, '') end - private - - def added_child(node) - node.attributes.merge formatting_options + # Returns only those formatting options applicable to the Group + # node itself; not those which are transmitted to the enclosed + # elements. + # + # @return [Hash] the node's formatting options + def formatting_options + attributes_for :display, *Schema.attr(:affixes) end + + def inheritable_formatting_options + attributes_for :'text-case', *Schema.attr(:font) + end end end -end \ No newline at end of file +end