feat(settings): up to 16 fields for glitch edition

This commit is contained in:
三咲智子 2023-01-10 16:33:20 +08:00
parent 88731ee18d
commit 217f1ea567
No known key found for this signature in database
GPG key ID: 69992F2250DFD93E
6 changed files with 61 additions and 47 deletions

View file

@ -0,0 +1 @@
export const maxAccountFieldCount = computed(() => isGlitchEdition.value ? 16 : 4)

View file

@ -55,6 +55,7 @@ export const currentUser = computed<UserLogin | undefined>(() => {
const publicInstance = ref<mastodon.v1.Instance | null>(null)
export const currentInstance = computed<null | mastodon.v1.Instance>(() => currentUser.value ? instances.value[currentUser.value.server] ?? null : publicInstance.value)
export const isGlitchEdition = computed(() => currentInstance.value?.version.includes('+glitch'))
export const publicServer = ref('')
export const currentServer = computed<string>(() => currentUser.value?.server || publicServer.value)