Merge remote-tracking branch 'soapbox/develop' into lexical

This commit is contained in:
marcin mikołajczak
2023-07-30 20:39:21 +02:00
45 changed files with 409 additions and 309 deletions

View File

@ -17,10 +17,10 @@ const overrides = custom('features');
const any = (arr: Array<any>): boolean => arr.some(Boolean);
/**
* Calckey, a fork of Misskey.
* @see {@link https://calckey.org/}
* Firefish, a fork of Misskey. Formerly known as Calckey.
* @see {@link https://joinfirefish.org/}
*/
export const CALCKEY = 'Calckey';
export const FIREFISH = 'Firefish';
/**
* Ditto, a Nostr server with Mastodon API.
@ -145,7 +145,7 @@ const getInstanceFeatures = (instance: Instance) => {
* @see GET /api/v1/accounts/lookup
*/
accountLookup: any([
v.software === CALCKEY,
v.software === FIREFISH,
v.software === MASTODON && gte(v.compatVersion, '3.4.0'),
v.software === PLEROMA && gte(v.version, '2.4.50'),
v.software === TAKAHE && gte(v.version, '0.6.1'),
@ -231,7 +231,7 @@ const getInstanceFeatures = (instance: Instance) => {
* @see GET /api/v1/bookmarks
*/
bookmarks: any([
v.software === CALCKEY,
v.software === FIREFISH,
v.software === FRIENDICA,
v.software === MASTODON && gte(v.compatVersion, '3.1.0'),
v.software === PLEROMA && gte(v.version, '0.9.9'),
@ -332,7 +332,7 @@ const getInstanceFeatures = (instance: Instance) => {
* @see {@link https://docs.joinmastodon.org/methods/conversations/}
*/
conversations: any([
v.software === CALCKEY,
v.software === FIREFISH,
v.software === FRIENDICA,
v.software === MASTODON && gte(v.compatVersion, '2.6.0'),
v.software === PLEROMA && gte(v.version, '0.9.9'),
@ -371,7 +371,7 @@ const getInstanceFeatures = (instance: Instance) => {
* @see PATCH /api/v1/accounts/update_credentials
*/
editProfile: any([
v.software === CALCKEY,
v.software === FIREFISH,
v.software === FRIENDICA,
v.software === MASTODON,
v.software === MITRA,
@ -457,7 +457,7 @@ const getInstanceFeatures = (instance: Instance) => {
/** Whether the accounts who favourited or emoji-reacted to a status can be viewed through the API. */
exposableReactions: any([
v.software === CALCKEY,
v.software === FIREFISH,
v.software === FRIENDICA,
v.software === MASTODON,
v.software === TAKAHE && gte(v.version, '0.6.1'),
@ -637,7 +637,7 @@ const getInstanceFeatures = (instance: Instance) => {
* @see GET /api/v1/timelines/list/:list_id
*/
lists: any([
v.software === CALCKEY,
v.software === FIREFISH,
v.software === FRIENDICA,
v.software === MASTODON && gte(v.compatVersion, '2.1.0'),
v.software === PLEROMA && gte(v.version, '0.9.9'),
@ -750,7 +750,7 @@ const getInstanceFeatures = (instance: Instance) => {
* @see POST /api/v1/statuses
*/
polls: any([
v.software === CALCKEY,
v.software === FIREFISH,
v.software === MASTODON && gte(v.version, '2.8.0'),
v.software === PLEROMA,
v.software === TRUTHSOCIAL,
@ -760,7 +760,7 @@ const getInstanceFeatures = (instance: Instance) => {
* Can set privacy scopes on statuses.
* @see POST /api/v1/statuses
*/
privacyScopes: v.software !== TRUTHSOCIAL,
privacyScopes: ![TRUTHSOCIAL, DITTO].includes(v.software!),
/**
* A directory of discoverable profiles from the instance.
@ -787,7 +787,7 @@ const getInstanceFeatures = (instance: Instance) => {
* @see GET /api/v1/timelines/public
*/
publicTimeline: any([
v.software === CALCKEY,
v.software === FIREFISH,
v.software === FRIENDICA,
v.software === MASTODON,
v.software === PLEROMA,
@ -960,6 +960,7 @@ const getInstanceFeatures = (instance: Instance) => {
v.software === FRIENDICA && gte(v.version, '2022.12.0'),
v.software === MASTODON && gte(v.compatVersion, '3.0.0'),
v.software === TRUTHSOCIAL,
v.software === DITTO,
]),
/**