@selfcommunity/react-ui
Version:
React UI Components to integrate a Community created with SelfCommunity Platform.
74 lines (65 loc) • 2.29 kB
TypeScript
import { PublicInfoProps } from './Section/PublicInfo';
import { AccountProps } from './Section/Account';
import { SCUserProfileFields, SCUserProfileSettings } from '../../types';
export interface UserProfileEditProps {
/**
* Id of user object
* @default null
*/
id?: string | number;
/**
* Overrides or extends the styles applied to the component.
* @default null
*/
className?: string;
/**
* User fields to display in the profile
* @default [real_name, date_joined, date_of_birth, website, description, bio]
*/
fields?: SCUserProfileFields[];
/**
* Settings to display in the profile
* @default [notification, interaction, private_message]
*/
settings?: SCUserProfileSettings[];
/**
* Props to apply to PublicInfo section
* @default {}
*/
UserProfileEditSectionPublicInfoProps?: Omit<PublicInfoProps, 'fields'>;
/**
* Props to apply to Settings section
* @default {}
*/
UserProfileEditSectionSettingsProps?: Omit<PublicInfoProps, 'settings'>;
/**
* Props to apply to Account section
* @default {}
*/
UserProfileEditSectionAccountProps?: AccountProps;
/**
* Any other properties
*/
[p: string]: any;
}
/**
* > API documentation for the Community-JS User Profile Edit component. Learn about the available props and the CSS API.
*
*
* This component renders a section composed of different tabs where the user can edit the settings about its public information, account and notifications.
* Take a look at our <strong>demo</strong> component [here](/docs/sdk/community-js/react-ui/Components/UserProfileEdit)
#### Import
```jsx
import {UserProfileEdit} from '@selfcommunity/react-ui';
```
#### Component Name
The name `SCUserProfileEdit` can be used when providing style overrides in the theme.
#### CSS
|Rule Name|Global class|Description|
|---|---|---|
|root|.SCUserProfileEdit-root|Styles applied to the root element.|
|tabs|.SCUserProfileEdit-tabs|Styles applied to the tab elements.|
|tabsContent|.SCUserProfileEdit-tabs-content|Styles applied to tab content elements.|
* @param inProps
*/
export default function UserProfileEdit(inProps: UserProfileEditProps): JSX.Element;