Skip to content

Conversation

@wobsoriano
Copy link
Member

@wobsoriano wobsoriano commented Dec 3, 2024

Description

This PR adds support for custom pages to the <UserProfile /> and <OrganizationProfile /> components of the Vue SDK.

Example usage:

<script setup>
import { UserProfile } from '@clerk/vue' 
</script>

<UserProfile path="/user-profile" routing="path">
  <UserProfile.Page label="Custom Page" url="custom-page">
    <template #labelIcon>
      <div>Icon</div>
    </template>
    <div>
        <h1>Custom Terms Page</h1>
        <p>This is the custom terms page</p>
    </div>
  </UserProfile.Page>
  <UserProfile.Link label="Homepage" url="/">
    <template #labelIcon>
      <div>Icon</div>
    </template>
  </UserProfile.Link>
</UserProfile>

Also, unlike the React counterpart where we loop over the children prop to check for custom pages, this one uses Vue's provide/inject and slots to determine the custom pages.

Just patching for now until we do a GA release

Resolves ECO-261

Checklist

  • pnpm test runs as expected.
  • pnpm build runs as expected.
  • (If applicable) JSDoc comments have been added or updated for any package exports
  • (If applicable) Documentation has been updated

Type of change

  • 🐛 Bug fix
  • 🌟 New feature
  • 🔨 Breaking change
  • 📖 Refactoring / dependency upgrade / documentation
  • other:

@vercel
Copy link

vercel bot commented Dec 3, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
clerk-js-sandbox ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 4, 2024 7:22pm

@changeset-bot
Copy link

changeset-bot bot commented Dec 3, 2024

🦋 Changeset detected

Latest commit: d635558

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 2 packages
Name Type
@clerk/vue Patch
@clerk/nuxt Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@wobsoriano wobsoriano marked this pull request as ready for review December 4, 2024 19:21
@wobsoriano wobsoriano merged commit bca0e77 into main Dec 4, 2024
27 checks passed
@wobsoriano wobsoriano deleted the rob/eco-261-custom-pages-for-userprofile-and-organizationprofile branch December 4, 2024 21:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants