Class: SwitchLabel
A field for displaying a switch label.
Hierarchy
EditableField
<number
,number
>↳
SwitchLabel
Constructors
constructor
• new SwitchLabel(page
, options?
): SwitchLabel
Parameters
Name | Type |
---|---|
page | AbstractFmcPage <any > |
options | Partial <SwitchLabelOptions > |
Returns
Inherit Doc
Overrides
Defined in
src/sdk/fmc/components/SwitchLabel.ts:29
Properties
isDisabled
• isDisabled: () => boolean
Type declaration
▸ (): boolean
Returns
boolean
Inherited from
Defined in
src/sdk/fmc/components/FmcComponent.ts:57
options
• Protected
options: SwitchLabelOptions
Overrides
Defined in
src/sdk/fmc/components/SwitchLabel.ts:26
page
• Protected
page: AbstractFmcPage
<any
>
Inherited from
Defined in
src/sdk/fmc/components/SwitchLabel.ts:30
value
• Protected
value: null
| number
= null
Inherited from
Defined in
src/sdk/fmc/components/DisplayField.ts:30
valueChanged
• Protected
Readonly
valueChanged: SubEvent
<EditableField
<number
, number
>, number
>
Inherited from
Defined in
src/sdk/fmc/components/EditableField.ts:32
Accessors
rawValue
• get
rawValue(): null
| T
Gets the raw value of this display field
Returns
null
| T
the value
Inherited from
EditableField.rawValue
Defined in
src/sdk/fmc/components/DisplayField.ts:36
Methods
bind
▸ bind(subscribable
): this
Binds the input field to a mutable subscribable.
Parameters
Name | Type | Description |
---|---|---|
subscribable | Subscribable <number > | MutableSubscribable <number , number > | the mutable subscribable |
Returns
this
the instance of this EditableField
Inherited from
Defined in
src/sdk/fmc/components/EditableField.ts:47
bindConsumer
▸ bindConsumer(consumer
, modifier
): this
Binds the input field to a Consumer.
Parameters
Name | Type | Description |
---|---|---|
consumer | Consumer <number > | the consumer to bind to (get) |
modifier | (value : number ) => void | the modifier to use when the value is modified (set) |
Returns
this
the instance of this EditableField
Inherited from
Defined in
src/sdk/fmc/components/EditableField.ts:63
bindSource
▸ bindSource(source
): this
Binds the input field to a data interface.
Parameters
Name | Type | Description |
---|---|---|
source | DataInterface <number , number > | the data interface |
Returns
this
the instance of this EditableField
Inherited from
Defined in
src/sdk/fmc/components/EditableField.ts:72
getOptions
▸ getOptions(): DisplayFieldOptions
<number
>
Returns the component's options
Returns
DisplayFieldOptions
<number
>
The options.
Inherited from
Defined in
src/sdk/fmc/components/FmcComponent.ts:124
handleSelectKey
▸ handleSelectKey(event
): Promise
<string
| boolean
>
Parameters
Name | Type |
---|---|
event | LineSelectKeyEvent |
Returns
Promise
<string
| boolean
>
Inherit Doc
Inherited from
Defined in
src/sdk/fmc/components/FmcComponent.ts:80
invalidate
▸ invalidate(): void
Invalidates the component and queues a re-render if one is not already queued
Returns
void
Inherited from
Defined in
src/sdk/fmc/components/FmcComponent.ts:69
onHandleSelectKey
▸ onHandleSelectKey(): Promise
<boolean
>
Returns
Promise
<boolean
>
Inherit Doc
Overrides
EditableField.onHandleSelectKey
Defined in
src/sdk/fmc/components/SwitchLabel.ts:86
render
▸ render(): string
Renders the FMC component into an FmcRenderTemplateRow
Returns
string
Overrides
Defined in
src/sdk/fmc/components/SwitchLabel.ts:42
takeValue
▸ takeValue(value
, shouldInvalidate?
): void
Takes an input value, displays it and stores it
Parameters
Name | Type | Default value | Description |
---|---|---|---|
value | null | number | undefined | the new input value |
shouldInvalidate | boolean | false | whether or not to invalidate the page |
Returns
void
Inherited from
Defined in
src/sdk/fmc/components/DisplayField.ts:60