@funhub/platform 0.1.28 → 0.1.29

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 (202) hide show
  1. package/dist/biz.d.mts +28 -10
  2. package/dist/biz.mjs +1 -1
  3. package/dist/components/biz/business/banner/variants/basic-banner/inspector-schema.d.mts +11 -11
  4. package/dist/components/biz/business/banner/variants/basic-banner/material.d.mts +1 -1
  5. package/dist/components/biz/business/banner-carousel/client.mjs +2 -0
  6. package/dist/components/biz/business/banner-carousel/default-props.mjs +2 -0
  7. package/dist/components/biz/business/banner-carousel/material.d.mts +22 -0
  8. package/dist/components/biz/business/banner-carousel/material.mjs +2 -0
  9. package/dist/components/biz/business/banner-carousel/schema.d.mts +23 -0
  10. package/dist/components/biz/business/banner-carousel/schema.mjs +2 -0
  11. package/dist/components/biz/business/banner-carousel/server.d.mts +18 -0
  12. package/dist/components/biz/business/banner-carousel/server.mjs +2 -0
  13. package/dist/components/biz/business/channel-list/channel-filter-dialog.mjs +1 -1
  14. package/dist/components/biz/business/channel-list/client.mjs +1 -1
  15. package/dist/components/biz/business/channel-list/material.d.mts +4 -2
  16. package/dist/components/biz/business/channel-list/schema.d.mts +9 -7
  17. package/dist/components/biz/business/channel-list/schema.mjs +1 -1
  18. package/dist/components/biz/business/detail/materials/registry.d.mts +34 -28
  19. package/dist/components/biz/business/detail/materials/video-detail-actions/client.d.mts +1 -1
  20. package/dist/components/biz/business/detail/materials/video-detail-actions/client.mjs +1 -1
  21. package/dist/components/biz/business/detail/materials/video-detail-actions/index.d.mts +2 -2
  22. package/dist/components/biz/business/detail/materials/video-detail-actions/material.d.mts +2 -1
  23. package/dist/components/biz/business/detail/materials/video-detail-actions/material.mjs +1 -1
  24. package/dist/components/biz/business/detail/materials/video-detail-actions/server.d.mts +10 -2
  25. package/dist/components/biz/business/detail/materials/video-detail-info/client.d.mts +1 -1
  26. package/dist/components/biz/business/detail/materials/video-detail-info/client.mjs +1 -1
  27. package/dist/components/biz/business/detail/materials/video-detail-info/index.d.mts +2 -2
  28. package/dist/components/biz/business/detail/materials/video-detail-info/material.d.mts +2 -1
  29. package/dist/components/biz/business/detail/materials/video-detail-info/server.d.mts +10 -2
  30. package/dist/components/biz/business/detail/materials/video-detail-info-title/client.mjs +1 -1
  31. package/dist/components/biz/business/detail/materials/video-detail-info-title/index.d.mts +2 -2
  32. package/dist/components/biz/business/detail/materials/video-detail-info-title/material.d.mts +2 -1
  33. package/dist/components/biz/business/detail/materials/video-detail-info-title/server.d.mts +10 -2
  34. package/dist/components/biz/business/detail/materials/video-detail-info-title-tags-episodes/client.mjs +1 -1
  35. package/dist/components/biz/business/detail/materials/video-detail-info-title-tags-episodes/index.d.mts +2 -2
  36. package/dist/components/biz/business/detail/materials/video-detail-info-title-tags-episodes/material.d.mts +2 -1
  37. package/dist/components/biz/business/detail/materials/video-detail-info-title-tags-episodes/server.d.mts +10 -2
  38. package/dist/components/biz/business/detail/materials/video-detail-player/client.d.mts +1 -1
  39. package/dist/components/biz/business/detail/materials/video-detail-player/client.mjs +1 -1
  40. package/dist/components/biz/business/detail/materials/video-detail-player/index.d.mts +2 -2
  41. package/dist/components/biz/business/detail/materials/video-detail-player/material.d.mts +2 -1
  42. package/dist/components/biz/business/detail/materials/video-detail-player/material.mjs +1 -1
  43. package/dist/components/biz/business/detail/materials/video-detail-player/server.d.mts +10 -2
  44. package/dist/components/biz/business/detail/materials/video-detail-recommend/client.mjs +1 -1
  45. package/dist/components/biz/business/detail/materials/video-detail-recommend/index.d.mts +2 -2
  46. package/dist/components/biz/business/detail/materials/video-detail-recommend/material.d.mts +2 -1
  47. package/dist/components/biz/business/detail/materials/video-detail-recommend/schema.d.mts +23 -23
  48. package/dist/components/biz/business/detail/materials/video-detail-recommend/server.d.mts +10 -2
  49. package/dist/components/biz/business/floating-ball/client.d.mts +1 -1
  50. package/dist/components/biz/business/floating-ball/material.d.mts +2 -1
  51. package/dist/components/biz/business/floating-ball/server.d.mts +11 -0
  52. package/dist/components/biz/business/header-search/header-avatar-icon/index.d.mts +2 -2
  53. package/dist/components/biz/business/header-search/header-avatar-icon/material.d.mts +2 -1
  54. package/dist/components/biz/business/header-search/header-avatar-icon/material.mjs +1 -1
  55. package/dist/components/biz/business/header-search/header-avatar-icon/server.d.mts +10 -2
  56. package/dist/components/biz/business/header-search/header-avatar-logo-search/index.d.mts +2 -2
  57. package/dist/components/biz/business/header-search/header-avatar-logo-search/material.d.mts +2 -1
  58. package/dist/components/biz/business/header-search/header-avatar-logo-search/material.mjs +1 -1
  59. package/dist/components/biz/business/header-search/header-avatar-logo-search/server.d.mts +10 -2
  60. package/dist/components/biz/business/header-search/header-avatar-logo-search-icon/index.d.mts +2 -2
  61. package/dist/components/biz/business/header-search/header-avatar-logo-search-icon/material.d.mts +2 -1
  62. package/dist/components/biz/business/header-search/header-avatar-logo-search-icon/material.mjs +1 -1
  63. package/dist/components/biz/business/header-search/header-avatar-logo-search-icon/server.d.mts +10 -2
  64. package/dist/components/biz/business/header-search/header-logo-search/index.d.mts +2 -2
  65. package/dist/components/biz/business/header-search/header-logo-search/material.d.mts +2 -1
  66. package/dist/components/biz/business/header-search/header-logo-search/material.mjs +1 -1
  67. package/dist/components/biz/business/header-search/header-logo-search/server.d.mts +10 -2
  68. package/dist/components/biz/business/header-search/header-search/index.d.mts +2 -2
  69. package/dist/components/biz/business/header-search/header-search/material.d.mts +2 -1
  70. package/dist/components/biz/business/header-search/header-search/material.mjs +1 -1
  71. package/dist/components/biz/business/header-search/header-search/server.d.mts +10 -2
  72. package/dist/components/biz/business/home-recommend/variants/home-recommend-grid/inspector-schema.d.mts +5 -5
  73. package/dist/components/biz/business/home-recommend/variants/home-recommend-grid/inspector-schema.mjs +1 -1
  74. package/dist/components/biz/business/home-recommend/variants/home-recommend-grid/material.d.mts +1 -1
  75. package/dist/components/biz/business/home-recommend/variants/home-recommend-grid/material.mjs +1 -1
  76. package/dist/components/biz/business/home-recommend/variants/home-recommend-grid/runtime/client.mjs +1 -1
  77. package/dist/components/biz/business/home-recommend/variants/home-recommend-grid/schema/component.mjs +1 -1
  78. package/dist/components/biz/business/home-recommend/variants/home-recommend-waterfall/inspector-schema.d.mts +5 -5
  79. package/dist/components/biz/business/home-recommend/variants/home-recommend-waterfall/material.d.mts +1 -1
  80. package/dist/components/biz/business/home-recommend/variants/home-recommend-waterfall/material.mjs +1 -1
  81. package/dist/components/biz/business/home-recommend/variants/home-recommend-waterfall/runtime/client.mjs +1 -1
  82. package/dist/components/biz/business/index.d.mts +27 -8
  83. package/dist/components/biz/business/index.mjs +1 -1
  84. package/dist/components/biz/business/large-feature-grid/client.d.mts +1 -1
  85. package/dist/components/biz/business/large-feature-grid/material.d.mts +2 -1
  86. package/dist/components/biz/business/large-feature-grid/server.d.mts +11 -0
  87. package/dist/components/biz/business/marquee/index.d.mts +2 -2
  88. package/dist/components/biz/business/marquee/material.d.mts +2 -1
  89. package/dist/components/biz/business/marquee/material.mjs +1 -1
  90. package/dist/components/biz/business/marquee/schema.d.mts +14 -14
  91. package/dist/components/biz/business/profile/index.d.mts +21 -0
  92. package/dist/components/biz/business/profile/profile-header/client.d.mts +19 -0
  93. package/dist/components/biz/business/profile/profile-header/client.mjs +2 -0
  94. package/dist/components/biz/business/profile/profile-header/index.d.mts +5 -0
  95. package/dist/components/biz/business/profile/profile-header/material.d.mts +9 -1
  96. package/dist/components/biz/business/profile/profile-header/material.mjs +1 -1
  97. package/dist/components/biz/business/profile/profile-header/schema.d.mts +40 -0
  98. package/dist/components/biz/business/profile/profile-header/schema.mjs +2 -0
  99. package/dist/components/biz/business/profile/profile-header/server.d.mts +33 -0
  100. package/dist/components/{pages/profile/_components/user-profile-header → biz/business/profile/profile-header}/server.mjs +1 -1
  101. package/dist/components/biz/business/profile/profile-header/user-profile-avatar.mjs +2 -0
  102. package/dist/components/biz/business/profile/profile-header/user-profile-cover-background.mjs +2 -0
  103. package/dist/components/biz/business/profile/profile-main/client.d.mts +17 -0
  104. package/dist/components/biz/business/profile/profile-main/client.mjs +2 -0
  105. package/dist/components/biz/business/profile/profile-main/index.d.mts +16 -0
  106. package/dist/components/biz/business/profile/profile-main/material.d.mts +14 -1
  107. package/dist/components/biz/business/profile/profile-main/material.mjs +1 -1
  108. package/dist/components/biz/business/profile/profile-main/schema.d.mts +55 -0
  109. package/dist/components/biz/business/profile/profile-main/schema.mjs +2 -0
  110. package/dist/components/biz/business/profile/profile-main/server.d.mts +11 -0
  111. package/dist/components/biz/business/profile/profile-main/server.mjs +2 -0
  112. package/dist/components/biz/business/profile/profile-main/shell.d.mts +25 -0
  113. package/dist/components/biz/business/profile/profile-main/shell.mjs +2 -0
  114. package/dist/components/biz/business/profile/profile-main/tabs/collect-tab/client.d.mts +25 -0
  115. package/dist/components/biz/business/profile/profile-main/tabs/collect-tab/client.mjs +2 -0
  116. package/dist/components/biz/business/profile/profile-main/tabs/collect-tab/index.d.mts +3 -0
  117. package/dist/components/biz/business/profile/profile-main/tabs/collect-tab/server.d.mts +54 -0
  118. package/dist/components/biz/business/profile/profile-main/tabs/collect-tab/server.mjs +2 -0
  119. package/dist/components/biz/business/profile/profile-main/tabs/history-tab/client.d.mts +19 -0
  120. package/dist/components/biz/business/profile/profile-main/tabs/history-tab/client.mjs +2 -0
  121. package/dist/components/biz/business/profile/profile-main/tabs/history-tab/index.d.mts +3 -0
  122. package/dist/components/biz/business/profile/profile-main/tabs/history-tab/server.d.mts +48 -0
  123. package/dist/components/{pages/profile/_components → biz/business/profile/profile-main}/tabs/history-tab/server.mjs +1 -1
  124. package/dist/components/biz/business/profile/profile-main/tabs/index.d.mts +13 -0
  125. package/dist/components/biz/business/profile/profile-main/tabs/like-tab/client.d.mts +76 -0
  126. package/dist/components/biz/business/profile/profile-main/tabs/like-tab/client.mjs +2 -0
  127. package/dist/components/biz/business/profile/profile-main/tabs/like-tab/index.d.mts +3 -0
  128. package/dist/components/biz/business/profile/profile-main/tabs/like-tab/server.d.mts +39 -0
  129. package/dist/components/{pages/profile/_components → biz/business/profile/profile-main}/tabs/like-tab/server.mjs +1 -1
  130. package/dist/components/biz/business/profile/profile-main/tabs/publish-tab/client.d.mts +30 -0
  131. package/dist/components/biz/business/profile/profile-main/tabs/publish-tab/client.mjs +2 -0
  132. package/dist/components/biz/business/profile/profile-main/tabs/publish-tab/index.d.mts +3 -0
  133. package/dist/components/biz/business/profile/profile-main/tabs/publish-tab/server.d.mts +33 -0
  134. package/dist/components/{pages/profile/_components → biz/business/profile/profile-main}/tabs/publish-tab/server.mjs +1 -1
  135. package/dist/components/biz/business/profile/profile-main/utils.mjs +2 -0
  136. package/dist/components/biz/business/profile/profile-main/variants.d.mts +32 -0
  137. package/dist/components/biz/business/profile/profile-main/variants.mjs +2 -0
  138. package/dist/components/biz/business/search-history/client.d.mts +7 -7
  139. package/dist/components/biz/business/search-history/client.mjs +1 -1
  140. package/dist/components/biz/business/search-history/index.d.mts +4 -4
  141. package/dist/components/biz/business/search-history/material.d.mts +3 -2
  142. package/dist/components/biz/business/search-history/material.mjs +1 -1
  143. package/dist/components/biz/business/search-history/schema.d.mts +8 -8
  144. package/dist/components/biz/business/search-history/server.d.mts +4 -4
  145. package/dist/components/biz/business/search-history/server.mjs +1 -1
  146. package/dist/components/biz/business/search-input/client.d.mts +2 -2
  147. package/dist/components/biz/business/search-input/client.mjs +1 -1
  148. package/dist/components/biz/business/search-input/index.d.mts +2 -2
  149. package/dist/components/biz/business/search-input/material.d.mts +2 -1
  150. package/dist/components/biz/business/search-input/material.mjs +1 -1
  151. package/dist/components/biz/business/search-input/schema.d.mts +5 -5
  152. package/dist/components/biz/business/shortcut-grid/client.d.mts +1 -1
  153. package/dist/components/biz/business/shortcut-grid/material.d.mts +2 -1
  154. package/dist/components/biz/business/shortcut-grid/schema.d.mts +11 -11
  155. package/dist/components/biz/business/shortcut-grid/server.d.mts +11 -0
  156. package/dist/components/biz/business/tab-bar/index.d.mts +2 -2
  157. package/dist/components/biz/business/tab-bar/material.d.mts +2 -1
  158. package/dist/components/biz/business/tab-bar/material.mjs +1 -1
  159. package/dist/components/biz/business/tab-bar/schema.d.mts +9 -9
  160. package/dist/components/biz/business/text-recommend/client.d.mts +2 -2
  161. package/dist/components/biz/business/text-recommend/client.mjs +1 -1
  162. package/dist/components/biz/business/text-recommend/index.d.mts +2 -2
  163. package/dist/components/biz/business/text-recommend/material.d.mts +2 -1
  164. package/dist/components/biz/business/text-recommend/material.mjs +1 -1
  165. package/dist/components/biz/business/text-recommend/schema.d.mts +6 -6
  166. package/dist/components/biz/business/video-horizontal-list/client.d.mts +5 -14
  167. package/dist/components/biz/business/video-horizontal-list/client.mjs +1 -1
  168. package/dist/components/biz/business/video-horizontal-list/index.d.mts +2 -2
  169. package/dist/components/biz/business/video-horizontal-list/material.d.mts +12 -2
  170. package/dist/components/biz/business/video-horizontal-list/material.mjs +1 -1
  171. package/dist/components/biz/business/video-horizontal-list/schema.d.mts +21 -3
  172. package/dist/components/biz/business/video-horizontal-list/schema.mjs +1 -1
  173. package/dist/components/biz/business/video-horizontal-list/server.d.mts +1 -1
  174. package/dist/components/biz/business/video-horizontal-list/server.mjs +1 -1
  175. package/dist/components/biz/example/button/index.d.mts +2 -2
  176. package/dist/components/biz/example/button/material.d.mts +2 -1
  177. package/dist/components/biz/example/button/schema.d.mts +14 -14
  178. package/dist/components/biz/renderer/renderer.d.mts +3 -3
  179. package/dist/components/biz/renderer/renderer.mjs +1 -1
  180. package/dist/components/pages/profile/page.mjs +1 -1
  181. package/dist/components/pages/search/page-client.mjs +1 -1
  182. package/dist/components/ui/button.d.mts +1 -1
  183. package/dist/materials.d.mts +4 -4
  184. package/dist/materials.mjs +1 -1
  185. package/dist/utils/schema/inspector.d.mts +111 -111
  186. package/dist/utils/schema/material.d.mts +13 -11
  187. package/dist/utils/schema/schema.d.mts +26 -26
  188. package/dist/utils/schema/utils.d.mts +1 -1
  189. package/dist/utils.mjs +1 -1
  190. package/package.json +1 -1
  191. package/dist/assets/images/Frame.mjs +0 -2
  192. package/dist/components/pages/profile/_components/tabs/collect-tab/client.mjs +0 -2
  193. package/dist/components/pages/profile/_components/tabs/collect-tab/server.mjs +0 -2
  194. package/dist/components/pages/profile/_components/tabs/history-tab/client.mjs +0 -2
  195. package/dist/components/pages/profile/_components/tabs/like-tab/client.mjs +0 -2
  196. package/dist/components/pages/profile/_components/tabs/publish-tab/client.mjs +0 -2
  197. package/dist/components/pages/profile/_components/user-profile-header/client.mjs +0 -2
  198. package/dist/components/pages/profile/_components/user-profile-header/user-profile-avatar.mjs +0 -2
  199. package/dist/components/pages/profile/_components/user-profile-header/user-profile-cover-background.mjs +0 -2
  200. package/dist/components/pages/profile/_components/user-profile-main/server.mjs +0 -2
  201. package/dist/components/pages/profile/_components/user-profile-main/shell.mjs +0 -2
  202. package/dist/components/pages/profile/utils.mjs +0 -2
