Class: Plutonium::UI::Page::Base

Inherits:
Component::Base show all
Defined in:
lib/plutonium/ui/page/base.rb

Direct Known Subclasses

Edit, Index, InteractiveAction, New, Show

Instance Method Summary collapse

Methods included from Component::Behaviour

#around_template

Methods included from Component::Tokens

#classes, #tokens

Methods included from Component::Kit

#BuildActionButton, #BuildBlock, #BuildBreadcrumbs, #BuildColorModeSelector, #BuildDynaFrameContent, #BuildDynaFrameHost, #BuildEmptyCard, #BuildFrameNavigatorPanel, #BuildPageHeader, #BuildPanel, #BuildSkeletonTable, #BuildTabList, #BuildTableInfo, #BuildTablePagination, #BuildTableScopesBar, #BuildTableSearchBar, #method_missing, #respond_to_missing?

Constructor Details

#initialize(page_title: nil, page_description: nil, page_actions: nil) ⇒ Base

Returns a new instance of Base.



7
8
9
10
11
# File 'lib/plutonium/ui/page/base.rb', line 7

def initialize(page_title: nil, page_description: nil, page_actions: nil)
  @page_title = page_title
  @page_description = page_description
  @page_actions = page_actions
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class Plutonium::UI::Component::Kit

Instance Method Details

#view_templateObject



13
14
15
16
17
18
19
20
21
22
23
24
25
# File 'lib/plutonium/ui/page/base.rb', line 13

def view_template(&)
  render_before_header
  render_header
  render_after_header

  render_before_content
  render_content(&)
  render_after_content

  render_before_footer
  render_footer
  render_after_footer
end