From c1ac61c3fd319f9fb6abfef1dbce91a164110d88 Mon Sep 17 00:00:00 2001 From: expdsn <18111002318@163.com> Date: Tue, 22 Oct 2024 16:27:19 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AE=8C=E6=88=90=E4=BA=86=E7=83=AD=E7=82=B9?= =?UTF-8?q?=E8=B5=84=E8=AE=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/icons/hotspot/baidu_info.png | Bin 0 -> 2470 bytes public/icons/hotspot/bilibili_info.png | Bin 0 -> 1648 bytes public/icons/hotspot/hot_tab_bg.png | Bin 0 -> 896 bytes public/icons/hotspot/weibo_info.png | Bin 0 -> 2234 bytes public/icons/热搜榜@2x.png | Bin 0 -> 5210 bytes src/layout/grid/BlockWrapper.tsx | 52 +++++++------- src/main.css | 8 ++- src/widgets/constellation/Modal.tsx | 3 +- src/widgets/discount/Modal.tsx | 88 +++++++++++++++-------- src/widgets/discount/useDiscountStore.ts | 32 ++++++--- src/widgets/hotspot/Large.tsx | 67 ++++++++++++++++- src/widgets/hotspot/Middle.tsx | 78 +++++++++++++++++++- src/widgets/hotspot/Modal.tsx | 76 ++++++++++++++++++-- src/widgets/hotspot/Small.tsx | 21 ++++-- src/widgets/hotspot/useHotspotStore.ts | 49 +++++++++++++ src/widgets/video/useVideoStore.tsx | 19 +++++ 16 files changed, 410 insertions(+), 83 deletions(-) create mode 100644 public/icons/hotspot/baidu_info.png create mode 100644 public/icons/hotspot/bilibili_info.png create mode 100644 public/icons/hotspot/hot_tab_bg.png create mode 100644 public/icons/hotspot/weibo_info.png create mode 100644 public/icons/热搜榜@2x.png create mode 100644 src/widgets/hotspot/useHotspotStore.ts diff --git a/public/icons/hotspot/baidu_info.png b/public/icons/hotspot/baidu_info.png new file mode 100644 index 0000000000000000000000000000000000000000..02132cb616aa49e7e86fe437140d2beb23346704 GIT binary patch literal 2470 zcmV;X30d}uP)Px#L}ge>W=%~1DgXcg2mk?xX#fN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{8!nGFW09&UVX! zpkbtm)E@f$xUv`|EWpY-4OC}mCrwXJQ+Iba)zs7|`>$J>W>x(H9Buf?% zN=Y6ii~&MA#rC9=tV&H&k@0mu(O=9H1yO9(WEe%M)p$#({UGe*{dhd73CLO`v36yH zGcYhfUg+xTa!pne5HG6|0g%ivdIHoz1vbL=I&xSTi=X?GtTL=BTn_+MZfk2ZNPs-* zR6x6li3#$=cZUR7O-cEavdJ+KHzP>(h0wh!(stY%yY=?UzCUy}uml5`#mPj;l zM^DKD*fRb4W^!m|g^!Yyp}z2+SihFrX=rFLk^toz1<3)Pykp1J?`U9*mas;hu+-T9 z;}H;rN+$?Ab_Sc91@Y!h>8E^nJNN6LI7UXuwzv*AgU$5zXZa04X2F93#z!O|%TG>(3i7gr#JkauTdrQVi91?>?N7@FWK5y9!lC95V>_>et#$=nY5YA9KWT8&jEdXgF z*Ohh!K>|K`gn|Kf0lSD>O5FRy%L$E)+(fMTAg4dK3XM+pZi<9qfx%9^oV?% z_t{(`{5j&>41)SVSRljci;up>Bcn_DrWk~=rj6qtGjm$BEhxxTJtfxQ|3S`;7^|=m zvx?CyQm^@aab|$})l+str$i87f0df9p~@{Jqzc&jq!YFemN^%D#Ly}1yiAZaJ~dyY zc6waE!jnIrcUcPUWe$NBX*=b%gySaBqjH7c4MY3&0dyfw_hV)vKFKtF~J`{>K{zRc|0*DI2`0hOivX41#}r9*g1z|CIA2c07*qo IM6N<$f>ACFR{#J2 literal 0 HcmV?d00001 diff --git a/public/icons/热搜榜@2x.png b/public/icons/热搜榜@2x.png new file mode 100644 index 0000000000000000000000000000000000000000..aac358b58eda7f568eea304c34aeca64f4f8164b GIT binary patch literal 5210 zcmV-g6s7BlP)Px}6iGxuRCr$PTzi}xMV~z&}0xF^=IaD~FL9#Jqccy-RzVqpx z>*?w4nO!5u9rf4lbX9eA)wh4o@2{C&YA@{o5plO&Sh{qnTDo+p@76Ev`kym)s`nci z8R@^{jypCovrKjDOZ_u|FfuYSYkYkCiz4z?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zR(y~o{+XW_U5Gh)qA<9E4@K?7%monvL;BZQKnt1L;0wG$L{{bjt=nNl*I|IJU%!4I zX5OZ+ukX%Yf?)BvkpL?c3V4QxdU^4BU02jEOeSJ}e0{EfgdW1^vu4e@FPR+s6U8@p U(DL4BRsaA107*qoM6N<$g6-V(zyJUM literal 0 HcmV?d00001 diff --git a/src/layout/grid/BlockWrapper.tsx b/src/layout/grid/BlockWrapper.tsx index 4c4be32..ba1fe5d 100644 --- a/src/layout/grid/BlockWrapper.tsx +++ b/src/layout/grid/BlockWrapper.tsx @@ -26,7 +26,7 @@ export default defineComponent({ const hover = ref(false) return () => (
-
- {props.block.link ? ( - props.block.link.startsWith('id:') ? ( - // 文件夹 - +
+
+ {props.block.link ? ( + props.block.link.startsWith('id:') ? ( + // 文件夹 + + ) : ( + // 链接 + + ) ) : ( - // 链接 - - ) - ) : ( - // 小组件 - + // 小组件 + + )} +
+ {settings.state.showBlockLabel && ( +
+ {layout.getLabel(props.block)} +
)}
- {settings.state.showBlockLabel && ( -
- {layout.getLabel(props.block)} -
- )}
) } diff --git a/src/main.css b/src/main.css index d0ce42b..d5a92a6 100644 --- a/src/main.css +++ b/src/main.css @@ -165,7 +165,13 @@ body { scrollbar-width: none; -ms-overflow-style: none; } - +.hover-move { + transform: translateY(0); + animation: none; + transition-duration: 0.3s; + transition-property: transform; + transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); +} .hover-move:hover { transform: translateY(-4px); } diff --git a/src/widgets/constellation/Modal.tsx b/src/widgets/constellation/Modal.tsx index a2958cc..604590b 100644 --- a/src/widgets/constellation/Modal.tsx +++ b/src/widgets/constellation/Modal.tsx @@ -56,7 +56,8 @@ export default defineComponent(() => { } > { + onClick={(e) => { + e.stopPropagation() page.value = (page.value % 2) + 1 }} class={clsx( diff --git a/src/widgets/discount/Modal.tsx b/src/widgets/discount/Modal.tsx index 3b84059..a503969 100644 --- a/src/widgets/discount/Modal.tsx +++ b/src/widgets/discount/Modal.tsx @@ -2,17 +2,17 @@ import { defineComponent, ref, watch, type VNodeRef } from 'vue' import useGameNews from './useDiscountStore' import { RiTimeLine } from 'oh-vue-icons/icons' import { addIcons, OhVueIcon } from 'oh-vue-icons' +import { IoCloseCircleOutline, RiCloseCircleLine } from 'oh-vue-icons/icons' import dayjs from 'dayjs' -addIcons(RiTimeLine) +addIcons(RiTimeLine, IoCloseCircleOutline, RiCloseCircleLine) export default defineComponent(() => { const store = useGameNews() const containerRef = ref(null as VNodeRef | null) - + const searchText = ref('') const handleScroll = () => { const container = containerRef.value if (container.scrollTop + container.clientHeight >= container.scrollHeight - 50) { - store.getNews() } } @@ -24,46 +24,74 @@ export default defineComponent(() => { }} >
- +
+ { + searchText.value = e.target.value + }} + onKeydown={(e: any) => { + if (e.key === 'Enter') { + store.getNews() + } + }} + > + +
-
-
+
+
{store.list.map((item, index) => { return (
{ - }} + onClick={() => {}} key={index} > - +
- - {item.gameid} - - - {item.name} - -
- +
+ {item.name} +
+ + {item.typename} + +
+
+
+ -13% +
+ + ¥{item.commdity[0].price} + + + ¥{item.commdity[0].oldprice} + + + 剩余{item.commdity[0].oldprice}天 + +
diff --git a/src/widgets/discount/useDiscountStore.ts b/src/widgets/discount/useDiscountStore.ts index f681ec3..34128c4 100644 --- a/src/widgets/discount/useDiscountStore.ts +++ b/src/widgets/discount/useDiscountStore.ts @@ -1,9 +1,17 @@ import request from "@/utils/request"; import { defineStore } from "pinia"; -import { ref, type VNodeRef } from "vue"; - +import { reactive, ref, type VNodeRef } from "vue"; +type CommdityType = { + commodityClass: string; + img: string; + price: string; + oldprice: string; + royaltyrate: string + url: string; +} export interface GameDiscount { + commdity: CommdityType[]; gameid: string; status: number; typeid: string; @@ -12,30 +20,34 @@ export interface GameDiscount { } export default defineStore("gameDiscount", () => { const list = ref([]) - const page = ref(1) const loading = ref(false) const noMoreData = ref(false) - const containerRef = ref(null) - + const state = reactive({ + pageId: 1, + name: '', + }) const getList = async () => { const res = await request<{ data: GameDiscount[]; - }>('GET', `/api/gameDiscount?page=${page.value}&page_size=16`) + }>('POST', '/api/gameDiscount', { + data: { + pageId: state.pageId, + name: state.name + } + }) return res.data } const getNews = async () => { if (loading.value || noMoreData.value) return; loading.value = true; - try { const data = await getList() - if (data.length === 0) { noMoreData.value = true; } else { list.value.push(...data); - page.value++; + state.pageId += 1; } } catch (e) { console.log(e); @@ -51,6 +63,6 @@ export default defineStore("gameDiscount", () => { loading, noMoreData, getNews, - containerRef + state, } }) \ No newline at end of file diff --git a/src/widgets/hotspot/Large.tsx b/src/widgets/hotspot/Large.tsx index b83de91..8238048 100644 --- a/src/widgets/hotspot/Large.tsx +++ b/src/widgets/hotspot/Large.tsx @@ -1,9 +1,72 @@ import { defineComponent } from 'vue' +import useHotspotStore, { PlatformList } from './useHotspotStore' +import clsx from 'clsx' +import jump from '@/utils/jump' export default defineComponent(() => { + const store = useHotspotStore() return () => ( -
- large +
+
+ {[...PlatformList.entries()].map(([key, value]) => ( +
{ + store.type = key + e.stopPropagation() + }} + class={clsx( + ' py-2 cursor-pointer bg rounded-xl flex gap-x-1 relative', + store.type === key ? 'text-[#4162ce] font-bold' : '' + )} + > + {value} + {store.type === key && ( + bg + )} +
+ ))} +
+
+
+ {store.hotMap + .get(store.type) + ?.filter((_, idx) => idx < 5) + .map((item, index) => ( +
{ + jump(item.url) + }} + > +
+ + {index + 1}. + + + {item.title} + +
+ {item.hotScore} +
+ ))} +
+
) }) diff --git a/src/widgets/hotspot/Middle.tsx b/src/widgets/hotspot/Middle.tsx index 53edc23..faaa59d 100644 --- a/src/widgets/hotspot/Middle.tsx +++ b/src/widgets/hotspot/Middle.tsx @@ -1,10 +1,82 @@ import { defineComponent } from 'vue' +import useHotspotStore, { PlatformList } from './useHotspotStore' +import clsx from 'clsx' +import { BiCaretRightFill } from 'oh-vue-icons/icons' +import jump from '@/utils/jump' +import { addIcons, OhVueIcon } from 'oh-vue-icons' +addIcons(BiCaretRightFill) export default defineComponent(() => { - + const store = useHotspotStore() return () => ( -
- middle +
+
+
+ {[...PlatformList.entries()] + .filter((_, idx) => idx === 0) + .map(([key, value]) => ( +
{ + store.type = key + e.stopPropagation() + }} + class={clsx( + ' py-2 cursor-pointer bg rounded-xl flex gap-x-1 relative', + store.type === key ? 'text-[#4162ce] font-bold' : '' + )} + > + {value} + {store.type === key && ( + bg + )} +
+ ))} +
+
+ +
+
+
+
+ {store.hotMap + .get(store.type) + ?.filter((_, idx) => idx < 5) + .map((item, index) => ( +
{ + jump(item.url) + }} + > +
+ + {index + 1}. + + + {item.title} + +
+ {item.hotScore} +
+ ))} +
+
) }) diff --git a/src/widgets/hotspot/Modal.tsx b/src/widgets/hotspot/Modal.tsx index 9890740..fb102af 100644 --- a/src/widgets/hotspot/Modal.tsx +++ b/src/widgets/hotspot/Modal.tsx @@ -1,12 +1,76 @@ import { defineComponent } from 'vue' +import useHotspotStore, { PlatformList } from './useHotspotStore' +import clsx from 'clsx' +import jump from '@/utils/jump' export default defineComponent(() => { + const store = useHotspotStore() return () => ( -
+
+
+ +
+
+
+
+ {[...PlatformList.entries()].map(([key, value]) => ( +
{ + store.type = key + }} + class={clsx( + 'w-full py-3 cursor-pointer pl-3 bg rounded-xl flex gap-x-1', + + store.type === key + ? 'bg-[#ffffff] text-[#4162ce] font-bold' + : 'hover:bg-[#ffffff] text-[#666]' + )} + > + + {value}热点 +
+ ))} +
+
+
+ {store.hotMap.get(store.type)?.map((item, index) => ( +
{ + jump(item.url) + }} + > +
+ + {index + 1} + + + {item.title} + +
+ {item.hotScore} +
+ ))} +
+
+
+
+
) }) diff --git a/src/widgets/hotspot/Small.tsx b/src/widgets/hotspot/Small.tsx index bf0a763..2704692 100644 --- a/src/widgets/hotspot/Small.tsx +++ b/src/widgets/hotspot/Small.tsx @@ -1,14 +1,25 @@ + import { defineComponent } from 'vue' export default defineComponent(() => { return () => (
- + +
+
+ 热点折扣 +
+ 立即查看 +
+ +
+
+
+
) }) + diff --git a/src/widgets/hotspot/useHotspotStore.ts b/src/widgets/hotspot/useHotspotStore.ts new file mode 100644 index 0000000..34f4b76 --- /dev/null +++ b/src/widgets/hotspot/useHotspotStore.ts @@ -0,0 +1,49 @@ +import useLayoutStore from '@/layout/useLayoutStore' +import request from '@/utils/request' +import { defineStore } from 'pinia' +import { computed, ref, watch } from 'vue' + +type HotType = { + desc: string + hotScore: string + index: number + picurl: string + title: string + url: string +} +export const PlatformList = new Map([ + ['baidu', '百度'], + ['weibo', '微博'], + ['bilibili', 'B站'] +] as const) + +export default defineStore('hotspot', () => { + const hotMap = ref>(new Map()) + const type = ref('baidu') + const addHotType = (key: string, hotType: HotType[]) => { + if (hotMap.value.has(key)) { + // 如果 key 已存在,向对应的数组中添加新元素 + return + } else { + // 如果 key 不存在,初始化一个新的数组并设置该 key + hotMap.value.set(key, hotType); + } + }; + const getNews = async (type: string) => { + const res = await request<{ + data: HotType[] + }>('GET', `/api/hotList?type=${type}`) + addHotType(type, res.data) + } + + watch(type, val => { + if (hotMap.value.has(val)) return + getNews(val) + }) + getNews(type.value) + + return { + hotMap, + type + } +}) diff --git a/src/widgets/video/useVideoStore.tsx b/src/widgets/video/useVideoStore.tsx index 6e2bb3b..fc596da 100644 --- a/src/widgets/video/useVideoStore.tsx +++ b/src/widgets/video/useVideoStore.tsx @@ -1,10 +1,29 @@ import useLayoutStore from '@/layout/useLayoutStore' +import request from '@/utils/request' import { defineStore } from 'pinia' import { computed, ref, watch } from 'vue' +type HotType = { + desc: string + hotScore: string + index: number + picurl: string + title: string + url: string +} +export const PlatformList = new Map([ + ['baidu', '百度'], + ['weibo', '微博'], + ['bilibili', 'B站'] +] as const) + export default defineStore('video', () => { const videoList = ref([]) const layout = useLayoutStore() + const type = ref('baidu') + const getNews = async (type: string) => { + const res = request('GET', `/api/hotList?type=${type}`) + } watch( () => layout.state.current, (val) => {