@@ -1,2 +1,2 @@
1
1
 
2
- import{defineMaterial as e}from"../../../../utils/schema/material.mjs";import{textRecommendInspectorPropsSchema as t}from"./schema.mjs";import{TextRecommendServer as n}from"./server.mjs";const r=e({type:`text-recommend`,name:`文字推荐`,icon:`/static/components-thumb/search_recommend_text.png`,category:`内容组件`,serverComponent:n,clientComponent:n,propsSchema:t});export{r as textRecommendMaterial};
2
+ import{defineMaterial as e}from"../../../../utils/schema/material.mjs";import{TextRecommendClient as t}from"./client.mjs";import{textRecommendInspectorPropsSchema as n}from"./schema.mjs";import{TextRecommendServer as r}from"./server.mjs";const i=e({type:`text-recommend`,name:`文字推荐`,icon:`/static/components-thumb/search_recommend_text.png`,category:`内容组件`,serverComponent:r,clientComponent:t,propsSchema:n});export{i as textRecommendMaterial};
@@ -1,21 +1,21 @@
1
1
 
2
2
  import { SchemaHasDefaultValue } from "../../../../utils/schema/schema.mjs";
3
3
  import "../../../../utils.mjs";
4
- import z from "zod";
4
+ import z$1 from "zod";
5
5
 
