Class: Components::ActorCard
- Inherits:
-
ModelCard
- Object
- ModelCard
- Components::ActorCard
- Defined in:
- app/components/actor_card.rb
Instance Method Summary collapse
- #before_template ⇒ Object
-
#initialize(actor:) ⇒ ActorCard
constructor
A new instance of ActorCard.
- #view_template ⇒ Object
Constructor Details
#initialize(actor:) ⇒ ActorCard
Returns a new instance of ActorCard.
4 5 6 |
# File 'app/components/actor_card.rb', line 4 def initialize(actor:) @actor = actor end |
Instance Method Details
#before_template ⇒ Object
8 9 |
# File 'app/components/actor_card.rb', line 8 def before_template end |
#view_template ⇒ Object
11 12 13 14 15 16 17 18 19 20 21 22 |
# File 'app/components/actor_card.rb', line 11 def view_template div class: "col col-3 mb-4" do div class: "card preview-card" do div(class: "card-header position-absolute w-100 top-0 z-3 bg-body-secondary text-secondary-emphasis opacity-75") do server_indicator @actor, full_address: true end PreviewFrame(object: @actor) div(class: "card-body") { info_row } actions end end end |