# SiGridComponent documentation

**Kind:** component

**Selector:** `si-grid`

```
import { SiGridComponent } from '@siemens/dashboards-ng';
```

The grid component is the actual component on which the widget instances are placed and visualized. You can think of a headless dashboard, without a title, toolbar or edit buttons.

```
component SiGridComponent implements OnInit, OnChanges, OnDestroy
```

#### Input Properties

| Name | Type | Default | Description |
| --- | --- | --- | --- |
| [dashboardId](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/components/grid/si-grid.component.ts#L74-L74>) | `string \| undefined` |  | An optional, but recommended dashboard id that is used in persistence and passed to the widget store for saving and loading data. |
| [editable](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/components/grid/si-grid.component.ts#L68-L68>) | `boolean` | `false` | Sets the grid into editable mode, in which the widget instances can be moved, resized, removed or new ones added. |
| [emitWidgetInstanceEditEvents](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/components/grid/si-grid.component.ts#L98-L98>) | `boolean` | `false` | When the user clicks edit on a widget instance, an editor need to appear and the widget editor component need to be loaded. When the grid is used standalone, it takes care and opens a modal dialog and loads the configured widget editor component. When the grid is used in a container like the flexible dashboard, the container manages where the widget instance editor is displayed. In this case this options prevents the grid from showing the editor in the dialog, and emits on `widgetInstanceEdit` on clicking the widget `edit` action. |
| [gridConfig](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/components/grid/si-grid.component.ts#L60-L60>) | `GridConfig \| undefined` | `inject(SI_DASHBOARD_CONFIGURATION)?.grid` | Configuration options for a grid instance. Default is the optional value from the [SI\_DASHBOARD\_CONFIGURATION](<../../types/SI_DASHBOARD_CONFIGURATION/index.html#t:SI_DASHBOARD_CONFIGURATION>). |
| [hideProgressIndicator](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/components/grid/si-grid.component.ts#L105-L105>) | `boolean` | `false` | Option to turn off the loading spinner on save and load operations. |
| [widgetCatalog](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/components/grid/si-grid.component.ts#L82-L82>) | `Widget[]` | `[]` | Provides the available widgets to the grid. When loading the widget configurations from the storage, we need to have the widget definition available to be able to create the widget instances on the grid. |
| [widgetInstanceEditorDialogComponent](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/components/grid/si-grid.component.ts#L111-L112>) | `Type<SiWidgetInstanceEditorDialogComponent> \| undefined` |  | Option to configure a custom widget instance editor dialog component. The component provides the editor hosting and the buttons to save and cancel. |

#### Output Properties

| Name | Type | Description |
| --- | --- | --- |
| [editableChange](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/components/grid/si-grid.component.ts#L68-L68>) | `boolean` | Sets the grid into editable mode, in which the widget instances can be moved, resized, removed or new ones added. |
| [isModified](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/components/grid/si-grid.component.ts#L121-L121>) | `boolean` | Emits the modification state of the grid. It is `unmodified` when the visible state is equal to the loaded state from the widget storage. When the user modifies the dashboard by e.g. while moving the widgets, the dashboard is marked as `modified` and emits `true` and when the user persists the change by saving, or reverts the state by canceling, the state is `unmodified` again and emits `false`. |
| [widgetInstanceEdit](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/components/grid/si-grid.component.ts#L133-L133>) | `WidgetConfig` | Emits to notify about edit events of widget instances. Only emits if `emitWidgetInstanceEditEvents` is set to `true`. |

#### Attributes and Methods

##### addWidgetInstance

[Source for addWidgetInstance](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/components/grid/si-grid.component.ts#L266-L275>)

Adds a new widget instance configuration to the dashboard grid. It is not persisted yet and is added to the transient widget instances.

```
addWidgetInstance(widgetInstanceConfig: Omit<WidgetConfig, "id">): void
```

#### Parameters

| Name | Type | Default | Description |
| --- | --- | --- | --- |
| [widgetInstanceConfig](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/components/grid/si-grid.component.ts#L266-L266>) | `Omit<WidgetConfig, "id">` |  | • The new widget configuration. |

**Returns:** [void](<https://www.typescriptlang.org/docs/handbook/2/functions.html#void>)

##### cancel

[Source for cancel](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/components/grid/si-grid.component.ts#L253-L258>)

Cancel current changes and restore last saved state.

```
cancel(): void
```

**Returns:** [void](<https://www.typescriptlang.org/docs/handbook/2/functions.html#void>)

##### edit

[Source for edit](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/components/grid/si-grid.component.ts#L211-L216>)

Set dashboard grid in editable mode to modify widget instances.

```
edit(): void
```

**Returns:** [void](<https://www.typescriptlang.org/docs/handbook/2/functions.html#void>)

##### editWidgetInstance

[Source for editWidgetInstance](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/components/grid/si-grid.component.ts#L306-L334>)

Opens the provided widget configuration in the related editor or emits on [widgetInstanceEdit](<index.html#SiGridComponent.widgetInstanceEdit>), if [emitWidgetInstanceEditEvents](<index.html#SiGridComponent.emitWidgetInstanceEditEvents>) is true.

```
editWidgetInstance(widgetInstanceConfig: WidgetConfig): void
```

#### Parameters

| Name | Type | Default | Description |
| --- | --- | --- | --- |
| [widgetInstanceConfig](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/components/grid/si-grid.component.ts#L306-L306>) | `WidgetConfig` |  | • The config of the widget instance to edit. |

**Returns:** [void](<https://www.typescriptlang.org/docs/handbook/2/functions.html#void>)

##### gridStackWrapper

[Source for gridStackWrapper](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/components/grid/si-grid.component.ts#L170-L170>)

**Modifiers:** readonly

**Type:** `Signal<SiGridstackWrapperComponent>`

**Default:** `viewChild.required(SiGridstackWrapperComponent)`

##### isLoading

[Source for isLoading](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/components/grid/si-grid.component.ts#L175-L175>)

**Modifiers:** readonly

**Type:** `BehaviorSubject<boolean>`

**Default:** `new BehaviorSubject<boolean>(false)`

Indication for load and save operations.

##### removeWidgetInstance

[Source for removeWidgetInstance](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/components/grid/si-grid.component.ts#L283-L297>)

Removes a widget instance from the visible widgets and puts it in the markedForRemoval array.

```
removeWidgetInstance(widgetInstanceId: string): void
```

#### Parameters

| Name | Type | Default | Description |
| --- | --- | --- | --- |
| [widgetInstanceId](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/components/grid/si-grid.component.ts#L283-L283>) | `string` |  | • The id of the widget instance to be removed. |

**Returns:** [void](<https://www.typescriptlang.org/docs/handbook/2/functions.html#void>)

##### save

[Source for save](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/components/grid/si-grid.component.ts#L222-L248>)

Persists the current widget instances to the widget storage and changes the editable and isModified modes.

```
save(): void
```

**Returns:** [void](<https://www.typescriptlang.org/docs/handbook/2/functions.html#void>)

##### updateWidgetInstance

[Source for updateWidgetInstance](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/components/grid/si-grid.component.ts#L342-L351>)

Updates the visible widgets with an updated configuration. Will update the user interface and emit on [isModified](<index.html#SiGridComponent.isModified>).

```
updateWidgetInstance(editedWidgetConfig: WidgetConfig): void
```

#### Parameters

| Name | Type | Default | Description |
| --- | --- | --- | --- |
| [editedWidgetConfig](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/components/grid/si-grid.component.ts#L342-L342>) | `WidgetConfig` |  | • The config of the widget instance that was updated. |

**Returns:** [void](<https://www.typescriptlang.org/docs/handbook/2/functions.html#void>)

### Types Documentation

### [GridConfig](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/gridstack.model.ts#L12-L17>)

**Kind:** interface

```
import type { GridConfig } from '@siemens/dashboards-ng';
```

Configuration object for the si-grid component, including the options of gridstack.

```
interface GridConfig
```

#### Properties

| Name | Type | Description |
| --- | --- | --- |
| [gridStackOptions](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/gridstack.model.ts#L16-L16>) (optional) | `GridStackOptions` | The configuration options of gridstack. |

### [Widget](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L17-L46>)

**Kind:** interface

```
import type { Widget } from '@siemens/dashboards-ng';
```

Widgets describe the entries within the widget catalog and holds all default configuration and factory functionality to instantiate a widget instance, represented as [WidgetConfig](<index.html#t:WidgetConfig>) objects.

```
interface Widget
```

#### Properties

| Name | Type | Description |
| --- | --- | --- |
| [componentFactory](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L29-L29>) | `WidgetComponentFactory` | The factory to instantiate a widget instance component that is added to the dashboard. |
| [defaults](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L31-L43>) (optional) | `Pick<WidgetConfig, "width" \| "height" \| "minWidth" \| "minHeight" \| "heading" \| "headingIcon" \| "expandable" \| "immutable" \| "image" \| "accentLine">` | Optional default values that can be set to widget instances. |
| [description](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L25-L25>) (optional) | `TranslatableString` | An optional description that is visible in the widget catalog. |
| [iconClass](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L27-L27>) (optional) | `string` | A CSS icon class that specifies the widget icon, displayed in the catalog. |
| [id](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L19-L19>) | `string` | A unique id of the widget. |
| [name](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L23-L23>) | `TranslatableString` | The name of the widget that is presented in the widget catalog. |
| [payload](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L45-L45>) (optional) | `any` | Optional default payload object that is copied into every widget instance [WidgetConfig](<index.html#t:WidgetConfig>). |
| [version](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L21-L21>) (optional) | `string` | An optional version string. |

### [WidgetConfig](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L146-L211>)

**Kind:** interface

```
import type { WidgetConfig } from '@siemens/dashboards-ng';
```

A [WidgetConfig](<index.html#t:WidgetConfig>) holds the configuration of a widget instance component that is visible on a dashboard. It can be persisted and used to restore a dashboards state.

```
interface WidgetConfig
```

#### Properties

| Name | Type | Description |
| --- | --- | --- |
| [accentLine](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L210-L210>) (optional) | `AccentLineType` | Optional type of the accent line. |
| [actionBarViewType](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L200-L200>) (optional) | `ViewType` |  |
| [expandable](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L189-L189>) (optional) | `boolean` | Defines whether the widget instance component can be expanded and enlarged over the dashboard. |
| [heading](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L185-L185>) (optional) | `TranslatableString` | grid item header text. |
| [headingIcon](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L187-L187>) (optional) | `string \| Record<string, string>` | Icon name or a single-entry map of camelCase icon name to SVG data URI. |
| [height](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L165-L165>) (optional) | `number` | Height of the grid item, where number represents how many rows it takes. (default?: 1) |
| [id](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L148-L148>) | `string` | A unique id of a widget instance |
| [image](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L206-L206>) (optional) | `WidgetImage` | Optional configuration for an image to be displayed on the widget instance. |
| [immutable](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L202-L202>) (optional) | `boolean` |  |
| [isNotRemovable](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L201-L201>) (optional) | `boolean` |  |
| [minHeight](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L181-L181>) (optional) | `number` | minimum height allowed during resize/creation (default?: undefined = un-constrained) |
| [minWidth](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L177-L177>) (optional) | `number` | minimum width allowed during resize/creation (default?: undefined = un-constrained) |
| [payload](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L191-L191>) (optional) | `any` | A widget specific payload object. Placeholder to pass in additional configuration. |
| [setupPending](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L199-L199>) (optional) | `boolean` | If true, the widget host renders a placeholder and waits for explicit configuration before instantiating the widget instance component.<br><br>Indicates that initial setup by the user is still pending. The flag flips to `false` once the setup has been completed. |
| [version](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L157-L157>) (optional) | `string` | Optionally, the version widget description that was used to create the widget config. |
| [widgetId](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L153-L153>) | `string` | The id of the widget descriptor that was used to instantiate the `WidgetConfig` and the widget instance component. |
| [width](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L161-L161>) (optional) | `number` | Width of the grid item, where number represents how many columns it spans (default?: 1) |
| [x](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L169-L169>) (optional) | `number` | Grid item position on x axis of the grid (default?: 0) |
| [y](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L173-L173>) (optional) | `number` | Grid item position on y axis of the grid (default?: 0) |

### [TranslatableString](<https://github.com/siemens/element/blob/main/projects/element-translate-ng/translate-types/global.types.ts#L18-L18>)

**Kind:** type alias

```
import type { TranslatableString } from '@siemens/element-translate-ng/translate-types';
```

Represents a translatable string. This can either be a translation key, e.g. `ACTIONS.EDIT` that will be automatically translated when displayed on the UI or a pre-translated string, e.g. `Edit`. Equivalent to a normal string in usage and functionality.

```
type TranslatableString = string & Translatable
```

### [WidgetComponentFactory](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L49-L50>)

**Kind:** type alias

```
import type { WidgetComponentFactory } from '@siemens/dashboards-ng';
```

Factory type that is either a [WidgetComponentTypeFactory](<index.html#t:WidgetComponentTypeFactory>), [FederatedModule](<index.html#t:FederatedModule>), [FederatedBridgeModule](<index.html#t:FederatedBridgeModule>) or [WebComponent](<index.html#t:WebComponent>).

```
type WidgetComponentFactory = WidgetComponentTypeFactory | FederatedModule | WebComponent | FederatedBridgeModule
```

### [ViewType](<https://github.com/siemens/element/blob/main/projects/element-ng/content-action-bar/si-content-action-bar.model.ts#L13-L13>)

**Kind:** type alias

```
import type { ViewType } from '@siemens/element-ng/content-action-bar';
```

```
type ViewType = 'collapsible' | 'expanded' | 'mobile'
```

### [WidgetImage](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L118-L140>)

**Kind:** interface

```
import type { WidgetImage } from '@siemens/dashboards-ng';
```

Image is used to configure an image to be displayed on a widget instance.

```
interface WidgetImage
```

#### Properties

| Name | Type | Description |
| --- | --- | --- |
| [alt](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L127-L127>) | `string` | The HTMLImageElement property [alt](<https://developer.mozilla.org/en-US/docs/Web/API/HTMLImageElement/alt#usage_notes>) provides fallback (alternate) text to display when the image specified by the \<img\> element is not loaded. |
| [dir](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L131-L131>) (optional) | `"horizontal" \| "vertical"` | Defines if an image is placed on top or start (left) of the card. |
| [objectFit](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L135-L135>) (optional) | `ObjectFit` | Sets the image [object-fit](<https://developer.mozilla.org/en-US/docs/Web/CSS/object-fit>) CSS property. |
| [objectPosition](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L139-L139>) (optional) | `string` | Sets the image [object-position](<https://developer.mozilla.org/en-US/docs/Web/CSS/object-position>) CSS property. |
| [src](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L122-L122>) | `string` | The image URL (See [\<img\>](<https://developer.mozilla.org/en-US/docs/Web/HTML/Element/img#src>)). |

### [AccentLineType](<https://github.com/siemens/element/blob/main/projects/element-ng/common/models/status-type.model.ts#L10-L10>)

**Kind:** type alias

```
import type { AccentLineType } from '@siemens/element-ng/common';
```

```
type AccentLineType = StatusType | 'caution' | 'primary' | 'inactive'
```

### [WidgetComponentTypeFactory](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L81-L81>)

**Kind:** type alias

```
import type { WidgetComponentTypeFactory } from '@siemens/dashboards-ng';
```

```
type WidgetComponentTypeFactory = CommonFactoryFields & (ModuleOptions | StandaloneOptions)
```

### [FederatedModule](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L88-L92>)

**Kind:** type alias

```
import type { FederatedModule } from '@siemens/dashboards-ng';
```

Factory configuration for loading widget components from a federated module. Supports both Module Federation and Native Federation patterns for micro-frontend architectures. Use this when the widget component is hosted in a separate, independently deployed application.

```
type FederatedModule = CommonFactoryFields &
  LoadRemoteModuleOptions & {
    factoryType: 'module-federation' | 'native-federation';
    [index: string]: any;
  }
```

### [WebComponent](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L103-L107>)

**Kind:** type alias

```
import type { WebComponent } from '@siemens/dashboards-ng';
```

```
type WebComponent = CommonFactoryFields & {
  factoryType: 'web-component';
  url: string;
  [index: string]: any;
}
```

#### Index Signatures

| Name | Type | Description |
| --- | --- | --- |
| [\[index: string\]](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L106-L106>) | `any` |  |

### [FederatedBridgeModule](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L97-L101>)

**Kind:** type alias

```
import type { FederatedBridgeModule } from '@siemens/dashboards-ng';
```

Use this when having native federation shell and remote module is using module federation.

```
type FederatedBridgeModule = CommonFactoryFields &
  LoadRemoteBridgeOptions & {
    factoryType: 'native-federation-module-bridge';
    [index: string]: any;
  }
```

#### Index Signatures

| Name | Type | Description |
| --- | --- | --- |
| [\[index: string\]](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L100-L100>) | `any` |  |

### [ObjectFit](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L113-L113>)

**Kind:** type alias

```
import type { ObjectFit } from '@siemens/dashboards-ng';
```

ObjectFit configuration options for a widget image.

See: [https://developer.mozilla.org/en-US/docs/Web/CSS/object-fit](<https://developer.mozilla.org/en-US/docs/Web/CSS/object-fit>)

```
type ObjectFit = 'contain' | 'cover' | 'fill' | 'none' | 'scale-down'
```

### [StatusType](<https://github.com/siemens/element/blob/main/projects/element-ng/common/models/status-type.model.ts#L7-L7>)

**Kind:** type alias

```
import type { StatusType } from '@siemens/element-ng/common';
```

```
type StatusType = 'success' | 'info' | 'warning' | 'danger' | 'caution' | 'critical'
```

### [CommonFactoryFields](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L52-L60>)

**Kind:** type alias

```
type CommonFactoryFields = {
  componentName: string;
  editorComponentName?: string;
  /**
   * CSS class that is added to the modal dialog when component editor dialog is shown.
   * Provides the option to change the size if the dialog.
   */
  editorModalClass?: string;
}
```

#### Properties

| Name | Type | Description |
| --- | --- | --- |
| [componentName](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L53-L53>) | `string` |  |
| [editorComponentName](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L54-L54>) (optional) | `string` |  |
| [editorModalClass](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L59-L59>) (optional) | `string` | CSS class that is added to the modal dialog when component editor dialog is shown. Provides the option to change the size if the dialog. |

### [ModuleOptions](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L68-L72>)

**Kind:** type alias

Use when component is not standalone and part of a module

```
type ModuleOptions = WidgetComponentTypeBaseConfig & {
  moduleName: string;
  moduleLoader: (name: string) => Promise<any>;
  componentLoader?: never;
}
```

#### Properties

| Name | Type | Description |
| --- | --- | --- |
| [componentLoader](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L71-L71>) (optional) | `undefined` |  |
| [factoryType](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L63-L63>) (optional) | `"default"` |  |
| [moduleLoader](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L70-L70>) | `(name: string) => Promise<any>` |  |
| [moduleName](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L69-L69>) | `string` |  |

### [StandaloneOptions](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L75-L79>)

**Kind:** type alias

Use when component is standalone

```
type StandaloneOptions = WidgetComponentTypeBaseConfig & {
  componentLoader: <T = unknown>(componentName: string) => Promise<Type<T>>;
  moduleName?: never;
  moduleLoader?: never;
}
```

#### Properties

| Name | Type | Description |
| --- | --- | --- |
| [componentLoader](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L76-L76>) | `<T = unknown>(componentName: string) => Promise<Type<T>>` |  |
| [factoryType](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L63-L63>) (optional) | `"default"` |  |
| [moduleLoader](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L78-L78>) (optional) | `undefined` |  |
| [moduleName](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L77-L77>) (optional) | `undefined` |  |

### [LoadRemoteModuleOptions](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L383-L384>)

**Kind:** type alias

```
import type { LoadRemoteModuleOptions } from '@siemens/dashboards-ng';
```

The Remote Module definition is based on `@angular-architects`. We take it over into this file to prevent adding a hard dependency.

```
type LoadRemoteModuleOptions = LoadRemoteModuleScriptOptions | LoadRemoteModuleEsmOptions | LoadRemoteModuleManifestOptions
```

### [LoadRemoteBridgeOptions](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L390-L398>)

**Kind:** type alias

```
import type { LoadRemoteBridgeOptions } from '@siemens/dashboards-ng';
```

Definition is based on `@module-federation/enhanced` loadRemote options. We take it over into this file to prevent adding a hard dependency.

```
type LoadRemoteBridgeOptions = {
  id: string;
  options?:
    | {
        loadFactory?: boolean | undefined;
        from: 'build' | 'runtime';
      }
    | undefined;
}
```

### [WidgetComponentTypeBaseConfig](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L62-L65>)

**Kind:** type alias

```
type WidgetComponentTypeBaseConfig = {
  factoryType?: 'default';
  [index: string]: any;
}
```

#### Properties

| Name | Type | Description |
| --- | --- | --- |
| [factoryType](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L63-L63>) (optional) | `"default"` |  |

#### Index Signatures

| Name | Type | Description |
| --- | --- | --- |
| [\[index: string\]](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L64-L64>) | `any` |  |

### [LoadRemoteModuleScriptOptions](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L400-L410>)

**Kind:** type alias

```
import type { LoadRemoteModuleScriptOptions } from '@siemens/dashboards-ng';
```

```
type LoadRemoteModuleScriptOptions = {
  type?: 'script';
  remoteEntry?: string;
  remoteName: string;
  exposedModule: string;
  /**
   * Optional nonce value applied to the script element for Content Security Policy (CSP) support.
   * Supported in Module Federation v21.2.0+; safely ignored by earlier versions.
   */
  nonce?: string;
}
```

### [LoadRemoteModuleEsmOptions](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L412-L416>)

**Kind:** type alias

```
import type { LoadRemoteModuleEsmOptions } from '@siemens/dashboards-ng';
```

```
type LoadRemoteModuleEsmOptions = {
  type: 'module';
  remoteEntry: string;
  exposedModule: string;
}
```

### [LoadRemoteModuleManifestOptions](<https://github.com/siemens/element/blob/main/projects/dashboards-ng/src/model/widgets.model.ts#L418-L422>)

**Kind:** type alias

```
import type { LoadRemoteModuleManifestOptions } from '@siemens/dashboards-ng';
```

```
type LoadRemoteModuleManifestOptions = {
  type: 'manifest';
  remoteName: string;
  exposedModule: string;
}
```
