mirror of
https://github.com/pixelfed/pixelfed.git
synced 2025-03-17 09:16:17 +00:00
Merge pull request #2347 from pixelfed/staging
Update private profiles, add context menu to mute, block or report
This commit is contained in:
commit
6f3f4e9dbb
9 changed files with 88 additions and 12 deletions
|
@ -72,6 +72,9 @@
|
||||||
- Updated comments, fix remote reply bug. ([f330616](https://github.com/pixelfed/pixelfed/commit/f330616))
|
- Updated comments, fix remote reply bug. ([f330616](https://github.com/pixelfed/pixelfed/commit/f330616))
|
||||||
- Updated PostComponent, add tagged people to mobile layout. ([7a2c2e78](https://github.com/pixelfed/pixelfed/commit/7a2c2e78))
|
- Updated PostComponent, add tagged people to mobile layout. ([7a2c2e78](https://github.com/pixelfed/pixelfed/commit/7a2c2e78))
|
||||||
- Updated Tag People, allow untagging yourself. ([c9452639](https://github.com/pixelfed/pixelfed/commit/c9452639))
|
- Updated Tag People, allow untagging yourself. ([c9452639](https://github.com/pixelfed/pixelfed/commit/c9452639))
|
||||||
|
- Updated ComposeModal.vue, add 451 http code warning. ([b213dcda](https://github.com/pixelfed/pixelfed/commit/b213dcda))
|
||||||
|
- Updated Profile.vue, add empty follower modal placeholder. ([b542a3c5](https://github.com/pixelfed/pixelfed/commit/b542a3c5))
|
||||||
|
- Updated private profiles, add context menu to mute, block or report. ([487c4ffc](https://github.com/pixelfed/pixelfed/commit/487c4ffc))
|
||||||
|
|
||||||
## [v0.10.9 (2020-04-17)](https://github.com/pixelfed/pixelfed/compare/v0.10.8...v0.10.9)
|
## [v0.10.9 (2020-04-17)](https://github.com/pixelfed/pixelfed/compare/v0.10.8...v0.10.9)
|
||||||
### Added
|
### Added
|
||||||
|
|
2
public/js/app.js
vendored
2
public/js/app.js
vendored
File diff suppressed because one or more lines are too long
2
public/js/compose.js
vendored
2
public/js/compose.js
vendored
File diff suppressed because one or more lines are too long
2
public/js/profile.js
vendored
2
public/js/profile.js
vendored
File diff suppressed because one or more lines are too long
|
@ -3,7 +3,7 @@
|
||||||
"/js/vendor.js": "/js/vendor.js?id=cfad22cce459d8852936",
|
"/js/vendor.js": "/js/vendor.js?id=cfad22cce459d8852936",
|
||||||
"/js/ace.js": "/js/ace.js?id=11e5550a450fece75c33",
|
"/js/ace.js": "/js/ace.js?id=11e5550a450fece75c33",
|
||||||
"/js/activity.js": "/js/activity.js?id=69fa5dc5355caa260a13",
|
"/js/activity.js": "/js/activity.js?id=69fa5dc5355caa260a13",
|
||||||
"/js/app.js": "/js/app.js?id=079456a2de46c4046c3b",
|
"/js/app.js": "/js/app.js?id=d1274e1bbd0cccd6089f",
|
||||||
"/css/app.css": "/css/app.css?id=984ae713647093adf63d",
|
"/css/app.css": "/css/app.css?id=984ae713647093adf63d",
|
||||||
"/css/appdark.css": "/css/appdark.css?id=464f0e4eef985b4bbf87",
|
"/css/appdark.css": "/css/appdark.css?id=464f0e4eef985b4bbf87",
|
||||||
"/css/landing.css": "/css/landing.css?id=e8239ddec8e3731cb474",
|
"/css/landing.css": "/css/landing.css?id=e8239ddec8e3731cb474",
|
||||||
|
@ -11,14 +11,14 @@
|
||||||
"/js/collectioncompose.js": "/js/collectioncompose.js?id=3fd79944492361ec7347",
|
"/js/collectioncompose.js": "/js/collectioncompose.js?id=3fd79944492361ec7347",
|
||||||
"/js/collections.js": "/js/collections.js?id=38be4150f3d2ebb15f50",
|
"/js/collections.js": "/js/collections.js?id=38be4150f3d2ebb15f50",
|
||||||
"/js/components.js": "/js/components.js?id=6fa3a327040cce89d04f",
|
"/js/components.js": "/js/components.js?id=6fa3a327040cce89d04f",
|
||||||
"/js/compose.js": "/js/compose.js?id=5c64faeceb9f7e5032c3",
|
"/js/compose.js": "/js/compose.js?id=b1d8d2cd9ede424f210b",
|
||||||
"/js/compose-classic.js": "/js/compose-classic.js?id=283f19c895f4118a2a8b",
|
"/js/compose-classic.js": "/js/compose-classic.js?id=283f19c895f4118a2a8b",
|
||||||
"/js/developers.js": "/js/developers.js?id=f75deca5ccf47d43eb07",
|
"/js/developers.js": "/js/developers.js?id=f75deca5ccf47d43eb07",
|
||||||
"/js/discover.js": "/js/discover.js?id=ea7279e1612a1989941d",
|
"/js/discover.js": "/js/discover.js?id=ea7279e1612a1989941d",
|
||||||
"/js/hashtag.js": "/js/hashtag.js?id=e6b41cab117cb03c7d2a",
|
"/js/hashtag.js": "/js/hashtag.js?id=e6b41cab117cb03c7d2a",
|
||||||
"/js/loops.js": "/js/loops.js?id=ac610897b12207c829b9",
|
"/js/loops.js": "/js/loops.js?id=ac610897b12207c829b9",
|
||||||
"/js/mode-dot.js": "/js/mode-dot.js?id=1225a9aac7a93d5d232f",
|
"/js/mode-dot.js": "/js/mode-dot.js?id=1225a9aac7a93d5d232f",
|
||||||
"/js/profile.js": "/js/profile.js?id=570db2b9099023739ad2",
|
"/js/profile.js": "/js/profile.js?id=985bcccda666453c4e7c",
|
||||||
"/js/profile-directory.js": "/js/profile-directory.js?id=611af669221ad8be3068",
|
"/js/profile-directory.js": "/js/profile-directory.js?id=611af669221ad8be3068",
|
||||||
"/js/quill.js": "/js/quill.js?id=00f2dca2463b3c9d3920",
|
"/js/quill.js": "/js/quill.js?id=00f2dca2463b3c9d3920",
|
||||||
"/js/rempos.js": "/js/rempos.js?id=b0e81561d85612cf9aab",
|
"/js/rempos.js": "/js/rempos.js?id=b0e81561d85612cf9aab",
|
||||||
|
|
6
resources/assets/js/app.js
vendored
6
resources/assets/js/app.js
vendored
|
@ -153,6 +153,10 @@ window.App.util = {
|
||||||
let u = url + '/embed';
|
let u = url + '/embed';
|
||||||
return '<iframe src="'+u+'" class="pixelfed__embed" style="max-width: 100%; border: 0" width="400" allowfullscreen="allowfullscreen"></iframe><script async defer src="'+window.location.origin +'/embed.js"><\/script>';
|
return '<iframe src="'+u+'" class="pixelfed__embed" style="max-width: 100%; border: 0" width="400" allowfullscreen="allowfullscreen"></iframe><script async defer src="'+window.location.origin +'/embed.js"><\/script>';
|
||||||
})
|
})
|
||||||
}
|
},
|
||||||
|
|
||||||
|
clipboard: (function(data) {
|
||||||
|
return navigator.clipboard.writeText(data);
|
||||||
|
})
|
||||||
|
|
||||||
};
|
};
|
|
@ -700,10 +700,21 @@ export default {
|
||||||
self.page = 2;
|
self.page = 2;
|
||||||
}, 300);
|
}, 300);
|
||||||
}).catch(function(e) {
|
}).catch(function(e) {
|
||||||
|
switch(e.response.status) {
|
||||||
|
case 451:
|
||||||
|
self.uploading = false;
|
||||||
|
io.value = null;
|
||||||
|
swal('Banned Content', 'This content has been banned and cannot be uploaded.', 'error');
|
||||||
|
self.page = 2;
|
||||||
|
break;
|
||||||
|
|
||||||
|
default:
|
||||||
self.uploading = false;
|
self.uploading = false;
|
||||||
io.value = null;
|
io.value = null;
|
||||||
swal('Oops, something went wrong!', 'An unexpected error occurred.', 'error');
|
swal('Oops, something went wrong!', 'An unexpected error occurred.', 'error');
|
||||||
self.page = 2;
|
self.page = 2;
|
||||||
|
break;
|
||||||
|
}
|
||||||
});
|
});
|
||||||
io.value = null;
|
io.value = null;
|
||||||
self.uploadProgress = 0;
|
self.uploadProgress = 0;
|
||||||
|
|
|
@ -434,6 +434,10 @@
|
||||||
dialog-class="follow-modal"
|
dialog-class="follow-modal"
|
||||||
>
|
>
|
||||||
<div class="list-group">
|
<div class="list-group">
|
||||||
|
<div v-if="followers.length == 0" class="list-group-item border-0">
|
||||||
|
<p class="text-center mb-0 font-weight-bold text-muted py-5">
|
||||||
|
<span class="text-dark">{{profileUsername}}</span> has no followers yet</p>
|
||||||
|
</div>
|
||||||
<div class="list-group-item border-0 py-1" v-for="(user, index) in followers" :key="'follower_'+index">
|
<div class="list-group-item border-0 py-1" v-for="(user, index) in followers" :key="'follower_'+index">
|
||||||
<div class="media mb-0">
|
<div class="media mb-0">
|
||||||
<a :href="user.url">
|
<a :href="user.url">
|
||||||
|
@ -452,7 +456,7 @@
|
||||||
<!-- <button class="btn btn-primary font-weight-bold btn-sm py-1">FOLLOW</button> -->
|
<!-- <button class="btn btn-primary font-weight-bold btn-sm py-1">FOLLOW</button> -->
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div v-if="followerMore" class="list-group-item text-center" v-on:click="followersLoadMore()">
|
<div v-if="followers.length && followerMore" class="list-group-item text-center" v-on:click="followersLoadMore()">
|
||||||
<p class="mb-0 small text-muted font-weight-light cursor-pointer">Load more</p>
|
<p class="mb-0 small text-muted font-weight-light cursor-pointer">Load more</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -31,6 +31,34 @@
|
||||||
</form>
|
</form>
|
||||||
</span>
|
</span>
|
||||||
@endif
|
@endif
|
||||||
|
<span class="pl-4">
|
||||||
|
<i class="fas fa-cog fa-lg text-muted cursor-pointer" data-toggle="modal" data-target="#ctxProfileMenu"></i>
|
||||||
|
<div class="modal" tabindex="-1" role="dialog" id="ctxProfileMenu">
|
||||||
|
<div class="modal-dialog modal-dialog-centered modal-sm">
|
||||||
|
<div class="modal-content">
|
||||||
|
<div class="modal-body p-0">
|
||||||
|
<div class="list-group-item cursor-pointer text-center rounded text-dark" onclick="window.App.util.clipboard('{{$user->url()}}');$('#ctxProfileMenu').modal('hide')">
|
||||||
|
Copy Link
|
||||||
|
</div>
|
||||||
|
@auth
|
||||||
|
<div class="list-group-item cursor-pointer text-center rounded text-dark" onclick="muteProfile()">
|
||||||
|
Mute
|
||||||
|
</div>
|
||||||
|
<a class="list-group-item cursor-pointer text-center rounded text-dark text-decoration-none" href="i/report?type=user&id={{$user->id}}">
|
||||||
|
Report User
|
||||||
|
</a>
|
||||||
|
<div class="list-group-item cursor-pointer text-center rounded text-dark" onclick="blockProfile()">
|
||||||
|
Block
|
||||||
|
</div>
|
||||||
|
@endauth
|
||||||
|
<div class="list-group-item cursor-pointer text-center rounded text-muted" onclick="$('#ctxProfileMenu').modal('hide')">
|
||||||
|
Close
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="profile-stats pb-3 d-inline-flex lead">
|
<div class="profile-stats pb-3 d-inline-flex lead">
|
||||||
<div class="font-weight-light pr-5">
|
<div class="font-weight-light pr-5">
|
||||||
|
@ -51,3 +79,29 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
@push('scripts')
|
||||||
|
<script type="text/javascript">
|
||||||
|
function muteProfile() {
|
||||||
|
axios.post('/i/mute', {
|
||||||
|
type: 'user',
|
||||||
|
item: '{{$user->id}}'
|
||||||
|
}).then(res => {
|
||||||
|
$('#ctxProfileMenu').modal('hide');
|
||||||
|
$('#ctxProfileMenu').hide();
|
||||||
|
swal('Muted Profile', 'You have successfully muted this profile.', 'success');
|
||||||
|
});
|
||||||
|
}
|
||||||
|
function blockProfile() {
|
||||||
|
axios.post('/i/block', {
|
||||||
|
type: 'user',
|
||||||
|
item: '{{$user->id}}'
|
||||||
|
}).then(res => {
|
||||||
|
$('#ctxProfileMenu').modal('hide');
|
||||||
|
$('#ctxProfileMenu').hide();
|
||||||
|
swal('Blocked Profile', 'You have successfully blocked this profile.', 'success');
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
</script>
|
||||||
|
@endpush
|
Loading…
Add table
Reference in a new issue