Skip to content

Commit a7ba757

Browse files
committed
Merge branch 'tencentyun:master' into feat/add-uploadFile
2 parents ebe25a4 + 5f5f614 commit a7ba757

File tree

3 files changed

+18063
-0
lines changed

3 files changed

+18063
-0
lines changed

CHANGELOG.md

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,26 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
99

10+
## [v1.2.12](https://github.com/tencentyun/cos-js-sdk-v5/compare/v1.2.11...v1.2.12) - 2021-06-03
11+
12+
-demo新增简单上传base64内容文件
13+
-sliceUploadFile方法新增返回值UploadId
14+
15+
### Merged
16+
17+
- Feat/put object base64&return upload [`#111`](https://github.com/tencentyun/cos-js-sdk-v5/pull/111)
18+
19+
### Commits
20+
21+
- feat [`1e2ca3a`](https://github.com/tencentyun/cos-js-sdk-v5/commit/1e2ca3ae255f64fee4aaab36c01d5a03eb3162a2)
22+
- upd:sliceUploadFile返回UploadId [`54d100f`](https://github.com/tencentyun/cos-js-sdk-v5/commit/54d100f41c8bd124c978860532d8a2a81ab1ff9d)
23+
- Updated CHANGELOG.md [`4a04539`](https://github.com/tencentyun/cos-js-sdk-v5/commit/4a0453966d67b586dbfe186e38973f72ffa8f9bd)
24+
- update version 1.2.12 [`843ffba`](https://github.com/tencentyun/cos-js-sdk-v5/commit/843ffba1ed4bb22ed5b23e5aeb7833f17f5577ad)
25+
- update version 1.2.12 [`cd0be19`](https://github.com/tencentyun/cos-js-sdk-v5/commit/cd0be1996ee5bf9e1cd007da2f44b121f23c04ab)
26+
- upd:sliceUploadFile返回UploadId [`4ff8a8e`](https://github.com/tencentyun/cos-js-sdk-v5/commit/4ff8a8ef35e5e6e80ed6aa2fdac629a954e596d6)
27+
- upd:优化base64文件上传demo [`cb8f356`](https://github.com/tencentyun/cos-js-sdk-v5/commit/cb8f356b2774280d7dce7886f4016a84c724fa14)
28+
- _No commit message_ [`c20924e`](https://github.com/tencentyun/cos-js-sdk-v5/commit/c20924e01e53e2045c2e30e76449a3d38dba6d57)
29+
1030
## [v1.2.11](https://github.com/tencentyun/cos-js-sdk-v5/compare/v1.2.10...v1.2.11) - 2021-05-28
1131

1232
### Merged

demo/crc64.html

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
2+
<!doctype html>
3+
<html lang="en">
4+
<head>
5+
<meta charset="UTF-8">
6+
<meta name="viewport"
7+
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
8+
<meta http-equiv="X-UA-Compatible" content="ie=edge">
9+
<title>CRC64</title>
10+
<style>
11+
h1 {
12+
font-weight: normal;
13+
}
14+
</style>
15+
</head>
16+
<body>
17+
18+
<div>
19+
<h1>JS 计算 CRC64</h1>
20+
<form id="form">
21+
<label>选择文件,计算 crc64:</label>
22+
<input id="file" type="file">
23+
</form>
24+
<div id="msg"></div>
25+
</div>
26+
27+
<script src="./crc64.js"></script>
28+
<script>
29+
var el = function (id) {
30+
return document.getElementById(id);
31+
};
32+
var calc = function (file) {
33+
var time0 = Date.now();
34+
CRC64.file_crc64(file, function (err, hash) {
35+
if (err) return console.log('crc64 error:', err);
36+
var time1 = Date.now();
37+
el('msg').innerHTML = 'cost ' + (time1 - time0) + 'ms, crc64=' + hash;
38+
el('form').reset();
39+
}, function (percent) {
40+
el('msg').innerHTML = (percent * 100).toFixed(2) + '%';
41+
});
42+
};
43+
el('file').onchange = function () {
44+
var file = this.files[0];
45+
calc(file);
46+
};
47+
48+
// calc string crc64
49+
console.log(CRC64.crc64('123456789'));
50+
</script>
51+
52+
</body>
53+
</html>

0 commit comments

Comments
 (0)