EVM
Components
ProfileButton

ProfileButton

The <ProfileButton /> component provides a custom Rainbowkit button to connect wallet and edit de[id].

⚠️

If your application contains sign in options that are not purely wallet-based, it is advised to render DeIdAvatar instead when the user is signed-in.

Usage

import { useDeId, useDeIdModal } from "@dustlabs/profiles/core";
import { ProfileButton } from "@dustlabs/profiles/evm";
 
function App() {
  const deId = useDeId();
  const deIdModal = useDeIdModal();
 
  return <ProfileButton deId={deId} deIdModal={deIdModal} />
}

Props

import { ProfileButtonProps } from "@dustlabs/profiles/evm";

deId

DeIdContext

The application's de[id] context. Retrieved from useDeId.

For more information on why this is needed, check out the contribution guidelines.

deIdModal

DeIdModalContext

The application's de[id] modal context. Retrieved from useDeIdModal.

For more information on why this is needed, check out the contribution guidelines.

options (optional)

ProfileButtonOptions

This parameter is an extended interface of DeIdAvatarOptions. It contains the following additional options:

label (optional)

string

The placeholder text on the button when in the disconnected state.