Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 21 additions & 1 deletion app/pages/pds.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
<script setup lang="ts">
import type { AtprotoProfile } from '#shared/types/atproto'
import { authRedirect } from '~/utils/atproto/helpers'

const route = useRoute()
const { locale } = useI18n()

async function handleCreateAccount() {
await authRedirect('https://npmx.social', {
create: true,
redirectTo: route.fullPath,
locale: locale.value,
})
}

useSeoMeta({
title: () => `${$t('pds.title')} - npmx`,
Expand Down Expand Up @@ -66,7 +78,15 @@ const totalAccounts = computed(() => pdsUsers.value.length)
<p class="text-fg-muted leading-relaxed mb-4">
{{ $t('pds.join.description') }}
</p>
<div class="mt-6">
<div class="mt-6 flex flex-wrap items-center gap-3">
<ButtonBase
type="button"
variant="primary"
classicon="i-lucide:user-plus"
@click="handleCreateAccount"
>
{{ $t('pds.join.create_account') }}
</ButtonBase>
<LinkBase
to="https://pdsmoover.com/moover/npmx.social"
class="gap-2 px-4 py-2 text-sm font-medium rounded-md border border-border hover:border-border-hover bg-bg-muted hover:bg-bg"
Expand Down
1 change: 1 addition & 0 deletions i18n/locales/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -1598,6 +1598,7 @@
"join": {
"title": "Join the Community",
"description": "Whether you are creating your first account on the atmosphere or migrating an existing one, you belong here. You can migrate your current account without losing your handle, your posts, or your followers.",
"create_account": "Create a new account",
"migrate": "Migrate with PDS MOOver"
},
"server": {
Expand Down
3 changes: 3 additions & 0 deletions i18n/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -4798,6 +4798,9 @@
"description": {
"type": "string"
},
"create_account": {
"type": "string"
},
"migrate": {
"type": "string"
}
Expand Down
Loading