From 2e07eac74777165e889f026aab56054f006799ca Mon Sep 17 00:00:00 2001 From: "Kalle (Sendou)" <38327916+Sendouc@users.noreply.github.com> Date: Sat, 27 Nov 2021 03:02:45 +0200 Subject: [PATCH] Adjust imports --- app/constants.ts | 46 ++++++++++++++++++ app/routes/to/$organization.$tournament.tsx | 2 +- .../to/$organization.$tournament/map-pool.tsx | 4 +- .../to/$organization.$tournament/teams.tsx | 2 +- app/utils.ts | 47 ------------------- 5 files changed, 50 insertions(+), 51 deletions(-) create mode 100644 app/constants.ts diff --git a/app/constants.ts b/app/constants.ts new file mode 100644 index 000000000..9011c1f1e --- /dev/null +++ b/app/constants.ts @@ -0,0 +1,46 @@ +export const stages = [ + "The Reef", + "Musselforge Fitness", + "Starfish Mainstage", + "Humpback Pump Track", + "Inkblot Art Academy", + "Sturgeon Shipyard", + "Moray Towers", + "Port Mackerel", + "Manta Maria", + "Kelp Dome", + "Snapper Canal", + "Blackbelly Skatepark", + "MakoMart", + "Walleye Warehouse", + "Shellendorf Institute", + "Arowana Mall", + "Goby Arena", + "Piranha Pit", + "Camp Triggerfish", + "Wahoo World", + "New Albacore Hotel", + "Ancho-V Games", + "Skipper Pavilion", +]; + +export const modesShort = ["TW", "SZ", "TC", "RM", "CB"]; + +export const navItems = [ + { + title: "builds", + items: ["browse", "gear", "analyzer"], + }, + { + title: "play", + items: ["calendar", "battle", "Rankings"], + }, + { + title: "tools", + items: ["planner", "rotations", "top 500"], + }, + { + title: "misc", + items: ["badges", "links"], + }, +]; diff --git a/app/routes/to/$organization.$tournament.tsx b/app/routes/to/$organization.$tournament.tsx index ab6014ce5..4a5bb780d 100644 --- a/app/routes/to/$organization.$tournament.tsx +++ b/app/routes/to/$organization.$tournament.tsx @@ -15,7 +15,7 @@ import { makeTitle } from "~/utils"; import { findTournamentByNameForUrl, FindTournamentByNameForUrlI, -} from "../../services/tournament"; +} from "~/services/tournament"; import tournamentStylesUrl from "../../styles/tournament.css"; export const links: LinksFunction = () => { diff --git a/app/routes/to/$organization.$tournament/map-pool.tsx b/app/routes/to/$organization.$tournament/map-pool.tsx index d37113413..48c51c397 100644 --- a/app/routes/to/$organization.$tournament/map-pool.tsx +++ b/app/routes/to/$organization.$tournament/map-pool.tsx @@ -1,9 +1,9 @@ import stylesUrl from "~/styles/map-pool.css"; import type { Mode } from ".prisma/client"; import classNames from "classnames"; -import { modesShort, stages } from "~/utils"; +import { modesShort, stages } from "~/constants"; import { LinksFunction, useMatches } from "remix"; -import { FindTournamentByNameForUrlI } from "../../../services/tournament"; +import { FindTournamentByNameForUrlI } from "~/services/tournament"; export const links: LinksFunction = () => { return [{ rel: "stylesheet", href: stylesUrl }]; diff --git a/app/routes/to/$organization.$tournament/teams.tsx b/app/routes/to/$organization.$tournament/teams.tsx index 8b6a02c12..762d4869d 100644 --- a/app/routes/to/$organization.$tournament/teams.tsx +++ b/app/routes/to/$organization.$tournament/teams.tsx @@ -1,5 +1,5 @@ import { useMatches, LinksFunction } from "remix"; -import { FindTournamentByNameForUrlI } from "../../../services/tournament"; +import type { FindTournamentByNameForUrlI } from "~/services/tournament"; import stylesUrl from "~/styles/teams.css"; import { Fragment } from "react"; diff --git a/app/utils.ts b/app/utils.ts index 0b7652925..0a896973b 100644 --- a/app/utils.ts +++ b/app/utils.ts @@ -1,50 +1,3 @@ -export const stages = [ - "The Reef", - "Musselforge Fitness", - "Starfish Mainstage", - "Humpback Pump Track", - "Inkblot Art Academy", - "Sturgeon Shipyard", - "Moray Towers", - "Port Mackerel", - "Manta Maria", - "Kelp Dome", - "Snapper Canal", - "Blackbelly Skatepark", - "MakoMart", - "Walleye Warehouse", - "Shellendorf Institute", - "Arowana Mall", - "Goby Arena", - "Piranha Pit", - "Camp Triggerfish", - "Wahoo World", - "New Albacore Hotel", - "Ancho-V Games", - "Skipper Pavilion", -]; - -export const modesShort = ["TW", "SZ", "TC", "RM", "CB"]; - -export const navItems = [ - { - title: "builds", - items: ["browse", "gear", "analyzer"], - }, - { - title: "play", - items: ["calendar", "battle", "Rankings"], - }, - { - title: "tools", - items: ["planner", "rotations", "top 500"], - }, - { - title: "misc", - items: ["badges", "links"], - }, -]; - export const makeTitle = (endOfTitle: string) => `sendou.ink | ${endOfTitle}`; export type Serialized = {