Class: Tramway::FlashComponent
- Inherits:
-
BaseComponent
- Object
- ViewComponent::Base
- BaseComponent
- Tramway::FlashComponent
- Includes:
- ColorsMethods
- Defined in:
- app/components/tramway/flash_component.rb
Overview
Description: A Tramway flash message component for displaying notifications.
Constant Summary
Constants included from ColorsMethods
Constants included from Helpers::ViewsHelper
Helpers::ViewsHelper::FORM_SIZES
Instance Method Summary collapse
Methods included from ColorsMethods
#normalized_type, #resolved_color, #type_color
Methods included from Helpers::ViewsHelper
#tramway_back_button, #tramway_badge, #tramway_button, #tramway_cell, #tramway_chat, #tramway_container, #tramway_flash, #tramway_form_for, #tramway_header, #tramway_main_container, #tramway_row, #tramway_table, #tramway_title
Methods included from Helpers::ComponentHelper
Methods included from Helpers::DecorateHelper
Instance Method Details
#container_classes ⇒ Object
13 14 15 |
# File 'app/components/tramway/flash_component.rb', line 13 def container_classes 'fixed top-4 right-4 z-50 flex w-fit max-w-sm flex-col gap-2 pointer-events-none' end |
#flash_classes ⇒ Object
17 18 19 |
# File 'app/components/tramway/flash_component.rb', line 17 def flash_classes (base_flash_classes + semantic_flash_classes).join(' ') end |
#title_classes ⇒ Object
21 22 23 |
# File 'app/components/tramway/flash_component.rb', line 21 def title_classes 'text-sm font-medium leading-6' end |