@funhub/platform 0.1.151 → 0.1.153
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.
- package/dist/components/biz/business/banner/variants/basic-banner/inspector-schema.d.mts +4 -5
- package/dist/components/biz/business/banner/variants/basic-banner/inspector-schema.mjs +1 -1
- package/dist/components/biz/business/banner/variants/basic-banner/material.d.mts +2 -3
- package/dist/components/biz/business/banner-carousel/material.d.mts +2 -3
- package/dist/components/biz/business/banner-carousel/schema.d.mts +2 -3
- package/dist/components/biz/business/banner-carousel/schema.mjs +1 -1
- package/dist/components/biz/business/channel-list/material.d.mts +2 -3
- package/dist/components/biz/business/channel-list/schema.d.mts +2 -3
- package/dist/components/biz/business/channel-list/schema.mjs +1 -1
- package/dist/components/biz/business/detail/shared/registry.d.mts +14 -17
- package/dist/components/biz/business/detail/shared/runtime-context-provider.mjs +1 -1
- package/dist/components/biz/business/detail/shared/use-video-detail-webview-bridge.mjs +1 -1
- package/dist/components/biz/business/detail/video-detail-actions/schema.mjs +1 -1
- package/dist/components/biz/business/detail/video-detail-info/material.d.mts +2 -3
- package/dist/components/biz/business/detail/video-detail-info/schema.d.mts +2 -3
- package/dist/components/biz/business/detail/video-detail-info/schema.mjs +1 -1
- package/dist/components/biz/business/detail/video-detail-info/server.mjs +1 -1
- package/dist/components/biz/business/detail/video-detail-info-title-tags-episodes/material.d.mts +2 -3
- package/dist/components/biz/business/detail/video-detail-info-title-tags-episodes/schema.d.mts +2 -3
- package/dist/components/biz/business/detail/video-detail-info-title-tags-episodes/schema.mjs +1 -1
- package/dist/components/biz/business/detail/video-detail-player/schema.mjs +1 -1
- package/dist/components/biz/business/detail/video-detail-player-bridge-only/client.d.mts +1 -1
- package/dist/components/biz/business/detail/video-detail-player-bridge-only/client.mjs +1 -1
- package/dist/components/biz/business/detail/video-detail-player-bridge-only/schema.mjs +1 -1
- package/dist/components/biz/business/detail/video-detail-recommend/client.mjs +1 -1
- package/dist/components/biz/business/detail/video-detail-recommend/material.d.mts +10 -11
- package/dist/components/biz/business/detail/video-detail-recommend/schema.d.mts +10 -11
- package/dist/components/biz/business/detail/video-detail-recommend/schema.mjs +1 -1
- package/dist/components/biz/business/floating-ball/material.d.mts +2 -3
- package/dist/components/biz/business/floating-ball/schema.d.mts +4 -5
- package/dist/components/biz/business/floating-ball/schema.mjs +1 -1
- package/dist/components/biz/business/header-search/header-avatar-icon/schema.mjs +1 -1
- package/dist/components/biz/business/header-search/header-avatar-logo-search/material.d.mts +2 -3
- package/dist/components/biz/business/header-search/header-avatar-logo-search/schema.d.mts +2 -3
- package/dist/components/biz/business/header-search/header-avatar-logo-search/schema.mjs +1 -1
- package/dist/components/biz/business/header-search/header-avatar-logo-search-icon/material.d.mts +2 -3
- package/dist/components/biz/business/header-search/header-avatar-logo-search-icon/schema.d.mts +2 -3
- package/dist/components/biz/business/header-search/header-avatar-logo-search-icon/schema.mjs +1 -1
- package/dist/components/biz/business/header-search/header-logo-search/material.d.mts +2 -3
- package/dist/components/biz/business/header-search/header-logo-search/schema.d.mts +2 -3
- package/dist/components/biz/business/header-search/header-logo-search/schema.mjs +1 -1
- package/dist/components/biz/business/header-search/header-search/schema.mjs +1 -1
- package/dist/components/biz/business/home-recommend/home-recommend-grid/inspector-schema.d.mts +12 -13
- package/dist/components/biz/business/home-recommend/home-recommend-grid/inspector-schema.mjs +1 -1
- package/dist/components/biz/business/home-recommend/home-recommend-grid/material.d.mts +12 -13
- package/dist/components/biz/business/home-recommend/home-recommend-waterfall/inspector-schema.d.mts +10 -11
- package/dist/components/biz/business/home-recommend/home-recommend-waterfall/inspector-schema.mjs +1 -1
- package/dist/components/biz/business/home-recommend/home-recommend-waterfall/material.d.mts +10 -11
- package/dist/components/biz/business/home-recommend/shared/home-recommend-base.mjs +1 -1
- package/dist/components/biz/business/home-recommend/shared/home-recommend-server-data.mjs +1 -1
- package/dist/components/biz/business/home-recommend/shared/home-recommend-video-detail.mjs +1 -1
- package/dist/components/biz/business/image-text-recommend/material.d.mts +14 -15
- package/dist/components/biz/business/image-text-recommend/schema.d.mts +14 -15
- package/dist/components/biz/business/image-text-recommend/schema.mjs +1 -1
- package/dist/components/biz/business/large-feature-grid/client.mjs +1 -1
- package/dist/components/biz/business/large-feature-grid/schema.mjs +1 -1
- package/dist/components/biz/business/marquee/material.d.mts +7 -8
- package/dist/components/biz/business/marquee/schema.d.mts +24 -26
- package/dist/components/biz/business/marquee/schema.mjs +1 -1
- package/dist/components/biz/business/profile/profile-header/schema.mjs +1 -1
- package/dist/components/biz/business/profile/profile-header/user-profile-avatar.mjs +1 -1
- package/dist/components/biz/business/profile/profile-main/schema.mjs +1 -1
- package/dist/components/biz/business/profile/profile-main/tabs/like-tab/client.d.mts +1 -1
- package/dist/components/biz/business/search-history/client.mjs +1 -1
- package/dist/components/biz/business/search-history/material.d.mts +2 -3
- package/dist/components/biz/business/search-history/schema.d.mts +2 -3
- package/dist/components/biz/business/search-history/schema.mjs +1 -1
- package/dist/components/biz/business/search-input/schema.mjs +1 -1
- package/dist/components/biz/business/shortcut-grid/material.d.mts +4 -5
- package/dist/components/biz/business/shortcut-grid/schema.d.mts +4 -5
- package/dist/components/biz/business/shortcut-grid/schema.mjs +1 -1
- package/dist/components/biz/business/tab-bar/schema.mjs +1 -1
- package/dist/components/biz/business/text-recommend/material.d.mts +3 -4
- package/dist/components/biz/business/text-recommend/schema.d.mts +3 -4
- package/dist/components/biz/business/text-recommend/schema.mjs +1 -1
- package/dist/components/biz/example/button/material.d.mts +8 -9
- package/dist/components/biz/example/button/schema.d.mts +19 -21
- package/dist/components/biz/example/button/schema.mjs +1 -1
- package/dist/components/common/series-episodes/index.mjs +1 -1
- package/dist/components/common/video-player/process-m3u8-cache.mjs +1 -1
- package/dist/components/pages/collection-add/page.mjs +1 -1
- package/dist/components/pages/collection-create/form.mjs +1 -1
- package/dist/components/pages/collection-detail/detail.mjs +1 -1
- package/dist/components/pages/login/verify.mjs +1 -1
- package/dist/components/pages/video-detail/video-detail-client.mjs +1 -1
- package/dist/components/pages/video-list/video-list-client.mjs +1 -1
- package/dist/components/ui/image.d.mts +4 -4
- package/dist/hooks.d.mts +1 -3
- package/dist/hooks.mjs +1 -1
- package/dist/service/generated/client.d.mts +4 -12
- package/dist/service/generated/client.mjs +1 -1
- package/dist/service/generated/tanstack.d.mts +4 -14
- package/dist/service/generated/tanstack.mjs +1 -1
- package/dist/service/register-by-verify-email-code.d.mts +2 -2
- package/dist/service/register-by-verify-email-code.mjs +1 -1
- package/dist/service.d.mts +4 -4
- package/dist/service.mjs +1 -1
- package/dist/types.d.mts +57 -548
- package/dist/ui.d.mts +1 -2
- package/dist/ui.mjs +1 -1
- package/dist/utils/http.mjs +1 -1
- package/dist/utils/schema/index.d.mts +1 -1
- package/dist/utils/schema/inspector.d.mts +71 -43
- package/dist/utils/schema/schema.d.mts +53 -59
- package/dist/utils/schema/schema.mjs +1 -1
- package/dist/utils.d.mts +2 -3
- package/dist/utils.mjs +1 -1
- package/package.json +28 -28
- package/dist/components/ui/dots-loading.d.mts +0 -25
- package/dist/components/ui/dots-loading.mjs +0 -2
- package/dist/hooks/use-first-row-height.d.mts +0 -69
- package/dist/hooks/use-first-row-height.mjs +0 -2
- package/dist/hooks/use-min-duration-loading.d.mts +0 -18
- package/dist/hooks/use-min-duration-loading.mjs +0 -2
- package/dist/utils/device-id.d.mts +0 -14
- package/dist/utils/device-id.mjs +0 -2
|
@@ -8,22 +8,21 @@ import z$1 from "zod";
|
|
|
8
8
|
* 定义可以被低代码右侧 inspector 编辑的 props
|
|
9
9
|
*/
|
|
10
10
|
declare const basicBannerInspectorPropsSchema: z$1.ZodObject<{
|
|
11
|
-
|
|
12
|
-
|
|
11
|
+
interval: z$1.ZodNumber & SchemaHasDefaultValue;
|
|
12
|
+
list: z$1.ZodOptional<z$1.ZodArray<z$1.ZodObject<{
|
|
13
13
|
contentId: z$1.ZodOptional<z$1.ZodNumber>;
|
|
14
14
|
title: z$1.ZodOptional<z$1.ZodString>;
|
|
15
15
|
coverUrl: z$1.ZodOptional<z$1.ZodString>;
|
|
16
16
|
showViewCount: z$1.ZodOptional<z$1.ZodBoolean>;
|
|
17
17
|
}, z$1.core.$strip>>> & SchemaHasDefaultValue;
|
|
18
|
-
} & {
|
|
19
18
|
mode: z$1.ZodOptional<z$1.ZodEnum<{
|
|
20
19
|
renderer: "renderer";
|
|
21
20
|
editor: "editor";
|
|
22
21
|
}>>;
|
|
23
22
|
}, z$1.core.$strip>;
|
|
24
23
|
declare const basicBannerInspectorDefaultProps: {
|
|
25
|
-
|
|
26
|
-
|
|
24
|
+
interval: number;
|
|
25
|
+
list: {
|
|
27
26
|
contentId?: number | undefined;
|
|
28
27
|
title?: string | undefined;
|
|
29
28
|
coverUrl?: string | undefined;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
|
|
2
|
-
import{
|
|
2
|
+
import{defineArrayItemPropSchema as e,defineComponentPropsSchema as t,defineNumberPropSchema as n,defineSwitchPropSchema as r,defineTextPropSchema as i,getSchemaDefaultProps as a}from"../../../../../../utils/schema/schema.mjs";import{defaultProps as o}from"./defaults/default-props.mjs";import s from"zod";const c=t({interval:n({label:`播放间隔`,defaultValue:o.interval}),list:e(s.object({contentId:n({label:`内容ID`,required:!1}),title:i({label:`内容标题`,required:!1}),coverUrl:i({label:`封面`,required:!1}),showViewCount:r({label:`角标`,required:!1})}),{required:!1,label:`list`,defaultValue:[{contentId:1,title:`视频标题一`,desc:`视频描述`,coverUrl:`/static/components-resource/banner.png`,showViewCount:!1},{contentId:2,title:`视频标题二`,coverUrl:`/static/components-resource/banner.png`,showViewCount:!1},{contentId:3,title:`视频标题三`,coverUrl:`/static/components-resource/banner.png`,showViewCount:!1}]})}),l=a(c);export{l as basicBannerInspectorDefaultProps,c as basicBannerInspectorPropsSchema};
|
|
@@ -8,14 +8,13 @@ import * as zod_v4_core0 from "zod/v4/core";
|
|
|
8
8
|
|
|
9
9
|
//#region components/biz/business/banner/variants/basic-banner/material.d.ts
|
|
10
10
|
declare const basicBannerMaterial: DefineMaterialOption<typeof BasicBanner, typeof BasicBanner, zod.ZodObject<{
|
|
11
|
-
|
|
12
|
-
|
|
11
|
+
interval: zod.ZodNumber & SchemaHasDefaultValue;
|
|
12
|
+
list: zod.ZodOptional<zod.ZodArray<zod.ZodObject<{
|
|
13
13
|
contentId: zod.ZodOptional<zod.ZodNumber>;
|
|
14
14
|
title: zod.ZodOptional<zod.ZodString>;
|
|
15
15
|
coverUrl: zod.ZodOptional<zod.ZodString>;
|
|
16
16
|
showViewCount: zod.ZodOptional<zod.ZodBoolean>;
|
|
17
17
|
}, zod_v4_core0.$strip>>> & SchemaHasDefaultValue;
|
|
18
|
-
} & {
|
|
19
18
|
mode: zod.ZodOptional<zod.ZodEnum<{
|
|
20
19
|
renderer: "renderer";
|
|
21
20
|
editor: "editor";
|
|
@@ -8,8 +8,8 @@ import * as zod_v4_core0 from "zod/v4/core";
|
|
|
8
8
|
|
|
9
9
|
//#region components/biz/business/banner-carousel/material.d.ts
|
|
10
10
|
declare const BannerCarouselMaterial: DefineMaterialOption<typeof BannerCarousel, typeof BannerCarousel, zod.ZodObject<{
|
|
11
|
-
|
|
12
|
-
|
|
11
|
+
interval: zod.ZodNumber & SchemaHasDefaultValue;
|
|
12
|
+
list: zod.ZodOptional<zod.ZodArray<zod.ZodObject<{
|
|
13
13
|
contentId: zod.ZodOptional<zod.ZodNumber>;
|
|
14
14
|
title: zod.ZodOptional<zod.ZodString>;
|
|
15
15
|
coverUrl: zod.ZodOptional<zod.ZodString>;
|
|
@@ -18,7 +18,6 @@ declare const BannerCarouselMaterial: DefineMaterialOption<typeof BannerCarousel
|
|
|
18
18
|
showEpisodeCount: zod.ZodOptional<zod.ZodBoolean>;
|
|
19
19
|
target: zod.ZodOptional<zod.ZodString>;
|
|
20
20
|
}, zod_v4_core0.$strip>>> & SchemaHasDefaultValue;
|
|
21
|
-
} & {
|
|
22
21
|
mode: zod.ZodOptional<zod.ZodEnum<{
|
|
23
22
|
renderer: "renderer";
|
|
24
23
|
editor: "editor";
|
|
@@ -8,8 +8,8 @@ import z$1 from "zod";
|
|
|
8
8
|
* 定义可以被低代码右侧 inspector 编辑的 props
|
|
9
9
|
*/
|
|
10
10
|
declare const basicBannerInspectorPropsSchema: z$1.ZodObject<{
|
|
11
|
-
|
|
12
|
-
|
|
11
|
+
interval: z$1.ZodNumber & SchemaHasDefaultValue;
|
|
12
|
+
list: z$1.ZodOptional<z$1.ZodArray<z$1.ZodObject<{
|
|
13
13
|
contentId: z$1.ZodOptional<z$1.ZodNumber>;
|
|
14
14
|
title: z$1.ZodOptional<z$1.ZodString>;
|
|
15
15
|
coverUrl: z$1.ZodOptional<z$1.ZodString>;
|
|
@@ -18,7 +18,6 @@ declare const basicBannerInspectorPropsSchema: z$1.ZodObject<{
|
|
|
18
18
|
showEpisodeCount: z$1.ZodOptional<z$1.ZodBoolean>;
|
|
19
19
|
target: z$1.ZodOptional<z$1.ZodString>;
|
|
20
20
|
}, z$1.core.$strip>>> & SchemaHasDefaultValue;
|
|
21
|
-
} & {
|
|
22
21
|
mode: z$1.ZodOptional<z$1.ZodEnum<{
|
|
23
22
|
renderer: "renderer";
|
|
24
23
|
editor: "editor";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
|
|
2
|
-
import{
|
|
2
|
+
import{defineArrayItemPropSchema as e,defineComponentPropsSchema as t,defineNumberPropSchema as n,defineSwitchPropSchema as r,defineTextPropSchema as i,getSchemaDefaultProps as a}from"../../../../utils/schema/schema.mjs";import{defaultProps as o}from"./default-props.mjs";import s from"zod";const c=t({interval:n({label:`播放间隔`,defaultValue:o.interval}),list:e(s.object({contentId:n({label:`内容ID`,required:!1}),title:i({label:`内容标题`,required:!1}),coverUrl:i({label:`封面`,required:!1}),badgeUrl:i({label:`角标`,required:!1}),showPlayCount:r({label:`展示播放量`,required:!1}),showEpisodeCount:r({label:`展示集数`,required:!1}),target:i({label:`跳转地址`,required:!1})}),{required:!1,label:`list`,defaultValue:[{contentId:1,title:`视频标题一`,desc:`视频描述`,coverUrl:`/static/components-resource/banner.png`,badgeUrl:``,showPlayCount:!1,showEpisodeCount:!1,target:``},{contentId:2,title:`视频标题二`,coverUrl:`/static/components-resource/banner.png`,badgeUrl:``,showPlayCount:!1,showEpisodeCount:!1,target:``},{contentId:3,title:`视频标题三`,coverUrl:`/static/components-resource/banner.png`,badgeUrl:``,showPlayCount:!1,showEpisodeCount:!1,target:``}]})});a(c);export{c as basicBannerInspectorPropsSchema};
|
|
@@ -8,13 +8,12 @@ import * as zod_v4_core0 from "zod/v4/core";
|
|
|
8
8
|
|
|
9
9
|
//#region components/biz/business/channel-list/material.d.ts
|
|
10
10
|
declare const channelListMaterial: DefineMaterialOption<typeof BasicChannelListClient, typeof BasicChannelListClient, zod.ZodObject<{
|
|
11
|
-
|
|
12
|
-
|
|
11
|
+
modifiable: zod.ZodBoolean & SchemaHasDefaultValue;
|
|
12
|
+
list: zod.ZodOptional<zod.ZodArray<zod.ZodObject<{
|
|
13
13
|
name: zod.ZodOptional<zod.ZodString>;
|
|
14
14
|
icon: zod.ZodOptional<zod.ZodString>;
|
|
15
15
|
isDefault: zod.ZodOptional<zod.ZodBoolean>;
|
|
16
16
|
}, zod_v4_core0.$strip>>> & SchemaHasDefaultValue;
|
|
17
|
-
} & {
|
|
18
17
|
mode: zod.ZodOptional<zod.ZodEnum<{
|
|
19
18
|
renderer: "renderer";
|
|
20
19
|
editor: "editor";
|
|
@@ -10,13 +10,12 @@ import z$1 from "zod";
|
|
|
10
10
|
* 定义可以被低代码右侧inspector编辑的props
|
|
11
11
|
*/
|
|
12
12
|
declare const channelListInspectorPropsSchema: z$1.ZodObject<{
|
|
13
|
-
|
|
14
|
-
|
|
13
|
+
modifiable: z$1.ZodBoolean & SchemaHasDefaultValue;
|
|
14
|
+
list: z$1.ZodOptional<z$1.ZodArray<z$1.ZodObject<{
|
|
15
15
|
name: z$1.ZodOptional<z$1.ZodString>;
|
|
16
16
|
icon: z$1.ZodOptional<z$1.ZodString>;
|
|
17
17
|
isDefault: z$1.ZodOptional<z$1.ZodBoolean>;
|
|
18
18
|
}, z$1.core.$strip>>> & SchemaHasDefaultValue;
|
|
19
|
-
} & {
|
|
20
19
|
mode: z$1.ZodOptional<z$1.ZodEnum<{
|
|
21
20
|
renderer: "renderer";
|
|
22
21
|
editor: "editor";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
|
|
2
|
-
import{
|
|
2
|
+
import{defineArrayItemPropSchema as e,defineComponentPropsSchema as t,defineSwitchPropSchema as n,defineTextPropSchema as r,getSchemaDefaultProps as i}from"../../../../utils/schema/schema.mjs";import a from"zod";const o=t({modifiable:n({label:`自定义频道`,defaultValue:!0}),list:e(a.object({name:r({label:`内容标题`,required:!1}),icon:r({label:`图标`,required:!1}),isDefault:n({label:`是否默认频道`,required:!1})}),{required:!1,label:`list`,defaultValue:[{name:`频道名称`,icon:``,isDefault:!0}]})});i(o);export{o as channelListInspectorPropsSchema};
|
|
@@ -35,17 +35,15 @@ declare const videoDetailMaterials: MaterialMap<readonly [DefineMaterialOption<t
|
|
|
35
35
|
editor: "editor";
|
|
36
36
|
}>>;
|
|
37
37
|
}, z$1.core.$strip>, "video-detail-player-bridge-only", "视频模块">, DefineMaterialOption<typeof VideoDetailInfo, typeof VideoDetailInfoClient, z$1.ZodObject<{
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
} & {
|
|
38
|
+
showTags: z$1.ZodBoolean & SchemaHasDefaultValue;
|
|
39
|
+
showEpisodes: z$1.ZodBoolean & SchemaHasDefaultValue;
|
|
41
40
|
mode: z$1.ZodOptional<z$1.ZodEnum<{
|
|
42
41
|
renderer: "renderer";
|
|
43
42
|
editor: "editor";
|
|
44
43
|
}>>;
|
|
45
44
|
}, z$1.core.$strip>, "video-detail-info", "内容组件">, DefineMaterialOption<typeof VideoDetailInfoTitleTagsEpisodes, typeof VideoDetailInfoTitleTagsEpisodesClient, z$1.ZodObject<{
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
} & {
|
|
45
|
+
showTags: z$1.ZodBoolean & SchemaHasDefaultValue;
|
|
46
|
+
showEpisodes: z$1.ZodBoolean & SchemaHasDefaultValue;
|
|
49
47
|
mode: z$1.ZodOptional<z$1.ZodEnum<{
|
|
50
48
|
renderer: "renderer";
|
|
51
49
|
editor: "editor";
|
|
@@ -56,16 +54,16 @@ declare const videoDetailMaterials: MaterialMap<readonly [DefineMaterialOption<t
|
|
|
56
54
|
editor: "editor";
|
|
57
55
|
}>>;
|
|
58
56
|
}, z$1.core.$strip>, "video-detail-actions", "行为组件">, DefineMaterialOption<typeof VideoDetailRecommend, typeof VideoDetailRecommendClient, z$1.ZodObject<{
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
57
|
+
rows: z$1.ZodNumber & SchemaHasDefaultValue;
|
|
58
|
+
columns: z$1.ZodNumber & SchemaHasDefaultValue;
|
|
59
|
+
smartTagEnabled: z$1.ZodBoolean & SchemaHasDefaultValue;
|
|
60
|
+
title: z$1.ZodString & SchemaHasDefaultValue;
|
|
61
|
+
showPlayCount: z$1.ZodBoolean & SchemaHasDefaultValue;
|
|
62
|
+
playCountDelta: z$1.ZodNumber & SchemaHasDefaultValue;
|
|
63
|
+
showEpisode: z$1.ZodBoolean & SchemaHasDefaultValue;
|
|
64
|
+
enableInfinite: z$1.ZodBoolean & SchemaHasDefaultValue;
|
|
65
|
+
smartTagIds: z$1.ZodOptional<z$1.ZodArray<z$1.ZodString>>;
|
|
66
|
+
items: z$1.ZodOptional<z$1.ZodArray<z$1.ZodObject<{
|
|
69
67
|
contentId: z$1.ZodString;
|
|
70
68
|
coverMode: z$1.ZodOptional<z$1.ZodEnum<{
|
|
71
69
|
content: "content";
|
|
@@ -82,7 +80,6 @@ declare const videoDetailMaterials: MaterialMap<readonly [DefineMaterialOption<t
|
|
|
82
80
|
playCountDelta: z$1.ZodOptional<z$1.ZodNumber>;
|
|
83
81
|
showEpisode: z$1.ZodOptional<z$1.ZodBoolean>;
|
|
84
82
|
}, z$1.core.$strip>>>;
|
|
85
|
-
} & {
|
|
86
83
|
mode: z$1.ZodOptional<z$1.ZodEnum<{
|
|
87
84
|
renderer: "renderer";
|
|
88
85
|
editor: "editor";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
|
|
2
|
-
"use client";import{gContentGetVideoDetail as e}from"../../../../../service/generated/client.mjs";import{useRouter as t}from"../../../../../utils/use-compatible-router.mjs";import{notifyBridgeEpisodeChanged as n}from"../../../../../utils/login-modal-bridge.mjs";import{useRequest as r}from"../../../../../hooks/query/use-query.mjs";import{useKeepAliveState as i}from"../../../../common/keep-scroll-position/index.mjs";import{createContext as a,use as o,useCallback as s,useEffect as c,useMemo as l}from"react";import{jsx as u}from"react/jsx-runtime";import{useParams as d}from"next/navigation";const f=a(void 0),p=`funhub:video-detail-episode-sync`;function m(e,t){let n=String(e||``).split(`/`).filter(Boolean),r=n.findIndex(e=>e===`video`||e===`webview`);return r<0?!1:n[r+1]===t}function h(e){let t=Math.floor(Number(e)||1);return t>0?t:1}function g(e){typeof window>`u`||window.dispatchEvent(new CustomEvent(p,{detail:e}))}function _(e){return e.type===p&&e instanceof CustomEvent}function v(e,t){if(!(!e&&!t))return{information:e?.information??t?.information,currentSeriesNum:e?.currentSeriesNum??t?.currentSeriesNum,onEpisodeChange:e?.onEpisodeChange??t?.onEpisodeChange,onUpdateInformation:e?.onUpdateInformation??t?.onUpdateInformation,detailId:e?.detailId??t?.detailId,episodeIndex:e?.episodeIndex??t?.episodeIndex,resumeProgressSeconds:e?.resumeProgressSeconds??t?.resumeProgressSeconds,isShow:e?.isShow??t?.isShow,isWebView:e?.isWebView??t?.isWebView,isInformationLoading:e?.isInformationLoading??t?.isInformationLoading,isInformationResolved:e?.isInformationResolved??t?.isInformationResolved}}function y({value:e,children:t}){let n=o(f);return u(f,{value:l(()=>v(n,e)??e,[n,e]),children:t})}function b(){let e=o(f),t=x({enabled:e===void 0||e.onEpisodeChange===void 0||e.detailId===void 0||e.currentSeriesNum===void 0||e.episodeIndex===void 0||e.isInformationLoading===void 0||e.isInformationResolved===void 0,shouldRequestInformation:!e?.information});return l(()=>{let n=v(e,t);return n&&(e&&t&&e.onEpisodeChange===void 0?{...n,currentSeriesNum:t.currentSeriesNum??n.currentSeriesNum,episodeIndex:t.episodeIndex??n.episodeIndex,onEpisodeChange:t.onEpisodeChange??n.onEpisodeChange}:n)},[e,t])}function x(a){let{enabled:o,shouldRequestInformation:u}=a,f=d(),v=t(),y=f.level,b=Array.isArray(y)?y:typeof y==`string`?[y]:[],x=b[0]||``,S=b.findIndex(e=>e===`episode`),C=S>=0?b[S+1]:b[2],w=Math.max(1,Number(C)||1),[T,E]=i(`video-detail-material-series-num-${x}`,w);c(()=>{E(w)},[w,E]),c(()=>{if(!x||typeof window>`u`)return;let e=e=>{if(!_(e))return;let t=e.detail;if(!t||t.detailId!==x)return;let n=h(t.seriesNum);E(e=>e===n?e:n)};return window.addEventListener(p,e),()=>{window.removeEventListener(p,e)}},[x,E]);let D=s(e=>{if(!x)return;let t=h(e);E(t),g({detailId:x,seriesNum:t})},[x,E]),O=Math.max(1,Number(T)||1),k=Math.max(0,O-1),A=b[1]||``,j=typeof window<`u`&&window.isWebView===!0,{data:M,isPending:N,isFetching:P,isError:F,isSuccess:I}=r([`video-detail-material-fallback`,x],async()=>x?await e({id:x}):null,{enabled:o&&u&&!!x}),L=l(()=>{let e=M?.data?.video;if(!(!e||typeof e!=`object`))return{...e,content_type:1,episode_cnt:e.links?.length||0}},[M?.data?.video]),R=s(e=>{let t=Math.max(1,Math.floor(Number(e)||1));if(!x||typeof window>`u`)return;let r=`/video/${x}/${encodeURIComponent(A)}/episode/${t}`,{search:i,hash:a,pathname:o}=window.location,s=`${o}${i}${a}`,c=`${r}${i}${a}`,l=m(o,x);if(s!==c){j&&n({
|
|
2
|
+
"use client";import{gContentGetVideoDetail as e}from"../../../../../service/generated/client.mjs";import{useRouter as t}from"../../../../../utils/use-compatible-router.mjs";import{notifyBridgeEpisodeChanged as n}from"../../../../../utils/login-modal-bridge.mjs";import{useRequest as r}from"../../../../../hooks/query/use-query.mjs";import{useKeepAliveState as i}from"../../../../common/keep-scroll-position/index.mjs";import{createContext as a,use as o,useCallback as s,useEffect as c,useMemo as l}from"react";import{jsx as u}from"react/jsx-runtime";import{useParams as d}from"next/navigation";const f=a(void 0),p=`funhub:video-detail-episode-sync`;function m(e,t){let n=String(e||``).split(`/`).filter(Boolean),r=n.findIndex(e=>e===`video`||e===`webview`);return r<0?!1:n[r+1]===t}function h(e){let t=Math.floor(Number(e)||1);return t>0?t:1}function g(e){typeof window>`u`||window.dispatchEvent(new CustomEvent(p,{detail:e}))}function _(e){return e.type===p&&e instanceof CustomEvent}function v(e,t){if(!(!e&&!t))return{information:e?.information??t?.information,currentSeriesNum:e?.currentSeriesNum??t?.currentSeriesNum,onEpisodeChange:e?.onEpisodeChange??t?.onEpisodeChange,onUpdateInformation:e?.onUpdateInformation??t?.onUpdateInformation,detailId:e?.detailId??t?.detailId,episodeIndex:e?.episodeIndex??t?.episodeIndex,resumeProgressSeconds:e?.resumeProgressSeconds??t?.resumeProgressSeconds,isShow:e?.isShow??t?.isShow,isWebView:e?.isWebView??t?.isWebView,isInformationLoading:e?.isInformationLoading??t?.isInformationLoading,isInformationResolved:e?.isInformationResolved??t?.isInformationResolved}}function y({value:e,children:t}){let n=o(f);return u(f,{value:l(()=>v(n,e)??e,[n,e]),children:t})}function b(){let e=o(f),t=x({enabled:e===void 0||e.onEpisodeChange===void 0||e.detailId===void 0||e.currentSeriesNum===void 0||e.episodeIndex===void 0||e.isInformationLoading===void 0||e.isInformationResolved===void 0,shouldRequestInformation:!e?.information});return l(()=>{let n=v(e,t);return n&&(e&&t&&e.onEpisodeChange===void 0?{...n,currentSeriesNum:t.currentSeriesNum??n.currentSeriesNum,episodeIndex:t.episodeIndex??n.episodeIndex,onEpisodeChange:t.onEpisodeChange??n.onEpisodeChange}:n)},[e,t])}function x(a){let{enabled:o,shouldRequestInformation:u}=a,f=d(),v=t(),y=f.level,b=Array.isArray(y)?y:typeof y==`string`?[y]:[],x=b[0]||``,S=b.findIndex(e=>e===`episode`),C=S>=0?b[S+1]:b[2],w=Math.max(1,Number(C)||1),[T,E]=i(`video-detail-material-series-num-${x}`,w);c(()=>{E(w)},[w,E]),c(()=>{if(!x||typeof window>`u`)return;let e=e=>{if(!_(e))return;let t=e.detail;if(!t||t.detailId!==x)return;let n=h(t.seriesNum);E(e=>e===n?e:n)};return window.addEventListener(p,e),()=>{window.removeEventListener(p,e)}},[x,E]);let D=s(e=>{if(!x)return;let t=h(e);E(t),g({detailId:x,seriesNum:t})},[x,E]),O=Math.max(1,Number(T)||1),k=Math.max(0,O-1),A=b[1]||``,j=typeof window<`u`&&window.isWebView===!0,{data:M,isPending:N,isFetching:P,isError:F,isSuccess:I}=r([`video-detail-material-fallback`,x],async()=>x?await e({id:x}):null,{enabled:o&&u&&!!x}),L=l(()=>{let e=M?.data?.video;if(!(!e||typeof e!=`object`))return{...e,content_type:1,episode_cnt:e.links?.length||0}},[M?.data?.video]),R=s(e=>{let t=Math.max(1,Math.floor(Number(e)||1));if(!x||typeof window>`u`)return;let r=`/video/${x}/${encodeURIComponent(A)}/episode/${t}`,{search:i,hash:a,pathname:o}=window.location,s=`${o}${i}${a}`,c=`${r}${i}${a}`,l=m(o,x);if(s!==c){j&&n({detailId:x,seriesNum:t,nextPath:r}),l&&typeof window.history?.replaceState==`function`?(window.history.replaceState(window.history.state,``,c),D(t)):v.replace(c,{scroll:!1});return}O!==t&&D(t)},[O,x,j,A,v,D]);if(o)return{information:L,currentSeriesNum:O,onEpisodeChange:R,detailId:x,episodeIndex:k,resumeProgressSeconds:0,isShow:!0,isWebView:j,isInformationLoading:u?!!x&&!L&&(N||P):!1,isInformationResolved:!x||!!L||!u||F||I}}export{y as VideoDetailMaterialRuntimeProvider,b as useVideoDetailMaterialRuntimeContext};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
|
|
2
|
-
"use client";import{decryptImageToUint8Array as
|
|
2
|
+
"use client";import e from"../../../../../utils/get-res-url.mjs";import{decryptImageToUint8Array as t}from"../../../../../utils/decrypt-image-client.mjs";import{pInteractionBrowse as n}from"../../../../../service/generated/client.mjs";import{uint8ArrayToBase64 as r}from"../../../../../utils/uint8.mjs";import{batchQueryContentInteractions as i}from"../../../../../hooks/use-content-operate.mjs";import{useCallback as a,useEffect as o,useMemo as s}from"react";function c(e){let t=String(e||``).split(`/`).filter(Boolean),n=t.findIndex(e=>e===`video`||e===`webview`);if(n<0)return``;try{return decodeURIComponent(t[n+1]||``)}catch{return t[n+1]||``}}function l(l){let{enabled:u=!0,detailId:d=``,information:f,episodeIndex:p=0,currentSeriesNum:m=1}=l,h=s(()=>String(d||f?.id||``).trim()||(typeof window<`u`?c(window.location.pathname):``),[d,f?.id]),g=a(()=>{let t=f?.links?.[p]?.m3u8_url||``,n=process.env.NEXT_PUBLIC_API_BASE||(typeof window<`u`?window.location.origin:``),r=t?`${e()}/m3f/${t}`:``,i=t&&n?`${n}/api/content/processM3u8?url=${encodeURIComponent(r)}`:``,a=f?.name||``;return{posterUrl:f?.img_y||f?.img_x||f?.preview_images?.[0]||``,src:i,title:a}},[p,f]),_=a(async()=>{let{src:e,title:n,posterUrl:i}=g(),a=``;if(i)try{let e=await t(i);e&&(a=r(e.bytes))}catch(e){console.warn(`[webview bridge] getVideoInfoAsync poster failed:`,e)}return{poster:a,src:e,title:n}},[g]),v=a(async()=>{if(!h)return null;let e=await i([h],1);return e?.interaction_list?.[0]?e.interaction_list[0].browse_record:null},[h]),y=a(async e=>{if(!h)return;let t=e.browse_episode||m,r=Date.now(),i=String(e.browse_key||r);try{await n({app_id:0,content_type:1,content_id:h,browse_duration:Number(e.browse_duration||0),browse_episode:String(t),browse_key:i,browse_page_ts:r})}catch(e){console.error(`上报播放进度失败:`,e)}},[m,h]);o(()=>{if(!u||typeof window>`u`)return;let e=window;return e.__funhubWebViewBridgeReady=!0,e.__funhubWebViewBridgeDetailId=h,e.video=h?{[h]:f}:{},e.getVideoInfo=g,e.getVideoInfoAsync=_,e.getVideoBrowseRecordAsync=v,e.reportVideoBrowse=y,window.dispatchEvent(new CustomEvent(`funhub:webview-bridge-ready`,{detail:{detailId:h}})),()=>{e.getVideoInfoAsync===_&&delete e.getVideoInfoAsync,e.getVideoInfo===g&&delete e.getVideoInfo,e.getVideoBrowseRecordAsync===v&&delete e.getVideoBrowseRecordAsync,e.reportVideoBrowse===y&&delete e.reportVideoBrowse}},[g,v,_,u,f,y,h])}export{l as useVideoDetailWebViewBridge};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
|
|
2
|
-
import{defineComponentPropsSchema as e,getSchemaDefaultProps as t}from"../../../../../utils/schema/schema.mjs";const n=e(
|
|
2
|
+
import{defineComponentPropsSchema as e,getSchemaDefaultProps as t}from"../../../../../utils/schema/schema.mjs";const n=e({});t(n);export{n as videoDetailActionsInspectorPropsSchema};
|
|
@@ -9,9 +9,8 @@ import * as zod_v4_core0 from "zod/v4/core";
|
|
|
9
9
|
|
|
10
10
|
//#region components/biz/business/detail/video-detail-info/material.d.ts
|
|
11
11
|
declare const videoDetailInfoMaterial: DefineMaterialOption<typeof VideoDetailInfo, typeof VideoDetailInfoClient, zod.ZodObject<{
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
} & {
|
|
12
|
+
showTags: zod.ZodBoolean & SchemaHasDefaultValue;
|
|
13
|
+
showEpisodes: zod.ZodBoolean & SchemaHasDefaultValue;
|
|
15
14
|
mode: zod.ZodOptional<zod.ZodEnum<{
|
|
16
15
|
renderer: "renderer";
|
|
17
16
|
editor: "editor";
|
|
@@ -9,9 +9,8 @@ import * as zod_v4_core0 from "zod/v4/core";
|
|
|
9
9
|
* 媒体信息-简介&选集物料暂不对外开放配置。
|
|
10
10
|
*/
|
|
11
11
|
declare const videoDetailInfoInspectorPropsSchema: zod.ZodObject<{
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
} & {
|
|
12
|
+
showTags: zod.ZodBoolean & SchemaHasDefaultValue;
|
|
13
|
+
showEpisodes: zod.ZodBoolean & SchemaHasDefaultValue;
|
|
15
14
|
mode: zod.ZodOptional<zod.ZodEnum<{
|
|
16
15
|
renderer: "renderer";
|
|
17
16
|
editor: "editor";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
|
|
2
|
-
import{defineComponentPropsSchema as e,getSchemaDefaultProps as
|
|
2
|
+
import{defineComponentPropsSchema as e,defineSwitchPropSchema as t,getSchemaDefaultProps as n}from"../../../../../utils/schema/schema.mjs";const r=e({showTags:t({label:`显示标签`,defaultValue:!1}),showEpisodes:t({label:`显示选集`,defaultValue:!0})});n(r);export{r as videoDetailInfoInspectorPropsSchema};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
|
|
2
|
-
import{VideoDetailMaterialRuntimeProvider as e}from"../shared/runtime-context-provider.mjs";import{VideoDetailInfoClient as t}from"./client.mjs";import{resolveVideoDetailRouteFromMaterialContext as n}from"../shared/material-route-context.mjs";import{getVideoDetailServerInformation as r}from"../shared/video-detail-server-data.mjs";import{jsx as i}from"react/jsx-runtime";async function
|
|
2
|
+
import{VideoDetailMaterialRuntimeProvider as e}from"../shared/runtime-context-provider.mjs";import{VideoDetailInfoClient as t}from"./client.mjs";import{resolveVideoDetailRouteFromMaterialContext as n}from"../shared/material-route-context.mjs";import{getVideoDetailServerInformation as r}from"../shared/video-detail-server-data.mjs";import{jsx as i,jsxs as a}from"react/jsx-runtime";import o from"next/link";async function s(s){let{mode:l=`renderer`,showEpisodes:d=!0,detailId:f,currentSeriesNum:p,__route:m,...h}=s;if(l!==`renderer`)return i(t,{...h,showEpisodes:d,mode:l});let g=n(m),_=String(f||g.detailId||``).trim();if(!_)return i(t,{...h,showEpisodes:d,mode:l});let v=await r(_);if(!v)return i(t,{...h,showEpisodes:d,mode:l});let y=Math.max(1,Number(p||g.currentSeriesNum||1)),b=c(v),x=d&&v.is_more_link===`y`&&b.length>1;return a(e,{value:{information:v,detailId:_,currentSeriesNum:y,episodeIndex:Math.max(0,y-1),isShow:!0,isInformationLoading:!1,isInformationResolved:!0},children:[i(t,{...h,showEpisodes:!1,mode:l}),x&&i(`div`,{className:`w-full px-[12px] mt-[12px]`,children:i(`div`,{className:`flex flex-wrap gap-[8px]`,children:b.map(e=>{let t=e.seriesNum===y;return i(o,{href:u(_,v.name||``,e.seriesNum),className:`h-[28px] min-w-[40px] rounded-[6px] border px-[8px] text-[12px] leading-[26px] text-center ${t?`border-theme5 text-theme5 bg-theme5/10`:`border-line1 text-text2 bg-bg1`}`,children:e.label},e.key)})})})]})}function c(e){return(Array.isArray(e.links)?e.links:[]).map((e,t)=>{let n=e||{},r=typeof n.id==`string`?n.id:``,i=l(n.id,n.name,t+1);return{key:r||`episode-${i}-${t+1}`,seriesNum:i,label:`第${i}集`}})}function l(e,t,n){let r=Number(e);if(Number.isFinite(r)&&r>0)return Math.floor(r);let i=Number(t);return Number.isFinite(i)&&i>0?Math.floor(i):n}function u(e,t,n){return`/video/${e}/${encodeURIComponent(t||``)}/episode/${n}`}export{s as VideoDetailInfo};
|
package/dist/components/biz/business/detail/video-detail-info-title-tags-episodes/material.d.mts
CHANGED
|
@@ -9,9 +9,8 @@ import * as zod_v4_core0 from "zod/v4/core";
|
|
|
9
9
|
|
|
10
10
|
//#region components/biz/business/detail/video-detail-info-title-tags-episodes/material.d.ts
|
|
11
11
|
declare const videoDetailInfoTitleTagsEpisodesMaterial: DefineMaterialOption<typeof VideoDetailInfoTitleTagsEpisodes, typeof VideoDetailInfoTitleTagsEpisodesClient, zod.ZodObject<{
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
} & {
|
|
12
|
+
showTags: zod.ZodBoolean & SchemaHasDefaultValue;
|
|
13
|
+
showEpisodes: zod.ZodBoolean & SchemaHasDefaultValue;
|
|
15
14
|
mode: zod.ZodOptional<zod.ZodEnum<{
|
|
16
15
|
renderer: "renderer";
|
|
17
16
|
editor: "editor";
|
package/dist/components/biz/business/detail/video-detail-info-title-tags-episodes/schema.d.mts
CHANGED
|
@@ -9,9 +9,8 @@ import * as zod_v4_core0 from "zod/v4/core";
|
|
|
9
9
|
* 媒体信息-选集物料暂不对外开放配置。
|
|
10
10
|
*/
|
|
11
11
|
declare const videoDetailInfoTitleTagsEpisodesInspectorPropsSchema: zod.ZodObject<{
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
} & {
|
|
12
|
+
showTags: zod.ZodBoolean & SchemaHasDefaultValue;
|
|
13
|
+
showEpisodes: zod.ZodBoolean & SchemaHasDefaultValue;
|
|
15
14
|
mode: zod.ZodOptional<zod.ZodEnum<{
|
|
16
15
|
renderer: "renderer";
|
|
17
16
|
editor: "editor";
|
package/dist/components/biz/business/detail/video-detail-info-title-tags-episodes/schema.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
|
|
2
|
-
import{defineComponentPropsSchema as e,getSchemaDefaultProps as
|
|
2
|
+
import{defineComponentPropsSchema as e,defineSwitchPropSchema as t,getSchemaDefaultProps as n}from"../../../../../utils/schema/schema.mjs";const r=e({showTags:t({label:`显示标签`,defaultValue:!0}),showEpisodes:t({label:`显示选集`,defaultValue:!0})});n(r);export{r as videoDetailInfoTitleTagsEpisodesInspectorPropsSchema};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
|
|
2
|
-
import{defineComponentPropsSchema as e,getSchemaDefaultProps as t}from"../../../../../utils/schema/schema.mjs";const n=e(
|
|
2
|
+
import{defineComponentPropsSchema as e,getSchemaDefaultProps as t}from"../../../../../utils/schema/schema.mjs";const n=e({});t(n);export{n as videoDetailPlayerInspectorPropsSchema};
|
|
@@ -7,6 +7,6 @@ import { VideoDetailPlayerBridgeOnlyProps } from "./schema.mjs";
|
|
|
7
7
|
* - 仅注入 Bridge 所需全局方法
|
|
8
8
|
* - 不渲染 UI(return null)
|
|
9
9
|
*/
|
|
10
|
-
declare function VideoDetailPlayerBridgeOnlyClient(
|
|
10
|
+
declare function VideoDetailPlayerBridgeOnlyClient(props: VideoDetailPlayerBridgeOnlyProps): null;
|
|
11
11
|
//#endregion
|
|
12
12
|
export { VideoDetailPlayerBridgeOnlyClient };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
|
|
2
|
-
"use client";import{
|
|
2
|
+
"use client";import{useVideoDetailMaterialRuntimeContext as e}from"../shared/runtime-context-provider.mjs";import{useVideoDetailWebViewBridge as t}from"../shared/use-video-detail-webview-bridge.mjs";function n(n){let r=e();return t({enabled:!0,detailId:r?.detailId||r?.information?.id||``,information:r?.information??null,episodeIndex:r?.episodeIndex??0,currentSeriesNum:r?.currentSeriesNum??1}),null}export{n as VideoDetailPlayerBridgeOnlyClient};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
|
|
2
|
-
import{defineComponentPropsSchema as e,getSchemaDefaultProps as t}from"../../../../../utils/schema/schema.mjs";const n=e(
|
|
2
|
+
import{defineComponentPropsSchema as e,getSchemaDefaultProps as t}from"../../../../../utils/schema/schema.mjs";const n=e({});t(n);export{n as videoDetailPlayerBridgeOnlyInspectorPropsSchema};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
|
|
2
|
-
"use client";import{gContentGetGuessYouLikeVideos as e,pContentBatchGetVideoDetail as t}from"../../../../../service/generated/client.mjs";import{Box as n}from"../../../../ui/box.mjs";import{DotsLoading as r}from"../../../../ui/dots-loading.mjs";import{Text as i}from"../../../../ui/text.mjs";import{useRequest as a}from"../../../../../hooks/query/use-query.mjs";import{useKeepAliveState as o}from"../../../../common/keep-scroll-position/index.mjs";import ee from"../../../../../assets/icons/detail/video_flag.mjs";import{MiniThreeCard as s}from"../../../../common/cards/mini-three-card.mjs";import{useCardDecoration as c}from"../../../../../hooks/use-card-decoration.mjs";import{buildEditorPreviewRecommendList as l}from"../shared/editor-preview.mjs";import{useVideoDetailMaterialRuntimeContext as u}from"../shared/runtime-context-provider.mjs";import{applyPlayCountDelta as te,clampColumns as ne,mergeManualAndPool as d,normalizeRecommendRuntimeProps as re,resolveRows as ie}from"./utils.mjs";import{useCallback as ae,useEffect as f,useMemo as p,useRef as oe,useState as se}from"react";import{jsx as m,jsxs as h}from"react/jsx-runtime";function g({rows:g,columns:_,smartTagEnabled:b,smartTagIds:x,title:pe,showPlayCount:me,playCountDelta:he,showEpisode:ge,enableInfinite:_e,items:ve,mode:ye=`renderer`}){let C=u()?.detailId||``,be=ye===`editor`,w=be,{getVerticalHoCoverImageUrl:T,getTitleText:E}=c(),D=oe(null),O=p(()=>re({smartTagEnabled:b,smartTagIds:x,enableInfinite:_e,items:ve}),[_e,ve,b,x]),k=O.smartTagEnabled,A=O.smartTagIds,j=p(()=>O.items??[],[O.items]),M=O.enableInfinite&&!be,N=!k,P=M&&k&&!w,xe=ie(g,M),F=ne(_),I=xe*F,L=Math.max(1,I),R=p(()=>[`video-detail-recommend`,C||`unknown`,L,A.join(`,`)].join(`:`),[C,L,A]),[Se,z]=o(`${R}:pool`,[]),[B,V]=o(`${R}:has-more`,!1),[H,U]=se(!1),W=p(()=>l(I),[I]),{data:G,isFetching:Ce,isPending:we}=a([`video-detail-recommend`,C,P?`paged`:`all`,L,A.join(`,`)],async()=>w?null:await e({page_size:L,tags:A}),{enabled:!w&&k,refetchOnMount:`always`}),K=p(()=>w?W:v(G?.data?.videos),[G?.data?.videos,W,w]);f(()=>{if(!P){U(!1);return}z(e=>{if(!K.length)return e;if(!e.length)return K;let t=[...K],n=new Set(K.map(e=>e.id).filter(Boolean));return e.forEach(e=>{(!e.id||!n.has(e.id))&&(t.push(e),e.id&&n.add(e.id))}),t});let e=y(G?.data?.videos,L);V(t=>t||e),U(!1)},[G?.data?.videos,K,L,V,z,P]);let q=P?Se:K,J=p(()=>N?Array.from(new Set(j.map(e=>S(e.contentId)).filter(Boolean))):[],[j,N]),{data:Te,isFetching:Ee,isPending:De}=a([`video-detail-recommend-manual-details`,J.join(`,`)],async()=>{if(!J.length)return[];let e=await t({ids:J});return(Array.isArray(e.data?.videos)?e.data.videos:[]).map(e=>ce(e))},{enabled:J.length>0,refetchOnMount:`always`}),Oe=p(()=>N?new Set(j.map(e=>S(e.contentId)).filter(Boolean)):new Set,[j,N]),ke=p(()=>w?q:q.filter(e=>!Oe.has(e.id)),[q,w,Oe]),Y=p(()=>{if(!N||!j.length)return[];let e=new Map;return q.forEach(t=>{let n=S(t.id);n&&e.set(n,t)}),(Te||[]).forEach(t=>{let n=S(t.id);n&&e.set(n,t)}),j.map((t,n)=>{let r=w?W[n%Math.max(1,W.length)]:fe(t,n),i=S(t.contentId),a=typeof t.coverUrl==`string`?t.coverUrl.trim():``,o=e.get(i)??{...r,id:i||r.id||`preview-manual-${n+1}`,name:r.name||`猜你喜欢 ${n+1}`,img_y:a||r.img_y,img_x:a||r.img_x},ee=t.titleMode===`custom`?t.title:E(o),s=t.coverMode===`content`?T(o)||a:a||T(o);return{info:{...o,name:ee||o.name,img_y:s||o.img_y,img_x:s||o.img_x},config:{showPlayCount:t.showPlayCount,playCountDelta:t.playCountDelta,showEpisode:t.showEpisode}}}).filter(Boolean)},[W,q,E,T,w,Te,j,N]),X=p(()=>ke.map(e=>({info:e})),[ke]),Z=N&&j.length>0,Ae=p(()=>Z?Y:d(Y,X,I),[Z,Y,I,X]),Q=p(()=>{if(P){if(!Y.length)return X;let e=new Set(Y.map(e=>e.info.id).filter(Boolean));return Y.concat(X.filter(t=>!e.has(t.info.id)))}if(M){if(!Y.length)return X;let e=new Set(Y.map(e=>e.info.id).filter(Boolean));return Y.concat(X.filter(t=>!e.has(t.info.id)))}return Ae},[Ae,Y,X,M,P]),je=B&&Q.length>0?Math.max(0,Q.length-4):-1,Me=String(pe||``).trim(),$=ae(async()=>{if(!(!P||!B||H)){U(!0);try{let t=await e({page_size:L,tags:A}),n=Array.isArray(t.data?.videos)?t.data.videos:[],r=v(n),i=0;z(e=>{let t=new Set(e.map(e=>e.id).filter(Boolean)),n=[...e];return r.forEach(e=>{(!e.id||!t.has(e.id))&&(n.push(e),e.id&&t.add(e.id))}),i=n.length-e.length,n}),V(y(n,L)&&i>0)}catch(e){console.error(`猜你喜欢分页加载失败`,e),V(!1)}finally{U(!1)}}},[B,H,L,A,V,z,P]);if(f(()=>{if(!P)return;let e=D.current;if(!e||!B)return;let t=new IntersectionObserver(e=>{e[0]?.isIntersecting&&!H&&$()});return t.observe(e),()=>{t.disconnect()}},[$,B,H,P,je]),!Q.length)return null;let Ne=!w&&(H||k&&(Ce||we)||J.length>0&&(Ee||De));return h(n,{className:`w-full mt-[16px] ${w?`pointer-events-none`:``}`,children:[Me?m(i,{className:`block pl-[12px] mb-[8px] text-text1 text-[18px] leading-[26px] font-bold`,children:Me}):null,m(n,{className:`w-full flex flex-wrap px-[12px]`,children:Q.map((e,t)=>{let n=E(e.info),r=me!==!1&&(e.config?.showPlayCount??!0),a=Number(e.config?.playCountDelta??he??0),o=e.config?.showEpisode??ge,c=ue(te(e.info.play_count||0,a)),l=le(e.info),u=Number.isFinite(F)&&F>0?F:3,ne=`${100/u}%`,d=t%u,re=u>1?{paddingLeft:8*d/u,paddingRight:8*(u-d-1)/u}:null;return m(`div`,{ref:t===je?D:void 0,style:{width:ne,...re||{}},children:m(s,{url:T(e.info),text:n,textChild:m(i,{as:`h3`,className:`text-text1 text-[16px] h-[24px] leading-[24px] my-[4px] line-clamp-1`,children:n}),style:{width:`100%`},bottomLeftChild:r?h(`div`,{className:`h-[20px] leading-[20px] text-[#fff] text-[12px] px-[4px] rounded-[4px] bg-[#333] ml-[4px] flex items-center`,children:[m(ee,{className:`w-[16px] h-[auto] text-[#fff] mr-[4px]`}),c]}):null,bottomRightChild:o&&l?m(`div`,{className:`text-[#fff] text-[12px] leading-[20px] pr-2`,children:l}):null,linkPath:w?``:de(e.info)})},`guess-like-${t}`)})}),Ne&&m(n,{className:`w-full flex justify-center py-[12px]`,children:m(r,{})})]})}function _(e){let t=e.is_more_link?`y`:`n`;return{id:e.video_id||``,mid:``,name:e.name||``,cat_id:``,cat_name:``,status:`1`,status_text:``,create_time:``,content_type:e.content_type,episode_cnt:e.episode_count||0,show_at:e.show_at??``,position:``,img_type:e.img_type??``,img_x:e.img_x??``,img_y:e.img_y??``,img_width:``,img_height:``,play_count:e.play_count,preview_images:[],duration:String(e.duration??``),score:String(e.score??``),is_more_link:t,update_status:String(e.update_status??``),description:e.description??``,language:``,director:``,actor:``,area:``,issue_date:``,publisher:``,series:``,number:``,tags:[],source_tags:e.source_tags??``,source_actor:[],links:Array.isArray(e.episodes)?e.episodes.map(e=>({id:e.id??``,name:e.name??``,preview_m3u8_url:e.preview_m3u8_url??``,m3u8_url:e.m3u8_url??``})):[],money:``,up_user:``,source_username:``,task_id:``,file_status:``}}function v(e){return Array.isArray(e)?e.map(e=>_(e)):[]}function ce(e){let t=String(e?.id||e?.mid||e?.video_id||``),n=e?.is_more_link===`y`?`y`:`n`,r=Array.isArray(e?.links)?e.links.map(e=>({id:String(e?.id||``),name:String(e?.name||``),preview_m3u8_url:String(e?.preview_m3u8_url||``),m3u8_url:String(e?.m3u8_url||``)})):[],i=Array.isArray(e?.video_episodes)?e.video_episodes.length:0,a=Number(e?.episode_cnt||i||r.length||0);return{id:t,mid:String(e?.mid||t),name:String(e?.name||``),cat_id:String(e?.cat_id||``),cat_name:String(e?.cat_name||``),status:String(e?.status||`1`),status_text:String(e?.status_text||``),create_time:String(e?.create_time||``),content_type:e?.content_type,episode_cnt:Number.isFinite(a)?a:0,show_at:String(e?.show_at||``),position:String(e?.position||``),img_type:String(e?.img_type||``),img_x:String(e?.img_x||``),img_y:String(e?.img_y||``),img_width:String(e?.img_width||``),img_height:String(e?.img_height||``),play_count:Number(e?.play_count??e?.browse_count??0),preview_images:Array.isArray(e?.preview_images)?e.preview_images:[],duration:String(e?.duration||``),score:String(e?.score||``),is_more_link:n,update_status:String(e?.update_status||``),description:String(e?.description||``),language:String(e?.language||``),director:String(e?.director||``),actor:String(e?.actor||``),area:String(e?.area||``),issue_date:String(e?.issue_date||``),publisher:String(e?.publisher||``),series:String(e?.series||``),number:String(e?.number||``),tags:Array.isArray(e?.tags)?e.tags:[],source_tags:String(e?.source_tags||``),source_actor:Array.isArray(e?.source_actor)?e.source_actor:[],links:r,money:String(e?.money||``),up_user:String(e?.up_user||``),source_username:String(e?.source_username||``),task_id:String(e?.task_id||``),file_status:String(e?.file_status||``)}}function y(e,t){if(!Array.isArray(e)||e.length===0)return!1;let n=e[0];if(typeof n?.has_more==`boolean`)return n.has_more;let r=Number(n?.total??0);return Number.isFinite(r)&&r>0?r>t:e.length>=t}function le(e){if(b(e)){let t=Number(e.episode_cnt||e.links?.length||0);return t>0?`全${t}集`:``}return x(Number(e.duration||0))}function b(e){return e.is_more_link===`y`}function x(e){if(!Number.isFinite(e)||e<=0)return``;let t=Math.floor(e),n=Math.floor(t/3600),r=Math.floor(t%3600/60),i=t%60,a=e=>String(e).padStart(2,`0`);return n>0?`${a(n)}:${a(r)}:${a(i)}`:`${a(r)}:${a(i)}`}function ue(e){let t=Number(e||`0`);return Number.isNaN(t)||t<=0?`0`:t>=1e4?`${(t/1e4).toFixed(1)}w`:t>=1e3?`${(t/1e3).toFixed(1)}k`:String(t)}function de(e){let t=encodeURIComponent(e.name||``);return`/video/${e.id}/${t}/episode/1`}function S(e){return typeof e==`string`?e.trim():``}function fe(e,t){let n=S(e.contentId)||`manual-${t+1}`,r=typeof e.coverUrl==`string`?e.coverUrl.trim():``,i=typeof e.title==`string`?e.title.trim():``,a=typeof e.description==`string`?e.description.trim():``;return{id:n,mid:n,name:i||`猜你喜欢 ${t+1}`,cat_id:``,cat_name:``,status:`1`,status_text:``,create_time:``,content_type:1,episode_cnt:0,show_at:``,position:``,img_type:``,img_x:r,img_y:r,img_width:``,img_height:``,play_count:0,preview_images:[],duration:``,score:``,is_more_link:`n`,update_status:``,description:a,language:``,director:``,actor:``,area:``,issue_date:``,publisher:``,series:``,number:``,tags:[],source_tags:``,source_actor:[],links:[],money:``,up_user:``,source_username:``,task_id:``,file_status:``}}export{g as VideoDetailRecommendClient};
|
|
2
|
+
"use client";import{gContentGetGuessYouLikeVideos as e,pContentBatchGetVideoDetail as t}from"../../../../../service/generated/client.mjs";import{Box as n}from"../../../../ui/box.mjs";import{Text as r}from"../../../../ui/text.mjs";import{useRequest as i}from"../../../../../hooks/query/use-query.mjs";import{useKeepAliveState as a}from"../../../../common/keep-scroll-position/index.mjs";import o from"../../../../../assets/icons/detail/video_flag.mjs";import{MiniThreeCard as s}from"../../../../common/cards/mini-three-card.mjs";import{useCardDecoration as c}from"../../../../../hooks/use-card-decoration.mjs";import{buildEditorPreviewRecommendList as l}from"../shared/editor-preview.mjs";import{useVideoDetailMaterialRuntimeContext as u}from"../shared/runtime-context-provider.mjs";import{applyPlayCountDelta as ee,clampColumns as d,mergeManualAndPool as f,normalizeRecommendRuntimeProps as p,resolveRows as m}from"./utils.mjs";import{useCallback as te,useEffect as h,useMemo as g,useRef as ne,useState as re}from"react";import{jsx as _,jsxs as ie}from"react/jsx-runtime";function v({rows:v,columns:ae,smartTagEnabled:y,smartTagIds:b,title:pe,showPlayCount:me,playCountDelta:he,showEpisode:ge,enableInfinite:S,items:C,mode:_e=`renderer`}){let w=u()?.detailId||``,ve=_e===`editor`,T=ve,{getVerticalHoCoverImageUrl:E,getTitleText:D}=c(),O=ne(null),k=g(()=>p({smartTagEnabled:y,smartTagIds:b,enableInfinite:S,items:C}),[S,C,y,b]),A=k.smartTagEnabled,j=k.smartTagIds,M=g(()=>k.items??[],[k.items]),N=k.enableInfinite&&!ve,P=!A,F=N&&A&&!T,ye=m(v,N),I=d(ae),L=ye*I,R=Math.max(1,L),z=g(()=>[`video-detail-recommend`,w||`unknown`,R,j.join(`,`)].join(`:`),[w,R,j]),[be,B]=a(`${z}:pool`,[]),[V,H]=a(`${z}:has-more`,!1),[U,W]=re(!1),G=g(()=>l(L),[L]),{data:K}=i([`video-detail-recommend`,w,F?`paged`:`all`,R,j.join(`,`)],async()=>T?null:await e({page_size:R,tags:j}),{enabled:!T&&A}),q=g(()=>T?G:oe(K?.data?.videos),[K?.data?.videos,G,T]);h(()=>{if(!F){W(!1);return}B(e=>{if(!q.length)return e;if(!e.length)return q;let t=[...q],n=new Set(q.map(e=>e.id).filter(Boolean));return e.forEach(e=>{(!e.id||!n.has(e.id))&&(t.push(e),e.id&&n.add(e.id))}),t});let e=ce(K?.data?.videos,R);H(t=>t||e),W(!1)},[K?.data?.videos,q,R,H,B,F]);let J=F?be:q,Y=g(()=>P?Array.from(new Set(M.map(e=>x(e.contentId)).filter(Boolean))):[],[M,P]),{data:xe}=i([`video-detail-recommend-manual-details`,Y.join(`,`)],async()=>{if(!Y.length)return[];let e=await t({ids:Y});return(Array.isArray(e.data?.videos)?e.data.videos:[]).map(e=>se(e))},{enabled:Y.length>0}),Se=g(()=>P?new Set(M.map(e=>x(e.contentId)).filter(Boolean)):new Set,[M,P]),Ce=g(()=>T?J:J.filter(e=>!Se.has(e.id)),[J,T,Se]),X=g(()=>{if(!P||!M.length)return[];let e=new Map;return J.forEach(t=>{let n=x(t.id);n&&e.set(n,t)}),(xe||[]).forEach(t=>{let n=x(t.id);n&&e.set(n,t)}),M.map((t,n)=>{let r=T?G[n%Math.max(1,G.length)]:fe(t,n),i=x(t.contentId),a=typeof t.coverUrl==`string`?t.coverUrl.trim():``,o=e.get(i)??{...r,id:i||r.id||`preview-manual-${n+1}`,name:r.name||`猜你喜欢 ${n+1}`,img_y:a||r.img_y,img_x:a||r.img_x},s=t.titleMode===`custom`?t.title:D(o),c=t.coverMode===`content`?E(o)||a:a||E(o);return{info:{...o,name:s||o.name,img_y:c||o.img_y,img_x:c||o.img_x},config:{showPlayCount:t.showPlayCount,playCountDelta:t.playCountDelta,showEpisode:t.showEpisode}}}).filter(Boolean)},[G,J,D,E,T,xe,M,P]),Z=g(()=>Ce.map(e=>({info:e})),[Ce]),we=P&&M.length>0,Te=g(()=>we?X:f(X,Z,L),[we,X,L,Z]),Q=g(()=>{if(F){if(!X.length)return Z;let e=new Set(X.map(e=>e.info.id).filter(Boolean));return X.concat(Z.filter(t=>!e.has(t.info.id)))}if(N){if(!X.length)return Z;let e=new Set(X.map(e=>e.info.id).filter(Boolean));return X.concat(Z.filter(t=>!e.has(t.info.id)))}return Te},[Te,X,Z,N,F]),Ee=V&&Q.length>0?Math.max(0,Q.length-4):-1,De=String(pe||``).trim(),$=te(async()=>{if(!(!F||!V||U)){W(!0);try{let t=await e({page_size:R,tags:j}),n=Array.isArray(t.data?.videos)?t.data.videos:[],r=oe(n),i=0;B(e=>{let t=new Set(e.map(e=>e.id).filter(Boolean)),n=[...e];return r.forEach(e=>{(!e.id||!t.has(e.id))&&(n.push(e),e.id&&t.add(e.id))}),i=n.length-e.length,n}),H(ce(n,R)&&i>0)}catch(e){console.error(`猜你喜欢分页加载失败`,e),H(!1)}finally{W(!1)}}},[V,U,R,j,H,B,F]);return h(()=>{if(!F)return;let e=O.current;if(!e||!V)return;let t=new IntersectionObserver(e=>{e[0]?.isIntersecting&&!U&&$()});return t.observe(e),()=>{t.disconnect()}},[$,V,U,F,Ee]),Q.length?ie(n,{className:`w-full mt-[16px] ${T?`pointer-events-none`:``}`,children:[De?_(r,{className:`block pl-[12px] mb-[8px] text-text1 text-[18px] leading-[26px] font-bold`,children:De}):null,_(n,{className:`w-full flex flex-wrap px-[12px]`,children:Q.map((e,t)=>{let n=D(e.info),i=me!==!1&&(e.config?.showPlayCount??!0),a=Number(e.config?.playCountDelta??he??0),c=e.config?.showEpisode??ge,l=ue(ee(e.info.play_count||0,a)),u=le(e.info),d=Number.isFinite(I)&&I>0?I:3,f=`${100/d}%`,p=t%d,m=d>1?{paddingLeft:8*p/d,paddingRight:8*(d-p-1)/d}:null;return _(`div`,{ref:t===Ee?O:void 0,style:{width:f,...m||{}},children:_(s,{url:E(e.info),text:n,textChild:_(r,{as:`h3`,className:`text-text1 text-[16px] h-[24px] leading-[24px] my-[4px] line-clamp-1`,children:n}),style:{width:`100%`},bottomLeftChild:i?ie(`div`,{className:`h-[20px] leading-[20px] text-[#fff] text-[12px] px-[4px] rounded-[4px] bg-[#333] ml-[4px] flex items-center`,children:[_(o,{className:`w-[16px] h-[auto] text-[#fff] mr-[4px]`}),l]}):null,bottomRightChild:c&&u?_(`div`,{className:`text-[#fff] text-[12px] leading-[20px] pr-2`,children:u}):null,linkPath:T?``:de(e.info)})},`guess-like-${t}`)})})]}):null}function ae(e){let t=e.is_more_link?`y`:`n`;return{id:e.video_id||``,mid:``,name:e.name||``,cat_id:``,cat_name:``,status:`1`,status_text:``,create_time:``,content_type:e.content_type,episode_cnt:e.episode_count||0,show_at:e.show_at??``,position:``,img_type:e.img_type??``,img_x:e.img_x??``,img_y:e.img_y??``,img_width:``,img_height:``,play_count:e.play_count,preview_images:[],duration:String(e.duration??``),score:String(e.score??``),is_more_link:t,update_status:String(e.update_status??``),description:e.description??``,language:``,director:``,actor:``,area:``,issue_date:``,publisher:``,series:``,number:``,tags:[],source_tags:e.source_tags??``,source_actor:[],links:Array.isArray(e.episodes)?e.episodes.map(e=>({id:e.id??``,name:e.name??``,preview_m3u8_url:e.preview_m3u8_url??``,m3u8_url:e.m3u8_url??``})):[],money:``,up_user:``,source_username:``,task_id:``,file_status:``}}function oe(e){return Array.isArray(e)?e.map(e=>ae(e)):[]}function se(e){let t=String(e?.id||e?.mid||e?.video_id||``),n=e?.is_more_link===`y`?`y`:`n`,r=Array.isArray(e?.links)?e.links.map(e=>({id:String(e?.id||``),name:String(e?.name||``),preview_m3u8_url:String(e?.preview_m3u8_url||``),m3u8_url:String(e?.m3u8_url||``)})):[],i=Array.isArray(e?.video_episodes)?e.video_episodes.length:0,a=Number(e?.episode_cnt||i||r.length||0);return{id:t,mid:String(e?.mid||t),name:String(e?.name||``),cat_id:String(e?.cat_id||``),cat_name:String(e?.cat_name||``),status:String(e?.status||`1`),status_text:String(e?.status_text||``),create_time:String(e?.create_time||``),content_type:e?.content_type,episode_cnt:Number.isFinite(a)?a:0,show_at:String(e?.show_at||``),position:String(e?.position||``),img_type:String(e?.img_type||``),img_x:String(e?.img_x||``),img_y:String(e?.img_y||``),img_width:String(e?.img_width||``),img_height:String(e?.img_height||``),play_count:Number(e?.play_count??e?.browse_count??0),preview_images:Array.isArray(e?.preview_images)?e.preview_images:[],duration:String(e?.duration||``),score:String(e?.score||``),is_more_link:n,update_status:String(e?.update_status||``),description:String(e?.description||``),language:String(e?.language||``),director:String(e?.director||``),actor:String(e?.actor||``),area:String(e?.area||``),issue_date:String(e?.issue_date||``),publisher:String(e?.publisher||``),series:String(e?.series||``),number:String(e?.number||``),tags:Array.isArray(e?.tags)?e.tags:[],source_tags:String(e?.source_tags||``),source_actor:Array.isArray(e?.source_actor)?e.source_actor:[],links:r,money:String(e?.money||``),up_user:String(e?.up_user||``),source_username:String(e?.source_username||``),task_id:String(e?.task_id||``),file_status:String(e?.file_status||``)}}function ce(e,t){if(!Array.isArray(e)||e.length===0)return!1;let n=e[0];if(typeof n?.has_more==`boolean`)return n.has_more;let r=Number(n?.total??0);return Number.isFinite(r)&&r>0?r>t:e.length>=t}function le(e){if(y(e)){let t=Number(e.episode_cnt||e.links?.length||0);return t>0?`全${t}集`:``}return b(Number(e.duration||0))}function y(e){return e.is_more_link===`y`}function b(e){if(!Number.isFinite(e)||e<=0)return``;let t=Math.floor(e),n=Math.floor(t/3600),r=Math.floor(t%3600/60),i=t%60,a=e=>String(e).padStart(2,`0`);return n>0?`${a(n)}:${a(r)}:${a(i)}`:`${a(r)}:${a(i)}`}function ue(e){let t=Number(e||`0`);return Number.isNaN(t)||t<=0?`0`:t>=1e4?`${(t/1e4).toFixed(1)}w`:t>=1e3?`${(t/1e3).toFixed(1)}k`:String(t)}function de(e){let t=encodeURIComponent(e.name||``);return`/video/${e.id}/${t}/episode/1`}function x(e){return typeof e==`string`?e.trim():``}function fe(e,t){let n=x(e.contentId)||`manual-${t+1}`,r=typeof e.coverUrl==`string`?e.coverUrl.trim():``,i=typeof e.title==`string`?e.title.trim():``,a=typeof e.description==`string`?e.description.trim():``;return{id:n,mid:n,name:i||`猜你喜欢 ${t+1}`,cat_id:``,cat_name:``,status:`1`,status_text:``,create_time:``,content_type:1,episode_cnt:0,show_at:``,position:``,img_type:``,img_x:r,img_y:r,img_width:``,img_height:``,play_count:0,preview_images:[],duration:``,score:``,is_more_link:`n`,update_status:``,description:a,language:``,director:``,actor:``,area:``,issue_date:``,publisher:``,series:``,number:``,tags:[],source_tags:``,source_actor:[],links:[],money:``,up_user:``,source_username:``,task_id:``,file_status:``}}export{v as VideoDetailRecommendClient};
|
|
@@ -9,16 +9,16 @@ import * as zod_v4_core0 from "zod/v4/core";
|
|
|
9
9
|
|
|
10
10
|
//#region components/biz/business/detail/video-detail-recommend/material.d.ts
|
|
11
11
|
declare const videoDetailRecommendMaterial: DefineMaterialOption<typeof VideoDetailRecommend, typeof VideoDetailRecommendClient, zod.ZodObject<{
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
12
|
+
rows: zod.ZodNumber & SchemaHasDefaultValue;
|
|
13
|
+
columns: zod.ZodNumber & SchemaHasDefaultValue;
|
|
14
|
+
smartTagEnabled: zod.ZodBoolean & SchemaHasDefaultValue;
|
|
15
|
+
title: zod.ZodString & SchemaHasDefaultValue;
|
|
16
|
+
showPlayCount: zod.ZodBoolean & SchemaHasDefaultValue;
|
|
17
|
+
playCountDelta: zod.ZodNumber & SchemaHasDefaultValue;
|
|
18
|
+
showEpisode: zod.ZodBoolean & SchemaHasDefaultValue;
|
|
19
|
+
enableInfinite: zod.ZodBoolean & SchemaHasDefaultValue;
|
|
20
|
+
smartTagIds: zod.ZodOptional<zod.ZodArray<zod.ZodString>>;
|
|
21
|
+
items: zod.ZodOptional<zod.ZodArray<zod.ZodObject<{
|
|
22
22
|
contentId: zod.ZodString;
|
|
23
23
|
coverMode: zod.ZodOptional<zod.ZodEnum<{
|
|
24
24
|
content: "content";
|
|
@@ -35,7 +35,6 @@ declare const videoDetailRecommendMaterial: DefineMaterialOption<typeof VideoDet
|
|
|
35
35
|
playCountDelta: zod.ZodOptional<zod.ZodNumber>;
|
|
36
36
|
showEpisode: zod.ZodOptional<zod.ZodBoolean>;
|
|
37
37
|
}, zod_v4_core0.$strip>>>;
|
|
38
|
-
} & {
|
|
39
38
|
mode: zod.ZodOptional<zod.ZodEnum<{
|
|
40
39
|
renderer: "renderer";
|
|
41
40
|
editor: "editor";
|
|
@@ -5,16 +5,16 @@ import z$1 from "zod";
|
|
|
5
5
|
|
|
6
6
|
//#region components/biz/business/detail/video-detail-recommend/schema.d.ts
|
|
7
7
|
declare const videoDetailRecommendInspectorPropsSchema: z$1.ZodObject<{
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
8
|
+
rows: z$1.ZodNumber & SchemaHasDefaultValue;
|
|
9
|
+
columns: z$1.ZodNumber & SchemaHasDefaultValue;
|
|
10
|
+
smartTagEnabled: z$1.ZodBoolean & SchemaHasDefaultValue;
|
|
11
|
+
title: z$1.ZodString & SchemaHasDefaultValue;
|
|
12
|
+
showPlayCount: z$1.ZodBoolean & SchemaHasDefaultValue;
|
|
13
|
+
playCountDelta: z$1.ZodNumber & SchemaHasDefaultValue;
|
|
14
|
+
showEpisode: z$1.ZodBoolean & SchemaHasDefaultValue;
|
|
15
|
+
enableInfinite: z$1.ZodBoolean & SchemaHasDefaultValue;
|
|
16
|
+
smartTagIds: z$1.ZodOptional<z$1.ZodArray<z$1.ZodString>>;
|
|
17
|
+
items: z$1.ZodOptional<z$1.ZodArray<z$1.ZodObject<{
|
|
18
18
|
contentId: z$1.ZodString;
|
|
19
19
|
coverMode: z$1.ZodOptional<z$1.ZodEnum<{
|
|
20
20
|
content: "content";
|
|
@@ -31,7 +31,6 @@ declare const videoDetailRecommendInspectorPropsSchema: z$1.ZodObject<{
|
|
|
31
31
|
playCountDelta: z$1.ZodOptional<z$1.ZodNumber>;
|
|
32
32
|
showEpisode: z$1.ZodOptional<z$1.ZodBoolean>;
|
|
33
33
|
}, z$1.core.$strip>>>;
|
|
34
|
-
} & {
|
|
35
34
|
mode: z$1.ZodOptional<z$1.ZodEnum<{
|
|
36
35
|
renderer: "renderer";
|
|
37
36
|
editor: "editor";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
|
|
2
|
-
import{defineComponentPropsSchema as e,getSchemaDefaultProps as
|
|
2
|
+
import{defineComponentPropsSchema as e,defineNumberPropSchema as t,defineSwitchPropSchema as n,defineTextPropSchema as r,getSchemaDefaultProps as i}from"../../../../../utils/schema/schema.mjs";import a from"zod";const o=e({rows:t({label:`行数`,defaultValue:1}),columns:t({label:`列数`,defaultValue:2}),smartTagEnabled:n({label:`智能铺设`,defaultValue:!1}),title:r({label:`推荐位名称`,defaultValue:`猜你喜欢`}),showPlayCount:n({label:`显示播放量`,defaultValue:!0}),playCountDelta:t({label:`播放量浮动`,defaultValue:0}),showEpisode:n({label:`显示集数`,defaultValue:!0}),enableInfinite:n({label:`无限下拉`,defaultValue:!1}),smartTagIds:a.array(a.string()).optional(),items:a.array(a.object({contentId:a.string(),coverMode:a.enum([`upload`,`content`]).optional(),coverUrl:a.string().optional(),titleMode:a.enum([`custom`,`content`]).optional(),title:a.string().optional(),description:a.string().optional(),showPlayCount:a.boolean().optional(),playCountDelta:a.number().optional(),showEpisode:a.boolean().optional()})).optional()});({...i(o)});export{o as videoDetailRecommendInspectorPropsSchema};
|
|
@@ -9,9 +9,8 @@ import * as zod_v4_core0 from "zod/v4/core";
|
|
|
9
9
|
|
|
10
10
|
//#region components/biz/business/floating-ball/material.d.ts
|
|
11
11
|
declare const floatingBallMaterial: DefineMaterialOption<typeof FloatingBall, typeof FloatingBallClient, zod.ZodObject<{
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
} & {
|
|
12
|
+
icon: zod.ZodString & SchemaHasDefaultValue;
|
|
13
|
+
href: zod.ZodString & SchemaHasDefaultValue;
|
|
15
14
|
mode: zod.ZodOptional<zod.ZodEnum<{
|
|
16
15
|
renderer: "renderer";
|
|
17
16
|
editor: "editor";
|
|
@@ -9,17 +9,16 @@ import * as zod_v4_core0 from "zod/v4/core";
|
|
|
9
9
|
* 悬浮球物料:图片链接 + 跳转链接。
|
|
10
10
|
*/
|
|
11
11
|
declare const floatingBallInspectorPropsSchema: zod.ZodObject<{
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
} & {
|
|
12
|
+
icon: zod.ZodString & SchemaHasDefaultValue;
|
|
13
|
+
href: zod.ZodString & SchemaHasDefaultValue;
|
|
15
14
|
mode: zod.ZodOptional<zod.ZodEnum<{
|
|
16
15
|
renderer: "renderer";
|
|
17
16
|
editor: "editor";
|
|
18
17
|
}>>;
|
|
19
18
|
}, zod_v4_core0.$strip>;
|
|
20
19
|
declare const floatingBallInspectorDefaultProps: {
|
|
21
|
-
|
|
22
|
-
|
|
20
|
+
icon: string;
|
|
21
|
+
href: string;
|
|
23
22
|
};
|
|
24
23
|
type FloatingBallInspectorProps = InferSchemaProps<typeof floatingBallInspectorPropsSchema>;
|
|
25
24
|
//#endregion
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
|
|
2
|
-
import{defineComponentPropsSchema as e,getSchemaDefaultProps as
|
|
2
|
+
import{defineComponentPropsSchema as e,defineTextPropSchema as t,getSchemaDefaultProps as n}from"../../../../utils/schema/schema.mjs";const r=e({icon:t({label:`图片链接`,required:!0,defaultValue:`/images/2026/01/21/6970431b570c52b14f085d7c/0f1bb13e-3cf1-441c-9036-ed26341d4199.jpgxxx`}),href:t({label:`跳转链接`,required:!0,defaultValue:`/publish`})}),i=n(r);export{i as floatingBallInspectorDefaultProps,r as floatingBallInspectorPropsSchema};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
|
|
2
|
-
import{defineComponentPropsSchema as e,getSchemaDefaultProps as t}from"../../../../../utils/schema/schema.mjs";const n=e(
|
|
2
|
+
import{defineComponentPropsSchema as e,getSchemaDefaultProps as t}from"../../../../../utils/schema/schema.mjs";const n=e({});t(n);export{n as headerAvatarIconInspectorPropsSchema};
|
|
@@ -9,9 +9,8 @@ import * as zod_v4_core0 from "zod/v4/core";
|
|
|
9
9
|
|
|
10
10
|
//#region components/biz/business/header-search/header-avatar-logo-search/material.d.ts
|
|
11
11
|
declare const headerAvatarLogoSearchMaterial: DefineMaterialOption<typeof HeaderAvatarLogoSearch, typeof HeaderAvatarLogoSearchClient, zod.ZodObject<{
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
} & {
|
|
12
|
+
logoSrc: zod.ZodOptional<zod.ZodString> & SchemaHasDefaultValue;
|
|
13
|
+
logoHref: zod.ZodOptional<zod.ZodString> & SchemaHasDefaultValue;
|
|
15
14
|
mode: zod.ZodOptional<zod.ZodEnum<{
|
|
16
15
|
renderer: "renderer";
|
|
17
16
|
editor: "editor";
|
|
@@ -11,9 +11,8 @@ import * as zod_v4_core0 from "zod/v4/core";
|
|
|
11
11
|
* - logoHref:可配置 logo 点击跳转地址
|
|
12
12
|
*/
|
|
13
13
|
declare const headerAvatarLogoSearchInspectorPropsSchema: zod.ZodObject<{
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
} & {
|
|
14
|
+
logoSrc: zod.ZodOptional<zod.ZodString> & SchemaHasDefaultValue;
|
|
15
|
+
logoHref: zod.ZodOptional<zod.ZodString> & SchemaHasDefaultValue;
|
|
17
16
|
mode: zod.ZodOptional<zod.ZodEnum<{
|
|
18
17
|
renderer: "renderer";
|
|
19
18
|
editor: "editor";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
|
|
2
|
-
import{defineComponentPropsSchema as e,getSchemaDefaultProps as
|
|
2
|
+
import{defineComponentPropsSchema as e,defineTextPropSchema as t,getSchemaDefaultProps as n}from"../../../../../utils/schema/schema.mjs";const r=e({logoSrc:t({label:`LOGO 图片地址`,required:!1,defaultValue:``}),logoHref:t({label:`LOGO 跳转地址`,required:!1,defaultValue:`/`})}),i=n(r);export{i as headerAvatarLogoSearchInspectorDefaultProps,r as headerAvatarLogoSearchInspectorPropsSchema};
|
package/dist/components/biz/business/header-search/header-avatar-logo-search-icon/material.d.mts
CHANGED
|
@@ -9,9 +9,8 @@ import * as zod_v4_core0 from "zod/v4/core";
|
|
|
9
9
|
|
|
10
10
|
//#region components/biz/business/header-search/header-avatar-logo-search-icon/material.d.ts
|
|
11
11
|
declare const headerAvatarLogoSearchIconMaterial: DefineMaterialOption<typeof HeaderAvatarLogoSearchIcon, typeof HeaderAvatarLogoSearchIconClient, zod.ZodObject<{
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
} & {
|
|
12
|
+
logoSrc: zod.ZodOptional<zod.ZodString> & SchemaHasDefaultValue;
|
|
13
|
+
logoHref: zod.ZodOptional<zod.ZodString> & SchemaHasDefaultValue;
|
|
15
14
|
mode: zod.ZodOptional<zod.ZodEnum<{
|
|
16
15
|
renderer: "renderer";
|
|
17
16
|
editor: "editor";
|