mirror of
https://github.com/cheeaun/phanpy.git
synced 2025-03-14 12:18:30 +03:00
Split local-visibility-post
feature into @pleroma
and @akkoma
variants
Co-authored-by: Lim Chee Aun <cheeaun@gmail.com>
This commit is contained in:
parent
1aff56a6bd
commit
33d6edda38
2 changed files with 5 additions and 3 deletions
|
@ -1169,7 +1169,7 @@ function Compose({
|
|||
<option value="public">
|
||||
<Trans>Public</Trans>
|
||||
</option>
|
||||
{supports('@pleroma/local-visibility-post') &&
|
||||
{(supports('@pleroma/local-visibility-post') || supports('@akkoma/local-visibility-post')) &&
|
||||
<option value="local">
|
||||
<Trans>Local</Trans>
|
||||
</option>
|
||||
|
|
|
@ -7,7 +7,8 @@ import { getCurrentInstance } from './store-utils';
|
|||
// Non-semver(?) UA string detection
|
||||
const containPixelfed = /pixelfed/i;
|
||||
const notContainPixelfed = /^(?!.*pixelfed).*$/i;
|
||||
const containAnyOma = /(?:pler|akk)oma/i
|
||||
const containPleroma = /pleroma/i;
|
||||
const containAkkoma = /akkoma/i;
|
||||
const platformFeatures = {
|
||||
'@mastodon/lists': notContainPixelfed,
|
||||
'@mastodon/filters': notContainPixelfed,
|
||||
|
@ -21,7 +22,8 @@ const platformFeatures = {
|
|||
'@pixelfed/trending': containPixelfed,
|
||||
'@pixelfed/home-include-reblogs': containPixelfed,
|
||||
'@pixelfed/global-feed': containPixelfed,
|
||||
'@pleroma/local-visibility-post': containAnyOma,
|
||||
'@pleroma/local-visibility-post': containPleroma,
|
||||
'@akkoma/local-visibility-post': containAkkoma,
|
||||
};
|
||||
const supportsCache = {};
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue