View Source GoogleApi.Chat.V1.Model.GoogleAppsCardV1SwitchControl (google_api_chat v0.34.3)

Either a toggle-style switch or a checkbox inside a decoratedText widget. Google Workspace Add-ons and Chat apps: Only supported in the decoratedText widget.

Attributes

  • controlType (type: String.t, default: nil) - How the switch appears in the user interface. Google Workspace Add-ons and Chat apps:
  • name (type: String.t, default: nil) - The name by which the switch widget is identified in a form input event. For details about working with form inputs, see Receive form data.
  • onChangeAction (type: GoogleApi.Chat.V1.Model.GoogleAppsCardV1Action.t, default: nil) - The action to perform when the switch state is changed, such as what function to run.
  • selected (type: boolean(), default: nil) - When true, the switch is selected.
  • value (type: String.t, default: nil) - The value entered by a user, returned as part of a form input event. For details about working with form inputs, see Receive form data.

Summary

Functions

Unwrap a decoded JSON object into its complex fields.

Types

@type t() :: %GoogleApi.Chat.V1.Model.GoogleAppsCardV1SwitchControl{
  controlType: String.t() | nil,
  name: String.t() | nil,
  onChangeAction: GoogleApi.Chat.V1.Model.GoogleAppsCardV1Action.t() | nil,
  selected: boolean() | nil,
  value: String.t() | nil
}

Functions

@spec decode(struct(), keyword()) :: struct()

Unwrap a decoded JSON object into its complex fields.