6
6
  //#region components/biz/business/text-recommend/schema.d.ts
7
7
  /**
8
8
  * 文字推荐物料属性定义
9
9
  */
10
- declare const textRecommendInspectorPropsSchema: z.ZodObject<{
11
- title: z.ZodString & SchemaHasDefaultValue;
12
- count: z.ZodType<"4" | "6" | "8" | "10", unknown, z.core.$ZodTypeInternals<"4" | "6" | "8" | "10", unknown>> & SchemaHasDefaultValue;
13
- }, z.core.$strip>;
10
+ declare const textRecommendInspectorPropsSchema: z$1.ZodObject<{
11
+ title: z$1.ZodString & SchemaHasDefaultValue;
12
+ count: z$1.ZodType<"4" | "6" | "8" | "10", unknown, z$1.core.$ZodTypeInternals<"4" | "6" | "8" | "10", unknown>> & SchemaHasDefaultValue;
13
+ }, z$1.core.$strip>;
14
14
  declare const textRecommendInspectorDefaultProps: {
15
15
  title: string;
16
16
  count: "4" | "6" | "8" | "10";
17
17
  };
18
- type TextRecommendInspectorProps = z.infer<typeof textRecommendInspectorPropsSchema>;
18
+ type TextRecommendInspectorProps = z$1.infer<typeof textRecommendInspectorPropsSchema>;
19
19
  type TextRecommendProps = TextRecommendInspectorProps;
20
20
  //#endregion
21
21
  export { TextRecommendInspectorProps, TextRecommendProps, textRecommendInspectorDefaultProps, textRecommendInspectorPropsSchema };
@@ -1,25 +1,16 @@
1
1
 
2
- import { ContentGetAppChannelBlockDataResponse } from "../../../../types.mjs";
3
2
  import { VideoHorizontalListProps } from "./schema.mjs";
4
3
  import * as react_jsx_runtime0 from "react/jsx-runtime";
5
4
 
6
5
  //#region components/biz/business/video-horizontal-list/client.d.ts
