Skip to content

Commit

Permalink
Merge pull request #52 from EOEFANS/main
Browse files Browse the repository at this point in the history
修复图片页偏移问题
  • Loading branch information
master1lan authored and GitHub Enterprise committed Mar 16, 2023
2 parents b588211 + e8ea1e5 commit f2bd2d8
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 24 deletions.
9 changes: 9 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,15 @@

All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.

## 1.2.5 (2023-03-16)


### 🐛 Bug Fixes

* **custom**: 修复跳转到图片页面时页面偏移问题 ([6582a13](https://vlink.dev/EOEFANS/eoefans-web/commits/6582a13))



## 1.2.4 (2023-03-16)


Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "eoefans-web",
"version": "1.2.4",
"version": "1.2.5",
"type": "module",
"scripts": {
"dev": "vite --config ./config/vite.dev.config.ts",
Expand Down
43 changes: 20 additions & 23 deletions src/routers/photo/masonry.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -80,38 +80,35 @@ export default function Masonry(props: PhotoRouterMasonryType) {

return (
<div className={styles["container"]}>
<Fade in={!isLoading} className={`${!isLoading ? "" : "hidden"}`}>
<div>
{!isLoading && (
{isLoading ? (
<Fade in={isLoading}>
<div>
<Masonic_masonry
items={lists}
items={loadingLists}
maxColumnCount={5}
{...minCount}
columnGutter={md ? 5 : 10}
rowGutter={md ? 5 : 10}
columnWidth={200}
render={PhotoCard}
render={PhotoLoadingItem}
overscanBy={Infinity}
className={styles["container"]}
/>
)}
</div>
</Fade>
<Fade in={isLoading} className={`${isLoading ? "" : "hidden"}`}>
<div>
<Masonic_masonry
items={loadingLists}
maxColumnCount={5}
{...minCount}
columnGutter={md ? 5 : 10}
rowGutter={md ? 5 : 10}
columnWidth={200}
render={PhotoLoadingItem}
overscanBy={Infinity}
className={styles["container"]}
/>
</div>
</Fade>
</div>
</Fade>
) : (
<Masonic_masonry
items={lists}
maxColumnCount={5}
{...minCount}
columnGutter={md ? 5 : 10}
rowGutter={md ? 5 : 10}
columnWidth={200}
render={PhotoCard}
overscanBy={Infinity}
className={styles["container"]}
/>
)}
</div>
);
}

0 comments on commit f2bd2d8

Please sign in to comment.