Class: Google::Apis::ChatV1::GoogleAppsCardV1Section

Inherits:
Object
  • Object
show all
Includes:
Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
Defined in:
lib/google/apis/chat_v1/classes.rb,
lib/google/apis/chat_v1/representations.rb,
lib/google/apis/chat_v1/representations.rb

Overview

A section contains a collection of widgets that are rendered vertically in the order that they are specified.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleAppsCardV1Section

Returns a new instance of GoogleAppsCardV1Section.



1983
1984
1985
# File 'lib/google/apis/chat_v1/classes.rb', line 1983

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#collapsibleBoolean Also known as: collapsible?

Indicates whether this section is collapsible. Collapsible sections hide some or all widgets, but users can expand the section to reveal the hidden widgets by clicking Show more. Users can hide the widgets again by clicking Show less. To determine which widgets are hidden, specify uncollapsibleWidgetsCount. Corresponds to the JSON property collapsible

Returns:

  • (Boolean)


1958
1959
1960
# File 'lib/google/apis/chat_v1/classes.rb', line 1958

def collapsible
  @collapsible
end

#headerString

Text that appears at the top of a section. Supports simple HTML formatted text. Corresponds to the JSON property header

Returns:

  • (String)


1966
1967
1968
# File 'lib/google/apis/chat_v1/classes.rb', line 1966

def header
  @header
end

#uncollapsible_widgets_countFixnum

The number of uncollapsible widgets which remain visible even when a section is collapsed. For example, when a section contains five widgets and the uncollapsibleWidgetsCount is set to 2, the first two widgets are always shown and the last three are collapsed by default. The uncollapsibleWidgetsCount is taken into account only when collapsible is true. Corresponds to the JSON property uncollapsibleWidgetsCount

Returns:

  • (Fixnum)


1976
1977
1978
# File 'lib/google/apis/chat_v1/classes.rb', line 1976

def uncollapsible_widgets_count
  @uncollapsible_widgets_count
end

#widgetsArray<Google::Apis::ChatV1::GoogleAppsCardV1Widget>

All the widgets in the section. Must contain at least 1 widget. Corresponds to the JSON property widgets



1981
1982
1983
# File 'lib/google/apis/chat_v1/classes.rb', line 1981

def widgets
  @widgets
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1988
1989
1990
1991
1992
1993
# File 'lib/google/apis/chat_v1/classes.rb', line 1988

def update!(**args)
  @collapsible = args[:collapsible] if args.key?(:collapsible)
  @header = args[:header] if args.key?(:header)
  @uncollapsible_widgets_count = args[:uncollapsible_widgets_count] if args.key?(:uncollapsible_widgets_count)
  @widgets = args[:widgets] if args.key?(:widgets)
end