global-context/integration/widget-wrapper/global-context-widget-wrapper.component.ts
OnInit
| changeDetection | ChangeDetectionStrategy.OnPush |
| host | { |
| selector | c8y-global-context-widget-wrapper |
| standalone | true |
| imports |
GlobalContextInlineComponent
GlobalContextWidgetConfigComponent
NgTemplateOutlet
ReactiveFormsModule
PopoverModule
PreviewControlsComponent
|
| template | |
Properties |
Methods |
Inputs |
Outputs |
constructor()
|
| config |
Type : GlobalContextState
|
Default value : {}
|
| controlLinks |
Type : LinkStatesMap
|
Default value : {}
|
| dashboardChildForLegacy |
Type : DashboardChildComponent
|
| displayMode |
Type : WidgetDisplayMode
|
Default value : WIDGET_DISPLAY_MODE.INLINE
|
| isLoading |
Default value : false
|
| widgetControlsConfig |
Type : WidgetControls | WidgetControlsPresetConfig
|
| Required : true |
Default value : { alias: 'widgetControls' }
|
| globalContextChange |
Type : EventEmitter
|
| ngOnInit |
ngOnInit()
|
|
Returns :
void
|
| onGlobalContextChange | ||||||
onGlobalContextChange(context: GlobalContextState)
|
||||||
|
Parameters :
Returns :
void
|
| onRefresh |
onRefresh()
|
|
Returns :
void
|
| pauseAutoRefresh |
pauseAutoRefresh()
|
|
Pause auto-refresh and unlink all controls from global context. Useful when user is interacting with the widget (e.g., scrolling through a list) and you want to prevent automatic updates. This does two things:
Returns :
void
|
| resumeAutoRefresh |
resumeAutoRefresh()
|
|
Resume auto-refresh and re-link all controls to global context. Useful when user has finished interacting with the widget (e.g., scrolled back to top) and you want to re-enable automatic updates. This does two things:
Returns :
void
|
| toggleAllLinks | ||||||||||||||||
toggleAllLinks(isLinked: boolean, suppressRefresh?: boolean, suppressEmit?: boolean)
|
||||||||||||||||
|
Directly toggle all link controls to linked or unlinked state. All controls are always toggled together as a unified group.
Parameters :
Returns :
void
|
| updateDateTimeContext | ||||||
updateDateTimeContext(dateTimeContext: any)
|
||||||
|
Update dateTimeContext for internal widget interactions (e.g., slider drag). This bypasses the config propagation logic and directly updates the inline component state.
Parameters :
Returns :
void
|
| Readonly GLOBAL_CONTEXT_DISPLAY_MODE |
Type : unknown
|
Default value : GLOBAL_CONTEXT_DISPLAY_MODE
|
| globalContextInlineComponent |
Type : GlobalContextInlineComponent
|
Decorators :
@ViewChild(GlobalContextInlineComponent)
|
| internalConfig |
Type : WritableSignal<GlobalContextState>
|
Default value : signal({})
|
| Readonly WIDGET_DISPLAY_MODE |
Type : unknown
|
Default value : WIDGET_DISPLAY_MODE
|
| widgetBodyRef |
Type : TemplateRef<unknown>
|
Decorators :
@ContentChild('widgetBody')
|
| widgetControls |
Type : unknown
|
Default value : computed(() => resolveWidgetControlsInput(this.widgetControlsConfig()))
|
| widgetHeaderRef |
Type : TemplateRef<unknown>
|
Decorators :
@ContentChild('widgetHeader')
|