Is your feature request related to a problem? Please describe.
I believe this is something that Raphael L pitched at some point. It'd be nice to have a hook that gives the widget some information about its current state, be it passed down as part of the props object or by calling the hook explicitly.
Information may include whether it's in popout state, if it's displayed currently, etc.
As of right now, it seems the way to do this is by passing the widgetId to the Widget component and have it call static functions from the framework (eg. UiFramework.frontstages.activeFrontstageDef?.findWidgetDef(widgetId)).
The whole thing feels like an antipattern as widget shouldn't need to know (or care for) the widgetId to begin with.
Is your feature request related to a problem? Please describe. I believe this is something that Raphael L pitched at some point. It'd be nice to have a hook that gives the widget some information about its current state, be it passed down as part of the
props
object or by calling the hook explicitly. Information may include whether it's in popout state, if it's displayed currently, etc.As of right now, it seems the way to do this is by passing the widgetId to the Widget component and have it call static functions from the framework (eg.
UiFramework.frontstages.activeFrontstageDef?.findWidgetDef(widgetId)
). The whole thing feels like an antipattern as widget shouldn't need to know (or care for) the widgetId to begin with.Thanks! Alex