From feb19c7f2d95ae668e6609cba61bb6bb41c18913 Mon Sep 17 00:00:00 2001 From: MJ_Akbari Date: Thu, 16 Oct 2025 22:55:35 +0330 Subject: [PATCH 1/2] redesign --- .../lib/store/purchases/purchases.thunk.ts | 3 +- apps/level_up/app/[locale]/(public)/page.tsx | 7 +-- .../features/competitions/CompetitonsList.tsx | 2 +- .../features/workshops/OfflineWorkshop.tsx | 4 +- .../features/workshops/OnlineWorkshop.tsx | 16 +++++-- .../providers/AntDesignProvider.tsx | 26 +++++----- apps/level_up/config/colors.ts | 7 +-- apps/level_up/messages/en.json | 6 +-- apps/level_up/messages/fa.json | 6 +-- apps/level_up/tailwind.config.ts | 48 +++++++++---------- apps/ssc/app/payment/callback/page.tsx | 12 ++--- .../core/src/api/Purchases/purchases.api.ts | 4 +- 12 files changed, 74 insertions(+), 67 deletions(-) diff --git a/apps/game_craft/lib/store/purchases/purchases.thunk.ts b/apps/game_craft/lib/store/purchases/purchases.thunk.ts index 0e67c419..506d5497 100644 --- a/apps/game_craft/lib/store/purchases/purchases.thunk.ts +++ b/apps/game_craft/lib/store/purchases/purchases.thunk.ts @@ -2,12 +2,13 @@ import { createAppAsyncThunk } from "../createAppAsyncThunk"; import { PurchasesResponse } from "@ssc/core"; +import {eventId} from "../../utils/constants"; export const fetchPurchasesThunk = createAppAsyncThunk( "purchases/fetchPurchases", async (_, thunkAPI) => { try { - const response = await thunkAPI.extra.Api.purchases.fetchPurchases(); + const response = await thunkAPI.extra.Api.purchases.fetchPurchases(eventId); const data = response.data.data; return thunkAPI.fulfillWithValue(data); } catch (error) { diff --git a/apps/level_up/app/[locale]/(public)/page.tsx b/apps/level_up/app/[locale]/(public)/page.tsx index 80f32045..dac6eb26 100644 --- a/apps/level_up/app/[locale]/(public)/page.tsx +++ b/apps/level_up/app/[locale]/(public)/page.tsx @@ -1,9 +1,7 @@ "use client"; import { Flex, theme } from "antd"; -import { GameCraftTimeline } from "../../../components/features/Timeline"; import { GameCraftIntro } from "../../../components/features/home/GameCraftIntro"; -import { Prizes } from "../../../components/features/home/Prizes"; import { AboutUs } from "../../../components/features/home/AboutUs"; import { OfflineWorkshop } from "../../../components/features/workshops/OfflineWorkshop"; import { OnlineWorkshop } from "../../../components/features/workshops/OnlineWorkshop"; @@ -47,7 +45,6 @@ export default function HomePage() { {/**/} {/* Workshop Sections - Matching React order exactly */} -
- {/* Sponsors Section */} + {/*Sponsors Section*/} {/**/} diff --git a/apps/level_up/components/features/competitions/CompetitonsList.tsx b/apps/level_up/components/features/competitions/CompetitonsList.tsx index 8235fede..1fcd4731 100644 --- a/apps/level_up/components/features/competitions/CompetitonsList.tsx +++ b/apps/level_up/components/features/competitions/CompetitonsList.tsx @@ -18,7 +18,7 @@ interface Props { } export function CompetitionsList({ - padding = "3rem 2rem", + padding = "2rem 2rem", backgroundColor, dashboardMode = false, }: Props) { diff --git a/apps/level_up/components/features/workshops/OfflineWorkshop.tsx b/apps/level_up/components/features/workshops/OfflineWorkshop.tsx index 7ace581d..936430a6 100644 --- a/apps/level_up/components/features/workshops/OfflineWorkshop.tsx +++ b/apps/level_up/components/features/workshops/OfflineWorkshop.tsx @@ -8,6 +8,8 @@ import { useEffect, useMemo, useState } from "react"; import { PresentationsList, PresentationType } from "@ssc/core"; import { clientApi } from "lib/api/client/clientApi"; import { eventId } from "lib/utils/constants"; +import Wave from "../../common/Wave"; +import {customColors} from "../../../config/colors"; interface OfflineWorkshopProps { padding?: string; @@ -15,7 +17,7 @@ interface OfflineWorkshopProps { } export function OfflineWorkshop({ - padding = "3rem 2rem", + padding = "2rem 2rem", backgroundColor, }: OfflineWorkshopProps) { const screens = useResponsive(); diff --git a/apps/level_up/components/features/workshops/OnlineWorkshop.tsx b/apps/level_up/components/features/workshops/OnlineWorkshop.tsx index 2f500a0e..c95707b5 100644 --- a/apps/level_up/components/features/workshops/OnlineWorkshop.tsx +++ b/apps/level_up/components/features/workshops/OnlineWorkshop.tsx @@ -9,6 +9,7 @@ import { useEffect, useMemo, useState } from "react"; import { PresentationsList, PresentationType } from "@ssc/core"; import { clientApi } from "lib/api/client/clientApi"; import { eventId } from "lib/utils/constants"; +import {customColors} from "../../../config/colors"; const { useToken } = theme; @@ -18,7 +19,7 @@ interface OnlineWorkshopProps { } export function OnlineWorkshop({ - padding = "3rem 2rem", + padding = "2rem 2rem", backgroundColor, }: OnlineWorkshopProps) { const { token } = useToken(); @@ -101,7 +102,7 @@ export function OnlineWorkshop({ backgroundColor: backgroundColor, }} > - + - {content} + + {content} + + { }); }, [searchParams]); - const handleRedirectToGameCraft = () => { - const gamecraftUrl = - process.env.NEXT_PUBLIC_GAMECRAFT_URL || "https://gamecraft.ir"; - window.location.href = gamecraftUrl; + const handleRedirect = () => { + const redirectUrl = + process.env.NEXT_PUBLIC_API_URL || "https://ceit-ssc.ir"; + window.location.href = redirectUrl; }; const { success, message, orderId } = paymentState; @@ -86,9 +86,9 @@ const PaymentCallbackContent = () => {
diff --git a/packages/core/src/api/Purchases/purchases.api.ts b/packages/core/src/api/Purchases/purchases.api.ts index d39818c3..8b16b50e 100644 --- a/packages/core/src/api/Purchases/purchases.api.ts +++ b/packages/core/src/api/Purchases/purchases.api.ts @@ -4,9 +4,9 @@ import { PurchasesResponse } from "../../types/api/Purchases/Purchases"; import { RequestResponse } from "../../types/api/general"; export class PurchasesApi extends ApiClient { - async fetchPurchases() { + async fetchPurchases(event: number) { return await this.Api.get>( - apiPath(ApiPath.PURCHASES_GET_LIST), + apiPath(ApiPath.PURCHASES_GET_LIST, {event}), { requiresAuth: true, } From 2e1bdc233c25e47cb66098ec0ae10e762ed5548e Mon Sep 17 00:00:00 2001 From: MJ_Akbari Date: Thu, 16 Oct 2025 23:35:09 +0330 Subject: [PATCH 2/2] redesign --- apps/level_up/lib/store/purchases/purchases.thunk.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/apps/level_up/lib/store/purchases/purchases.thunk.ts b/apps/level_up/lib/store/purchases/purchases.thunk.ts index 0e67c419..506d5497 100644 --- a/apps/level_up/lib/store/purchases/purchases.thunk.ts +++ b/apps/level_up/lib/store/purchases/purchases.thunk.ts @@ -2,12 +2,13 @@ import { createAppAsyncThunk } from "../createAppAsyncThunk"; import { PurchasesResponse } from "@ssc/core"; +import {eventId} from "../../utils/constants"; export const fetchPurchasesThunk = createAppAsyncThunk( "purchases/fetchPurchases", async (_, thunkAPI) => { try { - const response = await thunkAPI.extra.Api.purchases.fetchPurchases(); + const response = await thunkAPI.extra.Api.purchases.fetchPurchases(eventId); const data = response.data.data; return thunkAPI.fulfillWithValue(data); } catch (error) {