@funhub/platform 0.2.9 → 0.2.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (169) hide show
  1. package/dist/assets/icons/search/video.mjs +2 -0
  2. package/dist/biz.d.mts +5 -5
  3. package/dist/biz.mjs +1 -1
  4. package/dist/components/biz/business/advertisement/ad-match.d.mts +8 -4
  5. package/dist/components/biz/business/advertisement/ad-match.mjs +1 -1
  6. package/dist/components/biz/business/advertisement/ad-provider.mjs +1 -1
  7. package/dist/components/biz/business/advertisement/ad-query.d.mts +1 -2
  8. package/dist/components/biz/business/advertisement/ad-query.mjs +1 -1
  9. package/dist/components/biz/business/advertisement/ad-runtime-provider.d.mts +2 -2
  10. package/dist/components/biz/business/advertisement/ad-runtime-provider.mjs +1 -1
  11. package/dist/components/biz/business/advertisement/banner-ad/client.mjs +1 -1
  12. package/dist/components/biz/business/advertisement/banner-ad/material.d.mts +2 -3
  13. package/dist/components/biz/business/advertisement/banner-ad/material.mjs +1 -1
  14. package/dist/components/biz/business/advertisement/banner-ad/schema.d.mts +9 -6
  15. package/dist/components/biz/business/advertisement/banner-ad/schema.mjs +1 -1
  16. package/dist/components/biz/business/advertisement/feed-ad/index.d.mts +1 -31
  17. package/dist/components/biz/business/advertisement/feed-ad/index.mjs +1 -1
  18. package/dist/components/biz/business/advertisement/floating-ad/client.d.mts +4 -4
  19. package/dist/components/biz/business/advertisement/floating-ad/client.mjs +1 -1
  20. package/dist/components/biz/business/advertisement/floating-ad/index.d.mts +1 -1
  21. package/dist/components/biz/business/advertisement/floating-ad/material.d.mts +5 -0
  22. package/dist/components/biz/business/advertisement/floating-ad/schema.d.mts +21 -10
  23. package/dist/components/biz/business/advertisement/floating-ad/schema.mjs +1 -1
  24. package/dist/components/biz/business/advertisement/icon-ad/client.mjs +1 -1
  25. package/dist/components/biz/business/advertisement/icon-ad/material.d.mts +1 -2
  26. package/dist/components/biz/business/advertisement/icon-ad/material.mjs +1 -1
  27. package/dist/components/biz/business/advertisement/icon-ad/schema.d.mts +7 -2
  28. package/dist/components/biz/business/advertisement/icon-ad/schema.mjs +1 -1
  29. package/dist/components/biz/business/advertisement/index.d.mts +4 -4
  30. package/dist/components/biz/business/advertisement/popup-ad/client.mjs +3 -3
  31. package/dist/components/biz/business/advertisement/popup-ad/index.d.mts +1 -1
  32. package/dist/components/biz/business/advertisement/popup-ad/material.d.mts +2 -2
  33. package/dist/components/biz/business/advertisement/popup-ad/schema.d.mts +14 -15
  34. package/dist/components/biz/business/advertisement/popup-ad/schema.mjs +1 -1
  35. package/dist/components/biz/business/advertisement/text-ad/client.mjs +1 -1
  36. package/dist/components/biz/business/advertisement/text-ad/material.d.mts +1 -2
  37. package/dist/components/biz/business/advertisement/text-ad/material.mjs +1 -1
  38. package/dist/components/biz/business/advertisement/text-ad/schema.d.mts +5 -3
  39. package/dist/components/biz/business/advertisement/text-ad/schema.mjs +1 -1
  40. package/dist/components/biz/business/banner-carousel/client.mjs +1 -1
  41. package/dist/components/biz/business/detail/shared/detail-operate.mjs +1 -1
  42. package/dist/components/biz/business/detail/shared/registry.d.mts +1 -0
  43. package/dist/components/biz/business/detail/shared/runtime-context-provider.mjs +1 -1
  44. package/dist/components/biz/business/detail/shared/video-hero.mjs +1 -1
  45. package/dist/components/biz/business/detail/video-detail-info/client.mjs +1 -1
  46. package/dist/components/biz/business/detail/video-detail-recommend/client.mjs +1 -1
  47. package/dist/components/biz/business/detail/video-detail-recommend/material.d.mts +1 -0
  48. package/dist/components/biz/business/detail/video-detail-recommend/schema.d.mts +1 -0
  49. package/dist/components/biz/business/detail/video-detail-recommend/schema.mjs +1 -1
  50. package/dist/components/biz/business/detail/video-detail-recommend/shared.mjs +1 -1
  51. package/dist/components/biz/business/detail/video-detail-recommend/utils.mjs +1 -1
  52. package/dist/components/biz/business/header-search/header-avatar-logo-search/schema.mjs +1 -1
  53. package/dist/components/biz/business/header-search/shared/logo.mjs +1 -1
  54. package/dist/components/biz/business/home-recommend/home-recommend-grid/client.mjs +1 -1
  55. package/dist/components/biz/business/home-recommend/home-recommend-grid/inspector-schema.d.mts +4 -24
  56. package/dist/components/biz/business/home-recommend/home-recommend-grid/inspector-schema.mjs +1 -1
  57. package/dist/components/biz/business/home-recommend/home-recommend-grid/material.d.mts +2 -22
  58. package/dist/components/biz/business/home-recommend/home-recommend-grid/server.mjs +1 -1
  59. package/dist/components/biz/business/home-recommend/home-recommend-waterfall/client.mjs +1 -1
  60. package/dist/components/biz/business/home-recommend/home-recommend-waterfall/inspector-schema.d.mts +4 -24
  61. package/dist/components/biz/business/home-recommend/home-recommend-waterfall/inspector-schema.mjs +1 -1
  62. package/dist/components/biz/business/home-recommend/home-recommend-waterfall/material.d.mts +2 -22
  63. package/dist/components/biz/business/home-recommend/home-recommend-waterfall/server.mjs +1 -1
  64. package/dist/components/biz/business/home-recommend/shared/home-recommend-base.mjs +1 -1
  65. package/dist/components/biz/business/home-recommend/shared/home-recommend-default-config.mjs +1 -1
  66. package/dist/components/biz/business/home-recommend/shared/home-recommend-play-count.mjs +2 -0
  67. package/dist/components/biz/business/home-recommend/shared/home-recommend-preview.mjs +1 -1
  68. package/dist/components/biz/business/home-recommend/shared/home-recommend-runtime-props.mjs +1 -1
  69. package/dist/components/biz/business/home-recommend/shared/home-recommend-server-data.mjs +1 -1
  70. package/dist/components/biz/business/home-recommend/shared/home-recommend-smart-tag.mjs +2 -0
  71. package/dist/components/biz/business/hot-recommend/client.mjs +1 -1
  72. package/dist/components/biz/business/hot-recommend/material.d.mts +0 -1
  73. package/dist/components/biz/business/hot-recommend/schema.d.mts +0 -1
  74. package/dist/components/biz/business/hot-recommend/schema.mjs +1 -1
  75. package/dist/components/biz/business/image-text-recommend/client.d.mts +1 -1
  76. package/dist/components/biz/business/image-text-recommend/client.mjs +1 -1
  77. package/dist/components/biz/business/image-text-recommend/material.d.mts +7 -7
  78. package/dist/components/biz/business/image-text-recommend/schema.d.mts +25 -30
  79. package/dist/components/biz/business/image-text-recommend/schema.mjs +1 -1
  80. package/dist/components/biz/business/image-text-recommend/server.mjs +1 -1
  81. package/dist/components/biz/business/image-text-recommend/shared/query.mjs +1 -1
  82. package/dist/components/biz/business/index.d.mts +4 -4
  83. package/dist/components/biz/business/large-feature-grid/schema.mjs +1 -1
  84. package/dist/components/biz/business/marquee/client.mjs +1 -1
  85. package/dist/components/biz/business/marquee/marquee.module.mjs +24 -0
  86. package/dist/components/biz/business/marquee/material.d.mts +6 -5
  87. package/dist/components/biz/business/marquee/schema.d.mts +6 -5
  88. package/dist/components/biz/business/marquee/schema.mjs +1 -1
  89. package/dist/components/biz/business/profile/profile-header/client.mjs +1 -1
  90. package/dist/components/biz/business/profile/profile-header/user-profile-avatar.mjs +1 -1
  91. package/dist/components/biz/business/profile/profile-main/tabs/collect-tab/video-waterfall.mjs +1 -1
  92. package/dist/components/biz/business/profile/profile-main/utils.mjs +1 -1
  93. package/dist/components/biz/business/tab-bar/client.d.mts +0 -2
  94. package/dist/components/biz/business/tab-bar/client.mjs +1 -1
  95. package/dist/components/biz/business/text-recommend/client.mjs +1 -1
  96. package/dist/components/biz/business/text-recommend/material.d.mts +0 -1
  97. package/dist/components/biz/business/text-recommend/schema.d.mts +0 -1
  98. package/dist/components/biz/business/text-recommend/schema.mjs +1 -1
  99. package/dist/components/common/collection-popup/create-collection-sheet.d.mts +3 -0
  100. package/dist/components/common/collection-popup/create-collection-sheet.mjs +1 -1
  101. package/dist/components/common/collection-popup/index.mjs +1 -1
  102. package/dist/components/common/list/waterfall-recommend/recommend-badge-style.mjs +2 -0
  103. package/dist/components/common/list/waterfall-recommend/waterfall-recommend-display.mjs +2 -0
  104. package/dist/components/common/list/waterfall-recommend/waterfall-recommend.d.mts +5 -7
  105. package/dist/components/common/list/waterfall-recommend/waterfall-recommend.mjs +1 -1
  106. package/dist/components/common/series-episodes/index.d.mts +1 -0
  107. package/dist/components/common/series-episodes/index.mjs +1 -1
  108. package/dist/components/common/video-player/index.d.mts +1 -2
  109. package/dist/components/pages/collection-detail/detail.mjs +1 -1
  110. package/dist/components/pages/feed-series/feed-series-client.mjs +1 -1
  111. package/dist/components/pages/fullscreen-feed/page.mjs +1 -1
  112. package/dist/components/pages/search/search-result/shared.mjs +1 -1
  113. package/dist/components/pages/search-result/search-video-info.mjs +1 -1
  114. package/dist/components/pages/settings/_components/reset-password-drawer.mjs +1 -1
  115. package/dist/components/ui/badge.d.mts +1 -1
  116. package/dist/components/ui/button.d.mts +2 -2
  117. package/dist/components/ui/empty.d.mts +1 -1
  118. package/dist/components/ui/item.d.mts +1 -1
  119. package/dist/hooks.d.mts +1 -2
  120. package/dist/hooks.mjs +1 -1
  121. package/dist/i18n/locales/en.mjs +1 -1
  122. package/dist/i18n/locales/zh-CN.mjs +1 -1
  123. package/dist/materials.d.mts +1 -2
  124. package/dist/materials.mjs +1 -1
  125. package/dist/service/advertisement.d.mts +1 -1
  126. package/dist/service/advertisement.mjs +1 -1
  127. package/dist/service/generated/client.d.mts +2 -10
  128. package/dist/service/generated/client.mjs +1 -1
  129. package/dist/service/generated/tanstack.d.mts +2 -12
  130. package/dist/service/generated/tanstack.mjs +1 -1
  131. package/dist/service.d.mts +3 -3
  132. package/dist/service.mjs +1 -1
  133. package/dist/store/modules/user-store.d.mts +1 -1
  134. package/dist/store/modules/user-store.mjs +1 -1
  135. package/dist/store.d.mts +1 -3
  136. package/dist/store.mjs +1 -1
  137. package/dist/types.d.mts +1 -171
  138. package/dist/utils/device-id.d.mts +2 -2
  139. package/dist/utils/device-id.mjs +1 -1
  140. package/dist/utils/http.mjs +1 -1
  141. package/dist/utils/password-validator.mjs +1 -1
  142. package/dist/utils/schema/inspector.d.mts +2 -2
  143. package/dist/utils.d.mts +1 -3
  144. package/dist/utils.mjs +1 -1
  145. package/package.json +1 -2
  146. package/dist/components/biz/business/home-recommend/shared/home-recommend-smart-layout.mjs +0 -2
  147. package/dist/components/biz/business/ranking-recommend/client.d.mts +0 -17
  148. package/dist/components/biz/business/ranking-recommend/client.mjs +0 -70
  149. package/dist/components/biz/business/ranking-recommend/material.d.mts +0 -35
  150. package/dist/components/biz/business/ranking-recommend/material.mjs +0 -2
  151. package/dist/components/biz/business/ranking-recommend/schema.d.mts +0 -35
  152. package/dist/components/biz/business/ranking-recommend/schema.mjs +0 -2
  153. package/dist/components/biz/business/ranking-recommend/server.d.mts +0 -11
  154. package/dist/components/biz/business/ranking-recommend/server.mjs +0 -2
  155. package/dist/components/biz/business/ranking-recommend/shared/query.mjs +0 -2
  156. package/dist/components/biz/business/ranking-recommend/shared.d.mts +0 -15
  157. package/dist/components/biz/business/ranking-recommend/shared.mjs +0 -2
  158. package/dist/components/common/video-player/video-blind-ad-overlay.mjs +0 -2
  159. package/dist/components/common/video-player/video-player-ref-context.mjs +0 -2
  160. package/dist/hooks/use-is-client.d.mts +0 -10
  161. package/dist/hooks/use-is-client.mjs +0 -2
  162. package/dist/store/modules/blind-spot-ad-store.d.mts +0 -116
  163. package/dist/store/modules/blind-spot-ad-store.mjs +0 -2
  164. package/dist/store/modules/video-player-ref-store.d.mts +0 -21
  165. package/dist/store/modules/video-player-ref-store.mjs +0 -2
  166. package/dist/utils/browser-fingerprint.d.mts +0 -13
  167. package/dist/utils/browser-fingerprint.mjs +0 -2
  168. package/dist/utils/request-user-id.d.mts +0 -12
  169. package/dist/utils/request-user-id.mjs +0 -2
