Class: BlockKit::Surfaces::Modal
- Defined in:
- lib/block_kit/surfaces/modal.rb
Constant Summary collapse
- MAX_TITLE_LENGTH =
24- MAX_BUTTON_LENGTH =
24- SUPPORTED_ELEMENTS =
[ Elements::Button, Elements::ChannelsSelect, Elements::Checkboxes, Elements::ConversationsSelect, Elements::DatePicker, Elements::DatetimePicker, Elements::EmailTextInput, Elements::ExternalSelect, Elements::FileInput, Elements::Image, Elements::MultiChannelsSelect, Elements::MultiConversationsSelect, Elements::MultiExternalSelect, Elements::MultiStaticSelect, Elements::MultiUsersSelect, Elements::NumberInput, Elements::Overflow, Elements::PlainTextInput, Elements::RadioButtons, Elements::RichTextInput, Elements::StaticSelect, Elements::TimePicker, Elements::URLTextInput, Elements::UsersSelect ].freeze
Constants inherited from Base
Base::MAX_BLOCKS, Base::SUPPORTED_BLOCKS
Instance Method Summary collapse
Methods inherited from Base
#append, #image, inherited, #initialize
Methods inherited from Base
#==, fix, #fix_validation_errors, #fix_validation_errors!, fixes, inherited, #initialize, inspect, #inspect, #pretty_print, #to_json
Constructor Details
This class inherits a constructor from BlockKit::Surfaces::Base
Instance Method Details
#as_json ⇒ Object
57 58 59 60 61 62 63 64 65 66 |
# File 'lib/block_kit/surfaces/modal.rb', line 57 def as_json(*) super.merge( title: title&.as_json, close: close&.as_json, submit: submit&.as_json, clear_on_close: clear_on_close, notify_on_close: notify_on_close, submit_disabled: submit_disabled ).compact end |