Options
All
  • Public
  • Public/Protected
  • All
Menu

Module SelfServe/SelfServeTypes

Index

Type aliases

ChoiceItem

ChoiceItem: { key: string; labelTKey: string }

Type declaration

  • key: string

    Key used to pickup the string that uniquely identifies the dropdown choice item, from the strings JSON file.

  • labelTKey: string

    Key used to pickup the string corresponding to the label of the dropdown choice item, from the strings JSON file.

InputType

InputType: number | string | boolean | ChoiceItem | Description

OnChangeCallback

OnChangeCallback: (newValue: InputType, currentValues: Map<string, SmartUiInput>, baselineValues: ReadonlyMap<string, SmartUiInput>) => Map<string, SmartUiInput>

Function that dictates how the overall UI should transform when the UI element corresponding to a property, say prop1, is changed. The callback can be used to
* Change the value (and reflect it in the UI) for another property, say prop2
* Change the visibility for prop2 in the UI
* Disable or enable the UI element corresponding to prop2
depending on logic based on the newValue of prop1, the currentValues Map and baselineValues Map.

Type declaration

    • Parameters

      • newValue: InputType

        The newValue that the property needs to be set to, after the change in the UI element corresponding to this property.

      • currentValues: Map<string, SmartUiInput>

        The map of propertyName => SmartUiInput corresponding to the current state of the UI.

      • baselineValues: ReadonlyMap<string, SmartUiInput>

        The map of propertyName => SmartUiInput corresponding to the initial state of the UI.

      Returns Map<string, SmartUiInput>

      A new Map of propertyName => SmartUiInput corresponding to the new state of the overall UI

initializeCallback

initializeCallback: () => Promise<Map<string, SmartUiInput>>

Type declaration

onSaveCallback

onSaveCallback: (currentValues: Map<string, SmartUiInput>, baselineValues: ReadonlyMap<string, SmartUiInput>) => Promise<OnSaveResult>

Type declaration

Generated using TypeDoc