avatar-chip
Advanced tools
Comparing version 1.0.15 to 1.0.16
{ | ||
"name": "avatar-chip", | ||
"version": "1.0.15", | ||
"version": "1.0.16", | ||
"description": "", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
React avatar-chip based on "material-ui Chip" component and "muliti-avatar" | ||
![aCapture](https://user-images.githubusercontent.com/106660/132795601-b5862112-d3fb-43b6-a6fe-e28e78eb867c.JPG) | ||
------------------------------------ | ||
import dependencies | ||
@@ -8,14 +13,12 @@ import { Typography, Button, ButtonGroup, Container, Paper, Box, Avatar, Grid } from "@material-ui/core"; | ||
//default avatar is based on personName, if "src" is not provided | ||
//default label is based on personName, if "label" is not provided | ||
default avatar is based on personName, if "src" is not provided | ||
default label is based on personName, if "label" is not provided | ||
<AvatarChip | ||
size={["4rem", "3rem", "2rem", "1.5rem"]} | ||
personName={"bob"} | ||
//onClick={function () { alert("hello bob") }} | ||
//avatarProps={{ onClick: function (e) { e.stopPropagation(); alert("hi") } }} | ||
//src="https://picsum.photos/200/300" | ||
//label={<>theLabel</>} | ||
/> | ||
/> | ||
//just avatar, no label | ||
just avatar, no label | ||
<AvatarChip | ||
@@ -26,9 +29,10 @@ size={["4rem", "3rem", "2rem", "1.5rem"]} | ||
avatarProps={{ onClick: function (e) { e.stopPropagation(); alert("hi") } }} | ||
//src="https://picsum.photos/200/300" | ||
src="https://picsum.photos/200/300" | ||
label={<></>} | ||
/> | ||
/> | ||
Avatar with hover tip | ||
<AvatarChip | ||
<AvatarChip | ||
size={["4rem", "3rem", "2rem", "1.5rem"]} personName={"毛fdsdsdsdsdsd帅"} | ||
@@ -66,13 +70,14 @@ style={{backgroundColor:"skyblue",color:"blue"}} | ||
Demo https://vibrant-liskov-396f96.netlify.app/ | ||
### [Demo](https://vibrant-liskov-396f96.netlify.app/) | ||
https://vibrant-liskov-396f96.netlify.app/ | ||
https://github.com/cr7cr8/avatar-chip.git | ||
GitHub https://github.com/cr7cr8/avatar-chip.git | ||
git push -f origin master | ||
npm version patch | ||
npm publish | ||
npm publish |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
80
29189