From 31a4b4ee89a8aa95d2fae49cdb117f1cdd562169 Mon Sep 17 00:00:00 2001 From: SKairinos Date: Wed, 23 Oct 2024 14:17:47 +0000 Subject: [PATCH] rename env to settings --- src/app/hooks.tsx | 2 +- src/app/{env.ts => settings.ts} | 4 ++-- src/components/Header.tsx | 2 +- src/pages/agreementSignatures/AgreementSignatureTable.tsx | 2 +- src/pages/agreementSignatures/SignLatestAgreementForm.tsx | 2 +- src/pages/home/Home.tsx | 2 +- yarn.lock | 8 ++++---- 7 files changed, 11 insertions(+), 11 deletions(-) rename src/app/{env.ts => settings.ts} (68%) diff --git a/src/app/hooks.tsx b/src/app/hooks.tsx index 5c14134..6a3345e 100644 --- a/src/app/hooks.tsx +++ b/src/app/hooks.tsx @@ -8,7 +8,7 @@ import { type ReactNode, useEffect } from "react" import { createSearchParams, useLocation, useNavigate } from "react-router-dom" import { useDispatch, useSelector } from "react-redux" import Cookies from "js-cookie" -import { SESSION_METADATA_COOKIE_NAME } from "codeforlife/env" +import { SESSION_METADATA_COOKIE_NAME } from "codeforlife/settings" import { selectIsLoggedIn } from "codeforlife/slices/session" import type { AppDispatch, RootState } from "./store" diff --git a/src/app/env.ts b/src/app/settings.ts similarity index 68% rename from src/app/env.ts rename to src/app/settings.ts index b2c991a..fb04fb5 100644 --- a/src/app/env.ts +++ b/src/app/settings.ts @@ -1,6 +1,6 @@ -import env from "codeforlife/env" +import env from "codeforlife/settings" -export * from "codeforlife/env" +export * from "codeforlife/settings" export const LINK_CFL = env.VITE_LINK_CFL export const LINK_GH_LOGIN = env.VITE_LINK_GH_LOGIN diff --git a/src/components/Header.tsx b/src/components/Header.tsx index f214f6b..6e7475b 100644 --- a/src/components/Header.tsx +++ b/src/components/Header.tsx @@ -6,7 +6,7 @@ import { handleResultState } from "codeforlife/utils/api" import { type SessionMetadata, useSessionMetadata } from "../app/hooks" import CflLogoImage from "../images/cfl_logo.png" -import { LINK_CFL } from "../app/env" +import { LINK_CFL } from "../app/settings" import { useLogoutMutation } from "../api" import { useRetrieveContributorQuery } from "../api/contributor" diff --git a/src/pages/agreementSignatures/AgreementSignatureTable.tsx b/src/pages/agreementSignatures/AgreementSignatureTable.tsx index 735597c..905c3bd 100644 --- a/src/pages/agreementSignatures/AgreementSignatureTable.tsx +++ b/src/pages/agreementSignatures/AgreementSignatureTable.tsx @@ -15,7 +15,7 @@ import { LinkIconButton } from "codeforlife/components/router" import { OpenInNew as OpenInNewIcon } from "@mui/icons-material" import { TablePagination } from "codeforlife/components" -import { LINK_GH_CONTRIBUTING } from "../../app/env" +import { LINK_GH_CONTRIBUTING } from "../../app/settings" import { useLazyListAgreementSignaturesQuery } from "../../api/agreementSignature" export interface AgreementSignatureTableProps {} diff --git a/src/pages/agreementSignatures/SignLatestAgreementForm.tsx b/src/pages/agreementSignatures/SignLatestAgreementForm.tsx index fd7fb9d..47df3bf 100644 --- a/src/pages/agreementSignatures/SignLatestAgreementForm.tsx +++ b/src/pages/agreementSignatures/SignLatestAgreementForm.tsx @@ -6,7 +6,7 @@ import { PriorityHigh as PriorityHighIcon } from "@mui/icons-material" import { submitForm } from "codeforlife/utils/form" import { type AgreementSignature } from "../../api/agreementSignature" -import { LINK_GH_CONTRIBUTING } from "../../app/env" +import { LINK_GH_CONTRIBUTING } from "../../app/settings" import { useCreateAgreementSignatureMutation } from "../../api/agreementSignature" export interface SignLatestAgreementFormProps { diff --git a/src/pages/home/Home.tsx b/src/pages/home/Home.tsx index 7f8513a..e9367e9 100644 --- a/src/pages/home/Home.tsx +++ b/src/pages/home/Home.tsx @@ -11,7 +11,7 @@ import { GitHub as GitHubIcon } from "@mui/icons-material" import { Image } from "codeforlife/components" import { LinkButton } from "codeforlife/components/router" -import { LINK_CFL, LINK_GH_LOGIN } from "../../app/env" +import { LINK_CFL, LINK_GH_LOGIN } from "../../app/settings" import CflLogoImage from "../../images/cfl_logo.png" import { paths } from "../../routes" import { useLoginMutation } from "../../api/session" diff --git a/yarn.lock b/yarn.lock index 0927d7c..6c23fab 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1773,9 +1773,9 @@ undici-types "~6.19.2" "@types/node@^20.14.2": - version "20.16.15" - resolved "https://registry.yarnpkg.com/@types/node/-/node-20.16.15.tgz#826f97ca53a213d190124ca6a972206f06a88b69" - integrity sha512-DV58qQz9dBMqVVn+qnKwGa51QzCD4YM/tQM16qLKxdf5tqz5W4QwtrMzjSTbabN1cFTSuyxVYBy+QWHjWW8X/g== + version "20.17.0" + resolved "https://registry.yarnpkg.com/@types/node/-/node-20.17.0.tgz#d0620ba0fe4cf2a0f12351c7bdd805fc4e1f036b" + integrity sha512-a7zRo0f0eLo9K5X9Wp5cAqTUNGzuFLDG2R7C4HY2BhcMAsxgSPuRvAC1ZB6QkuUQXf0YZAgfOX2ZyrBa2n4nHQ== dependencies: undici-types "~6.19.2" @@ -2596,7 +2596,7 @@ clsx@^2.1.0, clsx@^2.1.1: "codeforlife@github:ocadotechnology/codeforlife-package-javascript#contributor-frontend-11": version "2.4.1" - resolved "https://codeload.github.com/ocadotechnology/codeforlife-package-javascript/tar.gz/b9c8ab0a61ea009fd8dafa252cf8367bc24ef008" + resolved "https://codeload.github.com/ocadotechnology/codeforlife-package-javascript/tar.gz/baff529ec56e81ecf121eb6ea90d2327b0558f0c" dependencies: "@emotion/react" "^11.10.6" "@emotion/styled" "^11.10.6"