- {[app_store_btn, play_market_btn].map((app) => (
-
+ {[app_store_btn, play_market_btn].map((app, i) => (
+
))}
diff --git a/src/Widgets/Header/HeaderLink/HeaderLink.scss b/src/Widgets/Header/HeaderLink/HeaderLink.scss
index 70fe221..ebfe110 100644
--- a/src/Widgets/Header/HeaderLink/HeaderLink.scss
+++ b/src/Widgets/Header/HeaderLink/HeaderLink.scss
@@ -7,6 +7,9 @@
font-size: 20px;
font-weight: 500;
line-height: 24px;
+ display: flex;
+ justify-content: center;
+ align-items: center;
gap: 30px;
border-radius: 15px;
background-color: #fff;
diff --git a/src/Widgets/MapSection/mapSectionStore.ts b/src/Widgets/MapSection/mapSectionStore.ts
index d05780e..5b45a60 100644
--- a/src/Widgets/MapSection/mapSectionStore.ts
+++ b/src/Widgets/MapSection/mapSectionStore.ts
@@ -1,8 +1,7 @@
-import { baseAPI } from "@/shared/api/baseAPI";
+import { apiInstance } from "@/shared/config/apiConfig";
import { IFetch } from "@/shared/types/fetch-type";
import { IList } from "@/shared/types/list-type";
import { IReport } from "@/shared/types/report-type";
-import axios from "axios";
import { create } from "zustand";
interface IFetchReports extends IList {
@@ -27,8 +26,8 @@ export const useMapStore = create
((set) => ({
try {
set({ isLoading: true });
- const response = await axios.get(
- `${baseAPI}/report/?category=${categories}`
+ const response = await apiInstance.get(
+ `/report/?category=${categories}`
);
set({ data: response.data });
diff --git a/src/Widgets/Navbar/Navbar.scss b/src/Widgets/Navbar/Navbar.scss
index 17ff677..55b65e9 100644
--- a/src/Widgets/Navbar/Navbar.scss
+++ b/src/Widgets/Navbar/Navbar.scss
@@ -12,7 +12,7 @@
background-color: #fff;
&__links {
- height: 60%;
+ height: 40%;
display: flex;
gap: 60px;
}
diff --git a/src/Widgets/NewsSection/newsSectionStore.ts b/src/Widgets/NewsSection/newsSectionStore.ts
index ee23c0c..a4e669a 100644
--- a/src/Widgets/NewsSection/newsSectionStore.ts
+++ b/src/Widgets/NewsSection/newsSectionStore.ts
@@ -1,4 +1,4 @@
-import { baseAPI } from "@/shared/api/baseAPI";
+import { apiInstance } from "@/shared/config/apiConfig";
import { IList } from "@/shared/types/list-type";
import { INews } from "@/shared/types/news-type";
import axios, { AxiosError } from "axios";
@@ -9,8 +9,7 @@ interface IFetchNews extends IList {
export const getNews = async () => {
try {
- const data = (await axios.get(`${baseAPI}/news/`))
- .data;
+ const data = (await apiInstance.get("/news/")).data;
return data.results.slice(0, 4);
} catch (error: unknown) {
diff --git a/src/Widgets/RatingSection/ratingSectionStore.ts b/src/Widgets/RatingSection/ratingSectionStore.ts
index 3cf040b..bad7864 100644
--- a/src/Widgets/RatingSection/ratingSectionStore.ts
+++ b/src/Widgets/RatingSection/ratingSectionStore.ts
@@ -1,4 +1,4 @@
-import { baseAPI } from "@/shared/api/baseAPI";
+import { apiInstance } from "@/shared/config/apiConfig";
import { IFetch } from "@/shared/types/fetch-type";
import { IList } from "@/shared/types/list-type";
import { IReport } from "@/shared/types/report-type";
@@ -27,9 +27,8 @@ export const useRatingStore = create((set) => ({
try {
set({ isLoading: true });
- const data = (
- await axios.get(`${baseAPI}/report/`)
- ).data;
+ const data = (await apiInstance.get("/report/"))
+ .data;
const searched = data.results.filter((rating) => {
return rating.location.some((location) => {
diff --git a/src/Widgets/StatisticsSection/StatisticsSection.tsx b/src/Widgets/StatisticsSection/StatisticsSection.tsx
index ec19b4f..bb5f2d7 100644
--- a/src/Widgets/StatisticsSection/StatisticsSection.tsx
+++ b/src/Widgets/StatisticsSection/StatisticsSection.tsx
@@ -20,7 +20,7 @@ const StatisticsSection = async () => {