Class: Precious::Views::Edit
- Includes:
- Editable
- Defined in:
- lib/gollum/frontend/views/edit.rb
Instance Attribute Summary collapse
-
#content ⇒ Object
readonly
Returns the value of attribute content.
-
#page ⇒ Object
readonly
Returns the value of attribute page.
Attributes inherited from Layout
Instance Method Summary collapse
- #footer ⇒ Object
- #format ⇒ Object
- #is_create_page ⇒ Object
- #is_edit_page ⇒ Object
- #page_name ⇒ Object
- #sidebar ⇒ Object
- #title ⇒ Object
Methods included from Editable
Methods inherited from Layout
Instance Attribute Details
#content ⇒ Object (readonly)
Returns the value of attribute content.
6 7 8 |
# File 'lib/gollum/frontend/views/edit.rb', line 6 def content @content end |
#page ⇒ Object (readonly)
Returns the value of attribute page.
6 7 8 |
# File 'lib/gollum/frontend/views/edit.rb', line 6 def page @page end |
Instance Method Details
#footer ⇒ Object
16 17 18 19 20 21 22 23 24 25 |
# File 'lib/gollum/frontend/views/edit.rb', line 16 def if @footer.nil? if page = @page. @footer = page.raw_data else @footer = false end end @footer end |
#format ⇒ Object
46 47 48 49 |
# File 'lib/gollum/frontend/views/edit.rb', line 46 def format @format = (@page.format || false) if @format.nil? @format.to_s.downcase end |
#is_create_page ⇒ Object
38 39 40 |
# File 'lib/gollum/frontend/views/edit.rb', line 38 def is_create_page false end |
#is_edit_page ⇒ Object
42 43 44 |
# File 'lib/gollum/frontend/views/edit.rb', line 42 def is_edit_page true end |
#page_name ⇒ Object
12 13 14 |
# File 'lib/gollum/frontend/views/edit.rb', line 12 def page_name @name.gsub('-', ' ') end |
#sidebar ⇒ Object
27 28 29 30 31 32 33 34 35 36 |
# File 'lib/gollum/frontend/views/edit.rb', line 27 def if @sidebar.nil? if page = @page. @sidebar = page.raw_data else @sidebar = false end end @sidebar end |
#title ⇒ Object
8 9 10 |
# File 'lib/gollum/frontend/views/edit.rb', line 8 def title "#{@page.title}" end |