Class: Google::Apps::Card::V1::DecoratedText::SwitchControl
- Inherits:
-
Object
- Object
- Google::Apps::Card::V1::DecoratedText::SwitchControl
- Extended by:
- Protobuf::MessageExts::ClassMethods
- Includes:
- Protobuf::MessageExts
- Defined in:
- proto_docs/google/apps/card/v1/card.rb
Overview
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.
Defined Under Namespace
Modules: ControlType
Instance Attribute Summary collapse
-
#control_type ⇒ ::Google::Apps::Card::V1::DecoratedText::SwitchControl::ControlType
How the switch appears in the user interface.
-
#name ⇒ ::String
The name by which the switch widget is identified in a form input event.
-
#on_change_action ⇒ ::Google::Apps::Card::V1::Action
The action to perform when the switch state is changed, such as what function to run.
-
#selected ⇒ ::Boolean
When
true
, the switch is selected. -
#value ⇒ ::String
The value entered by a user, returned as part of a form input event.
Instance Attribute Details
#control_type ⇒ ::Google::Apps::Card::V1::DecoratedText::SwitchControl::ControlType
Returns How the switch appears in the user interface.
850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 |
# File 'proto_docs/google/apps/card/v1/card.rb', line 850 class SwitchControl include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # How the switch appears in the user interface. # # [Google Workspace Add-ons # and Chat apps](https://developers.google.com/workspace/extend): module ControlType # A toggle-style switch. SWITCH = 0 # Deprecated in favor of `CHECK_BOX`. CHECKBOX = 1 # A checkbox. CHECK_BOX = 2 end end |
#name ⇒ ::String
Returns 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.
850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 |
# File 'proto_docs/google/apps/card/v1/card.rb', line 850 class SwitchControl include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # How the switch appears in the user interface. # # [Google Workspace Add-ons # and Chat apps](https://developers.google.com/workspace/extend): module ControlType # A toggle-style switch. SWITCH = 0 # Deprecated in favor of `CHECK_BOX`. CHECKBOX = 1 # A checkbox. CHECK_BOX = 2 end end |
#on_change_action ⇒ ::Google::Apps::Card::V1::Action
Returns The action to perform when the switch state is changed, such as what function to run.
850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 |
# File 'proto_docs/google/apps/card/v1/card.rb', line 850 class SwitchControl include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # How the switch appears in the user interface. # # [Google Workspace Add-ons # and Chat apps](https://developers.google.com/workspace/extend): module ControlType # A toggle-style switch. SWITCH = 0 # Deprecated in favor of `CHECK_BOX`. CHECKBOX = 1 # A checkbox. CHECK_BOX = 2 end end |
#selected ⇒ ::Boolean
Returns When true
, the switch is selected.
850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 |
# File 'proto_docs/google/apps/card/v1/card.rb', line 850 class SwitchControl include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # How the switch appears in the user interface. # # [Google Workspace Add-ons # and Chat apps](https://developers.google.com/workspace/extend): module ControlType # A toggle-style switch. SWITCH = 0 # Deprecated in favor of `CHECK_BOX`. CHECKBOX = 1 # A checkbox. CHECK_BOX = 2 end end |
#value ⇒ ::String
Returns 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.
850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 |
# File 'proto_docs/google/apps/card/v1/card.rb', line 850 class SwitchControl include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # How the switch appears in the user interface. # # [Google Workspace Add-ons # and Chat apps](https://developers.google.com/workspace/extend): module ControlType # A toggle-style switch. SWITCH = 0 # Deprecated in favor of `CHECK_BOX`. CHECKBOX = 1 # A checkbox. CHECK_BOX = 2 end end |