## Index

### Enumerations

- DescriptionType
- NumberUiType

### Classes

- SelfServeBaseClass

### Interfaces

- Description
- Info
- OnSaveResult
- RefreshParams
- RefreshResult
- SelfServeTelemetryMessage
- SmartUiInput

### Type aliases

- ChoiceItem
- InputType
- OnChangeCallback
- initializeCallback
- onSaveCallback

## 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

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

  - #### 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

- - (): Promise<Map<string, SmartUiInput>>

  - #### Returns Promise<Map<string, SmartUiInput>>

    Promise of Map of propertyName => `SmartUiInput` which will become the current state of the UI.

### onSaveCallback

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

#### Type declaration

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

  - #### Parameters

    - ##### 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 Promise<OnSaveResult>

Generated using TypeDoc