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

This commit is contained in:
marcin mikołajczak
2022-12-31 19:52:03 +01:00
38 changed files with 636 additions and 7719 deletions

View File

@ -64,6 +64,12 @@ export const GLITCH = 'glitch';
*/
export const AKKOMA = 'akkoma';
/**
* Takahē, backend with support for serving multiple domains.
* @see {@link https://jointakahe.org/}
*/
export const TAKAHE = 'Takahe';
/** Parse features for the given instance */
const getInstanceFeatures = (instance: Instance) => {
const v = parseVersion(instance.version);
@ -288,6 +294,7 @@ const getInstanceFeatures = (instance: Instance) => {
v.software === MASTODON && gte(v.compatVersion, '2.6.0'),
v.software === PLEROMA && gte(v.version, '0.9.9'),
v.software === PIXELFED,
v.software === TAKAHE,
]),
/**
@ -299,6 +306,14 @@ const getInstanceFeatures = (instance: Instance) => {
v.software === PLEROMA && gte(v.version, '0.9.9'),
]),
editProfile: any([
v.software === MASTODON,
v.software === MITRA,
v.software === PIXELFED,
v.software === PLEROMA,
v.software === TRUTHSOCIAL,
]),
editStatuses: any([
v.software === MASTODON && gte(v.version, '3.5.0'),
features.includes('editing'),
@ -574,6 +589,7 @@ const getInstanceFeatures = (instance: Instance) => {
publicTimeline: any([
v.software === MASTODON,
v.software === PLEROMA,
v.software === TAKAHE,
]),
/**

View File

@ -1,4 +1,4 @@
export const minimumAspectRatio = 1; // Square
export const minimumAspectRatio = 9 / 16; // Portrait phone
export const maximumAspectRatio = 10; // Generous min-height
export const isPanoramic = (ar: number) => {