Reference documentation and code samples for the Google Chat V1 API class Google::Apps::Card::V1::Icon.
An icon displayed in a widget on a card. For an example in Google Chat apps, see Add an icon .
Inherits
- Object
Extended By
- Google::Protobuf::MessageExts::ClassMethods
Includes
- Google::Protobuf::MessageExts
Methods
#alt_text
def
alt_text
()
-
>
::
String
- (::String) — Optional. A description of the icon used for accessibility.
If unspecified, the default value
Button
is provided. As a best practice, you should set a helpful description for what the icon displays, and if applicable, what it does. For example,A user's account portrait
, orOpens a new browser tab and navigates to the Google Chat developer documentation at https://developers.google.com/workspace/chat
.If the icon is set in a
Button
, thealtText
appears as helper text when the user hovers over the button. However, if the button also setstext
, the icon'saltText
is ignored.
#alt_text=
def
alt_text=
(
value
)
-
>
::
String
- value(::String) — Optional. A description of the icon used for accessibility.
If unspecified, the default value
Button
is provided. As a best practice, you should set a helpful description for what the icon displays, and if applicable, what it does. For example,A user's account portrait
, orOpens a new browser tab and navigates to the Google Chat developer documentation at https://developers.google.com/workspace/chat
.If the icon is set in a
Button
, thealtText
appears as helper text when the user hovers over the button. However, if the button also setstext
, the icon'saltText
is ignored.
- (::String) — Optional. A description of the icon used for accessibility.
If unspecified, the default value
Button
is provided. As a best practice, you should set a helpful description for what the icon displays, and if applicable, what it does. For example,A user's account portrait
, orOpens a new browser tab and navigates to the Google Chat developer documentation at https://developers.google.com/workspace/chat
.If the icon is set in a
Button
, thealtText
appears as helper text when the user hovers over the button. However, if the button also setstext
, the icon'saltText
is ignored.
#icon_url
def
icon_url
()
-
>
::
String
- (::String) — Display a custom icon hosted at an HTTPS URL.
For example:
"iconUrl": "https://developers.google.com/workspace/chat/images/quickstart-app-avatar.png"
Supported file types include
.png
and.jpg
.Note: The following fields are mutually exclusive:
icon_url
,known_icon
,material_icon
. If a field in that set is populated, all other fields in the set will automatically be cleared.
#icon_url=
def
icon_url=
(
value
)
-
>
::
String
- value(::String) — Display a custom icon hosted at an HTTPS URL.
For example:
"iconUrl": "https://developers.google.com/workspace/chat/images/quickstart-app-avatar.png"
Supported file types include
.png
and.jpg
.Note: The following fields are mutually exclusive:
icon_url
,known_icon
,material_icon
. If a field in that set is populated, all other fields in the set will automatically be cleared.
- (::String) — Display a custom icon hosted at an HTTPS URL.
For example:
"iconUrl": "https://developers.google.com/workspace/chat/images/quickstart-app-avatar.png"
Supported file types include
.png
and.jpg
.Note: The following fields are mutually exclusive:
icon_url
,known_icon
,material_icon
. If a field in that set is populated, all other fields in the set will automatically be cleared.
#image_type
def
image_type
()
-
>
::
Google
::
Apps
::
Card
::
V1
::
Widget
::
ImageType
- ( ::Google::Apps::Card::V1::Widget::ImageType
) — The crop style applied to the image. In some cases, applying a
CIRCLE
crop causes the image to be drawn larger than a built-in icon.
#image_type=
def
image_type=
(
value
)
-
>
::
Google
::
Apps
::
Card
::
V1
::
Widget
::
ImageType
- value( ::Google::Apps::Card::V1::Widget::ImageType
) — The crop style applied to the image. In some cases, applying a
CIRCLE
crop causes the image to be drawn larger than a built-in icon.
- ( ::Google::Apps::Card::V1::Widget::ImageType
) — The crop style applied to the image. In some cases, applying a
CIRCLE
crop causes the image to be drawn larger than a built-in icon.
#known_icon
def
known_icon
()
-
>
::
String
- (::String) — Display one of the built-in icons provided by Google Workspace.
For example, to display an airplane icon, specify
AIRPLANE
. For a bus, specifyBUS
.For a full list of supported icons, see built-in icons .
Note: The following fields are mutually exclusive:
known_icon
,icon_url
,material_icon
. If a field in that set is populated, all other fields in the set will automatically be cleared.
#known_icon=
def
known_icon=
(
value
)
-
>
::
String
- value(::String) — Display one of the built-in icons provided by Google Workspace.
For example, to display an airplane icon, specify
AIRPLANE
. For a bus, specifyBUS
.For a full list of supported icons, see built-in icons .
Note: The following fields are mutually exclusive:
known_icon
,icon_url
,material_icon
. If a field in that set is populated, all other fields in the set will automatically be cleared.
- (::String) — Display one of the built-in icons provided by Google Workspace.
For example, to display an airplane icon, specify
AIRPLANE
. For a bus, specifyBUS
.For a full list of supported icons, see built-in icons .
Note: The following fields are mutually exclusive:
known_icon
,icon_url
,material_icon
. If a field in that set is populated, all other fields in the set will automatically be cleared.
#material_icon
def
material_icon
()
-
>
::
Google
::
Apps
::
Card
::
V1
::
MaterialIcon
- ( ::Google::Apps::Card::V1::MaterialIcon
) — Display one of the Google Material
Icons
.
For example, to display a checkbox icon , use
"material_icon": { "name": "check_box" }
Note: The following fields are mutually exclusive:
material_icon
,known_icon
,icon_url
. If a field in that set is populated, all other fields in the set will automatically be cleared.
#material_icon=
def
material_icon=
(
value
)
-
>
::
Google
::
Apps
::
Card
::
V1
::
MaterialIcon
- value( ::Google::Apps::Card::V1::MaterialIcon
) — Display one of the Google Material
Icons
.
For example, to display a checkbox icon , use
"material_icon": { "name": "check_box" }
Note: The following fields are mutually exclusive:
material_icon
,known_icon
,icon_url
. If a field in that set is populated, all other fields in the set will automatically be cleared.
- ( ::Google::Apps::Card::V1::MaterialIcon
) — Display one of the Google Material
Icons
.
For example, to display a checkbox icon , use
"material_icon": { "name": "check_box" }
Note: The following fields are mutually exclusive:
material_icon
,known_icon
,icon_url
. If a field in that set is populated, all other fields in the set will automatically be cleared.