Class: Obp::Access::Renderer::Elements::ProtectedContentNote

Inherits:
Base
  • Object
show all
Defined in:
lib/obp/access/elements/protected_content_note.rb

Overview

OBP replaces paywalled sections with this placeholder ("Only informative sections of standards are publicly available..."). Skip it explicitly: render nothing and halt recursion, so the placeholder text never leaks into the output.

Instance Attribute Summary

Attributes inherited from Base

#document, #metas, #node

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Base

#initialize, #match_node?

Constructor Details

This class inherits a constructor from Obp::Access::Renderer::Elements::Base

Class Method Details

.classesObject



10
11
12
# File 'lib/obp/access/elements/protected_content_note.rb', line 10

def self.classes
  %w[sts-protected-content-note]
end

Instance Method Details

#renderObject

Accepts (and ignores) the render target; the nil return tells the renderer to halt recursion into this subtree.



16
17
18
# File 'lib/obp/access/elements/protected_content_note.rb', line 16

def render(*)
  nil
end