Class: OnyxCord::Components::TextInput

Inherits:
Object
  • Object
show all
Defined in:
lib/onyxcord/models/component.rb

Overview

A free-form text input bar in a modal.

Instance Attribute Summary collapse

Instance Attribute Details

#custom_idString (readonly)

Returns the developer-defined identifier for the text input.

Returns:

  • (String)

    the developer-defined identifier for the text input.



245
246
247
# File 'lib/onyxcord/models/component.rb', line 245

def custom_id
  @custom_id
end

#idInteger (readonly)

Returns the numeric identifier of the text input.

Returns:

  • (Integer)

    the numeric identifier of the text input.



235
236
237
# File 'lib/onyxcord/models/component.rb', line 235

def id
  @id
end

#styleSymbol (readonly)

Returns This is deprecated and not accurate. This will be removed in the next major version (4.0.0).

Returns:

  • (Symbol)

    This is deprecated and not accurate. This will be removed in the next major version (4.0.0).



239
240
241
# File 'lib/onyxcord/models/component.rb', line 239

def style
  @style
end

#valueString? (readonly)

Returns the value the user typed into the text input.

Returns:

  • (String, nil)

    the value the user typed into the text input.



242
243
244
# File 'lib/onyxcord/models/component.rb', line 242

def value
  @value
end