Look at description for changelog
- Wine support - Loading script - Format code - Hide downloads button on sidebar when not downloading - Add installs list - A lot of improvements & more
This commit is contained in:
12
src/types/DownloadedVersion.ts
Normal file
12
src/types/DownloadedVersion.ts
Normal file
@@ -0,0 +1,12 @@
|
||||
import { LauncherVersion } from './LauncherVersion'
|
||||
|
||||
export class DownloadedVersion {
|
||||
constructor (
|
||||
public version: LauncherVersion,
|
||||
public installDate: number = Date.now()
|
||||
) {}
|
||||
|
||||
static import (data: LauncherVersion) {
|
||||
return new DownloadedVersion(data)
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,7 @@
|
||||
import { DownloadProgress } from './DownloadProgress'
|
||||
import { LauncherVersion } from './LauncherVersion'
|
||||
import { NormalConfig } from './NormalConfig'
|
||||
import { VersionsConfig } from './VersionsConfig'
|
||||
|
||||
export type InstallsProps = {
|
||||
downloadProgress: DownloadProgress[]
|
||||
@@ -9,4 +11,6 @@ export type InstallsProps = {
|
||||
setFadeOut: (v: boolean) => void
|
||||
setSelectedVersionList: (v: LauncherVersion[]) => void
|
||||
setVersionList: (v: null | LauncherVersion[]) => void
|
||||
downloadedVersionsConfig: VersionsConfig | null
|
||||
normalConfig: NormalConfig | null
|
||||
}
|
||||
|
||||
@@ -2,6 +2,7 @@ export interface LauncherVersion {
|
||||
version: string
|
||||
displayName: string
|
||||
platforms: string[]
|
||||
downloadUrls: string[],
|
||||
downloadUrls: string[]
|
||||
executables: string[]
|
||||
id: number
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
export type SettingProps = {
|
||||
label: string
|
||||
value: boolean
|
||||
onChange: (val: boolean) => void,
|
||||
onChange: (val: boolean) => void
|
||||
className?: string
|
||||
}
|
||||
|
||||
5
src/types/SettingsProps.ts
Normal file
5
src/types/SettingsProps.ts
Normal file
@@ -0,0 +1,5 @@
|
||||
import { NormalConfig } from './NormalConfig'
|
||||
|
||||
export type SettingsProps = {
|
||||
normalConfig: NormalConfig | null
|
||||
}
|
||||
@@ -2,6 +2,6 @@ export class SettingsType {
|
||||
constructor (
|
||||
public checkForNewVersionOnLoad: boolean = true,
|
||||
public allowNotifications: boolean = true,
|
||||
public useWineOnUnixWhenNeeded: boolean = false,
|
||||
public useWineOnUnixWhenNeeded: boolean = false
|
||||
) {}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,8 @@
|
||||
import { DownloadProgress } from './DownloadProgress'
|
||||
|
||||
export type SidebarProps = {
|
||||
setShowPopup: (v: boolean) => void
|
||||
setPopupMode: (v: null | number) => void
|
||||
setFadeOut: (v: boolean) => void
|
||||
downloadProgress: DownloadProgress[]
|
||||
}
|
||||
|
||||
@@ -1,10 +1,7 @@
|
||||
import { LauncherVersion } from './LauncherVersion'
|
||||
import { DownloadedVersion } from './DownloadedVersion'
|
||||
|
||||
export class VersionsConfig {
|
||||
constructor (
|
||||
public version: string,
|
||||
public list: LauncherVersion[] = []
|
||||
) {}
|
||||
constructor (public version: string, public list: DownloadedVersion[] = []) {}
|
||||
|
||||
static import (data: any) {
|
||||
const cfg = new VersionsConfig(data.version)
|
||||
|
||||
Reference in New Issue
Block a user