diff --git a/asset/share.css b/asset/share.css new file mode 100644 index 0000000000000000000000000000000000000000..6ccfd2f4aeedb1b847a17ea82cddce743039c650 --- /dev/null +++ b/asset/share.css @@ -0,0 +1,15 @@ +#share-btn { + position: fixed; + right: 15px; + top: 220px; + width: 35px; + height: 35px; + background-repeat: no-repeat; + background-size: cover; + cursor: pointer; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + background-image: url('share.svg'); +} \ No newline at end of file diff --git a/asset/share.js b/asset/share.js new file mode 100644 index 0000000000000000000000000000000000000000..8e8a2e59a63b70f3c3e8c29582dd8b62705be723 --- /dev/null +++ b/asset/share.js @@ -0,0 +1,24 @@ +document.addEventListener('DOMContentLoaded', function() { + var shareBtn = document.createElement('a') + shareBtn.id = 'share-btn' + shareBtn.className = 'bdsharebuttonbox' + shareBtn.setAttribute('data-cmd', 'more') + document.body.append(shareBtn) + + window._bd_share_config = { + "common":{ + "bdSnsKey":{}, + "bdText":"", + "bdMini":"1", + "bdMiniList":false, + "bdPic":"", + "bdStyle":"2", + "bdSize":"16" + }, + "share":{} + } + var sc = document.createElement('script') + sc.src = 'http://bdimg.share.baidu.com/static/api/js/share.js' + + '?v=89860593.js?cdnversion=' + ~(-new Date()/36e5) + document.body.append(sc) +}) \ No newline at end of file diff --git a/asset/share.svg b/asset/share.svg new file mode 100644 index 0000000000000000000000000000000000000000..79da99c44346e81f86926eb0745fdc531ad9a7f4 --- /dev/null +++ b/asset/share.svg @@ -0,0 +1,10 @@ + + + + Share-1 + + + + + + \ No newline at end of file diff --git a/index.html b/index.html index acf1e4fbd816eb42a736b7a8b0f2048c7dd99422..0b5c032ac9d970b2a0efb2670db1b04e4aa556a2 100644 --- a/index.html +++ b/index.html @@ -18,6 +18,8 @@ + +
now loading...