Class: Spotlight::EditViewLinksComponent

Inherits:
ViewComponent::Base
  • Object
show all
Defined in:
app/components/spotlight/edit_view_links_component.rb

Overview

Allows component addition to exhibit navbar

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(page:, classes: 'page-links', delete_link: false) ⇒ EditViewLinksComponent

Returns a new instance of EditViewLinksComponent.



8
9
10
11
12
13
14
# File 'app/components/spotlight/edit_view_links_component.rb', line 8

def initialize(page:, classes: 'page-links', delete_link: false)
  super

  @page = page
  @classes = classes
  @delete_link = delete_link
end

Instance Attribute Details

#classesObject (readonly)

Returns the value of attribute classes.



6
7
8
# File 'app/components/spotlight/edit_view_links_component.rb', line 6

def classes
  @classes
end

Returns the value of attribute delete_link.



6
7
8
# File 'app/components/spotlight/edit_view_links_component.rb', line 6

def delete_link
  @delete_link
end

#pageObject (readonly)

Returns the value of attribute page.



6
7
8
# File 'app/components/spotlight/edit_view_links_component.rb', line 6

def page
  @page
end