Class: Shadcn::Card::Component

Inherits:
ApplicationViewComponent show all
Defined in:
app/components/shadcn/card/component.rb

Overview

Port of registry/new-york-v4/ui/card.tsx

Constant Summary

Constants inherited from ApplicationViewComponent

ApplicationViewComponent::CONTENTS_STYLE, ApplicationViewComponent::VOID_TAGS

Instance Attribute Summary

Attributes inherited from ApplicationViewComponent

#attributes

Instance Method Summary collapse

Methods inherited from ApplicationViewComponent

#css_classes, default_tag, #element_attributes, #initialize, #merged_style, #render_element, #shadcn_t, slot_name, #style_variants, #tag_name

Constructor Details

This class inherits a constructor from Shadcn::ApplicationViewComponent

Instance Method Details

#callObject



19
20
21
# File 'app/components/shadcn/card/component.rb', line 19

def call
  render_element(body: safe_join([ header, card_content, footer, content ].compact))
end