@@ -1,70 +0,0 @@
1
-
2
- "use client";import{isClient as e}from"../../../../utils/common.mjs";import{pContentBatchGetVideoDetail as t,pContentGetPopularVideoList as n}from"../../../../service/generated/client.mjs";import{pContentGetPopularVideoListKey as r}from"../../../../service/generated/tanstack.mjs";import{Box as i}from"../../../ui/box.mjs";import{Text as a}from"../../../ui/text.mjs";import o from"../../../ui/link.mjs";import{buildImageTextRecommendSmartPicked as s,getImageTextRecommendLayoutTags as c}from"../../../../hooks/image-text-recommend.mjs";import{useRequest as l}from"../../../../hooks/query/use-query.mjs";import u from"../../../../assets/icons/common/right_arrow_thin.mjs";import{buildRankingCardList as d,buildSmartRankingCardList as f,normalizeContentId as p,resolveCoverDisplaySrc as m,resolveOrderedContentIds as h}from"./shared.mjs";import{buildSmartPopularQuery as g,buildStableChosenTags as _}from"./shared/query.mjs";import{useEffect as v,useMemo as y,useRef as b,useState as x}from"react";import{jsx as S,jsxs as C}from"react/jsx-runtime";function w(e){let t=e===`nebula`?`
3
- <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 138" fill="none">
4
- <defs>
5
- <linearGradient id="bg" x1="10" y1="6" x2="84" y2="132" gradientUnits="userSpaceOnUse">
6
- <stop stop-color="#120B25"/>
7
- <stop offset="0.45" stop-color="#28306D"/>
8
- <stop offset="1" stop-color="#05030D"/>
9
- </linearGradient>
10
- <radialGradient id="cyan" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(33 34) rotate(62) scale(39 30)">
11
- <stop stop-color="#74DEFF"/>
12
- <stop offset="1" stop-color="#74DEFF" stop-opacity="0"/>
13
- </radialGradient>
14
- <radialGradient id="pink" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(72 28) rotate(118) scale(48 37)">
15
- <stop stop-color="#FF51D7"/>
16
- <stop offset="1" stop-color="#FF51D7" stop-opacity="0"/>
17
- </radialGradient>
18
- <linearGradient id="hair" x1="21" y1="30" x2="69" y2="109" gradientUnits="userSpaceOnUse">
19
- <stop stop-color="#1E2A77"/>
20
- <stop offset="1" stop-color="#5A1B6F"/>
21
- </linearGradient>
22
- </defs>
23
- <rect width="100" height="138" rx="4" fill="url(#bg)"/>
24
- <rect width="100" height="138" rx="4" fill="url(#cyan)"/>
25
- <rect width="100" height="138" rx="4" fill="url(#pink)"/>
26
- <path d="M12 47C20 28 34 18 49 18C67 18 82 31 85 53C79 46 71 42 60 42C48 42 39 47 30 58L12 47Z" fill="url(#hair)" opacity="0.95"/>
27
- <path d="M28 70C28 50 38 36 52 36C64 36 73 46 73 62C73 82 62 100 50 100C38 100 28 89 28 70Z" fill="#F0E7FF"/>
28
- <path d="M25 48C32 38 39 34 47 34C38 44 34 58 34 72C34 87 39 98 49 105C32 102 20 84 20 64C20 58 22 52 25 48Z" fill="#0E0D1A" opacity="0.9"/>
29
- <path d="M53 43C63 44 71 54 71 67C71 75 68 82 63 87C60 81 58 73 58 64C58 56 60 49 63 44L53 43Z" fill="#EAE6FF" opacity="0.65"/>
30
- <path d="M21 21L35 11L49 19L46 39L32 43L16 34L21 21Z" fill="#EFF4FF" opacity="0.82"/>
31
- <path d="M20 20L35 11L41 18L29 28L21 21Z" fill="#74DEFF" opacity="0.8"/>
32
- <circle cx="44" cy="63" r="4" fill="#2A2C63"/>
33
- <circle cx="44.5" cy="62.5" r="1.5" fill="#D9ECFF"/>
34
- <path d="M52 83C56 86 61 86 65 83" stroke="#C3B8F6" stroke-width="2" stroke-linecap="round"/>
35
- <path d="M61 58L72 52" stroke="#7ED7FF" stroke-width="2.5" stroke-linecap="round" opacity="0.7"/>
36
- <path d="M22 96C32 86 47 81 65 80" stroke="#FF7AE0" stroke-width="3" stroke-linecap="round" opacity="0.45"/>
37
- </svg>
38
- `:`
39
- <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 138" fill="none">
40
- <defs>
41
- <linearGradient id="bg" x1="17" y1="7" x2="83" y2="132" gradientUnits="userSpaceOnUse">
42
- <stop stop-color="#12080D"/>
43
- <stop offset="0.5" stop-color="#34111C"/>
44
- <stop offset="1" stop-color="#04060D"/>
45
- </linearGradient>
46
- <radialGradient id="red" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(42 33) rotate(52) scale(34 30)">
47
- <stop stop-color="#FF516E"/>
48
- <stop offset="1" stop-color="#FF516E" stop-opacity="0"/>
49
- </radialGradient>
50
- <radialGradient id="cyan" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(70 79) rotate(118) scale(44 31)">
51
- <stop stop-color="#3CC8FF"/>
52
- <stop offset="1" stop-color="#3CC8FF" stop-opacity="0"/>
53
- </radialGradient>
54
- </defs>
55
- <rect width="100" height="138" rx="4" fill="url(#bg)"/>
56
- <rect width="100" height="138" rx="4" fill="url(#red)"/>
57
- <rect width="100" height="138" rx="4" fill="url(#cyan)"/>
58
- <path d="M7 74C9 46 24 26 46 24C68 22 84 40 87 69C80 62 71 57 58 57C40 57 25 64 7 74Z" fill="#080B13" opacity="0.86"/>
59
- <path d="M33 39C40 31 48 27 56 27C69 27 79 40 79 58C79 84 64 105 48 105C34 105 23 90 23 69C23 57 27 47 33 39Z" fill="#F6F5FA"/>
60
- <path d="M16 71C18 54 24 42 33 34C31 42 30 48 30 55C30 75 38 92 50 104C43 105 35 103 28 97C18 88 14 79 16 71Z" fill="#07090F"/>
61
- <path d="M61 35L75 48L73 66L59 67L49 51L61 35Z" fill="#FFF7F4" opacity="0.95"/>
62
- <path d="M55 44L66 40L72 46L66 54L57 54L55 44Z" fill="#FF5D6F"/>
63
- <path d="M38 60C42 55 46 53 52 53C57 53 61 55 64 59" stroke="#141A2B" stroke-width="2.2" stroke-linecap="round"/>
64
- <circle cx="43" cy="67" r="4" fill="#121624"/>
65
- <circle cx="43.5" cy="66.5" r="1.5" fill="#DDF0FF"/>
66
- <path d="M51 86C55 88 60 88 65 84" stroke="#C9C1D8" stroke-width="2" stroke-linecap="round"/>
67
- <path d="M19 31L31 20L49 23L42 39L24 40L19 31Z" fill="#F8FCFF" opacity="0.82"/>
68
- <path d="M14 99C31 84 49 77 70 77" stroke="#FF6773" stroke-width="3" stroke-linecap="round" opacity="0.45"/>
69
- </svg>
70
- `;return`data:image/svg+xml;charset=UTF-8,${encodeURIComponent(t)}`}const T=w(`nebula`),E=w(`crimson`),D=T,O={padding:`0.5px`,background:`linear-gradient(180deg, rgba(230,42,255,0.9) 5%, rgba(239,255,69,0.5) 30%, rgba(233,69,255,0.8) 55%, rgba(233,69,255,0.9) 100%)`,WebkitMask:`linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0)`,WebkitMaskComposite:`xor`,maskComposite:`exclude`},k={background:`rgba(83, 83, 83, 0.2)`},A={backdropFilter:`blur(4px)`,WebkitBackdropFilter:`blur(4px)`,maskImage:`linear-gradient(180deg, transparent 58.3%, black 100%)`,WebkitMaskImage:`linear-gradient(180deg, transparent 58.3%, black 100%)`},j=[{contentId:`mock-1`,title:`东野圭吾作品:11字谜案`,cover:T,category:`烧脑悬疑`,heatText:`2242万热度`,score:8.9,statusText:`完结`,href:`#`},{contentId:`mock-2`,title:`东野圭吾作品:11字谜案`,cover:E,category:`烧脑悬疑`,heatText:`2242万热度`,score:8.9,statusText:`完结`,href:`#`}];function M(e){return Array.from({length:e},(e,t)=>({...j[t%j.length],contentId:`mock-${t+1}`}))}function N({filled:e,className:t=``}){return S(`svg`,{viewBox:`0 0 14 14`,fill:`none`,"aria-hidden":!0,className:t,children:S(`path`,{d:`M7 0.5L8.76 4.94L13.5 5.39L9.91 8.57L10.94 13.2L7 10.77L3.06 13.2L4.09 8.57L0.5 5.39L5.24 4.94L7 0.5Z`,fill:e?`#FFC039`:`rgba(255,255,255,0.3)`})})}function P({score:e}){let t=Math.ceil(e/2);return C(i,{className:`flex items-center gap-[8px]`,children:[S(i,{className:`flex items-center gap-[4px]`,children:Array.from({length:5},(e,n)=>S(N,{filled:n<t,className:`size-[14px]`},n))}),S(a,{className:`font-['DIN'] text-[12px] font-bold leading-normal text-[#FFC039]`,children:e.toFixed(1)})]})}function F({item:e,isEditor:t}){let n=m(e.cover,D),r=C(i,{className:`relative h-[158px] w-full`,children:[C(i,{className:`absolute left-0 top-[28px] h-[130px] w-full overflow-hidden rounded-[8px]`,children:[S(i,{className:`absolute inset-0 rounded-[8px]`,style:k}),S(i,{className:`pointer-events-none absolute rounded-full`,style:{left:`34px`,top:`-238px`,width:`385.969px`,height:`385.969px`,background:`radial-gradient(25.17% 25.17% at 64.27% 57.53%, #4F8DFF 0%, rgba(255,255,255,0) 100%)`,mixBlendMode:`overlay`,filter:`blur(50px)`}}),S(i,{className:`pointer-events-none absolute rounded-full`,style:{left:`210px`,top:`-75px`,width:`189px`,height:`187px`,background:`radial-gradient(50.27% 50.39% at 65.31% 48.07%, #FF5DEF 0%, rgba(255,255,255,0) 100%)`,mixBlendMode:`overlay`,filter:`blur(50px)`}}),S(i,{className:`pointer-events-none absolute inset-0 rounded-[8px]`,style:O})]}),C(i,{className:`absolute left-[16px] top-0 z-10 h-[138px] w-[100px] overflow-hidden rounded-[4px]`,children:[S(`img`,{src:n,alt:e.title,className:`absolute inset-0 size-full object-cover`}),S(i,{className:`pointer-events-none absolute inset-0 rounded-[4px]`,style:{background:`linear-gradient(180deg, rgba(8, 2, 17, 0) 44.64%, rgba(8, 2, 17, 0.7) 82.7%)`}}),S(i,{className:`pointer-events-none absolute inset-0 rounded-[4px]`,style:A}),e.statusText&&S(i,{className:`absolute bottom-[9px] right-[8px] flex h-[18px] w-[32px] items-center justify-center rounded-[4px] bg-white/20 p-[2px]`,children:S(a,{className:`font-['PingFang_SC'] text-[12px] leading-[14px] text-white`,children:e.statusText})})]}),C(i,{className:`absolute left-[132px] top-[58px] z-10 flex w-[210px] items-start justify-between`,children:[C(i,{className:`flex h-[71px] w-[152px] flex-col justify-between`,children:[C(i,{className:`flex flex-col gap-[4px]`,children:[S(a,{className:`line-clamp-1 font-['PingFang_SC'] text-[14px] font-medium leading-[20px] text-white`,children:e.title}),C(i,{className:`flex items-center gap-[10px] font-['PingFang_SC'] text-[14px] leading-[20px] text-white/60`,children:[e.category&&S(a,{className:`shrink-0 whitespace-nowrap`,children:e.category}),e.heatText&&S(a,{className:`shrink-0 whitespace-nowrap`,children:e.heatText})]})]}),e.score>0&&S(P,{score:e.score})]}),S(i,{"aria-hidden":!0,className:`size-[22px] shrink-0 opacity-0`})]})]});return t||!e.href||e.href===`#`?r:S(o,{href:e.href,className:`block`,children:r})}function I(o){let{title:m,items:w,layout:T,prefetchItems:E,mode:D=`renderer`}=o,O=D===`editor`,k=D===`renderer`,A=(m??``).trim()||`推荐榜`,j=!!T?.enabled,N=y(()=>c(T),[T]),P=w?.length??2,I=y(()=>_(N,P),[N,P]),L=y(()=>g(I,P),[I,P]),{data:R}=l(r(L),()=>n(L),{enabled:k&&!O&&j,staleTime:1/0}),[z,B]=x([]);v(()=>{O||!j||B(f(s(R?.data?.videos??[],I,P)))},[O,j,R,I,P]);let V=y(()=>O||j?[]:h(w),[w,O,j]),H=y(()=>Array.from(new Set(V)),[V]),U=y(()=>V.join(`,`),[V]),W=y(()=>Array.isArray(E)?E.map(e=>p(e.contentId)).join(`,`):``,[E]),[G,K]=x(()=>E??[]),q=b(``);v(()=>{O||j||(K(E??[]),q.current=W&&W===U?U:``)},[O,j,U,W,E]),v(()=>{if(O||j||!e()||!U||q.current===U)return;q.current=U;let n=!1;async function r(){try{let e=await t({ids:H},{cache:`no-store`}),r=Array.isArray(e.data?.videos)?e.data.videos:[];if(n)return;K(d(r,w??[]))}catch(e){console.error(`推荐榜数据获取失败`,e)}}return r(),()=>{n=!0}},[O,j,V,U,H,w]);let J=j?z:G,Y=y(()=>O?M(w?.length??2):[],[O,w?.length]),X=O?Y:J;return!O&&X.length===0?null:C(i,{className:`mt-[24px] w-full px-[16px]${O?` pointer-events-none`:``}`,children:[C(i,{className:`flex items-center justify-between`,children:[S(a,{className:`font-['PingFang_SC'] text-[18px] font-medium leading-[24px] text-white/90`,style:O?{textShadow:`0 1px 4px rgba(0,0,0,0.45)`}:void 0,children:A}),S(i,{className:`flex shrink-0 items-center justify-end gap-[2px] opacity-50`,style:O?{filter:`drop-shadow(0 1px 3px rgba(0,0,0,0.45))`}:void 0,children:S(i,{className:`overflow-hidden`,children:S(u,{className:`size-[24px] text-white`})})})]}),S(i,{className:`mt-[16px] flex flex-col gap-[16px]`,children:X.map((e,t)=>S(F,{item:e,isEditor:O},`${e.contentId}-${t}`))})]})}export{I as RankingRecommendClient};
@@ -1,35 +0,0 @@
1
-
2
- import { SchemaHasDefaultValue } from "../../../../utils/schema/schema.mjs";
3
- import { DefineMaterialOption } from "../../../../utils/schema/material.mjs";
4
- import "../../../../utils.mjs";
5
- import { RankingRecommendClient } from "./client.mjs";
6
- import { RankingRecommendServer } from "./server.mjs";
7
- import * as zod from "zod";
8
- import * as zod_v4_core0 from "zod/v4/core";
9
-
10
- //#region components/biz/business/ranking-recommend/material.d.ts
11
- declare const rankingRecommendMaterial: DefineMaterialOption<typeof RankingRecommendServer, typeof RankingRecommendClient, zod.ZodObject<{
12
- readonly title: zod.ZodString & SchemaHasDefaultValue;
13
- readonly moduleCount: zod.ZodNumber & SchemaHasDefaultValue;
14
- readonly layout: zod.ZodObject<{
15
- readonly enabled: zod.ZodBoolean & SchemaHasDefaultValue;
16
- readonly tags: zod.ZodArray<zod.ZodString> & SchemaHasDefaultValue;
17
- }, zod_v4_core0.$strip> | zod.ZodOptional<zod.ZodObject<{
18
- readonly enabled: zod.ZodBoolean & SchemaHasDefaultValue;
19
- readonly tags: zod.ZodArray<zod.ZodString> & SchemaHasDefaultValue;
20
- }, zod_v4_core0.$strip>>;
21
- readonly items: zod.ZodArray<zod.ZodObject<{
22
- id: zod.ZodString & SchemaHasDefaultValue;
23
- contentName: zod.ZodString & SchemaHasDefaultValue;
24
- title: zod.ZodString & SchemaHasDefaultValue;
25
- cover: zod.ZodString & SchemaHasDefaultValue;
26
- useVideoPoster: zod.ZodBoolean & SchemaHasDefaultValue;
27
- }, zod_v4_core0.$strip>> & SchemaHasDefaultValue;
28
- } & {
29
- mode: zod.ZodOptional<zod.ZodEnum<{
30
- renderer: "renderer";
31
- editor: "editor";
32
- }>>;
33
- }, zod_v4_core0.$strip>, "ranking-recommend", "内容组件">;
34
- //#endregion
35
- export { rankingRecommendMaterial };
@@ -1,2 +0,0 @@
1
-
2
- import{defineMaterial as e}from"../../../../utils/schema/material.mjs";import{RankingRecommendClient as t}from"./client.mjs";import{rankingRecommendInspectorPropsSchema as n}from"./schema.mjs";import{RankingRecommendServer as r}from"./server.mjs";const i=e({type:`ranking-recommend`,name:`推荐榜`,icon:`/static/components-thumb/search_recommend_text.png`,category:`内容组件`,serverComponent:r,clientComponent:t,propsSchema:n});export{i as rankingRecommendMaterial};
@@ -1,35 +0,0 @@
1
-
2
- import { InferSchemaProps, SchemaHasDefaultValue } from "../../../../utils/schema/schema.mjs";
3
- import "../../../../utils.mjs";
4
- import { z } from "zod";
5
-
6
- //#region components/biz/business/ranking-recommend/schema.d.ts
7
- /**
8
- * 推荐榜物料属性定义
9
- */
10
- declare const rankingRecommendInspectorPropsSchema: z.ZodObject<{
11
- readonly title: z.ZodString & SchemaHasDefaultValue;
12
- readonly moduleCount: z.ZodNumber & SchemaHasDefaultValue;
13
- readonly layout: z.ZodObject<{
14
- readonly enabled: z.ZodBoolean & SchemaHasDefaultValue;
15
- readonly tags: z.ZodArray<z.ZodString> & SchemaHasDefaultValue;
16
- }, z.core.$strip> | z.ZodOptional<z.ZodObject<{
17
- readonly enabled: z.ZodBoolean & SchemaHasDefaultValue;
18
- readonly tags: z.ZodArray<z.ZodString> & SchemaHasDefaultValue;
19
- }, z.core.$strip>>;
20
- readonly items: z.ZodArray<z.ZodObject<{
21
- id: z.ZodString & SchemaHasDefaultValue;
22
- contentName: z.ZodString & SchemaHasDefaultValue;
23
- title: z.ZodString & SchemaHasDefaultValue;
24
- cover: z.ZodString & SchemaHasDefaultValue;
25
- useVideoPoster: z.ZodBoolean & SchemaHasDefaultValue;
26
- }, z.core.$strip>> & SchemaHasDefaultValue;
27
- } & {
28
- mode: z.ZodOptional<z.ZodEnum<{
29
- renderer: "renderer";
30
- editor: "editor";
31
- }>>;
32
- }, z.core.$strip>;
33
- type RankingRecommendInspectorProps = InferSchemaProps<typeof rankingRecommendInspectorPropsSchema>;
34
- //#endregion
35
- export { RankingRecommendInspectorProps };
@@ -1,2 +0,0 @@
1
-
2
- import{defineComponentPropsSchema as e,getSchemaDefaultProps as t}from"../../../../utils/schema/schema.mjs";import{z as n}from"zod";const r=e(e=>({title:e.string(`推荐榜`,{label:`标题名称`,description:`支持输入,中/英/数/符,6个字符`}),moduleCount:e.number(2,{label:`推荐模块数`}),layout:e.object({enabled:e.boolean(!1,{fieldType:`switch`,label:`智能铺设`}),tags:e.array(n.string(),{label:`取数范围标签`,defaultValue:[`电影`]})},{label:`智能铺设`,defaultValue:{enabled:!1,tags:[`电影`]}}),items:e.array(n.object({id:e.string(``,{label:`内容ID`}),contentName:e.string(``,{label:`内容名称`}),title:e.string(``,{label:`推荐位内容名称`}),cover:e.string(``,{label:`推荐位封面`}),useVideoPoster:e.boolean(!0,{fieldType:`switch`,label:`沿用视频海报`})}),{label:`推荐榜内容`,defaultValue:[{id:`22edc8693ebbdaf1`,contentName:``,title:``,cover:``,useVideoPoster:!0},{id:`22edc8693ebbdaf1`,contentName:``,title:``,cover:``,useVideoPoster:!0}]})}));t(r);export{r as rankingRecommendInspectorPropsSchema};
@@ -1,11 +0,0 @@
1
-
2
- import { RankingRecommendProps } from "./client.mjs";
3
- import * as react_jsx_runtime0 from "react/jsx-runtime";
4
-
5
- //#region components/biz/business/ranking-recommend/server.d.ts
6
- /**
7
- * 推荐榜物料组件 - 服务端部分
8
- */
9
- declare function RankingRecommendServer(props: RankingRecommendProps): Promise<react_jsx_runtime0.JSX.Element>;
10
- //#endregion
11
- export { RankingRecommendServer };
@@ -1,2 +0,0 @@
1
-
2
- import{pContentBatchGetVideoDetail as e,pContentGetPopularVideoList as t}from"../../../../service/generated/client.mjs";import{pContentGetPopularVideoListKey as n}from"../../../../service/generated/tanstack.mjs";import{getImageTextRecommendLayoutTags as r}from"../../../../hooks/image-text-recommend.mjs";import{HydrationBoundary as i}from"../../../../hooks/query/hydration-boundary.mjs";import{buildRankingCardList as a,resolveOrderedContentIds as o}from"./shared.mjs";import{buildSmartPopularQuery as s,buildStableChosenTags as c}from"./shared/query.mjs";import{RankingRecommendClient as l}from"./client.mjs";import{jsx as u}from"react/jsx-runtime";const d=[];async function f(f){let{mode:p=`renderer`,items:m=d,layout:h,...g}=f,_=!!h?.enabled,v=[],y=f.prefetchItems;if(p===`renderer`)try{if(_){let e=r(h),i=m?.length??2,a=s(c(e,i),i),o=await t(a);v.push({queryKey:n(a),queryFn:()=>Promise.resolve(o)})}else{let t=o(m),n=Array.from(new Set(t));if(n.length>0){let t=await e({ids:n},{cache:`no-store`});y=a(Array.isArray(t.data?.videos)?t.data.videos:[],m)}}}catch(e){console.warn(`[ranking-recommend] server prefetch failed:`,e)}return u(i,{prefetch:v,children:u(l,{...g,items:m,layout:h,mode:p,prefetchItems:y})})}export{f as RankingRecommendServer};
@@ -1,2 +0,0 @@
1
-
2
- function e(e,t){let n=e.map(e=>String(e).trim()).filter(Boolean);if(!n.length||t<=0)return[];if(n.length>=t)return n.slice(0,t);let r=[...n];for(;r.length<t;)r.push(n[r.length%n.length]);return r}function t(e,t){return{page_size:Math.max(20,t*10),tags:e.length?Array.from(new Set(e)):void 0}}export{t as buildSmartPopularQuery,e as buildStableChosenTags};
@@ -1,15 +0,0 @@
1
-
2
- //#region components/biz/business/ranking-recommend/shared.d.ts
3
- /** 推荐榜卡片渲染数据。 */
4
- interface RankingCardItem {
5
- contentId: string;
6
- title: string;
7
- cover: string;
8
- category: string;
9
- heatText: string;
10
- score: number;
11
- statusText: string;
12
- href: string;
13
- }
14
- //#endregion
15
- export { RankingCardItem };
@@ -1,2 +0,0 @@
1
-
2
- import e from"../../../../utils/get-res-url.mjs";import{getPostDetailPagePath as t}from"../../../../utils/tools.mjs";function n(e){return typeof e==`string`?e.trim():String(e??``).trim()}function r(e){return Array.isArray(e)?e.map(e=>n(e?.id)).filter(Boolean):[]}function i(t,n=``){let r=typeof t==`string`?t.trim():``;if(!r)return n;if(r.startsWith(`http`)||r.startsWith(`//`)||r.startsWith(`data:`))return r;let i=e();return i?`${i}${r.startsWith(`/`)?r:`/${r}`}`:r}function a(e){return!e||!Number.isFinite(e)||e<=0?``:e>=1e4?`${(e/1e4).toFixed(e>=1e5?0:1).replace(/\.0$/,``)}万热度`:e>=1e3?`${(e/1e3).toFixed(1).replace(/\.0$/,``)}K热度`:`${Math.floor(e)}热度`}function o(e){let t=n(e.update_status);return t===`1`?`完结`:t===`0`?`连载中`:``}function s(e){let t=Number(e);return!Number.isFinite(t)||t<=0?0:t>10&&t<=100?t/10:Math.min(t,10)}function c(e){let r=n(e.id||e.mid||e.video_id),i=Number(e.play_count??e.browse_count??0);return{contentId:r,title:n(e.name),cover:n(e.img_y||e.img_x),category:n(e.cat_name),heatText:a(i),score:s(e.score),statusText:o(e),href:r?t({id:r,contentType:0}):`#`}}function l(e,t){let r=new Map;return e.forEach(e=>{let t=n(e.id||e.mid||e.video_id);t&&r.set(t,e)}),t.map(e=>{let t=n(e.id),i=t?r.get(t):void 0;if(!i)return null;let a=c(i),o=(e.title??``).trim();o&&(a.title=o);let s=(e.cover??``).trim();return s&&e.useVideoPoster===!1&&(a.cover=s),a}).filter(e=>!!e)}function u(e){let r=n(e.id||e.mid),i=Number(e.static?.browse_cnt??0),o=n(e.update_status);return{contentId:r,title:n(e.name),cover:n(e.img_y||e.img_x),category:n(e.cat_name),heatText:a(i),score:s(e.score),statusText:o===`1`?`完结`:o===`0`?`连载中`:``,href:r?t({id:r,contentType:0}):`#`}}function d(e){return e.map(u)}export{l as buildRankingCardList,d as buildSmartRankingCardList,n as normalizeContentId,i as resolveCoverDisplaySrc,r as resolveOrderedContentIds};
@@ -1,2 +0,0 @@
1
-
2
- "use client";import{useUserStore as e}from"../../../store/modules/user-store.mjs";import{pContentMatchAds as t}from"../../../service/generated/client.mjs";import{pContentMatchAdsKey as n}from"../../../service/generated/tanstack.mjs";import{useRequest as r}from"../../../hooks/query/use-query.mjs";import{useVideoPlayerRef as i}from"./video-player-ref-context.mjs";import{useIsClient as a}from"foxact/use-is-client";import{useEffect as o,useRef as s,useState as c}from"react";import{jsx as l}from"react/jsx-runtime";import{create as u}from"zustand";import{createJSONStorage as d,persist as f}from"zustand/middleware";import{createPortal as p}from"react-dom";const m=u()(f((e,t)=>({shownVideoIds:new Set,hasShown:e=>t().shownVideoIds.has(e),markAsShown:n=>{let r=t().shownVideoIds;if(!r.has(n)){let t=new Set(r);t.add(n),e({shownVideoIds:t})}}}),{name:`video-blind-ad-storage`,storage:typeof window<`u`?d(()=>sessionStorage):void 0,partialize:e=>({shownVideoIds:Array.from(e.shownVideoIds)}),merge:(e,t)=>({...t,shownVideoIds:new Set(e.shownVideoIds||[])})}));function h({videoId:u}){let d=i(),f=a(),h=e(e=>e.userId),{hasShown:g,markAsShown:_}=m(),v=s(0),y=s(null),[b,x]=c(!1),S=s(!1),C={user_id:h,ad_type:`blind`},{data:w,isLoading:T}=r(n(C),()=>t(C)),E=g(u);o(()=>{let e=d?.current?.getPlayer();if(!e||!w||E)return;let t=w.data?.settings?.trigger_video_progress_min??0;function n(r){if(S.current){e?.off(`timeupdate`,n);return}let i=r?.currentTime;if(y.current!==null){let e=i-y.current;e>0&&e<2&&(v.current+=e,!S.current&&v.current/60>=t&&(S.current=!0,x(!0)))}y.current=i}return e.on(`timeupdate`,n),()=>{e.off(`timeupdate`,n)}},[d,w,E]);let D=!E&&b;o(()=>{if(D)return document.body.style.overflow=`hidden`,()=>{document.body.style.overflow=``}},[D]);function O(){E||(_(u),window.open(w?.data.materials?.[0].advertise_url))}return!f||typeof document>`u`||T||w?.data?.hit===!1||E||!b?null:p(l(`div`,{className:`blind-ad-overlay fixed inset-0 h-screen w-screen z-[99999]`,onClick:O}),document.body)}export{h as VideoBlindAdOverlay};
@@ -1,2 +0,0 @@
1
-
2
- "use client";import{createContext as e,use as t}from"react";const n=e(null);function r(){return t(n)}export{n as VideoPlayerRefContext,r as useVideoPlayerRef};
@@ -1,10 +0,0 @@
1
-
2
- //#region hooks/use-is-client.d.ts
3
- /**
4
- * 判断当前是否在客户端环境
5
- *
6
- * 用于处理 SSR/CSR 兼容性问题
7
- */
8
- declare function useIsClient(): boolean;
9
- //#endregion
10
- export { useIsClient };
@@ -1,2 +0,0 @@
1
-
2
- "use client";import{useEffect as e,useState as t}from"react";function n(){let[n,r]=t(!1);return e(()=>{r(!0)},[]),n}export{n as useIsClient};
@@ -1,116 +0,0 @@
1
-
2
- import * as zustand from "zustand";
3
-
4
- //#region store/modules/blind-spot-ad-store.d.ts
5
- /**
6
- * 盲点广告配置
7
- */
8
- interface BlindSpotAdConfig {
9
- /**
10
- * 触发时间阈值(分钟)
11
- */
12
- triggerTimeMinutes: number;
13
- /**
14
- * 广告跳转链接
15
- */
16
- jumpUrl: string;
17
- /**
18
- * 是否启用
19
- */
20
- enabled: boolean;
21
- }
22
- /**
23
- * 盲点广告状态
24
- */
25
- interface BlindSpotAdState {
26
- /**
27
- * 当前会话ID
28
- */
29
- sessionId: string;
30
- /**
31
- * 已触发的视频ID集合
32
- */
33
- triggeredVideoIds: Set<string>;
34
- /**
35
- * 当前视频ID
36
- */
37
- currentVideoId: string | undefined;
38
- /**
39
- * 当前播放时间(秒)
40
- */
41
- currentTime: number;
42
- /**
43
- * 是否显示蒙层
44
- */
45
- isOverlayVisible: boolean;
46
- /**
47
- * 当前广告配置
48
- */
49
- adConfig: BlindSpotAdConfig | null;
50
- /**
51
- * 广告响应数据(原始)
52
- */
53
- adResponseData: any;
54
- }
55
- /**
56
- * 盲点广告操作
57
- */
58
- interface BlindSpotAdActions {
59
- /**
60
- * 初始化会话
61
- */
62
- initSession: () => void;
63
- /**
64
- * 设置当前视频ID
65
- */
66
- setCurrentVideo: (videoId: string | undefined) => void;
67
- /**
68
- * 更新播放时间
69
- */
70
- updateCurrentTime: (time: number) => void;
71
- /**
72
- * 标记视频已触发
73
- */
74
- markVideoTriggered: (videoId: string) => void;
75
- /**
76
- * 检查视频是否已触发
77
- */
78
- isVideoTriggered: (videoId: string) => boolean;
79
- /**
80
- * 显示蒙层
81
- */
82
- showOverlay: () => void;
83
- /**
84
- * 隐藏蒙层
85
- */
86
- hideOverlay: () => void;
87
- /**
88
- * 设置广告配置
89
- */
90
- setAdConfig: (config: BlindSpotAdConfig | null) => void;
91
- /**
92
- * 设置广告响应数据
93
- */
94
- setAdResponseData: (data: any) => void;
95
- /**
96
- * 检查是否应该触发盲点广告
97
- */
98
- shouldTriggerAd: () => boolean;
99
- /**
100
- * 重置状态(视频切换时)
101
- */
102
- reset: () => void;
103
- }
104
- /**
105
- * 盲点广告 Store
106
- *
107
- * 管理盲点广告的全局状态,包括:
108
- * - 会话管理
109
- * - 已触发视频记录
110
- * - 播放进度跟踪
111
- * - 蒙层显示状态
112
- * - 广告配置
113
- */
114
- declare const useBlindSpotAdStore: zustand.UseBoundStore<zustand.StoreApi<BlindSpotAdState & BlindSpotAdActions>>;
115
- //#endregion
116
- export { BlindSpotAdConfig, useBlindSpotAdStore };
@@ -1,2 +0,0 @@
1
-
2
- import{isClient as e}from"../../utils/common.mjs";import{createStore as t}from"../create-store.mjs";function n(){return`session_${Date.now()}_${Math.random().toString(36).substring(2,9)}`}const r=t((t,r)=>({sessionId:``,triggeredVideoIds:new Set,currentVideoId:void 0,currentTime:0,isOverlayVisible:!1,adConfig:null,adResponseData:null,initSession:()=>{t({sessionId:n(),triggeredVideoIds:new Set})},setCurrentVideo:e=>{t({currentVideoId:e,currentTime:0})},updateCurrentTime:e=>{t({currentTime:e})},markVideoTriggered:n=>{let{triggeredVideoIds:i}=r(),a=new Set(i);if(a.add(n),t({triggeredVideoIds:a}),e())try{let e=Array.from(a);sessionStorage.setItem(`blind_spot_ad_triggered_videos`,JSON.stringify(e))}catch(e){console.warn(`Failed to save triggered videos to sessionStorage:`,e)}},isVideoTriggered:e=>{let{triggeredVideoIds:t}=r();return t.has(e)},showOverlay:()=>{t({isOverlayVisible:!0})},hideOverlay:()=>{t({isOverlayVisible:!1})},setAdConfig:e=>{t({adConfig:e})},setAdResponseData:e=>{t({adResponseData:e})},shouldTriggerAd:()=>{let{currentVideoId:e,currentTime:t,adConfig:n,isOverlayVisible:i}=r();return!(i||!e||!n||!n.enabled||r().isVideoTriggered(e)||t<n.triggerTimeMinutes*60||!n.jumpUrl)},reset:()=>{t({currentVideoId:void 0,currentTime:0,isOverlayVisible:!1})}}),{name:`blind-spot-ad-store`,persist:!1});export{r as useBlindSpotAdStore};
@@ -1,21 +0,0 @@
1
-
2
- import { CommonPlayerRef } from "../../components/common/video-player/index.mjs";
3
- import * as zustand from "zustand";
4
-
5
- //#region store/modules/video-player-ref-store.d.ts
6
- /**
7
- * 视频播放器 Ref Store
8
- *
9
- * 用于全局存储当前视频详情页的播放器实例引用
10
- * 供盲点广告等需要访问播放器的功能使用
11
- */
12
- interface VideoPlayerRefState {
13
- playerRef: React.RefObject<CommonPlayerRef | null> | null;
14
- setPlayerRef: (ref: React.RefObject<CommonPlayerRef | null> | null) => void;
15
- }
16
- /**
17
- * 全局视频播放器 ref 状态管理。
18
- */
19
- declare const useVideoPlayerRefStore: zustand.UseBoundStore<zustand.StoreApi<VideoPlayerRefState>>;
20
- //#endregion
21
- export { useVideoPlayerRefStore };
@@ -1,2 +0,0 @@
1
-
2
- import{createStore as e}from"../create-store.mjs";const t=e(e=>({playerRef:null,setPlayerRef:t=>e({playerRef:t})}));export{t as useVideoPlayerRefStore};
@@ -1,13 +0,0 @@
1
-
2
- //#region utils/browser-fingerprint.d.ts
3
- /**
4
- * 获取或生成浏览器指纹。
5
- *
6
- * 说明:
7
- * - 优先复用内存与 localStorage 中的已生成值,避免重复加载 SDK。
8
- * - 使用 FingerprintJS 官方 SDK 生成 `visitorId`。
9
- * - SDK 失败或不可用时,降级为本地 UUID,避免阻塞游客身份初始化。
10
- */
11
- declare function getOrCreateBrowserFingerprint(force?: boolean): Promise<string>;
12
- //#endregion
13
- export { getOrCreateBrowserFingerprint };
@@ -1,2 +0,0 @@
1
-
2
- import{generateUUID as e,isClient as t}from"./common.mjs";const n=`funhub-browser-fingerprint`;let r=``,i=null;async function a(a=!1){if(!t())return``;if(!a&&r)return r;try{if(!a){let e=window.localStorage.getItem(n);if(e&&e.trim().length>=8)return r=e.trim(),r}}catch{}return(!i||a)&&(i=o().then(t=>{let i=t||e();r=i;try{window.localStorage.setItem(n,i)}catch{}return i}).finally(()=>{i=null})),await i}async function o(){try{let e=await(await(await import(`@fingerprintjs/fingerprintjs`)).default.load()).get();return String(e.visitorId||``).trim()}catch(e){return console.warn(`[browser-fingerprint] load fingerprint failed`,e),``}}export{a as getOrCreateBrowserFingerprint};
@@ -1,12 +0,0 @@
1
-
2
- //#region utils/request-user-id.d.ts
3
- /**
4
- * 解析请求头中应使用的用户标识。
5
- *
6
- * 规则:
7
- * - 登录态优先使用 `userId`。
8
- * - 未登录时回退到 `guestUserId`。
9
- */
10
- declare function resolveRequestUserId(userId?: string, guestUserId?: string): string;
11
- //#endregion
12
- export { resolveRequestUserId };
@@ -1,2 +0,0 @@
1
-
2
- function e(e,t){return(typeof e==`string`?e.trim():``)||(typeof t==`string`?t.trim():``)}export{e as resolveRequestUserId};