Skip to content

Commit

Permalink
fix: 🐛 一点点样式优化
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaochao.yang committed Oct 13, 2022
1 parent 803df60 commit 5f5b17b
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions src/blocks/Zip/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -77,9 +77,10 @@ export const Zip = () => {
},
{ before: 0, after: 0 },
);
const before = `${info.before / 1024}Kb`;
const after = `${info.after / 1024}Kb`;
notify.success('压缩完成', `${after} / ${before}`);
const before = `${(info.before / 1024).toFixed(2)} KB`;
const after = `${(info.after / 1024).toFixed(2)} KB`;
const ratio = ((info.after / info.before) * 100).toFixed(2);
notify.success('压缩完成', `${before} ~> ${after} -${ratio}%`);
}
}, [count, finished]);

Expand Down Expand Up @@ -111,8 +112,6 @@ export const Zip = () => {
});
};

fresh();

useRafInterval(() => {
fresh();
}, 123);
Expand Down

0 comments on commit 5f5b17b

Please sign in to comment.