Class: Daisy::Feedback::LoadingComponent
- Inherits:
-
LocoMotion::BaseComponent
- Object
- ViewComponent::Base
- LocoMotion::BaseComponent
- Daisy::Feedback::LoadingComponent
- Includes:
- LocoMotion::Concerns::TippableComponent
- Defined in:
- app/components/daisy/feedback/loading_component.rb
Overview
The helper method is also aliased as ‘daisy_loader` for better readability, but CSS classes must still use the `loading-*` prefix.
The LoadingComponent displays an animated indicator to show that a process is running in the background. It supports multiple animation styles and can be customized with different colors and sizes.
Includes the LocoMotion::Concerns::TippableComponent module to enable easy tooltip addition.
Constant Summary
Constants inherited from LocoMotion::BaseComponent
LocoMotion::BaseComponent::EMPTY_PART_IGNORED_TAGS, LocoMotion::BaseComponent::SELF_CLOSING_TAGS
Instance Attribute Summary
Attributes inherited from LocoMotion::BaseComponent
Instance Method Summary collapse
- #before_render ⇒ Object
- #call ⇒ Object
-
#initialize(*args, **kws, &block) ⇒ LoadingComponent
constructor
Creates a new Loading component.
Methods inherited from LocoMotion::BaseComponent
build, #component_ref, #config_option, #cssify, define_modifier, define_modifiers, define_part, define_parts, define_size, define_sizes, #empty_part_content, #inspect, #part, register_component_initializer, register_component_setup, #rendered_css, #rendered_data, #rendered_html, #rendered_stimulus_controllers, #rendered_tag_name, renders_many, renders_one, set_component_name, #set_loco_parent, #strip_spaces
Constructor Details
#initialize(*args, **kws, &block) ⇒ LoadingComponent
Creates a new Loading component.
39 40 41 |
# File 'app/components/daisy/feedback/loading_component.rb', line 39 def initialize(*args, **kws, &block) super end |
Instance Method Details
#before_render ⇒ Object
43 44 45 46 |
# File 'app/components/daisy/feedback/loading_component.rb', line 43 def before_render setup_component super end |
#call ⇒ Object
48 49 50 |
# File 'app/components/daisy/feedback/loading_component.rb', line 48 def call part(:component) end |