Small fixes

This commit is contained in:
Thoronium
2023-02-25 19:21:40 -07:00
committed by GitHub
parent 3848c39743
commit 9b1d3594ed
5 changed files with 11 additions and 8 deletions

View File

@@ -120,6 +120,9 @@ export class Main extends React.Component<IProps, IState> {
isDownloading: this.props.downloadHandler.getDownloads().filter((d) => d.status !== 'finished')?.length > 0,
})
}, 1000)
// Summon the news when loaded since it will not show until click normally
NewsSection.showNews()
}
async openExtrasMenu(playGame: () => void) {

View File

@@ -215,9 +215,9 @@ export default class Downloads extends React.Component<IProps, IState> {
<div className="DownloadMenuSection" id="downloadMenuContainerGCFullBuild">
<div className="DownloadLabel" id="downloadMenuLabelGCFullBuild">
<Tr
text={this.state.grasscutter_set ? 'downloads.grasscutter_full_build' : 'downloads.grasscutter_full_build_update'}
text={this.state.grasscutter_set ? 'downloads.grasscutter_fullbuild' : 'downloads.grasscutter_fullbuild_update'}
/>
<HelpButton contents="help.gc_full_build" />
<HelpButton contents="help.gc_fullbuild" />
</div>
<div className="DownloadValue" id="downloadMenuButtonGCFullBuild">
<BigButton

View File

@@ -40,8 +40,7 @@ export default class NewsSection extends React.Component<IProps, IState> {
super(props)
this.state = {
// Set to commits since latest doesn't show any real info anyways
selected: 'commits',
selected: props.selected || 'commits',
}
this.setSelected = this.setSelected.bind(this)