Skip to content

Commit

Permalink
✨ 优化文章操作选项
Browse files Browse the repository at this point in the history
  • Loading branch information
Licoy committed Nov 27, 2022
1 parent d817647 commit 98ef164
Show file tree
Hide file tree
Showing 7 changed files with 28 additions and 29 deletions.
2 changes: 1 addition & 1 deletion assets/dist/js/puock.min.js

Large diffs are not rendered by default.

20 changes: 10 additions & 10 deletions assets/dist/style/libs.min.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion assets/dist/style/style.min.css

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions assets/js/puock.js
Original file line number Diff line number Diff line change
Expand Up @@ -226,7 +226,7 @@ class Puock {
}

eventShareStart() {
$(document).on("click", ".share-to>div", (e) => {
$(document).on("click", ".share-to", (e) => {
const id = $(this.ct(e)).attr("data-id");
if (id === 'wx') return;
const url = window.location.href;
Expand Down Expand Up @@ -359,7 +359,7 @@ class Puock {
navbar: false,
url: this.data.params.main_lazy_img ? 'data-src' : 'src'
});
const cp = new ClipboardJS('.copy-opt', {
const cp = new ClipboardJS('.pk-copy', {
text: (trigger) => {
const t = $(trigger)
let input = t.attr("data-cp-input")
Expand Down
14 changes: 6 additions & 8 deletions assets/style/style.less
Original file line number Diff line number Diff line change
Expand Up @@ -567,14 +567,12 @@ body.pre-mac pre {
.modal-header, .modal-footer {
border: none;
}

.modal-backdrop, .mobile-menu-backdrop {
backdrop-filter: blur(2px);
-webkit-backdrop-filter: blur(2px);
opacity: 1 !important;
background-color: rgba(0, 0, 0, 0.53);
}

}
.modal-backdrop, .mobile-menu-backdrop {
backdrop-filter: blur(2px);
-webkit-backdrop-filter: blur(2px);
opacity: 1 !important;
background-color: rgba(0, 0, 0, 0.53);
}

a:hover {
Expand Down
2 changes: 2 additions & 0 deletions templates/post-actions.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ class="fa fa-share-from-square t-md"></i></div>
data-url="<?php echo pk_ajax_url('pk_poster', ['id' => $post->ID]) ?>"
><i class="fa-regular fa-images"></i></div>
<?php endif; ?>
<div class="circle-button puock-bg text-center pk-copy" data-cp-title="文章链接" data-cp-val="<?php echo get_permalink() ?>"><i
class="fa fa-copy t-md"></i></div>
<div class="ls">
<div class="circle-button puock-bg text-center post-menu-toggle post-menus-box"><i
class="fa fa-bars t-md"></i></div>
Expand Down
13 changes: 6 additions & 7 deletions templates/post-share.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,20 +9,19 @@
</button>
</div>
<div class="modal-body">
<div class="d-flex justify-content-center w-100 share-to">
<div data-id="wb" class="circle-button circle-sm circle-hb text-center bg-danger text-light"><i
<div class="d-flex justify-content-center w-100">
<div data-id="wb" class="share-to circle-button circle-sm circle-hb text-center bg-danger text-light"><i
class="fa-brands fa-weibo t-md"></i></div>
<div data-id="wx" id="wx-share" data-toggle="tooltip" data-html="true"
data-url="<?php echo PUOCK_ABS_URI . pk_post_qrcode(get_permalink()) ?>"
class="circle-button circle-sm circle-hb text-center bg-success text-light"><i
class="share-to circle-button circle-sm circle-hb text-center bg-success text-light"><i
class="fa-brands fa-weixin t-md"></i></div>
<div data-id="qzone" class="circle-button circle-sm circle-hb text-center bg-warning text-light">
<div data-id="qzone" class="share-to circle-button circle-sm circle-hb text-center bg-warning text-light">
<i class="fa-brands fa-qq t-md"></i></div>
<div data-id="tw" class="circle-button circle-sm circle-hb text-center bg-info text-light"><i
<div data-id="tw" class="share-to circle-button circle-sm circle-hb text-center bg-info text-light"><i
class="fa-brands fa-twitter t-md"></i></div>
<div data-id="fb" class="circle-button circle-sm circle-hb text-center bg-primary text-light"><i
<div data-id="fb" class="share-to circle-button circle-sm circle-hb text-center bg-primary text-light"><i
class="fa-brands fa-facebook t-md"></i></div>
<div class="circle-button circle-sm circle-hb text-center bg-secondary text-light copy-opt" data-cp-val="<?php echo get_permalink() ?>" data-cp-title="文章链接"><i class="fa fa-copy t-md"></i></div>
</div>
</div>
</div>
Expand Down

0 comments on commit 98ef164

Please sign in to comment.