mesnie-avatar-form
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

AvatarForm

pipeline status coverage report

AvatarForm is a small react package to render a svg avatar and the form to generate it from a customizable dataset.

Installation

yarn add mesnie-avatar-form

AvatarForm usage

import {AvatarForm, defaultData} from "mesnie-avatar-form";

<AvatarForm data={defaultData} />

form example

see AvatarForm/ for implementation details.

FormattedAvatar usage

import {FormattedAvatar, defaultData} from "mesnie-avatar-form";

<FormattedAvatar
    data={defaultData}
    skinColor={"#FF9F9F"}
    hairColor={"#241c11"}
    eyesColor={"#634e34"}
    backgroundColor={"#ecf0f1"}
    hairCutId={"A"}
    beardCutId={"Z"}
    mustacheCutId={"Z"}
    mouthShapeId={"A"}
    noseShapeId={"A"}
    eyesShapeId={"A"}
    browsShapeId={"A"}
    earsShapeId={"A"}
    faceShapeId={"A"}
    bodyShapeId={"A"}
    clothesId={"A"}
/>

avatar example

see FormattedAvatar/ for implementation details.

Contributing

To contribute, you should first fork the project and then

yarn build
yarn start

The AvatarForm will then be displayed on localhost:3000. Next you can add your modifications and test them with yarn test.

License

MIT

Readme

Keywords

Package Sidebar

Install

npm i mesnie-avatar-form

Weekly Downloads

0

Version

1.0.0

License

MIT

Unpacked Size

245 kB

Total Files

540

Last publish

Collaborators

  • mbuliard