7
- interface VideoHorizontalListClientProps extends VideoHorizontalListProps {
8
- initialData?: ContentGetAppChannelBlockDataResponse | null;
9
- defaultTitle: string;
10
- allEpisodesText: string;
11
- updatedToText: string;
6
+ interface ClientProps extends VideoHorizontalListProps {
7
+ allEpisodesText?: string;
8
+ updatedToText?: string;
12
9
  }
13
10
  /**
14
11
  * 视频横向列表物料组件 - 客户端部分
12
+ * 展示由配置面板传入的静态数据
15
13
  */
16
- declare function VideoHorizontalListClient({
17
- blockId,
18
- title: propTitle,
19
- initialData,
20
- defaultTitle,
21
- allEpisodesText,
22
- updatedToText
23
- }: VideoHorizontalListClientProps): react_jsx_runtime0.JSX.Element;
14
+ declare function VideoHorizontalListClient(props: ClientProps): react_jsx_runtime0.JSX.Element | null;
24
15
  //#endregion
25
16
  export { VideoHorizontalListClient };
@@ -1,2 +1,2 @@
1
1
 
2
- "use client";import{gContentGetAppChannelBlockData as e}from"../../../../service/generated/client.mjs";import{Image as t}from"../../../ui/image.mjs";import{Box as n}from"../../../ui/box.mjs";import{Text as r}from"../../../ui/text.mjs";import{usePaginated as i}from"../../../../hooks/query/use-query.mjs";import a from"../../../../assets/images/Frame.mjs";import{useRouter as o}from"next/navigation";import{useCallback as s,useMemo as c,useRef as l}from"react";import{jsx as u,jsxs as d}from"react/jsx-runtime";function f({blockId:f,title:p,initialData:m,defaultTitle:h,allEpisodesText:g,updatedToText:_}){let v=l(null),y=o(),b=e=>{if(!e)return`00:00`;let t=Math.floor(e/3600),n=Math.floor(e%3600/60),r=e%60,i=n.toString().padStart(2,`0`),a=r.toString().padStart(2,`0`);return t>0?`${t.toString().padStart(2,`0`)}:${i}:${a}`:`${i}:${a}`},x=g&&!g.includes(`.`)?g:`全{count}集`,S=_&&!_.includes(`.`)?_:`更新至{count}集`,C=s((e,t)=>!e&&e!==0?``:t===`1`?x.replace(`{count}`,String(e)):S.replace(`{count}`,String(e)),[x,S]),w=!!m?.block?.data?.videos?.length,T=c(()=>{if(w)return{pages:[{data:m}],pageParams:[void 0]}},[w,m]),{data:E,fetchNextPage:D,hasNextPage:O,isFetchingNextPage:k}=i({key:[`video-horizontal-list`,f],queryFn:t=>e({block_id:f,cursor:t}),getNextPageParam:e=>e.data?.block?.data?.cursor||void 0,options:{enabled:!!f,initialData:T},initialPageParam:void 0}),A=typeof a==`string`?a:a.src,j=c(()=>{let e=[];return E?.pages.forEach(t=>{let n=t.data?.block?.data?.videos;n&&e.push(...n)}),e.length===0?Array.from({length:4}).map((e,t)=>({id:`mock-${t}`,name:`这里是视频标题 ${t+1}`,img_x:A,type:2,episode_cnt:56,update_status:`1`,duration:3600,tags:[{name:`独家`}]})):e},[E,A]),M=s(()=>{if(!v.current||!O||k)return;let{scrollLeft:e,scrollWidth:t,clientWidth:n}=v.current;t-(e+n)<124.667*2&&D()},[O,k,D]),N=p||m?.block?.cn_name||h;return d(n,{className:`bg-bg1 flex flex-col gap-[12px] p-[12px] relative w-full overflow-hidden`,children:[N&&u(n,{className:`flex items-center relative shrink-0 w-full`,children:u(r,{as:`h2`,className:`text-[18px] font-bold text-text1 leading-[26px] truncate`,children:N})}),d(n,{ref:v,onScroll:M,className:`flex gap-[8px] items-start relative shrink-0 w-full overflow-x-auto no-scrollbar`,children:[j.map((e,i)=>{let a=e.tags?.[0]?.name;return d(n,{className:`flex flex-col gap-0 items-start relative shrink-0 w-[116.667px] cursor-pointer active:opacity-70 transition-opacity`,onClick:()=>{e.id&&!e.id.startsWith(`mock-`)&&y.push(`/video-detail/${e.id}`)},children:[d(n,{className:`flex flex-col items-start justify-between overflow-hidden relative rounded-[8px] w-full aspect-[116.667/155.5] bg-bg2`,children:[u(t,{src:e.img_x||A,alt:e.name||``,fill:!0,className:`object-cover`,unoptimized:!0,priority:!0}),a&&u(n,{className:`absolute top-0 right-0 h-[20px] flex items-center justify-center px-[6px] rounded-bl-[8px] rounded-tr-[8px] z-10`,style:{backgroundImage:`linear-gradient(120deg, #fd4c5e 1.59%, #f05d19 99.09%)`},children:u(r,{className:`text-[12px] text-white leading-[20px] font-medium whitespace-nowrap`,children:a})}),u(n,{className:`absolute bottom-0 left-0 right-0 bg-gradient-to-b from-transparent to-black/80 pt-[12px] pb-[4px] px-[4px] flex items-center justify-end`,children:u(r,{className:`text-[12px] text-white leading-[20px] whitespace-nowrap truncate max-w-full`,children:e.type===2?C(e.episode_cnt,e.update_status):b(e.duration)})})]}),u(n,{className:`py-[8px] w-full`,children:u(r,{className:`text-[16px] font-bold text-text1 leading-[24px] truncate w-full block`,children:e.name})})]},`${e.id}-${i}`)}),k&&u(n,{className:`flex items-center justify-center shrink-0 w-[40px] h-[80px]`,children:u(n,{className:`w-4 h-4 border-2 border-theme1 border-t-transparent rounded-full animate-spin`})})]})]})}export{f as VideoHorizontalListClient};
2
+ "use client";import{jsx as e,jsxs as t}from"react/jsx-runtime";import n from"next/image";function r(r){let{title:i,items:a=[]}=r;return!a||a.length===0?null:t(`div`,{className:`bg-bg1 px-3 py-3`,children:[i&&e(`div`,{className:`mb-3 flex items-center justify-between`,children:e(`h2`,{className:`text-[18px] font-bold text-text1 leading-[26px]`,children:i})}),e(`div`,{className:`flex overflow-x-auto pb-2 scrollbar-hide space-x-2`,children:a.map((r,i)=>t(`div`,{className:`flex-shrink-0 w-[116.67px]`,children:[t(`div`,{className:`relative aspect-[116.67/155.56] rounded-lg overflow-hidden bg-bg2`,children:[r.cover?e(n,{src:r.cover,alt:r.title,fill:!0,sizes:`116.67px`,className:`object-cover`}):e(`div`,{className:`w-full h-full flex items-center justify-center text-text3 text-xs`,children:`无封面`}),r.badge&&e(`div`,{className:`absolute top-0 right-0 text-white text-[12px] px-[6px] py-0 rounded-bl-[8px] rounded-tr-[8px] font-normal leading-[20px]`,style:{backgroundImage:`linear-gradient(120deg, #FD4C5E 1.59%, #F05D19 99.09%)`},children:r.badge}),e(`div`,{className:`absolute bottom-0 left-0 right-0 bg-gradient-to-t from-black/80 to-transparent pb-1 pt-3 px-1 flex justify-end items-center`,children:r.showEpisodes&&r.episodesText&&e(`span`,{className:`text-white text-[12px] leading-[20px]`,children:r.episodesText})})]}),e(`div`,{className:`mt-2 py-2`,children:e(`h3`,{className:`text-[16px] text-text1 line-clamp-1 font-bold leading-[24px]`,children:r.title})})]},i))})]})}export{r as VideoHorizontalListClient};
@@ -1,5 +1,5 @@
1
1
 
2
2
  import { VideoHorizontalListInspectorProps, VideoHorizontalListProps, videoHorizontalListInspectorDefaultProps, videoHorizontalListInspectorPropsSchema } from "./schema.mjs";
3
+ import { VideoHorizontalListClient } from "./client.mjs";
3
4
  import { VideoHorizontalListServer } from "./server.mjs";
4
- import { videoHorizontalListMaterial } from "./material.mjs";
5
- import { VideoHorizontalListClient } from "./client.mjs";
5
+ import { videoHorizontalListMaterial } from "./material.mjs";
@@ -2,6 +2,7 @@
2
2
  import { SchemaHasDefaultValue } from "../../../../utils/schema/schema.mjs";
3
3
  import { DefineMaterialOption } from "../../../../utils/schema/material.mjs";
4
4
  import "../../../../utils.mjs";
5
+ import { VideoHorizontalListClient } from "./client.mjs";
5
6
  import { VideoHorizontalListServer } from "./server.mjs";
6
7
  import * as zod from "zod";
7
8
  import * as zod_v4_core0 from "zod/v4/core";
@@ -10,9 +11,18 @@ import * as zod_v4_core0 from "zod/v4/core";
10
11
  /**
11
12
  * 视频横向列表物料定义
12
13
  */
13
- declare const videoHorizontalListMaterial: DefineMaterialOption<typeof VideoHorizontalListServer, zod.ZodObject<{
14
- blockId: zod.ZodString & SchemaHasDefaultValue;
14
+ declare const videoHorizontalListMaterial: DefineMaterialOption<typeof VideoHorizontalListServer, typeof VideoHorizontalListClient, zod.ZodObject<{
15
15
  title: zod.ZodString & SchemaHasDefaultValue;
16
+ items: zod.ZodArray<zod.ZodObject<{
17
+ title: zod.ZodString;
18
+ description: zod.ZodOptional<zod.ZodString>;
19
+ cover: zod.ZodOptional<zod.ZodString>;
20
+ playCount: zod.ZodOptional<zod.ZodString>;
21
+ showPlayCount: zod.ZodOptional<zod.ZodBoolean>;
22
+ showEpisodes: zod.ZodOptional<zod.ZodBoolean>;
23
+ episodesText: zod.ZodOptional<zod.ZodString>;
24
+ badge: zod.ZodOptional<zod.ZodString>;
25
+ }, zod_v4_core0.$strip>> & SchemaHasDefaultValue;
16
26
  }, zod_v4_core0.$strip>, "video-horizontal-list">;
17
27
  //#endregion
18
28
  export { videoHorizontalListMaterial };
@@ -1,2 +1,2 @@
1
1
 
2
- import{defineMaterial as e}from"../../../../utils/schema/material.mjs";import{videoHorizontalListInspectorPropsSchema as t}from"./schema.mjs";import{VideoHorizontalListServer as n}from"./server.mjs";const r=e({type:`video-horizontal-list`,name:`视频横向列表`,icon:`/static/components-thumb/search_recommend_media.png`,category:`内容组件`,serverComponent:n,clientComponent:n,propsSchema:t});export{r as videoHorizontalListMaterial};
2
+ import{defineMaterial as e}from"../../../../utils/schema/material.mjs";import{VideoHorizontalListClient as t}from"./client.mjs";import{videoHorizontalListInspectorPropsSchema as n}from"./schema.mjs";import{VideoHorizontalListServer as r}from"./server.mjs";const i=e({type:`video-horizontal-list`,name:`视频横向列表`,icon:`/static/components-thumb/search_recommend_media.png`,category:`内容组件`,serverComponent:r,clientComponent:t,propsSchema:n});export{i as videoHorizontalListMaterial};
@@ -1,19 +1,37 @@
1
1
 
2
2
  import { SchemaHasDefaultValue } from "../../../../utils/schema/schema.mjs";
3
3
  import "../../../../utils.mjs";
4
- import z from "zod";
4
+ import { z } from "zod";
5
5
 
6
6
  //#region components/biz/business/video-horizontal-list/schema.d.ts
7
7
  /**
8
8
  * 视频横向列表物料属性定义
9
9
  */
10
10
  declare const videoHorizontalListInspectorPropsSchema: z.ZodObject<{
11
- blockId: z.ZodString & SchemaHasDefaultValue;
12
11
  title: z.ZodString & SchemaHasDefaultValue;
12
+ items: z.ZodArray<z.ZodObject<{
13
+ title: z.ZodString;
14
+ description: z.ZodOptional<z.ZodString>;
15
+ cover: z.ZodOptional<z.ZodString>;
16
+ playCount: z.ZodOptional<z.ZodString>;
17
+ showPlayCount: z.ZodOptional<z.ZodBoolean>;
18
+ showEpisodes: z.ZodOptional<z.ZodBoolean>;
19
+ episodesText: z.ZodOptional<z.ZodString>;
20
+ badge: z.ZodOptional<z.ZodString>;
21
+ }, z.core.$strip>> & SchemaHasDefaultValue;
13
22
  }, z.core.$strip>;
14
23
  declare const videoHorizontalListInspectorDefaultProps: {
15
- blockId: string;
16
24
  title: string;
25
+ items: {
26
+ title: string;
27
+ description?: string | undefined;
28
+ cover?: string | undefined;
29
+ playCount?: string | undefined;
30
+ showPlayCount?: boolean | undefined;
31
+ showEpisodes?: boolean | undefined;
32
+ episodesText?: string | undefined;
33
+ badge?: string | undefined;
34
+ }[];
17
35
  };
18
36
  type VideoHorizontalListInspectorProps = z.infer<typeof videoHorizontalListInspectorPropsSchema>;
19
37
  type VideoHorizontalListProps = VideoHorizontalListInspectorProps;
@@ -1,2 +1,2 @@
1
1
 
2
- import{defineComponentPropsSchema as e,defineTextPropSchema as t,getSchemaDefaultProps as n}from"../../../../utils/schema/schema.mjs";const r=e({blockId:t({label:`推荐位 ID`,defaultValue:``}),title:t({label:`推荐名称`,defaultValue:`推荐视频`})}),i=n(r);export{i as videoHorizontalListInspectorDefaultProps,r as videoHorizontalListInspectorPropsSchema};
2
+ import{defineArrayItemPropSchema as e,defineComponentPropsSchema as t,defineTextPropSchema as n,getSchemaDefaultProps as r}from"../../../../utils/schema/schema.mjs";import{z as i}from"zod";const a=i.object({title:i.string(),description:i.string().optional(),cover:i.string().optional(),playCount:i.string().optional(),showPlayCount:i.boolean().optional(),showEpisodes:i.boolean().optional(),episodesText:i.string().optional(),badge:i.string().optional()}),o=t({title:n({label:`推荐位名称`,defaultValue:`推荐视频`}),items:e(a,{label:`推荐位模块`,defaultValue:[]})}),s=r(o);export{s as videoHorizontalListInspectorDefaultProps,o as videoHorizontalListInspectorPropsSchema};
@@ -5,7 +5,7 @@ import * as react_jsx_runtime0 from "react/jsx-runtime";
5
5
  //#region components/biz/business/video-horizontal-list/server.d.ts
6
6
  /**
7
7
  * 视频横向列表物料组件 - 服务端部分
8
- * 负责初始数据的预取和国际化文案
8
+ * 负责国际化文案的预取和属性透传
9
9
  */
10
10
  declare function VideoHorizontalListServer(props: VideoHorizontalListProps): Promise<react_jsx_runtime0.JSX.Element>;
11
11
  //#endregion
@@ -1,2 +1,2 @@
1
1
 
2
- import{gContentGetAppChannelBlockData as e}from"../../../../service/generated/client.mjs";import{VideoHorizontalListClient as t}from"./client.mjs";import{jsx as n}from"react/jsx-runtime";import{getTranslations as r}from"next-intl/server";async function i(i){let{blockId:a}=i,o=null,s=await r(`components.biz.business.videoHorizontalList`);if(a)try{o=(await e({block_id:a})).data}catch(e){console.error(`VideoHorizontalListServer prefetch error:`,e)}return n(t,{...i,initialData:o,defaultTitle:s(`defaultTitle`),allEpisodesText:s.raw(`allEpisodes`),updatedToText:s.raw(`updatedTo`)})}export{i as VideoHorizontalListServer};
2
+ import{VideoHorizontalListClient as e}from"./client.mjs";import{jsx as t}from"react/jsx-runtime";import{getTranslations as n}from"next-intl/server";async function r(r){let i=await n(`components.biz.business.videoHorizontalList`);return t(e,{...r,allEpisodesText:i.raw(`allEpisodes`),updatedToText:i.raw(`updatedTo`)})}export{r as VideoHorizontalListServer};
@@ -1,5 +1,5 @@
1
1
 
2
2
  import { ButtonInspectorProps, ButtonProps, buttonInspectorDefaultProps, buttonInspectorPropsSchema } from "./schema.mjs";
3
3
  import { ButtonClient } from "./client.mjs";
4
- import { exampleButtonMaterial } from "./material.mjs";
5
- import { Button } from "./server.mjs";
4
+ import { Button } from "./server.mjs";
5
+ import { exampleButtonMaterial } from "./material.mjs";
@@ -3,11 +3,12 @@ import { SchemaHasDefaultValue } from "../../../../utils/schema/schema.mjs";
3
3
  import { DefineMaterialOption } from "../../../../utils/schema/material.mjs";
4
4
  import "../../../../utils/schema/index.mjs";
5
5
  import { ButtonClient } from "./client.mjs";
6
+ import { Button } from "./server.mjs";
6
7
  import * as zod from "zod";
7
8
  import * as zod_v4_core0 from "zod/v4/core";
8
9
 
9
10
  //#region components/biz/example/button/material.d.ts
10
- declare const exampleButtonMaterial: DefineMaterialOption<typeof ButtonClient, zod.ZodObject<{
11
+ declare const exampleButtonMaterial: DefineMaterialOption<typeof Button, typeof ButtonClient, zod.ZodObject<{
11
12
  text: zod.ZodString & SchemaHasDefaultValue;
12
13
  variant: zod.ZodType<"default" | "blue" | "red", unknown, zod_v4_core0.$ZodTypeInternals<"default" | "blue" | "red", unknown>> & SchemaHasDefaultValue;
13
14
  disabled: zod.ZodOptional<zod.ZodBoolean> & SchemaHasDefaultValue;
@@ -1,24 +1,24 @@
1
1
 
2
2
  import { SchemaHasDefaultValue } from "../../../../utils/schema/schema.mjs";
3
3
  import "../../../../utils/schema/index.mjs";
4
- import z from "zod";
4
+ import z$1 from "zod";
5
5
 
6
6
  //#region components/biz/example/button/schema.d.ts
7
7
  /**
8
8
  * 定义可以被低代码右侧inspector编辑的props
9
9
  */
10
- declare const buttonInspectorPropsSchema: z.ZodObject<{
11
- text: z.ZodString & SchemaHasDefaultValue;
12
- variant: z.ZodType<"default" | "blue" | "red", unknown, z.core.$ZodTypeInternals<"default" | "blue" | "red", unknown>> & SchemaHasDefaultValue;
13
- disabled: z.ZodOptional<z.ZodBoolean> & SchemaHasDefaultValue;
14
- loading: z.ZodOptional<z.ZodBoolean>;
15
- items: z.ZodOptional<z.ZodArray<z.ZodObject<{
16
- name: z.ZodOptional<z.ZodString>;
17
- }, z.core.$strip>>> & SchemaHasDefaultValue;
18
- info: z.ZodOptional<z.ZodObject<{
19
- readonly address: z.ZodOptional<z.ZodString>;
20
- }, z.core.$strip>> & SchemaHasDefaultValue;
21
- }, z.core.$strip>;
10
+ declare const buttonInspectorPropsSchema: z$1.ZodObject<{
11
+ text: z$1.ZodString & SchemaHasDefaultValue;
12
+ variant: z$1.ZodType<"default" | "blue" | "red", unknown, z$1.core.$ZodTypeInternals<"default" | "blue" | "red", unknown>> & SchemaHasDefaultValue;
13
+ disabled: z$1.ZodOptional<z$1.ZodBoolean> & SchemaHasDefaultValue;
14
+ loading: z$1.ZodOptional<z$1.ZodBoolean>;
15
+ items: z$1.ZodOptional<z$1.ZodArray<z$1.ZodObject<{
16
+ name: z$1.ZodOptional<z$1.ZodString>;
17
+ }, z$1.core.$strip>>> & SchemaHasDefaultValue;
18
+ info: z$1.ZodOptional<z$1.ZodObject<{
19
+ readonly address: z$1.ZodOptional<z$1.ZodString>;
20
+ }, z$1.core.$strip>> & SchemaHasDefaultValue;
21
+ }, z$1.core.$strip>;
22
22
  declare const buttonInspectorDefaultProps: {
23
23
  text: string;
24
24
  variant: "default" | "blue" | "red";
@@ -30,7 +30,7 @@ declare const buttonInspectorDefaultProps: {
30
30
  address?: string | undefined;
31
31
  };
32
32
  };
33
- type ButtonInspectorProps<T extends object = object> = z.infer<typeof buttonInspectorPropsSchema> & T;
33
+ type ButtonInspectorProps<T extends object = object> = z$1.infer<typeof buttonInspectorPropsSchema> & T;
34
34
  /**
35
35
  * 基于ButtonInspectorProps再派生出组件真正的props(因为不是所有props都需要被编辑,比如说下面的children就不需要,但是button组件又需要传入children)
36
36
  */
@@ -1,15 +1,15 @@
1
1
 
2
2
  import { DefineMaterialOption } from "../../../utils/schema/material.mjs";
3
- import z from "zod";
4
3
  import { ComponentType, ReactNode } from "react";
5
4
  import * as react_jsx_runtime0 from "react/jsx-runtime";
5
+ import z$1 from "zod";
6
6
 
7
7
  //#region components/biz/renderer/renderer.d.ts
8
8
  type NodeInspectorProps = Record<string, unknown>;
9
9
  type NodeId = string;
10
10
  type MaterialType = string;
11
- type MaterialPropsSchema = z.ZodObject<z.ZodRawShape>;
12
- type MaterialCategory = DefineMaterialOption<ComponentType<any>, MaterialPropsSchema>['category'];
11
+ type MaterialPropsSchema = z$1.ZodObject<z$1.ZodRawShape>;
12
+ type MaterialCategory = DefineMaterialOption<ComponentType<any>, ComponentType<any>, MaterialPropsSchema>['category'];
13
13
  type RendererMode = 'server' | 'client';
14
14
  interface RendererMaterial<TSchema extends MaterialPropsSchema = MaterialPropsSchema> {
15
15
  type: MaterialType;
@@ -1,2 +1,2 @@
1
1
 
2
- import{generateMaterialMap as e}from"../../../utils/schema/utils.mjs";import{cn as t}from"../../../utils/cn.mjs";import{materials_exports as n}from"../../../materials.mjs";import{Fragment as r,jsx as i,jsxs as a}from"react/jsx-runtime";function o(e,t){let n=t.props,r=e.propsSchema.safeParse(n);return r.success?{isValid:!0,props:r.data}:{isValid:!1,props:n,message:r.error?.message}}function s(e){let{document:t,materialMap:n,nodeId:c,ancestors:l,mode:u}=e;if(l.has(c))return null;let d=t.page.nodes[c];if(!d)return null;let f=new Set(l);f.add(c);let p=d.children.map(e=>i(s,{document:t,materialMap:n,nodeId:e,ancestors:f,mode:u},e)),m=n[d.type];if(!m)return p.length===0?null:i(r,{children:p});let h=o(m,d);return h.isValid?i(u===`client`?m.clientComponent:m.serverComponent,{...h.props,children:p}):a(`div`,{children:[`组件配置错误`,h.message]})}function c(r){let{className:a,document:o,materials:c,mode:l=`server`}=r,u=o.page.nodes[o.page.rootId];if(!u)return i(`div`,{className:t(`funhub-renderer`,a)});let d=e(c??Object.values(n));return i(`div`,{className:t(`funhub-renderer`,a),children:i(s,{document:o,materialMap:d,nodeId:u.id,ancestors:new Set,mode:l})})}export{c as Renderer};
2
+ import{cn as e}from"../../../utils/cn.mjs";import{generateMaterialMap as t}from"../../../utils/schema/utils.mjs";import{materials_exports as n}from"../../../materials.mjs";import{Fragment as r,jsx as i,jsxs as a}from"react/jsx-runtime";function o(e,t){let n=t.props,r=e.propsSchema.safeParse(n);return r.success?{isValid:!0,props:r.data}:{isValid:!1,props:n,message:r.error?.message}}function s(e){let{document:t,materialMap:n,nodeId:c,ancestors:l,mode:u}=e;if(l.has(c))return null;let d=t.page.nodes[c];if(!d)return null;let f=new Set(l);f.add(c);let p=d.children.map(e=>i(s,{document:t,materialMap:n,nodeId:e,ancestors:f,mode:u},e)),m=n[d.type];if(!m)return p.length===0?null:i(r,{children:p});let h=o(m,d);return h.isValid?i(u===`client`?m.clientComponent:m.serverComponent,{...h.props,children:p}):a(`div`,{children:[`组件配置错误`,h.message]})}function c(r){let{className:a,document:o,materials:c,mode:l=`server`}=r,u=o.page.nodes[o.page.rootId];if(!u)return i(`div`,{className:e(`funhub-renderer`,a)});let d=t(c??Object.values(n));return i(`div`,{className:e(`funhub-renderer`,a),children:i(s,{document:o,materialMap:d,nodeId:u.id,ancestors:new Set,mode:l})})}export{c as Renderer};
@@ -1,2 +1,2 @@
1
1
 
2
- import{UserProfileHeader as e}from"./_components/user-profile-header/server.mjs";import{UserProfileMain as t}from"./_components/user-profile-main/server.mjs";import{UserProfilePageLayout as n}from"./layout.mjs";import{jsx as r,jsxs as i}from"react/jsx-runtime";import{cookies as a}from"next/headers";async function o(o){let{className:s,id:c,showCreateAction:l,showBackButton:u,requireLogin:d,tab:f,likeTab:p,historyTab:m,collectTab:h,collectCollectionTab:g}=o,_=await a(),v=_.get(`token`)?.value||``,y=_.get(`userId`)?.value||``,b={};v&&(b.Authorization=`Bearer ${v}`),y&&(b[`X-User-Id`]=y);let x=Object.keys(b).length>0?{headers:b}:void 0;return i(n,{id:c,cookieUserId:y,className:s,children:[r(e,{id:c,showBackButton:u,requireLogin:d,cookieToken:v,cookieUserId:y,token:v,currentUserId:y,authConfig:x}),r(t,{id:c,showCreateAction:l,requireLogin:d,cookieToken:v,cookieUserId:y,token:v,currentUserId:y,authConfig:x,tab:f,likeTab:p,historyTab:m,collectTab:h,collectCollectionTab:g})]})}export{o as UserProfilePage};
2
+ import{UserProfileHeader as e}from"../../biz/business/profile/profile-header/server.mjs";import{UserProfileMain as t}from"../../biz/business/profile/profile-main/server.mjs";import{UserProfilePageLayout as n}from"./layout.mjs";import{jsx as r,jsxs as i}from"react/jsx-runtime";import{cookies as a}from"next/headers";async function o(o){let{className:s,id:c,showCreateAction:l,showBackButton:u,requireLogin:d,tab:f,likeTab:p,historyTab:m,collectTab:h,collectCollectionTab:g}=o,_=await a(),v=_.get(`token`)?.value||``,y=_.get(`userId`)?.value||``,b={};v&&(b.Authorization=`Bearer ${v}`),y&&(b[`X-User-Id`]=y);let x=Object.keys(b).length>0?{headers:b}:void 0;return i(n,{id:c,cookieUserId:y,className:s,children:[r(e,{id:c,showBackButton:u,requireLogin:d,cookieToken:v,cookieUserId:y,token:v,currentUserId:y,authConfig:x}),r(t,{id:c,showCreateAction:l,requireLogin:d,cookieToken:v,cookieUserId:y,token:v,currentUserId:y,authConfig:x,tab:f,likeTab:p,historyTab:m,collectTab:h,collectCollectionTab:g})]})}export{o as UserProfilePage};
@@ -1,2 +1,2 @@
1
1
 
2
- "use client";import{updateUrlParams as e}from"../../../utils/common.mjs";import t from"../../../utils/event-bus.mjs";import{useUserStore as n}from"../../../store/modules/user-store.mjs";import{gContentGetRecommendSearchList as r}from"../../../service/generated/client.mjs";import{Text as i}from"../../ui/text.mjs";import{useRequest as a}from"../../../hooks/query/use-query.mjs";import{useSearchHistory as o}from"../../../hooks/use-search-history.mjs";import{SearchHistory2Server as s}from"../../biz/business/search-history/server.mjs";import{eventKey as c}from"../../../constants/event-key.mjs";import l from"./hot-recommend.mjs";import u from"./hot-search.mjs";import d from"./search-result/index.mjs";import f from"./top-header.mjs";import{useSearchParams as p}from"next/navigation";import{memo as m,useEffect as h,useMemo as g,useState as _}from"react";import{Fragment as v,jsx as y,jsxs as b}from"react/jsx-runtime";import{useTranslations as x}from"next-intl";const S=[{labelKey:`tabs.all`,value:`all`},{labelKey:`tabs.video`,value:`video`},{labelKey:`tabs.post`,value:`info`},{labelKey:`tabs.user`,value:`user`}],C=m(({searchType:e,onChange:t,tabList:n})=>y(`nav`,{className:`w-full h-[42px] bg-bg1 flex items-center px-[3px] sticky top-[53px] left-0 z-50`,children:n.map(n=>y(i,{className:`h-[30px] rounded-[15px] leading-[30px] px-[9px] text-[16px] bg-transparent transition-all duration-150 ${e===n.value?`text-theme5 !text-[20px] font-bold`:`text-text2`}`,onClick:()=>{e!==n.value&&t(n.value)},children:n.label},n.value))}));function w(){let i=x(`components.pages.search.pageClient`),{userInfo:m}=n(),w=m?.user_id||`guest`,T=p().get(`q`)?.toString()||``,E=T?decodeURIComponent(T):``,{data:D,refetch:O}=a([`hotSearchKey`],()=>r({user_id:w})),k=g(()=>D?.data?.recommend_list??[],[D]),[A,j]=_(E),M=g(()=>S.map(e=>({value:e.value,label:i(e.labelKey)})),[i]),[N,P]=_(E),[F,I]=_(0),[L,R]=_(S[0].value),[,z]=_([]),{history:B,addHistory:V}=o({storageKey:w}),H=g(()=>A.trim()===``?k.length>0||B.length>0||A.trim()===``:!1,[k,A,B]),U=g(()=>A.trim()!==``&&!H,[A,H]);return h(()=>(t.on(c.EXCHANGE_SEARCH_TYPE,R),()=>{t.off(c.EXCHANGE_SEARCH_TYPE,R)}),[R]),b(`div`,{className:`w-full min-h-screen bg-bg1 pb-[12px]`,children:[y(f,{setSearchInputVal:t=>{t!==A&&(z([]),j(t),e({q:t}))},initInputVal:N,initInputVersion:F,addSearchHistory:V}),H&&b(`div`,{className:`w-full pt-[8px]`,children:[B.length>0&&y(s,{title:i(`searchHistory`),rows:`2`,onHistoryClick:e=>{P(e),I(e=>e+1)}}),y(u,{initHotSearchKeywordList:k,onRefreshHotKey:async()=>(await O()).data??{code:0,message:``,data:{recommend_list:[]}},onClick:e=>{P(e.title||``),I(e=>e+1)}})]}),y(l,{isShow:A.trim()===``}),U&&b(v,{children:[y(C,{searchType:L,tabList:M,onChange:e=>{R(e),z([])}}),y(d,{inputVal:A,searchType:L},`${L}-${A}`)]})]})}export{w as default};
2
+ "use client";import{updateUrlParams as e}from"../../../utils/common.mjs";import t from"../../../utils/event-bus.mjs";import{useUserStore as n}from"../../../store/modules/user-store.mjs";import{gContentGetRecommendSearchList as r}from"../../../service/generated/client.mjs";import{Text as i}from"../../ui/text.mjs";import{useRequest as a}from"../../../hooks/query/use-query.mjs";import{useSearchHistory as o}from"../../../hooks/use-search-history.mjs";import{SearchHistoryServer as s}from"../../biz/business/search-history/server.mjs";import{eventKey as c}from"../../../constants/event-key.mjs";import l from"./hot-recommend.mjs";import u from"./hot-search.mjs";import d from"./search-result/index.mjs";import f from"./top-header.mjs";import{useSearchParams as p}from"next/navigation";import{memo as m,useEffect as h,useMemo as g,useState as _}from"react";import{Fragment as v,jsx as y,jsxs as b}from"react/jsx-runtime";import{useTranslations as x}from"next-intl";const S=[{labelKey:`tabs.all`,value:`all`},{labelKey:`tabs.video`,value:`video`},{labelKey:`tabs.post`,value:`info`},{labelKey:`tabs.user`,value:`user`}],C=m(({searchType:e,onChange:t,tabList:n})=>y(`nav`,{className:`w-full h-[42px] bg-bg1 flex items-center px-[3px] sticky top-[53px] left-0 z-50`,children:n.map(n=>y(i,{className:`h-[30px] rounded-[15px] leading-[30px] px-[9px] text-[16px] bg-transparent transition-all duration-150 ${e===n.value?`text-theme5 !text-[20px] font-bold`:`text-text2`}`,onClick:()=>{e!==n.value&&t(n.value)},children:n.label},n.value))}));function w(){let i=x(`components.pages.search.pageClient`),{userInfo:m}=n(),w=m?.user_id||`guest`,T=p().get(`q`)?.toString()||``,E=T?decodeURIComponent(T):``,{data:D,refetch:O}=a([`hotSearchKey`],()=>r({user_id:w})),k=g(()=>D?.data?.recommend_list??[],[D]),[A,j]=_(E),M=g(()=>S.map(e=>({value:e.value,label:i(e.labelKey)})),[i]),[N,P]=_(E),[F,I]=_(0),[L,R]=_(S[0].value),[,z]=_([]),{history:B,addHistory:V}=o({storageKey:w}),H=g(()=>A.trim()===``?k.length>0||B.length>0||A.trim()===``:!1,[k,A,B]),U=g(()=>A.trim()!==``&&!H,[A,H]);return h(()=>(t.on(c.EXCHANGE_SEARCH_TYPE,R),()=>{t.off(c.EXCHANGE_SEARCH_TYPE,R)}),[R]),b(`div`,{className:`w-full min-h-screen bg-bg1 pb-[12px]`,children:[y(f,{setSearchInputVal:t=>{t!==A&&(z([]),j(t),e({q:t}))},initInputVal:N,initInputVersion:F,addSearchHistory:V}),H&&b(`div`,{className:`w-full pt-[8px]`,children:[B.length>0&&y(s,{title:i(`searchHistory`),rows:`2`,onHistoryClick:e=>{P(e),I(e=>e+1)}}),y(u,{initHotSearchKeywordList:k,onRefreshHotKey:async()=>(await O()).data??{code:0,message:``,data:{recommend_list:[]}},onClick:e=>{P(e.title||``),I(e=>e+1)}})]}),y(l,{isShow:A.trim()===``}),U&&b(v,{children:[y(C,{searchType:L,tabList:M,onChange:e=>{R(e),z([])}}),y(d,{inputVal:A,searchType:L},`${L}-${A}`)]})]})}export{w as default};
@@ -8,7 +8,7 @@ import * as class_variance_authority_types0 from "class-variance-authority/types
8
8
  /** buttonVariants 工具定义。 */
9
9
  declare const buttonVariants: (props?: ({
10
10
  variant?: "link" | "default" | "destructive" | "secondary" | "outline" | "ghost" | null | undefined;
11
- size?: "default" | "icon" | "xs" | "sm" | "lg" | "icon-xs" | "icon-sm" | "icon-lg" | null | undefined;
11
+ size?: "default" | "xs" | "sm" | "lg" | "icon" | "icon-xs" | "icon-sm" | "icon-lg" | null | undefined;
12
12
  } & class_variance_authority_types0.ClassProp) | undefined) => string;
13
13
  /** Button 组件属性。 */
14
14
  type ButtonProps = Button.Props & VariantProps<typeof buttonVariants> & {
@@ -17,10 +17,12 @@ import { searchInputMaterial } from "./components/biz/business/search-input/mate
17
17
  import { tabBarMaterial } from "./components/biz/business/tab-bar/material.mjs";
18
18
  import { textRecommendMaterial } from "./components/biz/business/text-recommend/material.mjs";
19
19
  import { videoHorizontalListMaterial } from "./components/biz/business/video-horizontal-list/material.mjs";
20
- import { basicBannerMaterial } from "./components/biz/business/banner/variants/basic-banner/material.mjs";
21
20
  import { homeRecommendGridMaterial } from "./components/biz/business/home-recommend/variants/home-recommend-grid/material.mjs";
22
21
  import { homeRecommendWaterfallMaterial } from "./components/biz/business/home-recommend/variants/home-recommend-waterfall/material.mjs";
22
+ import { profileHeaderMaterial } from "./components/biz/business/profile/profile-header/material.mjs";
23
+ import { profileMainMaterial } from "./components/biz/business/profile/profile-main/material.mjs";
23
24
  import { exampleButtonMaterial } from "./components/biz/example/button/material.mjs";
25
+ import { BannerCarouselMaterial } from "./components/biz/business/banner-carousel/material.mjs";
24
26
  import { channelListMaterial } from "./components/biz/business/channel-list/material.mjs";
25
27
  import { floatingBallMaterial } from "./components/biz/business/floating-ball/material.mjs";
26
28
  import { headerAvatarIconMaterial } from "./components/biz/business/header-search/header-avatar-icon/material.mjs";
@@ -30,7 +32,5 @@ import { headerLogoSearchMaterial } from "./components/biz/business/header-searc
30
32
  import { headerSearchMaterial } from "./components/biz/business/header-search/header-search/material.mjs";
31
33
  import "./components/biz/business/header-search/index.mjs";
32
34
  import { largeFeatureGridMaterial } from "./components/biz/business/large-feature-grid/material.mjs";
33
- import { profileHeaderMaterial } from "./components/biz/business/profile/profile-header/material.mjs";
34
- import { profileMainMaterial } from "./components/biz/business/profile/profile-main/material.mjs";
35
35
  import { shortcutGridMaterial } from "./components/biz/business/shortcut-grid/material.mjs";
36
- export { basicBannerMaterial, channelListMaterial, exampleButtonMaterial, floatingBallMaterial, headerAvatarIconMaterial, headerAvatarLogoSearchIconMaterial, headerAvatarLogoSearchMaterial, headerLogoSearchMaterial, headerSearchMaterial, homeRecommendGridMaterial, homeRecommendWaterfallMaterial, largeFeatureGridMaterial, marqueeMaterial, profileHeaderMaterial, profileMainMaterial, searchHistoryMaterial, searchInputMaterial, shortcutGridMaterial, tabBarMaterial, textRecommendMaterial, videoDetailActionsMaterial, videoDetailInfoMaterial, videoDetailInfoTitleMaterial, videoDetailInfoTitleTagsEpisodesMaterial, videoDetailPlayerMaterial, videoDetailRecommendMaterial, videoHorizontalListMaterial };
36
+ export { BannerCarouselMaterial, channelListMaterial, exampleButtonMaterial, floatingBallMaterial, headerAvatarIconMaterial, headerAvatarLogoSearchIconMaterial, headerAvatarLogoSearchMaterial, headerLogoSearchMaterial, headerSearchMaterial, homeRecommendGridMaterial, homeRecommendWaterfallMaterial, largeFeatureGridMaterial, marqueeMaterial, profileHeaderMaterial, profileMainMaterial, searchHistoryMaterial, searchInputMaterial, shortcutGridMaterial, tabBarMaterial, textRecommendMaterial, videoDetailActionsMaterial, videoDetailInfoMaterial, videoDetailInfoTitleMaterial, videoDetailInfoTitleTagsEpisodesMaterial, videoDetailPlayerMaterial, videoDetailRecommendMaterial, videoHorizontalListMaterial };
@@ -1,2 +1,2 @@
1
1
 
2
- import{__exportAll as e}from"./_virtual/_rolldown/runtime.mjs";import{marqueeMaterial as t}from"./components/biz/business/marquee/material.mjs";import{searchHistoryMaterial as n}from"./components/biz/business/search-history/material.mjs";import{searchInputMaterial as r}from"./components/biz/business/search-input/material.mjs";import{tabBarMaterial as i}from"./components/biz/business/tab-bar/material.mjs";import{textRecommendMaterial as a}from"./components/biz/business/text-recommend/material.mjs";import{videoHorizontalListMaterial as o}from"./components/biz/business/video-horizontal-list/material.mjs";import{basicBannerMaterial as s}from"./components/biz/business/banner/variants/basic-banner/material.mjs";import{homeRecommendGridMaterial as c}from"./components/biz/business/home-recommend/variants/home-recommend-grid/material.mjs";import{homeRecommendWaterfallMaterial as l}from"./components/biz/business/home-recommend/variants/home-recommend-waterfall/material.mjs";import{exampleButtonMaterial as u}from"./components/biz/example/button/material.mjs";import{channelListMaterial as d}from"./components/biz/business/channel-list/material.mjs";import{videoDetailInfoMaterial as f}from"./components/biz/business/detail/materials/video-detail-info/material.mjs";import{videoDetailInfoTitleMaterial as p}from"./components/biz/business/detail/materials/video-detail-info-title/material.mjs";import{videoDetailInfoTitleTagsEpisodesMaterial as m}from"./components/biz/business/detail/materials/video-detail-info-title-tags-episodes/material.mjs";import{videoDetailPlayerMaterial as h}from"./components/biz/business/detail/materials/video-detail-player/material.mjs";import{videoDetailRecommendMaterial as g}from"./components/biz/business/detail/materials/video-detail-recommend/material.mjs";import{videoDetailActionsMaterial as _}from"./components/biz/business/detail/materials/video-detail-actions/material.mjs";import{floatingBallMaterial as v}from"./components/biz/business/floating-ball/material.mjs";import{headerAvatarIconMaterial as y}from"./components/biz/business/header-search/header-avatar-icon/material.mjs";import{headerAvatarLogoSearchMaterial as b}from"./components/biz/business/header-search/header-avatar-logo-search/material.mjs";import{headerAvatarLogoSearchIconMaterial as x}from"./components/biz/business/header-search/header-avatar-logo-search-icon/material.mjs";import{headerLogoSearchMaterial as S}from"./components/biz/business/header-search/header-logo-search/material.mjs";import{headerSearchMaterial as C}from"./components/biz/business/header-search/header-search/material.mjs";import{largeFeatureGridMaterial as w}from"./components/biz/business/large-feature-grid/material.mjs";import{profileHeaderMaterial as T}from"./components/biz/business/profile/profile-header/material.mjs";import{profileMainMaterial as E}from"./components/biz/business/profile/profile-main/material.mjs";import{shortcutGridMaterial as D}from"./components/biz/business/shortcut-grid/material.mjs";var O=e({basicBannerMaterial:()=>s,channelListMaterial:()=>d,exampleButtonMaterial:()=>u,floatingBallMaterial:()=>v,headerAvatarIconMaterial:()=>y,headerAvatarLogoSearchIconMaterial:()=>x,headerAvatarLogoSearchMaterial:()=>b,headerLogoSearchMaterial:()=>S,headerSearchMaterial:()=>C,homeRecommendGridMaterial:()=>c,homeRecommendWaterfallMaterial:()=>l,largeFeatureGridMaterial:()=>w,marqueeMaterial:()=>t,profileHeaderMaterial:()=>T,profileMainMaterial:()=>E,searchHistoryMaterial:()=>n,searchInputMaterial:()=>r,shortcutGridMaterial:()=>D,tabBarMaterial:()=>i,textRecommendMaterial:()=>a,videoDetailActionsMaterial:()=>_,videoDetailInfoMaterial:()=>f,videoDetailInfoTitleMaterial:()=>p,videoDetailInfoTitleTagsEpisodesMaterial:()=>m,videoDetailPlayerMaterial:()=>h,videoDetailRecommendMaterial:()=>g,videoHorizontalListMaterial:()=>o});export{s as basicBannerMaterial,d as channelListMaterial,u as exampleButtonMaterial,v as floatingBallMaterial,y as headerAvatarIconMaterial,x as headerAvatarLogoSearchIconMaterial,b as headerAvatarLogoSearchMaterial,S as headerLogoSearchMaterial,C as headerSearchMaterial,c as homeRecommendGridMaterial,l as homeRecommendWaterfallMaterial,w as largeFeatureGridMaterial,t as marqueeMaterial,O as materials_exports,T as profileHeaderMaterial,E as profileMainMaterial,n as searchHistoryMaterial,r as searchInputMaterial,D as shortcutGridMaterial,i as tabBarMaterial,a as textRecommendMaterial,_ as videoDetailActionsMaterial,f as videoDetailInfoMaterial,p as videoDetailInfoTitleMaterial,m as videoDetailInfoTitleTagsEpisodesMaterial,h as videoDetailPlayerMaterial,g as videoDetailRecommendMaterial,o as videoHorizontalListMaterial};
2
+ import{__exportAll as e}from"./_virtual/_rolldown/runtime.mjs";import{marqueeMaterial as t}from"./components/biz/business/marquee/material.mjs";import{searchHistoryMaterial as n}from"./components/biz/business/search-history/material.mjs";import{searchInputMaterial as r}from"./components/biz/business/search-input/material.mjs";import{tabBarMaterial as i}from"./components/biz/business/tab-bar/material.mjs";import{textRecommendMaterial as a}from"./components/biz/business/text-recommend/material.mjs";import{videoHorizontalListMaterial as o}from"./components/biz/business/video-horizontal-list/material.mjs";import{homeRecommendGridMaterial as s}from"./components/biz/business/home-recommend/variants/home-recommend-grid/material.mjs";import{homeRecommendWaterfallMaterial as c}from"./components/biz/business/home-recommend/variants/home-recommend-waterfall/material.mjs";import{profileHeaderMaterial as l}from"./components/biz/business/profile/profile-header/material.mjs";import{profileMainMaterial as u}from"./components/biz/business/profile/profile-main/material.mjs";import{exampleButtonMaterial as d}from"./components/biz/example/button/material.mjs";import{BannerCarouselMaterial as f}from"./components/biz/business/banner-carousel/material.mjs";import{channelListMaterial as p}from"./components/biz/business/channel-list/material.mjs";import{videoDetailInfoMaterial as m}from"./components/biz/business/detail/materials/video-detail-info/material.mjs";import{videoDetailInfoTitleMaterial as h}from"./components/biz/business/detail/materials/video-detail-info-title/material.mjs";import{videoDetailInfoTitleTagsEpisodesMaterial as g}from"./components/biz/business/detail/materials/video-detail-info-title-tags-episodes/material.mjs";import{videoDetailPlayerMaterial as _}from"./components/biz/business/detail/materials/video-detail-player/material.mjs";import{videoDetailRecommendMaterial as v}from"./components/biz/business/detail/materials/video-detail-recommend/material.mjs";import{videoDetailActionsMaterial as y}from"./components/biz/business/detail/materials/video-detail-actions/material.mjs";import{floatingBallMaterial as b}from"./components/biz/business/floating-ball/material.mjs";import{headerAvatarIconMaterial as x}from"./components/biz/business/header-search/header-avatar-icon/material.mjs";import{headerAvatarLogoSearchMaterial as S}from"./components/biz/business/header-search/header-avatar-logo-search/material.mjs";import{headerAvatarLogoSearchIconMaterial as C}from"./components/biz/business/header-search/header-avatar-logo-search-icon/material.mjs";import{headerLogoSearchMaterial as w}from"./components/biz/business/header-search/header-logo-search/material.mjs";import{headerSearchMaterial as T}from"./components/biz/business/header-search/header-search/material.mjs";import{largeFeatureGridMaterial as E}from"./components/biz/business/large-feature-grid/material.mjs";import{shortcutGridMaterial as D}from"./components/biz/business/shortcut-grid/material.mjs";var O=e({BannerCarouselMaterial:()=>f,channelListMaterial:()=>p,exampleButtonMaterial:()=>d,floatingBallMaterial:()=>b,headerAvatarIconMaterial:()=>x,headerAvatarLogoSearchIconMaterial:()=>C,headerAvatarLogoSearchMaterial:()=>S,headerLogoSearchMaterial:()=>w,headerSearchMaterial:()=>T,homeRecommendGridMaterial:()=>s,homeRecommendWaterfallMaterial:()=>c,largeFeatureGridMaterial:()=>E,marqueeMaterial:()=>t,profileHeaderMaterial:()=>l,profileMainMaterial:()=>u,searchHistoryMaterial:()=>n,searchInputMaterial:()=>r,shortcutGridMaterial:()=>D,tabBarMaterial:()=>i,textRecommendMaterial:()=>a,videoDetailActionsMaterial:()=>y,videoDetailInfoMaterial:()=>m,videoDetailInfoTitleMaterial:()=>h,videoDetailInfoTitleTagsEpisodesMaterial:()=>g,videoDetailPlayerMaterial:()=>_,videoDetailRecommendMaterial:()=>v,videoHorizontalListMaterial:()=>o});export{f as BannerCarouselMaterial,p as channelListMaterial,d as exampleButtonMaterial,b as floatingBallMaterial,x as headerAvatarIconMaterial,C as headerAvatarLogoSearchIconMaterial,S as headerAvatarLogoSearchMaterial,w as headerLogoSearchMaterial,T as headerSearchMaterial,s as homeRecommendGridMaterial,c as homeRecommendWaterfallMaterial,E as largeFeatureGridMaterial,t as marqueeMaterial,O as materials_exports,l as profileHeaderMaterial,u as profileMainMaterial,n as searchHistoryMaterial,r as searchInputMaterial,D as shortcutGridMaterial,i as tabBarMaterial,a as textRecommendMaterial,y as videoDetailActionsMaterial,m as videoDetailInfoMaterial,h as videoDetailInfoTitleMaterial,g as videoDetailInfoTitleTagsEpisodesMaterial,_ as videoDetailPlayerMaterial,v as videoDetailRecommendMaterial,o as videoHorizontalListMaterial};