Skip to content

Commit

Permalink
pr fix
Browse files Browse the repository at this point in the history
  • Loading branch information
MBudreviciusBentley committed Dec 31, 2024
1 parent 0da7b9d commit e3e70b7
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 12 deletions.
17 changes: 7 additions & 10 deletions ui/appui-react/src/appui-react/frontstage/FrontstageDef.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,8 @@ export class FrontstageDef {
private _isApplicationClosing = false;
private _usage?: string;
private _version: number = 0;
private _toolSettings?: WidgetDef & {
activeToolEmptyNode?: React.ReactNode;
};
private _toolSettings?: WidgetDef;
private _activeToolEmptyNode?: React.ReactNode;
private _statusBar?: WidgetDef;
private _contentManipulation?: WidgetDef;
private _viewNavigation?: WidgetDef;
Expand Down Expand Up @@ -115,11 +114,12 @@ export class FrontstageDef {
return this._floatingContentControls;
}

public get toolSettings():
| (WidgetDef & { activeToolEmptyNode?: React.ReactNode })
| undefined {
public get toolSettings(): WidgetDef | undefined {
return this._toolSettings;
}
public get activeToolEmptyNode(): React.ReactNode | undefined {
return this._activeToolEmptyNode;
}
public get statusBar(): WidgetDef | undefined {
return this._statusBar;
}
Expand Down Expand Up @@ -584,10 +584,7 @@ export class FrontstageDef {
config.toolSettings,
WidgetType.ToolSettings
);
if (this._toolSettings) {
this._toolSettings.activeToolEmptyNode =
config.toolSettings?.activeToolEmptyNode;
}
this._activeToolEmptyNode = config.toolSettings?.activeToolEmptyNode;
this._statusBar = createWidgetDef(config.statusBar, WidgetType.StatusBar);
this._contentManipulation = createWidgetDef(
config.contentManipulation,
Expand Down
4 changes: 2 additions & 2 deletions ui/appui-react/src/appui-react/widget-panels/ToolSettings.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ export function ToolSettingsDockedContent() {
() => [
{
editorNode: null,
labelNode: frontstageDef?.toolSettings?.activeToolEmptyNode ?? (
labelNode: frontstageDef?.activeToolEmptyNode ?? (
<EmptyToolSettingsLabel toolId={activeToolId} />
),
},
Expand Down Expand Up @@ -189,7 +189,7 @@ export function ToolSettingsWidgetContent() {
key={forceRefreshKey}
>
<ScrollableWidgetContent>
{node ?? frontstageDef?.toolSettings?.activeToolEmptyNode ?? (
{node ?? frontstageDef?.activeToolEmptyNode ?? (
<EmptyToolSettingsLabel toolId={activeToolId} />
)}
</ScrollableWidgetContent>
Expand Down

0 comments on commit e3e70b7

Please sign in to comment.