vdux-avatar
Circular avatar component
Last updated 5 years ago by ashaffer88 .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install vdux-avatar 
SYNC missed versions from official npm registry.

avatar

js-standard-style

Circular avatar component

Installation

$ npm install vdux-avatar

Usage

Use it to render avatars.

<Avatar src='/images/cat.jpg' />

API - props

  • src - URL of the image
  • circle - Defaults to true. Makes it a circle.
  • size - Defaults to 32. Sets width/height simultaneously.

Theming

Avatar makes use of two themable properties, configurable in the context key baseTheme of vdux-base:

  • circularAvatars - Boolean. Defaults to true. If you set it to false, your avatars will default to being square.
  • avatarScale - Array of sizes. If you use this, you can set a scale for your avatars that your size prop may index into.

License

MIT

Current Tags

  • 1.0.4                                ...           latest (5 years ago)

5 Versions

  • 1.0.4                                ...           5 years ago
  • 1.0.3                                ...           5 years ago
  • 1.0.2                                ...           5 years ago
  • 1.0.1                                ...           5 years ago
  • 1.0.0                                ...           5 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 1
Dependencies (4)
Dev Dependencies (11)
Dependents (2)

Copyright 2014 - 2017 © taobao.org |