From 42e9a05818323ca0543754f4136406c7fd0c5d42 Mon Sep 17 00:00:00 2001 From: Antonio De Lucreziis Date: Wed, 11 Jan 2023 12:37:46 +0100 Subject: [PATCH] fix: fixed some imports --- client/components/Problem.tsx | 3 ++- client/components/Solution.tsx | 3 ++- client/pages/ScoresPage.tsx | 2 +- client/pages/UserPage.tsx | 2 +- 4 files changed, 6 insertions(+), 4 deletions(-) diff --git a/client/components/Problem.tsx b/client/components/Problem.tsx index 8be8801..c0a84b7 100644 --- a/client/components/Problem.tsx +++ b/client/components/Problem.tsx @@ -1,4 +1,5 @@ -import { prependBaseUrl } from '../api' +import { prependBaseUrl } from '../../shared/utils' + import { Markdown } from './Markdown' type Props = { diff --git a/client/components/Solution.tsx b/client/components/Solution.tsx index ad7b910..4c7a01d 100644 --- a/client/components/Solution.tsx +++ b/client/components/Solution.tsx @@ -1,7 +1,8 @@ import { useState } from 'preact/hooks' import { JSX } from 'preact/jsx-runtime' import { ProblemId, Solution as SolutionModel, SolutionId, SolutionStatus, UserId } from '../../shared/model' -import { prependBaseUrl, server } from '../api' +import { prependBaseUrl } from '../../shared/utils' +import { server } from '../api' import { useCurrentUser } from '../hooks/useCurrentUser' import { Markdown } from './Markdown' diff --git a/client/pages/ScoresPage.tsx b/client/pages/ScoresPage.tsx index f3ffb81..56810cb 100644 --- a/client/pages/ScoresPage.tsx +++ b/client/pages/ScoresPage.tsx @@ -1,7 +1,7 @@ import { useContext, useState } from 'preact/hooks' import { SolutionStat } from '../../shared/model' import { sortByNumericKey, sortByStringKey } from '../../shared/utils' -import { prependBaseUrl } from '../api' +import { prependBaseUrl } from '../../shared/utils' import { Header } from '../components/Header' import { useResource, MetadataContext } from '../hooks' diff --git a/client/pages/UserPage.tsx b/client/pages/UserPage.tsx index d489a80..efc164e 100644 --- a/client/pages/UserPage.tsx +++ b/client/pages/UserPage.tsx @@ -1,6 +1,6 @@ import { isAdministrator, Solution as SolutionModel, SolutionStat } from '../../shared/model' import { sortByStringKey } from '../../shared/utils' -import { prependBaseUrl } from '../api' +import { prependBaseUrl } from '../../shared/utils' import { Header } from '../components/Header' import { Solution } from '../components/Solution' import { useResource } from '../hooks'