aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/packages/ui/src/types/bindings/fabric.ts
blob: 181f8be017f6fd53abb8105b31f0f23080c11ca6 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.

/**
 * Represents a Minecraft version supported by Fabric.
 */
export type FabricGameVersion = { version: string; stable: boolean };

/**
 * Represents a Fabric intermediary mapping version.
 */
export type FabricIntermediaryVersion = {
  maven: string;
  version: string;
  stable: boolean;
};

/**
 * Launcher metadata from Fabric Meta API.
 */
export type FabricLauncherMeta = {
  version: number;
  libraries: FabricLibraries;
  mainClass: FabricMainClass;
};

/**
 * Libraries required by Fabric loader.
 */
export type FabricLibraries = {
  client: Array<FabricLibrary>;
  common: Array<FabricLibrary>;
  server: Array<FabricLibrary>;
};

/**
 * A single Fabric library dependency.
 */
export type FabricLibrary = { name: string; url: string | null };

/**
 * Represents a combined loader + intermediary version entry.
 */
export type FabricLoaderEntry = {
  loader: FabricLoaderVersion;
  intermediary: FabricIntermediaryVersion;
  launcherMeta: FabricLauncherMeta;
};

/**
 * Represents a Fabric loader version from the Meta API.
 */
export type FabricLoaderVersion = {
  separator: string;
  build: number;
  maven: string;
  version: string;
  stable: boolean;
};

/**
 * Main class configuration for Fabric.
 * Can be either a struct with client/server fields or a simple string.
 */
export type FabricMainClass = { client: string; server: string } | string;

/**
 * Information about an installed Fabric version.
 */
export type InstalledFabricVersion = {
  id: string;
  minecraftVersion: string;
  loaderVersion: string;
  path: string;
};