diff --git a/bun.lockb b/bun.lockb index 04c5af9..9926790 100755 Binary files a/bun.lockb and b/bun.lockb differ diff --git a/package.json b/package.json index b1b10ce..d712b1a 100755 --- a/package.json +++ b/package.json @@ -32,24 +32,24 @@ "build": "astro build --config ./source/astro.js" }, "dependencies": { - "@astrojs/mdx": "^3.1.3", - "@astrojs/node": "^8.3.2", + "@astrojs/mdx": "^3.1.5", + "@astrojs/node": "^8.3.3", "@astrojs/vue": "^4.5.0", - "@iconoir/vue": "^7.8.0", + "@iconoir/vue": "^7.9.0", "@minpluto/zorn": "^0.4.5", "@nurodev/astro-bun": "^1.1.5", - "@openpanel/sdk": "^0.0.9-beta", - "@supabase/supabase-js": "^2.45.1", + "@openpanel/sdk": "^1.0.0", + "@supabase/supabase-js": "^2.45.3", "@xexiu/astro-modal": "^0.5.9", - "astro": "^4.13.3", + "astro": "^4.15.4", "astro-analytics": "^2.7.0", "astro-i18next": "^1.0.0-beta.21", "astro-tooltips": "^0.6.2", "astro-useragent": "^4.0.2", "rss-to-json": "^2.1.1", - "undici": "^6.19.7" + "undici": "^6.19.8" }, "devDependencies": { - "sass": "^1.77.8" + "sass": "^1.78.0" } } \ No newline at end of file diff --git a/source/src/components/category/CategoryCard.astro b/source/src/components/category/CategoryCard.astro new file mode 100644 index 0000000..8d6970f --- /dev/null +++ b/source/src/components/category/CategoryCard.astro @@ -0,0 +1,79 @@ +--- +const { + Link, + Name, + Platform, + Thumbnail, + Ratio = "16:9" // "16:9" or "9:16" +} = Astro.props +--- + + + + { + ()=> { + if (Platform === "YouTube") { + return + } else if (Platform === "Twitch") { + return + } + } + } +
+

{Name}

+
+
+ + + +{ + ()=> { + if (Ratio === "16:9") { + return + } else if (Ratio === "9:16") { + return + } + } +} \ No newline at end of file diff --git a/source/src/pages/index.astro b/source/src/pages/index.astro index b743c35..498d021 100755 --- a/source/src/pages/index.astro +++ b/source/src/pages/index.astro @@ -13,6 +13,7 @@ import { FireFlame, Frame, Gamepad, GraphUp, Movie, MusicDoubleNote } from "@ico // Components import Trending from "@components/category/trending.astro"; import Chip from "@components/Chip.astro"; +import CategoryCard from "@components/category/CategoryCard.astro"; // Fetch const TrendingFetch = DEFAULT_MEDIA_DATA_PROXY + '/api/v1/trending' @@ -46,51 +47,67 @@ const TwitchDiscoverData = await TwitchDiscoverFetch.json()
{TrendingSplit.map((data) => - - -
- -

{t("SIDEBAR.CATEGORY_LIST.POPULAR")}

-
-
+ +
+
)} {MoviesSplit.map((data) => - - -
- -

{t("SIDEBAR.CATEGORY_LIST.TRAILERS")}

-
-
+ +
+
)} {MusicSplit.map((data) => - - -
- -

{t("SIDEBAR.CATEGORY_LIST.MUSIC")}

-
-
+ +
+
)} {GamingSplit.map((data) => - - -
- -

{t("SIDEBAR.CATEGORY_LIST.GAMES")}

-
-
+ +
+
)}

{TwitchDiscoverData.data.map((data) => - - -
-

{data.displayName}

-
-
+ +
+
)}

@@ -99,6 +116,18 @@ const TwitchDiscoverData = await TwitchDiscoverFetch.json() \ No newline at end of file