# command: ui.activate
Description: Activates a component with the given ID or model, causing it to become visible. For VertiGIS Studio Mobile, only ID is supported.

Inputs: `ActivateArgs`

ActivateArgs properties:
```json
{
  "id": {
    "description": "The unique ID for this entity.",
    "type": "string",
    "isRequired": "true"
  },
  "itemType": {
    "description": "The item type for this entity when it participates in an App.",
    "type": "string",
    "isRequired": "true"
  },
  "component": {
    "anyOf": [
      {
        "$ref": "#/definitions/Model"
      },
      {
        "type": "string"
      }
    ],
    "description": "The component to activate or deactivate. Can be identified by its ID or model.",
    "isRequired": "true"
  },
  "validateState": {
    "description": "Whether to validate the component's state before activation or deactivation. Defaults to `false` if not provided.",
    "type": "boolean"
  }
}
```

---
# command: ui.alert
Description: Shows an alert to the user.

Inputs: `AlertCommandArgs`

AlertCommandArgs properties:
```json
{
  "buttonText": {
    "description": "The text to display on the dismiss button.",
    "type": "string"
  },
  "initialPosition": {
    "description": "Where the dialog appears in the app when it is created. Defaults to \"center\" position. Web only."
  },
  "isDraggable": {
    "description": "Whether the dialog is draggable or not. Defaults to true. Web only.",
    "type": "boolean"
  },
  "message": {
    "description": "The message to be displayed in the dialog.",
    "type": "string"
  },
  "title": {
    "description": "The title of the dialog.",
    "type": "string"
  }
}
```

---
# command: ui.deactivate
Description: Deactivates a component with the given ID, causing it to disappear. For VertiGIS Studio Mobile, only ID is supported.

Inputs: `DeactivateArgs`

DeactivateArgs properties:
```json
{
  "id": {
    "description": "The unique ID for this entity.",
    "type": "string",
    "isRequired": "true"
  },
  "itemType": {
    "description": "The item type for this entity when it participates in an App.",
    "type": "string",
    "isRequired": "true"
  },
  "component": {
    "anyOf": [
      {
        "$ref": "#/definitions/Model"
      },
      {
        "type": "string"
      }
    ],
    "description": "The component to activate or deactivate. Can be identified by its ID or model.",
    "isRequired": "true"
  },
  "validateState": {
    "description": "Whether to validate the component's state before activation or deactivation. Defaults to `false` if not provided.",
    "type": "boolean"
  }
}
```

---
# command: ui.display-busy-state
Description: Displays a loading indicator and custom message to the user to indicate that the UI is busy.

Inputs: `DisplayBusyStateArgs`

DisplayBusyStateArgs properties:
```json
{
  "id": {
    "description": "The ID used to link a busy state to its caller. Web only.",
    "type": "string"
  },
  "maximumDisplayDurationMs": {
    "description": "The maximum number of milliseconds the busy state will be displayed. Web only.",
    "type": "number"
  },
  "message": {
    "description": "The message to display.",
    "type": "string"
  },
  "messageDelayMs": {
    "description": "The number of milliseconds to wait before displaying the message. Default is 3000. Web only.",
    "type": "number"
  },
  "minimumDisplayDurationMs": {
    "description": "The minimum duration, in milliseconds, that the busy state will be displayed. Defaults to 500. Mobile only.",
    "type": "number"
  },
  "title": {
    "description": "The title to display. Mobile only.",
    "type": "string"
  }
}
```

---
# command: ui.display-notification
Description: Shows a notification to the user.

Inputs: `DisplayNotificationArgs`

DisplayNotificationArgs properties:
```json
{
  "autoClose": {
    "description": "Indicates if the notification should auto-close after a time duration. Defaults to true. Mobile only.",
    "type": "boolean"
  },
  "category": {
    "description": "The category of notification, i.e. \"error\" (default is \"info\")."
  },
  "disableTimeouts": {
    "description": "Disable notification timeouts. Timeouts only apply to \"info\" and \"success\" categories. Web only.",
    "type": "boolean"
  },
  "id": {
    "description": "Optional identifier that can be used to hide a particular notification (see `ui.hide-notification`) Web only.",
    "type": "string"
  },
  "message": {
    "description": "The message to be displayed in the notification. Mobile only supports a string for this property.",
    "isRequired": "true"
  },
  "notificationGroup": {
    "description": "Notifications in the same notification group are mutually exclusive, and will supersede one another. Mobile only.",
    "type": "string"
  },
  "onClose": {
    "description": "Invoked when the notification is closed, either explicitly or due to timeout. Web only."
  },
  "position": {
    "description": "The position of the notification on the screen. Web only."
  },
  "title": {
    "description": "The notification title - only shown for system notifications. Mobile only.",
    "type": "string"
  },
  "type": {
    "description": "The type of notification - 'app', 'system', or 'auto'. Defaults to 'auto'. Mobile only."
  }
}
```

