@bbki.ng/site 5.4.9 → 5.4.10
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/CHANGELOG.md +2 -0
- package/index.html +1 -1
- package/package.json +1 -1
- package/src/blog/app.tsx +0 -2
- package/src/blog/components/index.tsx +0 -5
- package/src/blog/components/reaction/oh_reaction.tsx +0 -3
- package/src/blog/components/video_player/index.tsx +2 -1
- package/src/blog/constants/index.ts +0 -2
- package/src/blog/constants/routes.ts +0 -2
- package/src/blog/pages/index.tsx +0 -13
- package/src/blog/pages/streaming/index.tsx +16 -14
- package/src/blog/articles/now.mdx +0 -20
- package/src/blog/components/Footer.tsx +0 -39
- package/src/blog/components/book_list/index.tsx +0 -52
- package/src/blog/components/comment/comment-btn.tsx +0 -15
- package/src/blog/components/comment/comment-icon.tsx +0 -20
- package/src/blog/components/comment/index.tsx +0 -1
- package/src/blog/components/corner_prompt_box/index.tsx +0 -63
- package/src/blog/components/disabled_text/index.tsx +0 -23
- package/src/blog/components/fade_out_cover/index.tsx +0 -37
- package/src/blog/components/footer/footer_links.ts +0 -13
- package/src/blog/components/footer/index.tsx +0 -21
- package/src/blog/components/movie_list/index.tsx +0 -53
- package/src/blog/constants/cusdis.ts +0 -6
- package/src/blog/constants/photo_projects.ts +0 -54
- package/src/blog/constants/photos.ts +0 -277
- package/src/blog/constants/video_logs.ts +0 -16
- package/src/blog/pages/extensions/png/consts.ts +0 -9
- package/src/blog/pages/extensions/png/index.tsx +0 -26
- package/src/blog/pages/extensions/png/png_projects.tsx +0 -73
- package/src/blog/pages/now/index.tsx +0 -7
package/CHANGELOG.md
CHANGED
package/index.html
CHANGED
|
@@ -55,7 +55,7 @@
|
|
|
55
55
|
</style>
|
|
56
56
|
<script src="https://unpkg.com/open-heart-element" type="module"></script>
|
|
57
57
|
<script type="module" src="https://cdn.jsdelivr.net/npm/@bbki.ng/bbimg@0.0.3/dist/index.js"></script>
|
|
58
|
-
<script type="module" src="https://cdn.jsdelivr.net/npm/@bbki.ng/bb-msg-history@0.11.
|
|
58
|
+
<script type="module" src="https://cdn.jsdelivr.net/npm/@bbki.ng/bb-msg-history@0.11.2/dist/index.js"></script>
|
|
59
59
|
</head>
|
|
60
60
|
|
|
61
61
|
<body class="h-full m-0 flex flex-col font-mono">
|
package/package.json
CHANGED
package/src/blog/app.tsx
CHANGED
|
@@ -14,8 +14,6 @@ import { Login } from "@/pages/login";
|
|
|
14
14
|
import { SWR } from "@/swr";
|
|
15
15
|
import { GlobalLoadingContext } from "@/context/global_loading_state_provider";
|
|
16
16
|
import { AppCtxMenu } from "@/components/app_ctx_menu";
|
|
17
|
-
import { Pochacco, PochaccoPose } from "@/components/Pochacco/Pochacco";
|
|
18
|
-
import { Role, useRole } from "@/hooks/use_role";
|
|
19
17
|
import { BotRedirect } from "@/pages/bot";
|
|
20
18
|
import { BBContext } from "@/context/bbcontext";
|
|
21
19
|
import { useClipboardToPost } from "@/hooks/use_clipboard_to_post";
|
|
@@ -1,9 +1,6 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import { LinkList } from "@bbki.ng/components";
|
|
3
3
|
import { BlurCover } from "@bbki.ng/components";
|
|
4
|
-
import { DelayFadeIn } from "@/components/DelayFadeIn/DelayFadeIn";
|
|
5
|
-
|
|
6
|
-
export { DisabledText, SmallDisabledText } from "./disabled_text";
|
|
7
4
|
|
|
8
5
|
export { ImgList } from "./img_list";
|
|
9
6
|
|
|
@@ -21,8 +18,6 @@ export { ReloadPrompt } from "./reload_prompt";
|
|
|
21
18
|
|
|
22
19
|
export { Stickers } from "./stickers";
|
|
23
20
|
|
|
24
|
-
export { CornerPromptBox } from "./corner_prompt_box";
|
|
25
|
-
|
|
26
21
|
export { Tags } from "./tags";
|
|
27
22
|
|
|
28
23
|
export { MySuspense } from "./my_suspense";
|
|
@@ -9,7 +9,6 @@ import { GlobalLoadingContext } from "@/context/global_loading_state_provider";
|
|
|
9
9
|
import { BlinkDot, Button, ButtonType } from "@bbki.ng/components";
|
|
10
10
|
import { faces, hearts, ReactionEmojiPair, sadFaces } from "./emojis";
|
|
11
11
|
import { ShareBtn } from "../share/share-btn";
|
|
12
|
-
import { CommentBtn } from "../comment/comment-btn";
|
|
13
12
|
|
|
14
13
|
declare global {
|
|
15
14
|
namespace JSX {
|
|
@@ -101,8 +100,6 @@ export const Reaction = (props: { title: string; url: string }) => {
|
|
|
101
100
|
url: props.url,
|
|
102
101
|
}}
|
|
103
102
|
/>
|
|
104
|
-
|
|
105
|
-
{/*<CommentBtn />*/}
|
|
106
103
|
</div>
|
|
107
104
|
);
|
|
108
105
|
};
|
|
@@ -4,7 +4,8 @@ import { useVideoControls, useVideoEleHeight, useVideoProgress } from "@/hooks";
|
|
|
4
4
|
import { BlurCover, ProgressBar } from "@/components";
|
|
5
5
|
import { BgColors, TextColors } from "@/types/color";
|
|
6
6
|
import { AspectRatioBox } from "@/components/aspect_ratio_box";
|
|
7
|
-
|
|
7
|
+
|
|
8
|
+
const VIDEO_TAG_ASPECT_RATIO = 0.5624910522548318;
|
|
8
9
|
|
|
9
10
|
type videoPlayProps = {
|
|
10
11
|
src: string;
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import { createClient } from "@supabase/supabase-js";
|
|
2
2
|
|
|
3
|
-
export { PHOTO_PROJECTS } from "./photo_projects";
|
|
4
|
-
export { VIDEO_LOGS, VIDEO_TAG_ASPECT_RATIO } from "./video_logs";
|
|
5
3
|
export { ROUTES, ROUTE_NAME, GITHUB_REPO_ADDRESS } from "./routes";
|
|
6
4
|
export const DEFAULT_DELAY = 200;
|
|
7
5
|
export const SUPABASE: {
|
package/src/blog/pages/index.tsx
CHANGED
|
@@ -1,15 +1,2 @@
|
|
|
1
|
-
import React, { lazy, Suspense } from "react";
|
|
2
|
-
import { minDelay } from "@/utils";
|
|
3
|
-
|
|
4
|
-
const NowLazy = lazy(() => minDelay(import("./now")));
|
|
5
|
-
const NowPage = () => {
|
|
6
|
-
return (
|
|
7
|
-
<Suspense fallback={null}>
|
|
8
|
-
<NowLazy />
|
|
9
|
-
</Suspense>
|
|
10
|
-
);
|
|
11
|
-
};
|
|
12
|
-
|
|
13
1
|
export { Cover } from "./cover";
|
|
14
|
-
export { NowPage };
|
|
15
2
|
export { default as Streaming } from "./streaming";
|
|
@@ -44,22 +44,24 @@ const Streaming = () => {
|
|
|
44
44
|
|
|
45
45
|
const formattedData = formatStreamingData(streaming || []);
|
|
46
46
|
|
|
47
|
-
if (isLoading) {
|
|
48
|
-
|
|
49
|
-
}
|
|
47
|
+
// if (isLoading) {
|
|
48
|
+
// return null;
|
|
49
|
+
// }
|
|
50
50
|
|
|
51
51
|
return (
|
|
52
|
-
<Article title="直播">
|
|
53
|
-
|
|
54
|
-
<
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
52
|
+
<Article title="直播" loading={isLoading}>
|
|
53
|
+
{isLoading ? null : (
|
|
54
|
+
<Panel className="!p-[10px]">
|
|
55
|
+
<bb-msg-history
|
|
56
|
+
// infinite
|
|
57
|
+
hide-scroll-bar
|
|
58
|
+
ref={bbMsgHistoryRef}
|
|
59
|
+
style={{ height: "100%", "--bb-max-height": "200px" } as React.CSSProperties}
|
|
60
|
+
>
|
|
61
|
+
{formattedData}
|
|
62
|
+
</bb-msg-history>
|
|
63
|
+
</Panel>
|
|
64
|
+
)}
|
|
63
65
|
</Article>
|
|
64
66
|
);
|
|
65
67
|
};
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
title: "近况"
|
|
3
|
-
---
|
|
4
|
-
|
|
5
|
-
import { MovieList } from "@/components/movie_list";
|
|
6
|
-
import { BookList } from "@/components/book_list";
|
|
7
|
-
|
|
8
|
-
## 编码
|
|
9
|
-
|
|
10
|
-
- game dev
|
|
11
|
-
- c#
|
|
12
|
-
- unity
|
|
13
|
-
|
|
14
|
-
## 阅读
|
|
15
|
-
|
|
16
|
-
<BookList />
|
|
17
|
-
|
|
18
|
-
## 电影
|
|
19
|
-
|
|
20
|
-
<MovieList />
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
import React, { useContext } from "react";
|
|
2
|
-
import { Link, Tag } from "@bbki.ng/components";
|
|
3
|
-
import { useLocation } from "react-router-dom";
|
|
4
|
-
import { usePaths } from "@/hooks";
|
|
5
|
-
import { GlobalLoadingContext } from "@/context/global_loading_state_provider";
|
|
6
|
-
|
|
7
|
-
export const Footer = () => {
|
|
8
|
-
const location = useLocation();
|
|
9
|
-
const isRoot = location.pathname === "/";
|
|
10
|
-
const { isLoading } = useContext(GlobalLoadingContext);
|
|
11
|
-
|
|
12
|
-
if (isRoot) {
|
|
13
|
-
// @ts-ignore
|
|
14
|
-
const appVer = GLOBAL_BBKING_VERSION;
|
|
15
|
-
const tagUrl = `https://github.com/bbbottle/bottle/releases/tag/@bbki.ng/site@${appVer}`;
|
|
16
|
-
return (
|
|
17
|
-
<div className="mt-128">
|
|
18
|
-
<Tag to={tagUrl} prefix="v" external>
|
|
19
|
-
{appVer}
|
|
20
|
-
</Tag>
|
|
21
|
-
</div>
|
|
22
|
-
);
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
if (isLoading) {
|
|
26
|
-
return null;
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
const paths = usePaths();
|
|
30
|
-
const prevPath = paths[paths.length - 2];
|
|
31
|
-
|
|
32
|
-
return (
|
|
33
|
-
<div className="w-full flex justify-center md:hidden">
|
|
34
|
-
<Link to={prevPath.path || ""} className="text-center">
|
|
35
|
-
cd ..
|
|
36
|
-
</Link>
|
|
37
|
-
</div>
|
|
38
|
-
);
|
|
39
|
-
};
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { Table, Link, Error } from "@bbki.ng/components";
|
|
3
|
-
import { useBooks } from "@/hooks";
|
|
4
|
-
import { TableSkeleton } from "@/components/table_skeleton";
|
|
5
|
-
|
|
6
|
-
const CELL_STYLE = {
|
|
7
|
-
width: 100,
|
|
8
|
-
maxWidth: 100,
|
|
9
|
-
};
|
|
10
|
-
|
|
11
|
-
export const BookList = () => {
|
|
12
|
-
const { books, isLoading, isError } = useBooks();
|
|
13
|
-
if (isError) {
|
|
14
|
-
return <Error error={isError} />;
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
if (isLoading) {
|
|
18
|
-
return <TableSkeleton headers={["书名", "状态"]} />;
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
const renderHeader = () => {
|
|
22
|
-
return (
|
|
23
|
-
<>
|
|
24
|
-
<Table.HCell style={CELL_STYLE}>书名</Table.HCell>
|
|
25
|
-
<Table.HCell style={CELL_STYLE}>状态</Table.HCell>
|
|
26
|
-
</>
|
|
27
|
-
);
|
|
28
|
-
};
|
|
29
|
-
|
|
30
|
-
const filteredBooks = books.filter((m: any) => m.visible == 1);
|
|
31
|
-
|
|
32
|
-
const renderRow = (index: number) => {
|
|
33
|
-
const { name: title, link, status } = filteredBooks[index];
|
|
34
|
-
return (
|
|
35
|
-
<>
|
|
36
|
-
<Table.Cell style={CELL_STYLE}>
|
|
37
|
-
<Link to={link} external>
|
|
38
|
-
{title}
|
|
39
|
-
</Link>
|
|
40
|
-
</Table.Cell>
|
|
41
|
-
<Table.Cell style={CELL_STYLE}>{status}</Table.Cell>
|
|
42
|
-
</>
|
|
43
|
-
);
|
|
44
|
-
};
|
|
45
|
-
return (
|
|
46
|
-
<Table
|
|
47
|
-
rowCount={filteredBooks.length}
|
|
48
|
-
rowRenderer={renderRow}
|
|
49
|
-
headerRenderer={renderHeader}
|
|
50
|
-
/>
|
|
51
|
-
);
|
|
52
|
-
};
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { Button, ButtonType } from "@bbki.ng/components";
|
|
3
|
-
import { CommentIcon } from "./comment-icon";
|
|
4
|
-
export const CommentBtn = () => {
|
|
5
|
-
return (
|
|
6
|
-
<Button
|
|
7
|
-
size="small"
|
|
8
|
-
className="text-gray-400 hover:text-gray-600 transition-colors ease-in duration-200 px-0"
|
|
9
|
-
type={ButtonType.GHOST}
|
|
10
|
-
onClick={() => {}}
|
|
11
|
-
>
|
|
12
|
-
<CommentIcon />
|
|
13
|
-
</Button>
|
|
14
|
-
);
|
|
15
|
-
};
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
|
|
3
|
-
export const CommentIcon = () => {
|
|
4
|
-
return (
|
|
5
|
-
<svg
|
|
6
|
-
data-testid="geist-icon"
|
|
7
|
-
stroke-linejoin="round"
|
|
8
|
-
viewBox="0 0 16 16"
|
|
9
|
-
height="12"
|
|
10
|
-
width="12"
|
|
11
|
-
>
|
|
12
|
-
<path
|
|
13
|
-
fill-rule="evenodd"
|
|
14
|
-
clip-rule="evenodd"
|
|
15
|
-
d="M2.8914 10.4028L2.98327 10.6318C3.22909 11.2445 3.5 12.1045 3.5 13C3.5 13.3588 3.4564 13.7131 3.38773 14.0495C3.69637 13.9446 4.01409 13.8159 4.32918 13.6584C4.87888 13.3835 5.33961 13.0611 5.70994 12.7521L6.22471 12.3226L6.88809 12.4196C7.24851 12.4724 7.61994 12.5 8 12.5C11.7843 12.5 14.5 9.85569 14.5 7C14.5 4.14431 11.7843 1.5 8 1.5C4.21574 1.5 1.5 4.14431 1.5 7C1.5 8.18175 1.94229 9.29322 2.73103 10.2153L2.8914 10.4028ZM2.8135 15.7653C1.76096 16 1 16 1 16C1 16 1.43322 15.3097 1.72937 14.4367C1.88317 13.9834 2 13.4808 2 13C2 12.3826 1.80733 11.7292 1.59114 11.1903C0.591845 10.0221 0 8.57152 0 7C0 3.13401 3.58172 0 8 0C12.4183 0 16 3.13401 16 7C16 10.866 12.4183 14 8 14C7.54721 14 7.10321 13.9671 6.67094 13.9038C6.22579 14.2753 5.66881 14.6656 5 15C4.23366 15.3832 3.46733 15.6195 2.8135 15.7653Z"
|
|
16
|
-
fill="currentColor"
|
|
17
|
-
></path>
|
|
18
|
-
</svg>
|
|
19
|
-
);
|
|
20
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {}
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
import React, { EventHandler, useEffect } from "react";
|
|
2
|
-
import { PopConfirm } from "@bbki.ng/components";
|
|
3
|
-
import classNames from "classnames";
|
|
4
|
-
|
|
5
|
-
type cornerPromptBoxProps = {
|
|
6
|
-
okLabel?: string;
|
|
7
|
-
onOk?: (() => void) | null;
|
|
8
|
-
onCancel?: (() => void) | null;
|
|
9
|
-
cancelLabel?: string;
|
|
10
|
-
autoCancelAfter?: number;
|
|
11
|
-
content: string;
|
|
12
|
-
showBox: boolean;
|
|
13
|
-
className?: string;
|
|
14
|
-
};
|
|
15
|
-
|
|
16
|
-
export const CornerPromptBox = (props: cornerPromptBoxProps) => {
|
|
17
|
-
const { onOk, onCancel, content, showBox, autoCancelAfter, className } =
|
|
18
|
-
props;
|
|
19
|
-
|
|
20
|
-
useEffect(() => {
|
|
21
|
-
if (!autoCancelAfter || !onCancel || !showBox) {
|
|
22
|
-
return;
|
|
23
|
-
}
|
|
24
|
-
const timerId = setTimeout(() => {
|
|
25
|
-
onCancel();
|
|
26
|
-
}, autoCancelAfter);
|
|
27
|
-
|
|
28
|
-
return () => {
|
|
29
|
-
clearTimeout(timerId);
|
|
30
|
-
};
|
|
31
|
-
}, [showBox]);
|
|
32
|
-
|
|
33
|
-
const handleOk = async () => {
|
|
34
|
-
if (!onOk) {
|
|
35
|
-
return;
|
|
36
|
-
}
|
|
37
|
-
return onOk();
|
|
38
|
-
};
|
|
39
|
-
|
|
40
|
-
if (!showBox) {
|
|
41
|
-
return null;
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
return (
|
|
45
|
-
<div className="p-0 m-0 w-0 h-0">
|
|
46
|
-
<div
|
|
47
|
-
className={classNames(
|
|
48
|
-
"left-0 bottom-0 m-32 z-10 bg-white fixed",
|
|
49
|
-
className
|
|
50
|
-
)}
|
|
51
|
-
>
|
|
52
|
-
<PopConfirm
|
|
53
|
-
onOk={handleOk}
|
|
54
|
-
onCancel={
|
|
55
|
-
onCancel as EventHandler<React.MouseEvent<HTMLButtonElement>>
|
|
56
|
-
}
|
|
57
|
-
>
|
|
58
|
-
{content}
|
|
59
|
-
</PopConfirm>
|
|
60
|
-
</div>
|
|
61
|
-
</div>
|
|
62
|
-
);
|
|
63
|
-
};
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import classnames from "classnames";
|
|
3
|
-
|
|
4
|
-
type disabledTextProps = {
|
|
5
|
-
children: any;
|
|
6
|
-
className?: string;
|
|
7
|
-
};
|
|
8
|
-
|
|
9
|
-
export const DisabledText = (props: disabledTextProps) => {
|
|
10
|
-
return (
|
|
11
|
-
<span className={classnames("text-gray-400", props.className)}>
|
|
12
|
-
{props.children}
|
|
13
|
-
</span>
|
|
14
|
-
);
|
|
15
|
-
};
|
|
16
|
-
|
|
17
|
-
export const SmallDisabledText = (props: disabledTextProps) => {
|
|
18
|
-
return (
|
|
19
|
-
<small>
|
|
20
|
-
<DisabledText>{props.children}</DisabledText>
|
|
21
|
-
</small>
|
|
22
|
-
);
|
|
23
|
-
};
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
import React, { FunctionComponent, useEffect, useState } from "react";
|
|
2
|
-
import classnames from "classnames";
|
|
3
|
-
import { DEFAULT_DELAY } from "@/constants";
|
|
4
|
-
|
|
5
|
-
type FadeOutCoverProps = {
|
|
6
|
-
duration: number; // ms
|
|
7
|
-
coverColor: string;
|
|
8
|
-
};
|
|
9
|
-
|
|
10
|
-
export const FadeOutCover: FunctionComponent<FadeOutCoverProps> = (props) => {
|
|
11
|
-
const [hidden, setHidden] = useState(false);
|
|
12
|
-
useEffect(() => {
|
|
13
|
-
const id = setTimeout(() => {
|
|
14
|
-
setHidden(true);
|
|
15
|
-
}, props.duration || DEFAULT_DELAY);
|
|
16
|
-
return () => {
|
|
17
|
-
clearTimeout(id);
|
|
18
|
-
};
|
|
19
|
-
}, []);
|
|
20
|
-
return (
|
|
21
|
-
<div
|
|
22
|
-
style={{
|
|
23
|
-
backgroundColor: props.coverColor || "#fff",
|
|
24
|
-
}}
|
|
25
|
-
className={classnames(
|
|
26
|
-
"transition-opacity",
|
|
27
|
-
"h-full",
|
|
28
|
-
"w-full",
|
|
29
|
-
"absolute",
|
|
30
|
-
"opacity-100",
|
|
31
|
-
{
|
|
32
|
-
"opacity-0": hidden,
|
|
33
|
-
}
|
|
34
|
-
)}
|
|
35
|
-
/>
|
|
36
|
-
);
|
|
37
|
-
};
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { pathObj } from "@/types/path";
|
|
2
|
-
import { GITHUB_REPO_ADDRESS, ROUTES } from "@/constants";
|
|
3
|
-
|
|
4
|
-
export const FooterLinks: pathObj[] = [
|
|
5
|
-
{
|
|
6
|
-
name: "blog",
|
|
7
|
-
path: ROUTES.BLOG,
|
|
8
|
-
},
|
|
9
|
-
// {
|
|
10
|
-
// text: "contributing",
|
|
11
|
-
// link: "https://github.com/bbbottle/bbki.ng/blob/main/CONTRIBUTING.md",
|
|
12
|
-
// },
|
|
13
|
-
];
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { pathObj } from "@/types/path";
|
|
3
|
-
import { TextColors } from "@/types/color";
|
|
4
|
-
// import { List } from "../list";
|
|
5
|
-
import { FooterLinks } from "./footer_links";
|
|
6
|
-
import { Link, LinkColor } from "@bbki.ng/components";
|
|
7
|
-
|
|
8
|
-
export const Footer = () => {
|
|
9
|
-
const renderFooterLink = (l: pathObj) => {
|
|
10
|
-
return (
|
|
11
|
-
<Link to={l.path as string} color={LinkColor.GRAY}>
|
|
12
|
-
{l.name}
|
|
13
|
-
</Link>
|
|
14
|
-
);
|
|
15
|
-
};
|
|
16
|
-
|
|
17
|
-
return renderFooterLink(FooterLinks[0]);
|
|
18
|
-
// return (
|
|
19
|
-
// <List items={FooterLinks} itemRenderer={renderFooterLink} horizontal />
|
|
20
|
-
// );
|
|
21
|
-
};
|
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { Table, Link, Error } from "@bbki.ng/components";
|
|
3
|
-
import { TableSkeleton } from "@/components/table_skeleton";
|
|
4
|
-
import { useMovies } from "@/hooks";
|
|
5
|
-
|
|
6
|
-
const CELL_STYLE = {
|
|
7
|
-
width: 100,
|
|
8
|
-
maxWidth: 100,
|
|
9
|
-
};
|
|
10
|
-
|
|
11
|
-
export const MovieList = () => {
|
|
12
|
-
const { movies, isLoading, isError } = useMovies();
|
|
13
|
-
|
|
14
|
-
if (isError) {
|
|
15
|
-
return <Error error={isError} />;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
if (isLoading) {
|
|
19
|
-
return <TableSkeleton />;
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
const filteredMovies = movies.filter((m: any) => m.visible == 1);
|
|
23
|
-
|
|
24
|
-
const renderHeader = () => {
|
|
25
|
-
return (
|
|
26
|
-
<>
|
|
27
|
-
<Table.HCell style={CELL_STYLE}>名字</Table.HCell>
|
|
28
|
-
<Table.HCell style={CELL_STYLE}>状态</Table.HCell>
|
|
29
|
-
</>
|
|
30
|
-
);
|
|
31
|
-
};
|
|
32
|
-
|
|
33
|
-
const renderRow = (index: number) => {
|
|
34
|
-
const { name, link, status } = filteredMovies[index];
|
|
35
|
-
return (
|
|
36
|
-
<>
|
|
37
|
-
<Table.Cell style={CELL_STYLE}>
|
|
38
|
-
<Link to={link} external>
|
|
39
|
-
{name}
|
|
40
|
-
</Link>
|
|
41
|
-
</Table.Cell>
|
|
42
|
-
<Table.Cell style={CELL_STYLE}>{status}</Table.Cell>
|
|
43
|
-
</>
|
|
44
|
-
);
|
|
45
|
-
};
|
|
46
|
-
return (
|
|
47
|
-
<Table
|
|
48
|
-
rowCount={filteredMovies.length}
|
|
49
|
-
rowRenderer={renderRow}
|
|
50
|
-
headerRenderer={renderHeader}
|
|
51
|
-
/>
|
|
52
|
-
);
|
|
53
|
-
};
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
import { OSS_PHOTOS } from "@/constants/photos";
|
|
2
|
-
import { PhotoProject } from "@/types/photo";
|
|
3
|
-
|
|
4
|
-
export const PHOTO_PROJECTS: PhotoProject[] = [
|
|
5
|
-
{
|
|
6
|
-
name: "过去的来意",
|
|
7
|
-
description: '"往事越千年"',
|
|
8
|
-
images: [OSS_PHOTOS.quyuan, OSS_PHOTOS.weapons, OSS_PHOTOS.stone],
|
|
9
|
-
},
|
|
10
|
-
{
|
|
11
|
-
name: "敬县城",
|
|
12
|
-
description: '"早秋惊落叶,飘零似客心。翻飞未肯下,犹言忆故林。"',
|
|
13
|
-
images: [
|
|
14
|
-
OSS_PHOTOS.motorcycle,
|
|
15
|
-
OSS_PHOTOS.cycle,
|
|
16
|
-
OSS_PHOTOS.corner,
|
|
17
|
-
OSS_PHOTOS.streetGames,
|
|
18
|
-
OSS_PHOTOS.localDishes,
|
|
19
|
-
],
|
|
20
|
-
},
|
|
21
|
-
{
|
|
22
|
-
name: "海底的家",
|
|
23
|
-
description:
|
|
24
|
-
'"河流用一生梳理 \\ 地球的表情 \\ 沿岸收集人類的喜怒哀樂 \\ 檔案堆滿了海底的家"',
|
|
25
|
-
images: [
|
|
26
|
-
OSS_PHOTOS.playWithWater,
|
|
27
|
-
OSS_PHOTOS.shopping,
|
|
28
|
-
OSS_PHOTOS.chess,
|
|
29
|
-
OSS_PHOTOS.player,
|
|
30
|
-
// OSS_PHOTOS.swimmer,
|
|
31
|
-
OSS_PHOTOS.players,
|
|
32
|
-
// OSS_PHOTOS.dragonRiver,
|
|
33
|
-
// OSS_PHOTOS.riverAndBoats,
|
|
34
|
-
OSS_PHOTOS.riverSide,
|
|
35
|
-
OSS_PHOTOS.quilt,
|
|
36
|
-
// OSS_PHOTOS.fishing,
|
|
37
|
-
OSS_PHOTOS.waterLine,
|
|
38
|
-
OSS_PHOTOS.bridge,
|
|
39
|
-
OSS_PHOTOS.building,
|
|
40
|
-
OSS_PHOTOS.smoking,
|
|
41
|
-
// OSS_PHOTOS.jzBridge,
|
|
42
|
-
],
|
|
43
|
-
},
|
|
44
|
-
// {
|
|
45
|
-
// title: "光前",
|
|
46
|
-
// description: "城中村,个人深圳经历出入口。",
|
|
47
|
-
// images: [OSS_PHOTOS.oldMan, OSS_PHOTOS.oldWomen, OSS_PHOTOS.littleChild],
|
|
48
|
-
// },
|
|
49
|
-
// {
|
|
50
|
-
// title: "三百零一",
|
|
51
|
-
// description: "陋室光影",
|
|
52
|
-
// images: [OSS_PHOTOS.phone, OSS_PHOTOS.chair],
|
|
53
|
-
// },
|
|
54
|
-
];
|
|
@@ -1,277 +0,0 @@
|
|
|
1
|
-
import { BgColors } from "@/types/color";
|
|
2
|
-
import { ossProcessType } from "@/types/oss";
|
|
3
|
-
|
|
4
|
-
export const OSS_PHOTOS = {
|
|
5
|
-
playWithWater: {
|
|
6
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/xiang-jiang-river/DSCF2203-1.jpg",
|
|
7
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
8
|
-
processType: ossProcessType.PROG,
|
|
9
|
-
width: 1879,
|
|
10
|
-
height: 1238,
|
|
11
|
-
},
|
|
12
|
-
shopping: {
|
|
13
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/xiang-jiang-river/shopping.jpg",
|
|
14
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
15
|
-
width: 1746,
|
|
16
|
-
height: 1746,
|
|
17
|
-
},
|
|
18
|
-
quyuan: {
|
|
19
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/from-the-past/quyuan.webp",
|
|
20
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
21
|
-
width: 4126,
|
|
22
|
-
height: 6262,
|
|
23
|
-
},
|
|
24
|
-
stone: {
|
|
25
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/from-the-past/stone.webp",
|
|
26
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
27
|
-
renderedWidth: 300,
|
|
28
|
-
width: 5536,
|
|
29
|
-
height: 4126,
|
|
30
|
-
},
|
|
31
|
-
weapons: {
|
|
32
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/from-the-past/weapon.webp",
|
|
33
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
34
|
-
width: 6155,
|
|
35
|
-
height: 4126,
|
|
36
|
-
},
|
|
37
|
-
roof: {
|
|
38
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/xiang-jiang-river/DSCF1807.RAF.jpg",
|
|
39
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
40
|
-
width: 6262,
|
|
41
|
-
height: 3278,
|
|
42
|
-
},
|
|
43
|
-
chess: {
|
|
44
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/xiang-jiang-river/checkmate.webp",
|
|
45
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
46
|
-
width: 6262,
|
|
47
|
-
height: 4126,
|
|
48
|
-
},
|
|
49
|
-
swimmer: {
|
|
50
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/xiang-jiang-river/swimmer.jpg",
|
|
51
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
52
|
-
width: 6081,
|
|
53
|
-
height: 4126,
|
|
54
|
-
},
|
|
55
|
-
player: {
|
|
56
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/xiang-jiang-river/player-min.webp",
|
|
57
|
-
width: 2692,
|
|
58
|
-
height: 3546,
|
|
59
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
60
|
-
},
|
|
61
|
-
players: {
|
|
62
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/xiang-jiang-river/players.jpg",
|
|
63
|
-
width: 3368,
|
|
64
|
-
height: 2344,
|
|
65
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
66
|
-
},
|
|
67
|
-
fishing: {
|
|
68
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/xiang-jiang-river/p2705047873.webp",
|
|
69
|
-
thumbnailSrc:
|
|
70
|
-
"https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/xiang-jiang-river/p2705047873.webp?x-oss-process=style/thumbnail",
|
|
71
|
-
width: 1080,
|
|
72
|
-
height: 720,
|
|
73
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
74
|
-
},
|
|
75
|
-
dragonRiver: {
|
|
76
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/xiang-jiang-river/164-2.jpg",
|
|
77
|
-
width: 4021,
|
|
78
|
-
height: 4021,
|
|
79
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
80
|
-
},
|
|
81
|
-
waterLine: {
|
|
82
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/xiang-jiang-river/p2704851973.webp",
|
|
83
|
-
thumbnailSrc:
|
|
84
|
-
"https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/xiang-jiang-river/p2704851973.webp?x-oss-process=style/thumbnail",
|
|
85
|
-
renderedWidth: 500,
|
|
86
|
-
width: 1080,
|
|
87
|
-
height: 720,
|
|
88
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
89
|
-
},
|
|
90
|
-
phone: {
|
|
91
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/301/DSCF1355.RAF.min.jpg",
|
|
92
|
-
width: 924,
|
|
93
|
-
height: 619,
|
|
94
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
95
|
-
},
|
|
96
|
-
riverAndBoats: {
|
|
97
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/xiang-jiang-river/x2705749244.jpg",
|
|
98
|
-
renderedWidth: 800,
|
|
99
|
-
width: 1080,
|
|
100
|
-
height: 830,
|
|
101
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
102
|
-
},
|
|
103
|
-
riverSide: {
|
|
104
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/xiang-jiang-river/x2705752731.jpg",
|
|
105
|
-
renderedWidth: 400,
|
|
106
|
-
width: 1080,
|
|
107
|
-
height: 720,
|
|
108
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
109
|
-
},
|
|
110
|
-
xwy: {
|
|
111
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/illustration/illustration/xwy.jpg",
|
|
112
|
-
renderedWidth: 400,
|
|
113
|
-
width: 1125,
|
|
114
|
-
height: 750,
|
|
115
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
116
|
-
},
|
|
117
|
-
quilt: {
|
|
118
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/xiang-jiang-river/x2710816755.jpg",
|
|
119
|
-
thumbnailSrc:
|
|
120
|
-
"https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/xiang-jiang-river/x2710816755.jpg?x-oss-process=style/thumbnail",
|
|
121
|
-
renderedWidth: 490,
|
|
122
|
-
width: 1080,
|
|
123
|
-
height: 832,
|
|
124
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
125
|
-
},
|
|
126
|
-
bridge: {
|
|
127
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/xiang-jiang-river/p2705529760.webp",
|
|
128
|
-
thumbnailSrc:
|
|
129
|
-
"https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/xiang-jiang-river/p2705529760.webp?x-oss-process=style/thumbnail",
|
|
130
|
-
renderedWidth: 450,
|
|
131
|
-
width: 1080,
|
|
132
|
-
height: 726,
|
|
133
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
134
|
-
},
|
|
135
|
-
building: {
|
|
136
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/xiang-jiang-river/%E5%BE%AE%E4%BF%A1%E5%9B%BE%E7%89%87_20211025194518.jpg",
|
|
137
|
-
thumbnailSrc:
|
|
138
|
-
"https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/xiang-jiang-river/%E5%BE%AE%E4%BF%A1%E5%9B%BE%E7%89%87_20211025194518.jpg?x-oss-process=style/thumbnail",
|
|
139
|
-
width: 3019,
|
|
140
|
-
height: 2293,
|
|
141
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
142
|
-
},
|
|
143
|
-
chair: {
|
|
144
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/301/room-301.jpg",
|
|
145
|
-
renderedWidth: 490,
|
|
146
|
-
width: 970,
|
|
147
|
-
height: 745,
|
|
148
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
149
|
-
},
|
|
150
|
-
smoking: {
|
|
151
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/xiang-jiang-river/DSCF1383.jpg",
|
|
152
|
-
width: 2023,
|
|
153
|
-
height: 2670,
|
|
154
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
155
|
-
},
|
|
156
|
-
jzBridge: {
|
|
157
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/xiang-jiang-river/DSCF1401.jpg",
|
|
158
|
-
width: 5980,
|
|
159
|
-
height: 3699,
|
|
160
|
-
renderedWidth: 700,
|
|
161
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
162
|
-
},
|
|
163
|
-
motorcycle: {
|
|
164
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/county-town/4688FF3F-8EF5-4F63-B726-9AC275C1A97E-50268-000009856F7D5885.jpg",
|
|
165
|
-
thumbnailSrc:
|
|
166
|
-
"https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/county-town/4688FF3F-8EF5-4F63-B726-9AC275C1A97E-50268-000009856F7D5885.jpg?x-oss-process=style/thumbnail",
|
|
167
|
-
width: 1306,
|
|
168
|
-
height: 821,
|
|
169
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
170
|
-
},
|
|
171
|
-
cycle: {
|
|
172
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/county-town/3922C86B-79D5-455F-9FA8-7EB405CE95A6-38852-000007863DB50E30.jpg",
|
|
173
|
-
thumbnailSrc:
|
|
174
|
-
"https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/county-town/3922C86B-79D5-455F-9FA8-7EB405CE95A6-38852-000007863DB50E30.jpg?x-oss-process=style/thumbnail",
|
|
175
|
-
renderedWidth: 400,
|
|
176
|
-
width: 1501,
|
|
177
|
-
height: 1144,
|
|
178
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
179
|
-
},
|
|
180
|
-
streetGames: {
|
|
181
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/county-town/B3AACBCA-807B-44C0-9CA2-E1F7E0C00C93_black.jpg",
|
|
182
|
-
thumbnailSrc:
|
|
183
|
-
"https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/county-town/B3AACBCA-807B-44C0-9CA2-E1F7E0C00C93_black.jpg?x-oss-process=style/thumbnail",
|
|
184
|
-
width: 898,
|
|
185
|
-
height: 729,
|
|
186
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
187
|
-
},
|
|
188
|
-
corner: {
|
|
189
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/county-town/E2FDA467-AD6D-4410-9B50-66E1624C13D6-38852-0000078630EDA7C4.jpg",
|
|
190
|
-
thumbnailSrc:
|
|
191
|
-
"https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/county-town/E2FDA467-AD6D-4410-9B50-66E1624C13D6-38852-0000078630EDA7C4.jpg?x-oss-process=style/thumbnail",
|
|
192
|
-
renderedWidth: 500,
|
|
193
|
-
width: 1776,
|
|
194
|
-
height: 1184,
|
|
195
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
196
|
-
},
|
|
197
|
-
localDishes: {
|
|
198
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/county-town/IMG_3869.JPG",
|
|
199
|
-
thumbnailSrc:
|
|
200
|
-
"https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/county-town/IMG_3869.JPG?x-oss-process=style/thumbnail",
|
|
201
|
-
renderedWidth: 490,
|
|
202
|
-
width: 897,
|
|
203
|
-
height: 720,
|
|
204
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
205
|
-
},
|
|
206
|
-
oldMan: {
|
|
207
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/before-the-light/IMG_1844.jpg?x-oss-process=style/webp",
|
|
208
|
-
thumbnailSrc:
|
|
209
|
-
"https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/before-the-light/IMG_1844.jpg?x-oss-process=style/thumbnail",
|
|
210
|
-
renderedWidth: 400,
|
|
211
|
-
width: 2673,
|
|
212
|
-
height: 3564,
|
|
213
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
214
|
-
},
|
|
215
|
-
oldWomen: {
|
|
216
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/before-the-light/IMG_E1668.JPG?x-oss-process=style/webp",
|
|
217
|
-
thumbnailSrc:
|
|
218
|
-
"https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/before-the-light/IMG_E1668.JPG?x-oss-process=style/thumbnail",
|
|
219
|
-
width: 1325,
|
|
220
|
-
height: 1960,
|
|
221
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
222
|
-
},
|
|
223
|
-
littleChild: {
|
|
224
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/before-the-light/IMG_E1677.JPG",
|
|
225
|
-
thumbnailSrc:
|
|
226
|
-
"https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/before-the-light/IMG_E1677.JPG?x-oss-process=style/thumbnail",
|
|
227
|
-
width: 2801,
|
|
228
|
-
renderedWidth: 600,
|
|
229
|
-
height: 2801,
|
|
230
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
231
|
-
},
|
|
232
|
-
logoPreview: {
|
|
233
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/illustration/illustration/favicon.png",
|
|
234
|
-
width: 640,
|
|
235
|
-
height: 640,
|
|
236
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
237
|
-
},
|
|
238
|
-
validLogoExample: {
|
|
239
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/illustration/illustration/Logo-with-image.png",
|
|
240
|
-
width: 1092,
|
|
241
|
-
height: 1386,
|
|
242
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
243
|
-
},
|
|
244
|
-
logoVariants: {
|
|
245
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/illustration/illustration/valid-variations.png",
|
|
246
|
-
width: 2800,
|
|
247
|
-
height: 640,
|
|
248
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
249
|
-
},
|
|
250
|
-
badLogoExamples: {
|
|
251
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/illustration/illustration/Bad-Examples.png",
|
|
252
|
-
width: 2801,
|
|
253
|
-
height: 1362,
|
|
254
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
255
|
-
},
|
|
256
|
-
logoColors: {
|
|
257
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/illustration/illustration/colors.png",
|
|
258
|
-
thumbnailSrc:
|
|
259
|
-
"https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/illustration/illustration/colors.png?x-oss-process=style/thumbnail",
|
|
260
|
-
width: 2466,
|
|
261
|
-
height: 640,
|
|
262
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
263
|
-
},
|
|
264
|
-
logoExcludesZone: {
|
|
265
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/image/illustration/illustration/Logo-Clear-Area.png",
|
|
266
|
-
width: 1000,
|
|
267
|
-
height: 1000,
|
|
268
|
-
avgColor: BgColors.LIGHT_GRAY,
|
|
269
|
-
},
|
|
270
|
-
};
|
|
271
|
-
|
|
272
|
-
export const PHOTOS_FOR_DEMO = [
|
|
273
|
-
OSS_PHOTOS.riverSide,
|
|
274
|
-
OSS_PHOTOS.stone,
|
|
275
|
-
OSS_PHOTOS.chair,
|
|
276
|
-
OSS_PHOTOS.weapons,
|
|
277
|
-
];
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
export const VIDEO_LOGS = [
|
|
2
|
-
{
|
|
3
|
-
name: "2021-09-10",
|
|
4
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/video/2021-09-10",
|
|
5
|
-
},
|
|
6
|
-
{
|
|
7
|
-
name: "2020-09-18",
|
|
8
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/video/2021-09-18.mov",
|
|
9
|
-
},
|
|
10
|
-
{
|
|
11
|
-
name: "2020-09-28",
|
|
12
|
-
src: "https://zjh-im-res.oss-cn-shenzhen.aliyuncs.com/video/2021-09-28-4k30H.mov",
|
|
13
|
-
},
|
|
14
|
-
];
|
|
15
|
-
|
|
16
|
-
export const VIDEO_TAG_ASPECT_RATIO = 0.5624910522548318;
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { useProjects } from "@/hooks/use_projects";
|
|
3
|
-
import { CenterLinkList } from "@/components";
|
|
4
|
-
|
|
5
|
-
const Projects = () => {
|
|
6
|
-
const { projects, isLoading } = useProjects("");
|
|
7
|
-
|
|
8
|
-
if (isLoading) {
|
|
9
|
-
return null;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
const links = projects.map((p: any) => ({
|
|
13
|
-
to: `/projects/${p.name}`,
|
|
14
|
-
name: p.name,
|
|
15
|
-
}));
|
|
16
|
-
|
|
17
|
-
return <CenterLinkList links={links} />;
|
|
18
|
-
};
|
|
19
|
-
|
|
20
|
-
export default () => {
|
|
21
|
-
return (
|
|
22
|
-
// <MySuspense>
|
|
23
|
-
<Projects />
|
|
24
|
-
// </MySuspense>
|
|
25
|
-
);
|
|
26
|
-
};
|
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
import React, { useEffect } from "react";
|
|
2
|
-
import { MySuspense } from "@/components";
|
|
3
|
-
import { useParams } from "react-router-dom";
|
|
4
|
-
import { useProjects } from "@/hooks/use_projects";
|
|
5
|
-
import { imageFormatter } from "@/utils";
|
|
6
|
-
import { Gallery } from "@bbki.ng/components";
|
|
7
|
-
import { ImageUploader } from "@/components/ImageUploader";
|
|
8
|
-
import classnames from "classnames";
|
|
9
|
-
import { ImageRenderer } from "@bbki.ng/components/lib";
|
|
10
|
-
import { ImgCtxMenu } from "@/components/Img_ctx_menu";
|
|
11
|
-
import {EffectLayer} from "@/components/effect-layer/EffectLayer";
|
|
12
|
-
|
|
13
|
-
const ProjectDetail = () => {
|
|
14
|
-
const { id } = useParams();
|
|
15
|
-
const { projects, refresh } = useProjects(id, true);
|
|
16
|
-
|
|
17
|
-
useEffect(() => {
|
|
18
|
-
return () => {
|
|
19
|
-
refresh().then(() => {});
|
|
20
|
-
};
|
|
21
|
-
}, []);
|
|
22
|
-
|
|
23
|
-
const renderImage: ImageRenderer = (img, index, col) => {
|
|
24
|
-
const imgInfo = projects.images[index];
|
|
25
|
-
|
|
26
|
-
return (
|
|
27
|
-
<ImgCtxMenu
|
|
28
|
-
date={imgInfo.created_at}
|
|
29
|
-
name={imgInfo.title}
|
|
30
|
-
width={imgInfo.width}
|
|
31
|
-
height={imgInfo.height}
|
|
32
|
-
id={imgInfo.id}
|
|
33
|
-
onRemoved={refresh}
|
|
34
|
-
>
|
|
35
|
-
<div
|
|
36
|
-
className={classnames("mb-128 select-none", {
|
|
37
|
-
"md:mr-64": col === 0,
|
|
38
|
-
"md:ml-64": col !== 0,
|
|
39
|
-
})}
|
|
40
|
-
>
|
|
41
|
-
{img}
|
|
42
|
-
</div>
|
|
43
|
-
</ImgCtxMenu>
|
|
44
|
-
);
|
|
45
|
-
};
|
|
46
|
-
|
|
47
|
-
const renderUploader = () => (
|
|
48
|
-
<ImageUploader
|
|
49
|
-
onUploadFinish={refresh}
|
|
50
|
-
projectId={projects.id}
|
|
51
|
-
projectName={id}
|
|
52
|
-
/>
|
|
53
|
-
);
|
|
54
|
-
|
|
55
|
-
return (
|
|
56
|
-
<>
|
|
57
|
-
<Gallery
|
|
58
|
-
images={projects.images.map(imageFormatter)}
|
|
59
|
-
imageRenderer={renderImage}
|
|
60
|
-
>
|
|
61
|
-
{renderUploader()}
|
|
62
|
-
</Gallery>
|
|
63
|
-
</>
|
|
64
|
-
);
|
|
65
|
-
};
|
|
66
|
-
|
|
67
|
-
export default () => {
|
|
68
|
-
return (
|
|
69
|
-
<MySuspense>
|
|
70
|
-
<ProjectDetail />
|
|
71
|
-
</MySuspense>
|
|
72
|
-
);
|
|
73
|
-
};
|