Skip to content

Commit 15d07e3

Browse files
committed
Change settings icon to close icon when the settings pane is open
1 parent 17dd844 commit 15d07e3

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

user-interface/dist/bundle.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

user-interface/src/App.tsx

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,19 +25,25 @@ export class App extends React.Component<IAppProps, {}> {
2525
super(props);
2626
this.ToggleSettings = this.ToggleSettings.bind(this);
2727
}
28+
2829
private boldStyle = {
2930
root: {
3031
fontWeight: FontWeights.semibold,
3132
backgroundColor: this.props.backgroundColor
3233
}
3334
};
35+
36+
private SettingsIcon = "Settings";
37+
3438
private ToggleSettings(event: React.MouseEvent<HTMLAnchorElement, MouseEvent>) {
3539
switch (CurrentView) {
3640
case 0:
3741
CurrentView = Views.MainView;
42+
this.SettingsIcon = "Settings";
3843
break;
3944
case 1:
4045
CurrentView = Views.SettingsView;
46+
this.SettingsIcon = "Cancel";
4147
break;
4248
default:
4349
console.error("Invalid view: " + CurrentView, "Valid views are: " + JSON.stringify(Views));
@@ -62,7 +68,7 @@ export class App extends React.Component<IAppProps, {}> {
6268
}}>
6369
<div>
6470
<ActionButton iconProps={{
65-
iconName: "Settings",
71+
iconName: this.SettingsIcon,
6672
styles: SettingsStyle
6773
}}
6874
/>

0 commit comments

Comments
 (0)