Class: BlockKit::Elements::Base
- Defined in:
- lib/block_kit/elements/base.rb
Direct Known Subclasses
BaseButton, Checkboxes, DatePicker, DatetimePicker, EmailTextInput, FileInput, NumberInput, Overflow, PlainTextInput, RadioButtons, RichTextInput, Select, TimePicker, URLTextInput
Constant Summary collapse
- MAX_ACTION_ID_LENGTH =
255
Class Method Summary collapse
Instance Method Summary collapse
- #as_json ⇒ Object
-
#initialize(attributes = {}) ⇒ Base
constructor
A new instance of Base.
Methods inherited from Base
#==, fix, #fix_validation_errors, #fix_validation_errors!, fixes, #inspect, inspect, #pretty_print, #to_json
Constructor Details
Class Method Details
.inherited(subclass) ⇒ Object
12 13 14 |
# File 'lib/block_kit/elements/base.rb', line 12 def self.inherited(subclass) subclass.attribute_fixers = attribute_fixers.deep_dup end |
Instance Method Details
#as_json ⇒ Object
22 23 24 |
# File 'lib/block_kit/elements/base.rb', line 22 def as_json(*) super.merge(action_id: action_id).compact end |