diff options
| author | FifthWit <fifthwitbusiness@gmail.com> | 2025-01-30 10:44:30 -0600 |
|---|---|---|
| committer | FifthWit <fifthwitbusiness@gmail.com> | 2025-01-30 10:44:30 -0600 |
| commit | e40f07211f5f15dcb138e2520a76d13afd3c0cfd (patch) | |
| tree | 46bad6a17e66d55a4a65088c0b6eb8c48641615a /frontend/src/types | |
| parent | added prettier for more consistency (diff) | |
| download | lphub-e40f07211f5f15dcb138e2520a76d13afd3c0cfd.tar.gz lphub-e40f07211f5f15dcb138e2520a76d13afd3c0cfd.tar.bz2 lphub-e40f07211f5f15dcb138e2520a76d13afd3c0cfd.zip | |
formatted with prettier
Diffstat (limited to 'frontend/src/types')
| -rw-r--r-- | frontend/src/types/Chapters.ts | 22 | ||||
| -rw-r--r-- | frontend/src/types/Content.ts | 8 | ||||
| -rw-r--r-- | frontend/src/types/Game.ts | 13 | ||||
| -rw-r--r-- | frontend/src/types/Map.ts | 36 | ||||
| -rw-r--r-- | frontend/src/types/MapNames.ts | 220 | ||||
| -rw-r--r-- | frontend/src/types/Pagination.ts | 2 | ||||
| -rw-r--r-- | frontend/src/types/Profile.ts | 21 | ||||
| -rw-r--r-- | frontend/src/types/Ranking.ts | 40 | ||||
| -rw-r--r-- | frontend/src/types/Search.ts | 6 |
9 files changed, 183 insertions, 185 deletions
diff --git a/frontend/src/types/Chapters.ts b/frontend/src/types/Chapters.ts index 1d48306..8924b97 100644 --- a/frontend/src/types/Chapters.ts +++ b/frontend/src/types/Chapters.ts | |||
| @@ -1,19 +1,19 @@ | |||
| 1 | import type { Game } from "@customTypes/Game"; | 1 | import type { Game } from '@customTypes/Game'; |
| 2 | import type { Map } from "@customTypes/Map"; | 2 | import type { Map } from '@customTypes/Map'; |
| 3 | 3 | ||
| 4 | interface Chapter { | 4 | interface Chapter { |
| 5 | id: number; | 5 | id: number; |
| 6 | name: string; | 6 | name: string; |
| 7 | image: string; | 7 | image: string; |
| 8 | is_disabled: boolean; | 8 | is_disabled: boolean; |
| 9 | } | 9 | } |
| 10 | 10 | ||
| 11 | export interface GameChapter { | 11 | export interface GameChapter { |
| 12 | chapter: Chapter; | 12 | chapter: Chapter; |
| 13 | maps: Map[]; | 13 | maps: Map[]; |
| 14 | } | 14 | } |
| 15 | 15 | ||
| 16 | export interface GamesChapters { | 16 | export interface GamesChapters { |
| 17 | game: Game; | 17 | game: Game; |
| 18 | chapters: Chapter[]; | 18 | chapters: Chapter[]; |
| 19 | } \ No newline at end of file | 19 | } |
diff --git a/frontend/src/types/Content.ts b/frontend/src/types/Content.ts index 775fab4..77b3970 100644 --- a/frontend/src/types/Content.ts +++ b/frontend/src/types/Content.ts | |||
| @@ -6,18 +6,18 @@ export interface ModMenuContent { | |||
| 6 | showcase: string; | 6 | showcase: string; |
| 7 | description: string; | 7 | description: string; |
| 8 | category_id: number; | 8 | category_id: number; |
| 9 | }; | 9 | } |
| 10 | 10 | ||
| 11 | export interface MapDiscussionContent { | 11 | export interface MapDiscussionContent { |
| 12 | title: string; | 12 | title: string; |
| 13 | content: string; | 13 | content: string; |
| 14 | }; | 14 | } |
| 15 | 15 | ||
| 16 | export interface MapDiscussionCommentContent { | 16 | export interface MapDiscussionCommentContent { |
| 17 | comment: string; | 17 | comment: string; |
| 18 | }; | 18 | } |
| 19 | 19 | ||
| 20 | export interface UploadRunContent { | 20 | export interface UploadRunContent { |
| 21 | host_demo: File | null; | 21 | host_demo: File | null; |
| 22 | partner_demo: File | null; | 22 | partner_demo: File | null; |
| 23 | }; | 23 | } |
diff --git a/frontend/src/types/Game.ts b/frontend/src/types/Game.ts index 1a80341..be2cd73 100644 --- a/frontend/src/types/Game.ts +++ b/frontend/src/types/Game.ts | |||
| @@ -1,37 +1,36 @@ | |||
| 1 | import type { Map } from '@customTypes/Map'; | 1 | import type { Map } from '@customTypes/Map'; |
| 2 | 2 | ||
| 3 | |||
| 4 | export interface Game { | 3 | export interface Game { |
| 5 | id: number; | 4 | id: number; |
| 6 | name: string; | 5 | name: string; |
| 7 | image: string; | 6 | image: string; |
| 8 | is_coop: boolean; | 7 | is_coop: boolean; |
| 9 | category_portals: GameCategoryPortals[]; | 8 | category_portals: GameCategoryPortals[]; |
| 10 | }; | 9 | } |
| 11 | 10 | ||
| 12 | export interface GameChapters { | 11 | export interface GameChapters { |
| 13 | game: Game; | 12 | game: Game; |
| 14 | chapters: Chapter[]; | 13 | chapters: Chapter[]; |
| 15 | }; | 14 | } |
| 16 | 15 | ||
| 17 | export interface GameMaps { | 16 | export interface GameMaps { |
| 18 | game: Game; | 17 | game: Game; |
| 19 | maps: Map[]; | 18 | maps: Map[]; |
| 20 | }; | 19 | } |
| 21 | 20 | ||
| 22 | export interface Category { | 21 | export interface Category { |
| 23 | id: number; | 22 | id: number; |
| 24 | name: string; | 23 | name: string; |
| 25 | }; | 24 | } |
| 26 | 25 | ||
| 27 | interface Chapter { | 26 | interface Chapter { |
| 28 | id: number; | 27 | id: number; |
| 29 | name: string; | 28 | name: string; |
| 30 | image: string; | 29 | image: string; |
| 31 | is_disabled: boolean; | 30 | is_disabled: boolean; |
| 32 | }; | 31 | } |
| 33 | 32 | ||
| 34 | export interface GameCategoryPortals { | 33 | export interface GameCategoryPortals { |
| 35 | category: Category; | 34 | category: Category; |
| 36 | portal_count: number; | 35 | portal_count: number; |
| 37 | }; | 36 | } |
diff --git a/frontend/src/types/Map.ts b/frontend/src/types/Map.ts index 89c66d5..6bc6369 100644 --- a/frontend/src/types/Map.ts +++ b/frontend/src/types/Map.ts | |||
| @@ -9,15 +9,15 @@ export interface Map { | |||
| 9 | is_disabled: boolean; | 9 | is_disabled: boolean; |
| 10 | difficulty: number; | 10 | difficulty: number; |
| 11 | category_portals: GameCategoryPortals[]; | 11 | category_portals: GameCategoryPortals[]; |
| 12 | }; | 12 | } |
| 13 | 13 | ||
| 14 | export interface MapDiscussion { | 14 | export interface MapDiscussion { |
| 15 | discussion: MapDiscussionsDetail; | 15 | discussion: MapDiscussionsDetail; |
| 16 | }; | 16 | } |
| 17 | 17 | ||
| 18 | export interface MapDiscussions { | 18 | export interface MapDiscussions { |
| 19 | discussions: MapDiscussionsDetail[]; | 19 | discussions: MapDiscussionsDetail[]; |
| 20 | }; | 20 | } |
| 21 | 21 | ||
| 22 | export interface MapDiscussionsDetail { | 22 | export interface MapDiscussionsDetail { |
| 23 | id: number; | 23 | id: number; |
| @@ -27,22 +27,24 @@ export interface MapDiscussionsDetail { | |||
| 27 | comments: MapDiscussionDetailComment[]; | 27 | comments: MapDiscussionDetailComment[]; |
| 28 | created_at: string; | 28 | created_at: string; |
| 29 | updated_at: string; | 29 | updated_at: string; |
| 30 | }; | 30 | } |
| 31 | 31 | ||
| 32 | interface MapDiscussionDetailComment { | 32 | interface MapDiscussionDetailComment { |
| 33 | comment: string; | 33 | comment: string; |
| 34 | date: string; | 34 | date: string; |
| 35 | user: UserShort; | 35 | user: UserShort; |
| 36 | }; | 36 | } |
| 37 | 37 | ||
| 38 | export interface MapLeaderboard { | 38 | export interface MapLeaderboard { |
| 39 | map: MapSummaryMap; | 39 | map: MapSummaryMap; |
| 40 | records: MapLeaderboardRecordSingleplayer[] | MapLeaderboardRecordMultiplayer[]; | 40 | records: |
| 41 | | MapLeaderboardRecordSingleplayer[] | ||
| 42 | | MapLeaderboardRecordMultiplayer[]; | ||
| 41 | pagination: Pagination; | 43 | pagination: Pagination; |
| 42 | }; | 44 | } |
| 43 | 45 | ||
| 44 | export interface MapLeaderboardRecordSingleplayer { | 46 | export interface MapLeaderboardRecordSingleplayer { |
| 45 | kind: "singleplayer"; | 47 | kind: 'singleplayer'; |
| 46 | placement: number; | 48 | placement: number; |
| 47 | record_id: number; | 49 | record_id: number; |
| 48 | score_count: number; | 50 | score_count: number; |
| @@ -50,10 +52,10 @@ export interface MapLeaderboardRecordSingleplayer { | |||
| 50 | user: UserShort; | 52 | user: UserShort; |
| 51 | demo_id: string; | 53 | demo_id: string; |
| 52 | record_date: string; | 54 | record_date: string; |
| 53 | }; | 55 | } |
| 54 | 56 | ||
| 55 | export interface MapLeaderboardRecordMultiplayer { | 57 | export interface MapLeaderboardRecordMultiplayer { |
| 56 | kind: "multiplayer"; | 58 | kind: 'multiplayer'; |
| 57 | placement: number; | 59 | placement: number; |
| 58 | record_id: number; | 60 | record_id: number; |
| 59 | score_count: number; | 61 | score_count: number; |
| @@ -63,13 +65,12 @@ export interface MapLeaderboardRecordMultiplayer { | |||
| 63 | host_demo_id: string; | 65 | host_demo_id: string; |
| 64 | partner_demo_id: string; | 66 | partner_demo_id: string; |
| 65 | record_date: string; | 67 | record_date: string; |
| 66 | }; | 68 | } |
| 67 | |||
| 68 | 69 | ||
| 69 | export interface MapSummary { | 70 | export interface MapSummary { |
| 70 | map: MapSummaryMap; | 71 | map: MapSummaryMap; |
| 71 | summary: MapSummaryDetails; | 72 | summary: MapSummaryDetails; |
| 72 | }; | 73 | } |
| 73 | 74 | ||
| 74 | interface MapSummaryMap { | 75 | interface MapSummaryMap { |
| 75 | id: number; | 76 | id: number; |
| @@ -79,11 +80,11 @@ interface MapSummaryMap { | |||
| 79 | map_name: string; | 80 | map_name: string; |
| 80 | is_coop: boolean; | 81 | is_coop: boolean; |
| 81 | is_disabled: boolean; | 82 | is_disabled: boolean; |
| 82 | }; | 83 | } |
| 83 | 84 | ||
| 84 | interface MapSummaryDetails { | 85 | interface MapSummaryDetails { |
| 85 | routes: MapSummaryDetailsRoute[]; | 86 | routes: MapSummaryDetailsRoute[]; |
| 86 | }; | 87 | } |
| 87 | 88 | ||
| 88 | interface MapSummaryDetailsRoute { | 89 | interface MapSummaryDetailsRoute { |
| 89 | route_id: number; | 90 | route_id: number; |
| @@ -93,16 +94,15 @@ interface MapSummaryDetailsRoute { | |||
| 93 | completion_count: number; | 94 | completion_count: number; |
| 94 | description: string; | 95 | description: string; |
| 95 | showcase: string; | 96 | showcase: string; |
| 96 | }; | 97 | } |
| 97 | 98 | ||
| 98 | interface MapSummaryDetailsRouteHistory { | 99 | interface MapSummaryDetailsRouteHistory { |
| 99 | runner_name: string; | 100 | runner_name: string; |
| 100 | score_count: number; | 101 | score_count: number; |
| 101 | date: string; | 102 | date: string; |
| 102 | }; | 103 | } |
| 103 | 104 | ||
| 104 | export interface MapDeleteEndpoint { | 105 | export interface MapDeleteEndpoint { |
| 105 | map_id: number; | 106 | map_id: number; |
| 106 | record_id: number; | 107 | record_id: number; |
| 107 | } | 108 | } |
| 108 | |||
diff --git a/frontend/src/types/MapNames.ts b/frontend/src/types/MapNames.ts index b6313e7..9ea9851 100644 --- a/frontend/src/types/MapNames.ts +++ b/frontend/src/types/MapNames.ts | |||
| @@ -1,127 +1,127 @@ | |||
| 1 | export const MapNames: { [key: string]: number } = { | 1 | export const MapNames: { [key: string]: number } = { |
| 2 | "sp_a1_intro1": 1, | 2 | sp_a1_intro1: 1, |
| 3 | "sp_a1_intro2": 2, | 3 | sp_a1_intro2: 2, |
| 4 | "sp_a1_intro3": 3, | 4 | sp_a1_intro3: 3, |
| 5 | "sp_a1_intro4": 4, | 5 | sp_a1_intro4: 4, |
| 6 | "sp_a1_intro5": 5, | 6 | sp_a1_intro5: 5, |
| 7 | "sp_a1_intro6": 6, | 7 | sp_a1_intro6: 6, |
| 8 | "sp_a1_intro7": 7, | 8 | sp_a1_intro7: 7, |
| 9 | "sp_a1_wakeup": 8, | 9 | sp_a1_wakeup: 8, |
| 10 | "sp_a2_intro": 9, | 10 | sp_a2_intro: 9, |
| 11 | 11 | ||
| 12 | "sp_a2_laser_intro": 10, | 12 | sp_a2_laser_intro: 10, |
| 13 | "sp_a2_laser_stairs": 11, | 13 | sp_a2_laser_stairs: 11, |
| 14 | "sp_a2_dual_lasers": 12, | 14 | sp_a2_dual_lasers: 12, |
| 15 | "sp_a2_laser_over_goo": 13, | 15 | sp_a2_laser_over_goo: 13, |
| 16 | "sp_a2_catapult_intro": 14, | 16 | sp_a2_catapult_intro: 14, |
| 17 | "sp_a2_trust_fling": 15, | 17 | sp_a2_trust_fling: 15, |
| 18 | "sp_a2_pit_flings": 16, | 18 | sp_a2_pit_flings: 16, |
| 19 | "sp_a2_fizzler_intro": 17, | 19 | sp_a2_fizzler_intro: 17, |
| 20 | 20 | ||
| 21 | "sp_a2_sphere_peek": 18, | 21 | sp_a2_sphere_peek: 18, |
| 22 | "sp_a2_ricochet": 19, | 22 | sp_a2_ricochet: 19, |
| 23 | "sp_a2_bridge_intro": 20, | 23 | sp_a2_bridge_intro: 20, |
| 24 | "sp_a2_bridge_the_gap": 21, | 24 | sp_a2_bridge_the_gap: 21, |
| 25 | "sp_a2_turret_intro": 22, | 25 | sp_a2_turret_intro: 22, |
| 26 | "sp_a2_laser_relays": 23, | 26 | sp_a2_laser_relays: 23, |
| 27 | "sp_a2_turret_blocker": 24, | 27 | sp_a2_turret_blocker: 24, |
| 28 | "sp_a2_laser_vs_turret": 25, | 28 | sp_a2_laser_vs_turret: 25, |
| 29 | "sp_a2_pull_the_rug": 26, | 29 | sp_a2_pull_the_rug: 26, |
| 30 | 30 | ||
| 31 | "sp_a2_column_blocker": 27, | 31 | sp_a2_column_blocker: 27, |
| 32 | "sp_a2_laser_chaining": 28, | 32 | sp_a2_laser_chaining: 28, |
| 33 | "sp_a2_triple_laser": 29, | 33 | sp_a2_triple_laser: 29, |
| 34 | "sp_a2_bts1": 30, | 34 | sp_a2_bts1: 30, |
| 35 | "sp_a2_bts2": 31, | 35 | sp_a2_bts2: 31, |
| 36 | 36 | ||
| 37 | "sp_a2_bts3": 32, | 37 | sp_a2_bts3: 32, |
| 38 | "sp_a2_bts4": 33, | 38 | sp_a2_bts4: 33, |
| 39 | "sp_a2_bts5": 34, | 39 | sp_a2_bts5: 34, |
| 40 | "sp_a2_core": 35, | 40 | sp_a2_core: 35, |
| 41 | 41 | ||
| 42 | "sp_a3_01": 36, | 42 | sp_a3_01: 36, |
| 43 | "sp_a3_03": 37, | 43 | sp_a3_03: 37, |
| 44 | "sp_a3_jump_intro": 38, | 44 | sp_a3_jump_intro: 38, |
| 45 | "sp_a3_bomb_flings": 39, | 45 | sp_a3_bomb_flings: 39, |
| 46 | "sp_a3_crazy_box": 40, | 46 | sp_a3_crazy_box: 40, |
| 47 | "sp_a3_transition01": 41, | 47 | sp_a3_transition01: 41, |
| 48 | 48 | ||
| 49 | "sp_a3_speed_ramp": 42, | 49 | sp_a3_speed_ramp: 42, |
| 50 | "sp_a3_speed_flings": 43, | 50 | sp_a3_speed_flings: 43, |
| 51 | "sp_a3_portal_intro": 44, | 51 | sp_a3_portal_intro: 44, |
| 52 | "sp_a3_end": 45, | 52 | sp_a3_end: 45, |
| 53 | 53 | ||
| 54 | "sp_a4_intro": 46, | 54 | sp_a4_intro: 46, |
| 55 | "sp_a4_tb_intro": 47, | 55 | sp_a4_tb_intro: 47, |
| 56 | "sp_a4_tb_trust_drop": 48, | 56 | sp_a4_tb_trust_drop: 48, |
| 57 | "sp_a4_tb_wall_button": 49, | 57 | sp_a4_tb_wall_button: 49, |
| 58 | "sp_a4_tb_polarity": 50, | 58 | sp_a4_tb_polarity: 50, |
| 59 | "sp_a4_tb_catch": 51, | 59 | sp_a4_tb_catch: 51, |
| 60 | "sp_a4_stop_the_box": 52, | 60 | sp_a4_stop_the_box: 52, |
| 61 | "sp_a4_laser_catapult": 53, | 61 | sp_a4_laser_catapult: 53, |
| 62 | "sp_a4_laser_platform": 54, | 62 | sp_a4_laser_platform: 54, |
| 63 | "sp_a4_speed_tb_catch": 55, | 63 | sp_a4_speed_tb_catch: 55, |
| 64 | "sp_a4_jump_polarity": 56, | 64 | sp_a4_jump_polarity: 56, |
| 65 | 65 | ||
| 66 | "sp_a4_finale1": 57, | 66 | sp_a4_finale1: 57, |
| 67 | "sp_a4_finale2": 58, | 67 | sp_a4_finale2: 58, |
| 68 | "sp_a4_finale3": 59, | 68 | sp_a4_finale3: 59, |
| 69 | "sp_a4_finale4": 60, | 69 | sp_a4_finale4: 60, |
| 70 | 70 | ||
| 71 | "mp_coop_start": 61, | 71 | mp_coop_start: 61, |
| 72 | "mp_coop_lobby_3": 62, | 72 | mp_coop_lobby_3: 62, |
| 73 | 73 | ||
| 74 | "mp_coop_doors": 63, | 74 | mp_coop_doors: 63, |
| 75 | "mp_coop_race_2": 64, | 75 | mp_coop_race_2: 64, |
| 76 | "mp_coop_laser_2": 65, | 76 | mp_coop_laser_2: 65, |
| 77 | "mp_coop_rat_maze": 66, | 77 | mp_coop_rat_maze: 66, |
| 78 | "mp_coop_laser_crusher": 67, | 78 | mp_coop_laser_crusher: 67, |
| 79 | "mp_coop_teambts": 68, | 79 | mp_coop_teambts: 68, |
| 80 | 80 | ||
| 81 | "mp_coop_fling_3": 69, | 81 | mp_coop_fling_3: 69, |
| 82 | "mp_coop_infinifling_train": 70, | 82 | mp_coop_infinifling_train: 70, |
| 83 | "mp_coop_come_along": 71, | 83 | mp_coop_come_along: 71, |
| 84 | "mp_coop_fling_1": 72, | 84 | mp_coop_fling_1: 72, |
| 85 | "mp_coop_catapult_1": 73, | 85 | mp_coop_catapult_1: 73, |
| 86 | "mp_coop_multifling_1": 74, | 86 | mp_coop_multifling_1: 74, |
| 87 | "mp_coop_fling_crushers": 75, | 87 | mp_coop_fling_crushers: 75, |
| 88 | "mp_coop_fan": 76, | 88 | mp_coop_fan: 76, |
| 89 | 89 | ||
| 90 | "mp_coop_wall_intro": 77, | 90 | mp_coop_wall_intro: 77, |
| 91 | "mp_coop_wall_2": 78, | 91 | mp_coop_wall_2: 78, |
| 92 | "mp_coop_catapult_wall_intro": 79, | 92 | mp_coop_catapult_wall_intro: 79, |
| 93 | "mp_coop_wall_block": 80, | 93 | mp_coop_wall_block: 80, |
| 94 | "mp_coop_catapult_2": 81, | 94 | mp_coop_catapult_2: 81, |
| 95 | "mp_coop_turret_walls": 82, | 95 | mp_coop_turret_walls: 82, |
| 96 | "mp_coop_turret_ball": 83, | 96 | mp_coop_turret_ball: 83, |
| 97 | "mp_coop_wall_5": 84, | 97 | mp_coop_wall_5: 84, |
| 98 | 98 | ||
| 99 | "mp_coop_tbeam_redirect": 85, | 99 | mp_coop_tbeam_redirect: 85, |
| 100 | "mp_coop_tbeam_drill": 86, | 100 | mp_coop_tbeam_drill: 86, |
| 101 | "mp_coop_tbeam_catch_grind_1": 87, | 101 | mp_coop_tbeam_catch_grind_1: 87, |
| 102 | "mp_coop_tbeam_laser_1": 88, | 102 | mp_coop_tbeam_laser_1: 88, |
| 103 | "mp_coop_tbeam_polarity": 89, | 103 | mp_coop_tbeam_polarity: 89, |
| 104 | "mp_coop_tbeam_polarity2": 90, | 104 | mp_coop_tbeam_polarity2: 90, |
| 105 | "mp_coop_tbeam_polarity3": 91, | 105 | mp_coop_tbeam_polarity3: 91, |
| 106 | "mp_coop_tbeam_maze": 92, | 106 | mp_coop_tbeam_maze: 92, |
| 107 | "mp_coop_tbeam_end": 93, | 107 | mp_coop_tbeam_end: 93, |
| 108 | 108 | ||
| 109 | "mp_coop_paint_come_along": 94, | 109 | mp_coop_paint_come_along: 94, |
| 110 | "mp_coop_paint_redirect": 95, | 110 | mp_coop_paint_redirect: 95, |
| 111 | "mp_coop_paint_bridge": 96, | 111 | mp_coop_paint_bridge: 96, |
| 112 | "mp_coop_paint_walljumps": 97, | 112 | mp_coop_paint_walljumps: 97, |
| 113 | "mp_coop_paint_speed_fling": 98, | 113 | mp_coop_paint_speed_fling: 98, |
| 114 | "mp_coop_paint_red_racer": 99, | 114 | mp_coop_paint_red_racer: 99, |
| 115 | "mp_coop_paint_speed_catch": 100, | 115 | mp_coop_paint_speed_catch: 100, |
| 116 | "mp_coop_paint_longjump_intro": 101, | 116 | mp_coop_paint_longjump_intro: 101, |
| 117 | 117 | ||
| 118 | "mp_coop_separation_1": 102, | 118 | mp_coop_separation_1: 102, |
| 119 | "mp_coop_tripleaxis": 103, | 119 | mp_coop_tripleaxis: 103, |
| 120 | "mp_coop_catapult_catch": 104, | 120 | mp_coop_catapult_catch: 104, |
| 121 | "mp_coop_2paints_1bridge": 105, | 121 | mp_coop_2paints_1bridge: 105, |
| 122 | "mp_coop_paint_conversion": 106, | 122 | mp_coop_paint_conversion: 106, |
| 123 | "mp_coop_bridge_catch": 107, | 123 | mp_coop_bridge_catch: 107, |
| 124 | "mp_coop_laser_tbeam": 108, | 124 | mp_coop_laser_tbeam: 108, |
| 125 | "mp_coop_paint_rat_maze": 109, | 125 | mp_coop_paint_rat_maze: 109, |
| 126 | "mp_coop_paint_crazy_box": 110, | 126 | mp_coop_paint_crazy_box: 110, |
| 127 | }; | 127 | }; |
diff --git a/frontend/src/types/Pagination.ts b/frontend/src/types/Pagination.ts index ccff04b..18494eb 100644 --- a/frontend/src/types/Pagination.ts +++ b/frontend/src/types/Pagination.ts | |||
| @@ -3,4 +3,4 @@ export interface Pagination { | |||
| 3 | total_pages: number; | 3 | total_pages: number; |
| 4 | current_page: number; | 4 | current_page: number; |
| 5 | page_size: number; | 5 | page_size: number; |
| 6 | }; | 6 | } |
diff --git a/frontend/src/types/Profile.ts b/frontend/src/types/Profile.ts index 42e5c3e..8051ae5 100644 --- a/frontend/src/types/Profile.ts +++ b/frontend/src/types/Profile.ts | |||
| @@ -1,10 +1,10 @@ | |||
| 1 | import type { Pagination } from "@customTypes/Pagination"; | 1 | import type { Pagination } from '@customTypes/Pagination'; |
| 2 | 2 | ||
| 3 | export interface UserShort { | 3 | export interface UserShort { |
| 4 | steam_id: string; | 4 | steam_id: string; |
| 5 | user_name: string; | 5 | user_name: string; |
| 6 | avatar_link: string; | 6 | avatar_link: string; |
| 7 | }; | 7 | } |
| 8 | 8 | ||
| 9 | export interface UserProfile { | 9 | export interface UserProfile { |
| 10 | profile: boolean; | 10 | profile: boolean; |
| @@ -17,25 +17,25 @@ export interface UserProfile { | |||
| 17 | rankings: UserProfileRankings; | 17 | rankings: UserProfileRankings; |
| 18 | records: UserProfileRecords[]; | 18 | records: UserProfileRecords[]; |
| 19 | pagination: Pagination; | 19 | pagination: Pagination; |
| 20 | }; | 20 | } |
| 21 | 21 | ||
| 22 | interface UserProfileTitles { | 22 | interface UserProfileTitles { |
| 23 | name: string; | 23 | name: string; |
| 24 | color: string; | 24 | color: string; |
| 25 | }; | 25 | } |
| 26 | 26 | ||
| 27 | interface UserProfileLinks { | 27 | interface UserProfileLinks { |
| 28 | p2sr: string; | 28 | p2sr: string; |
| 29 | steam: string; | 29 | steam: string; |
| 30 | youtube: string; | 30 | youtube: string; |
| 31 | twitch: string; | 31 | twitch: string; |
| 32 | }; | 32 | } |
| 33 | 33 | ||
| 34 | interface UserProfileRankings { | 34 | interface UserProfileRankings { |
| 35 | overall: UserProfileRankingsDetail; | 35 | overall: UserProfileRankingsDetail; |
| 36 | singleplayer: UserProfileRankingsDetail; | 36 | singleplayer: UserProfileRankingsDetail; |
| 37 | cooperative: UserProfileRankingsDetail; | 37 | cooperative: UserProfileRankingsDetail; |
| 38 | }; | 38 | } |
| 39 | 39 | ||
| 40 | interface UserProfileRecords { | 40 | interface UserProfileRecords { |
| 41 | game_id: number; | 41 | game_id: number; |
| @@ -44,8 +44,8 @@ interface UserProfileRecords { | |||
| 44 | map_name: string; | 44 | map_name: string; |
| 45 | map_wr_count: number; | 45 | map_wr_count: number; |
| 46 | placement: number; | 46 | placement: number; |
| 47 | scores: UserProfileRecordsScores[] | 47 | scores: UserProfileRecordsScores[]; |
| 48 | }; | 48 | } |
| 49 | 49 | ||
| 50 | interface UserProfileRecordsScores { | 50 | interface UserProfileRecordsScores { |
| 51 | record_id: number; | 51 | record_id: number; |
| @@ -53,11 +53,10 @@ interface UserProfileRecordsScores { | |||
| 53 | score_count: number; | 53 | score_count: number; |
| 54 | score_time: number; | 54 | score_time: number; |
| 55 | date: string; | 55 | date: string; |
| 56 | }; | 56 | } |
| 57 | 57 | ||
| 58 | interface UserProfileRankingsDetail { | 58 | interface UserProfileRankingsDetail { |
| 59 | rank: number; | 59 | rank: number; |
| 60 | completion_count: number; | 60 | completion_count: number; |
| 61 | completion_total: number; | 61 | completion_total: number; |
| 62 | }; | 62 | } |
| 63 | |||
diff --git a/frontend/src/types/Ranking.ts b/frontend/src/types/Ranking.ts index a143355..06a5ca4 100644 --- a/frontend/src/types/Ranking.ts +++ b/frontend/src/types/Ranking.ts | |||
| @@ -1,31 +1,31 @@ | |||
| 1 | import type { UserShort } from "@customTypes/Profile"; | 1 | import type { UserShort } from '@customTypes/Profile'; |
| 2 | 2 | ||
| 3 | export interface RankingType { | 3 | export interface RankingType { |
| 4 | placement: number; | 4 | placement: number; |
| 5 | user: UserShort; | 5 | user: UserShort; |
| 6 | total_score: number; | 6 | total_score: number; |
| 7 | } | 7 | } |
| 8 | 8 | ||
| 9 | export interface SteamRankingType { | 9 | export interface SteamRankingType { |
| 10 | user_name: string; | 10 | user_name: string; |
| 11 | avatar_link: string; | 11 | avatar_link: string; |
| 12 | steam_id: string; | 12 | steam_id: string; |
| 13 | sp_score: number; | 13 | sp_score: number; |
| 14 | mp_score: number; | 14 | mp_score: number; |
| 15 | overall_score: number; | 15 | overall_score: number; |
| 16 | sp_rank: number; | 16 | sp_rank: number; |
| 17 | mp_rank: number; | 17 | mp_rank: number; |
| 18 | overall_rank: number; | 18 | overall_rank: number; |
| 19 | } | 19 | } |
| 20 | 20 | ||
| 21 | export interface Ranking { | 21 | export interface Ranking { |
| 22 | rankings_overall: RankingType[]; | 22 | rankings_overall: RankingType[]; |
| 23 | rankings_singleplayer: RankingType[]; | 23 | rankings_singleplayer: RankingType[]; |
| 24 | rankings_multiplayer: RankingType[]; | 24 | rankings_multiplayer: RankingType[]; |
| 25 | } | 25 | } |
| 26 | 26 | ||
| 27 | export interface SteamRanking { | 27 | export interface SteamRanking { |
| 28 | rankings_overall: SteamRankingType[]; | 28 | rankings_overall: SteamRankingType[]; |
| 29 | rankings_singleplayer: SteamRankingType[]; | 29 | rankings_singleplayer: SteamRankingType[]; |
| 30 | rankings_multiplayer: SteamRankingType[]; | 30 | rankings_multiplayer: SteamRankingType[]; |
| 31 | } \ No newline at end of file | 31 | } |
diff --git a/frontend/src/types/Search.ts b/frontend/src/types/Search.ts index d218806..48b9169 100644 --- a/frontend/src/types/Search.ts +++ b/frontend/src/types/Search.ts | |||
| @@ -1,13 +1,13 @@ | |||
| 1 | import type { UserShort } from "@customTypes/Profile"; | 1 | import type { UserShort } from '@customTypes/Profile'; |
| 2 | 2 | ||
| 3 | export interface Search { | 3 | export interface Search { |
| 4 | players: UserShort[]; | 4 | players: UserShort[]; |
| 5 | maps: SearchMap[]; | 5 | maps: SearchMap[]; |
| 6 | }; | 6 | } |
| 7 | 7 | ||
| 8 | interface SearchMap { | 8 | interface SearchMap { |
| 9 | id: number; | 9 | id: number; |
| 10 | game: string; | 10 | game: string; |
| 11 | chapter: string; | 11 | chapter: string; |
| 12 | map: string; | 12 | map: string; |
| 13 | }; | 13 | } |