Class: HakumiComponents::Table::EllipsisConfig::TooltipConfig
- Inherits:
-
Object
- Object
- HakumiComponents::Table::EllipsisConfig::TooltipConfig
- Extended by:
- T::Sig
- Defined in:
- app/components/hakumi_components/table/ellipsis_config.rb
Constant Summary collapse
- TooltipTitle =
T.type_alias { T.nilable(T.any(String, Proc)) }
Instance Attribute Summary collapse
-
#options ⇒ Object
readonly
Returns the value of attribute options.
-
#title ⇒ Object
readonly
Returns the value of attribute title.
Instance Method Summary collapse
-
#initialize(title:, options:) ⇒ TooltipConfig
constructor
A new instance of TooltipConfig.
- #to_h ⇒ Object
Constructor Details
#initialize(title:, options:) ⇒ TooltipConfig
Returns a new instance of TooltipConfig.
29 30 31 32 |
# File 'app/components/hakumi_components/table/ellipsis_config.rb', line 29 def initialize(title:, options:) @title = T.let(title, TooltipTitle) @options = T.let(, InputHash) end |
Instance Attribute Details
#options ⇒ Object (readonly)
Returns the value of attribute options.
38 39 40 |
# File 'app/components/hakumi_components/table/ellipsis_config.rb', line 38 def @options end |
#title ⇒ Object (readonly)
Returns the value of attribute title.
35 36 37 |
# File 'app/components/hakumi_components/table/ellipsis_config.rb', line 35 def title @title end |
Instance Method Details
#to_h ⇒ Object
41 42 43 |
# File 'app/components/hakumi_components/table/ellipsis_config.rb', line 41 def to_h @options.merge(title: @title).compact end |