class Google::Apis::ChatV1::KeyValue

A UI element contains a key (label) and a value (content). And this element may also contain some actions such as onclick button.

Attributes

bottom_label[RW]

The text of the bottom label. Formatted text supported. Corresponds to the JSON property `bottomLabel` @return [String]

button[RW]

A button. Can be a text button or an image button. Corresponds to the JSON property `button` @return [Google::Apis::ChatV1::Button]

content[RW]

The text of the content. Formatted text supported and always required. Corresponds to the JSON property `content` @return [String]

content_multiline[RW]

If the content should be multiline. Corresponds to the JSON property `contentMultiline` @return [Boolean]

content_multiline?[RW]

If the content should be multiline. Corresponds to the JSON property `contentMultiline` @return [Boolean]

icon[RW]

An enum value that will be replaced by the Chat API with the corresponding icon image. Corresponds to the JSON property `icon` @return [String]

icon_url[RW]

The icon specified by a URL. Corresponds to the JSON property `iconUrl` @return [String]

on_click[RW]

An onclick action (e.g. open a link). Corresponds to the JSON property `onClick` @return [Google::Apis::ChatV1::OnClick]

top_label[RW]

The text of the top label. Formatted text supported. Corresponds to the JSON property `topLabel` @return [String]

Public Class Methods

new(**args) click to toggle source
# File lib/google/apis/chat_v1/classes.rb, line 2242
def initialize(**args)
   update!(**args)
end

Public Instance Methods

update!(**args) click to toggle source

Update properties of this object

# File lib/google/apis/chat_v1/classes.rb, line 2247
def update!(**args)
  @bottom_label = args[:bottom_label] if args.key?(:bottom_label)
  @button = args[:button] if args.key?(:button)
  @content = args[:content] if args.key?(:content)
  @content_multiline = args[:content_multiline] if args.key?(:content_multiline)
  @icon = args[:icon] if args.key?(:icon)
  @icon_url = args[:icon_url] if args.key?(:icon_url)
  @on_click = args[:on_click] if args.key?(:on_click)
  @top_label = args[:top_label] if args.key?(:top_label)
end