---
# command: ui.focus
Description: Focuses on a component or DOM element. Web only.

Inputs: `FocusArgs`

FocusArgs properties:
```json
{
  "component": {
    "anyOf": [
      {
        "$ref": "#/definitions/Model"
      },
      {
        "type": "string"
      }
    ],
    "description": "The component to focus. If the selector property is not defined, the first focusable element within the component will receive focus. If this property is not defined, only the selector will be used."
  },
  "selector": {
    "description": "The CSS selector used to find an HTML Element in the DOM. If a component is also provided, the selector will only look within the component's element tree in the DOM.",
    "type": "string"
  },
  "timeout": {
    "description": "The maximum number of milliseconds the command will spend attempting to focus the element. This may be useful in cases where the target component/element requires time to load or render. Defaults to 0.",
    "type": "number"
  }
}
```

---
# command: ui.hide-busy-state
Description: Hides the busy state if currently shown. In Web, requires the ID of the caller that was used to show the busy state.

Inputs: `string`

---
# command: ui.hide-notification
Description: Hides a notification previously shown to the user.

Inputs: `( HideNotificationArgs )`

HideNotificationArgs properties:
```json
{
  "id": {
    "description": "Optional identifier that can be used to hide a particular notification. Web only.",
    "type": "string"
  }
}
```

---
# command: ui.narrate
Description: Forces assistive technology (screen readers) to narrate a translatable message to the end user. Web only.

Inputs: `NarrateArgs`

NarrateArgs properties:
```json
{
  "args": {
    "description": "The values to substitute into the format string if it contains substitution placeholders (see utilities/string/format in ArcGIS Extensions API).",
    "items": {},
    "type": "array"
  },
  "currency": {
    "description": "The default unit of currency to use when formatting currency. See {@link utilities /format/number!NumberSettings.currency}.",
    "type": "string"
  },
  "dateFormat": {
    "description": "The default format to use when formatting dates. See {@link utilities /format/date!DateFormatter.format}.",
    "type": "string"
  },
  "defaultValue": {
    "description": "An optional default value to fallback to when a language resource key does not exist. Web only.",
    "type": "string"
  },
  "fractionalDigits": {
    "description": "The default number of digits to show after the decimal point when formatting numbers. See {@link utilities /format/number!NumberSettings.fractionalDigits}.",
    "type": "number"
  },
  "locale": {
    "description": "The locale to use for translation. If not specified, the current locale will be used.",
    "type": "string"
  },
  "numberFormat": {
    "description": "The default format to use when formatting numbers. See {@link utilities /format/number!NumberFormatter.format}.",
    "type": "string"
  },
  "text": {
    "description": "The string to translate. If the text is a language resource key, then a localized version of that resource will be used if one exists, otherwise the original text is returned.",
    "type": "string",
    "isRequired": "true"
  },
  "timeFormat": {
    "description": "The default format to use when formatting times. See {@link utilities /format/time!TimeFormatter.format}.",
    "type": "string"
  },
  "timeZone": {
    "description": "The time zone of a date being formatted. See {@link utilities /format/date!DateFormatter.timeZone}.",
    "type": "string"
  },
  "timeout": {
    "description": "A timeout before the narration is executed. This can be used to avoid focus changes that can interrupt the screen reader. Defaults to 50ms.",
    "type": "number"
  }
}
```

---
# command: ui.set-density
Description: Sets the density level for the UI. Web only.

Inputs: `UIDensity`

---
# command: ui.set-locale
Description: Sets the locale for the application and loads any locale-specific resources. Accepts a valid locale code (example: "en", "fr" or "de-AT"). Web only.

Inputs: `string`

---
# command: ui.set-theme
Description: Sets the color theme of the viewer. The required argument is the new theme's ID.

Inputs: `string`

---
# command: ui.set-visual-state
Description: Sets the visual state of a component. Web only.

Inputs: `SetVisualStateArgs`

SetVisualStateArgs properties:
```json
{
  "id": {
    "description": "The component ID.",
    "isRequired": "true"
  },
  "visualState": {
    "description": "The visual state of the component. The set of visual states is specific to the type of component.",
    "isRequired": "true"
  }
}
```

---
