News testing

This commit is contained in:
Thoronium
2023-02-25 21:00:57 -07:00
committed by GitHub
parent d6b1c7a613
commit ec611f9d7d
2 changed files with 1 additions and 4 deletions

View File

@@ -18,7 +18,6 @@ import { listen } from '@tauri-apps/api/event'
import { dataDir } from '@tauri-apps/api/path'
import { appWindow } from '@tauri-apps/api/window'
import { unpatchGame } from '../utils/metadata'
import { showNews } from './components/news/NewsSection'
import DownloadHandler from '../utils/download'
// Graphics
@@ -121,9 +120,6 @@ 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
showNews()
}
async openExtrasMenu(playGame: () => void) {

View File

@@ -50,6 +50,7 @@ export default class NewsSection extends React.Component<IProps, IState> {
componentDidMount() {
// Call showNews off the bat
this.showNews()
this.setSelected('commits')
}
setSelected(item: string) {