@zonos/amino 5.1.23 → 5.1.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -15,6 +15,7 @@ export type AvatarProps = {
15
15
  size?: ImageSize;
16
16
  };
17
17
  type AvartarBaseProps = Required<AvatarProps> & {
18
+ backgroundColor?: string;
18
19
  backgroundPosition?: string;
19
20
  backgroundSize?: string;
20
21
  backgroundUrl?: string;
@@ -1 +1 @@
1
- "use strict";var e=require("../../_tslib-ccfac372.js"),n=require("react/jsx-runtime"),r=require("styled-components"),t=require("../../styles/constants/theme.js");function a(e){return e&&e.__esModule?e:{default:e}}var o,i,s,d,c,u=a(r),b={round:"50%",rounded:"10px",square:"0px"},l=u.default.div(i||(i=e.__makeTemplateObject(["\n display: flex;\n justify-content: center;\n align-items: center;\n background-color: ",";\n border: ",";\n\n ","\n"],["\n display: flex;\n justify-content: center;\n align-items: center;\n background-color: ",";\n border: ",";\n\n ","\n"])),t.theme.gray100,(function(e){return e.$bordered?"".concat(e.$size/16,"px solid ").concat(t.theme.gray0):void 0}),(function(n){return n.$size&&r.css(o||(o=e.__makeTemplateObject(["\n border-radius: ",";\n height: ","px;\n width: ","px;\n "],["\n border-radius: ",";\n height: ","px;\n width: ","px;\n "])),b[n.$shape],n.$size,n.$size)})),g=u.default.div(c||(c=e.__makeTemplateObject(["\n background-color: ",";\n height: 100%;\n width: 100%;\n\n ","\n\n ","\n"],["\n background-color: ",";\n height: 100%;\n width: 100%;\n\n ","\n\n ","\n"])),t.theme.gray100,(function(n){return r.css(s||(s=e.__makeTemplateObject(["\n border-radius: ",";\n "],["\n border-radius: ",";\n "])),b[n.shape])}),(function(n){return n.backgroundUrl&&r.css(d||(d=e.__makeTemplateObject(["\n background-image: url(",");\n background-position: ",";\n background-repeat: no-repeat;\n background-size: ",";\n "],["\n background-image: url(",");\n background-position: ",";\n background-repeat: no-repeat;\n background-size: ",";\n "])),n.backgroundUrl,n.backgroundPosition||"center",n.backgroundSize)}));exports.AvatarBase=function(r){var t=r.children,a=e.__rest(r,["children"]);return n.jsx(l,{$bordered:a.bordered,$shape:a.shape,$size:a.size,children:t||n.jsx(g,e.__assign({},a))})},exports.avatarShapes=b;
1
+ "use strict";var e=require("../../_tslib-ccfac372.js"),n=require("react/jsx-runtime"),r=require("styled-components"),t=require("../../styles/constants/theme.js");function a(e){return e&&e.__esModule?e:{default:e}}var o,i,s,d,c,u=a(r),b={round:"50%",rounded:"10px",square:"0px"},l=u.default.div(i||(i=e.__makeTemplateObject(["\n display: flex;\n justify-content: center;\n align-items: center;\n border: ",";\n\n ","\n"],["\n display: flex;\n justify-content: center;\n align-items: center;\n border: ",";\n\n ","\n"])),(function(e){return e.$bordered?"".concat(e.$size/16,"px solid ").concat(t.theme.gray0):void 0}),(function(n){return n.$size&&r.css(o||(o=e.__makeTemplateObject(["\n border-radius: ",";\n height: ","px;\n width: ","px;\n "],["\n border-radius: ",";\n height: ","px;\n width: ","px;\n "])),b[n.$shape],n.$size,n.$size)})),p=u.default.div(c||(c=e.__makeTemplateObject(["\n height: 100%;\n width: 100%;\n\n ","\n\n ","\n"],["\n height: 100%;\n width: 100%;\n\n ","\n\n ","\n"])),(function(n){return r.css(s||(s=e.__makeTemplateObject(["\n border-radius: ",";\n "],["\n border-radius: ",";\n "])),b[n.shape])}),(function(n){return n.backgroundUrl&&r.css(d||(d=e.__makeTemplateObject(["\n background-image: url(",");\n background-position: ",";\n background-repeat: no-repeat;\n background-size: ",";\n background-color: ",";\n "],["\n background-image: url(",");\n background-position: ",";\n background-repeat: no-repeat;\n background-size: ",";\n background-color: ",";\n "])),n.backgroundUrl,n.backgroundPosition||"center",n.backgroundSize,n.backgroundColor||"".concat(t.theme.gray100))}));exports.AvatarBase=function(r){var t=r.children,a=e.__rest(r,["children"]);return n.jsx(l,{$bordered:a.bordered,$shape:a.shape,$size:a.size,children:t||n.jsx(p,e.__assign({},a))})},exports.avatarShapes=b;
@@ -1 +1 @@
1
- "use strict";var e=require("react/jsx-runtime"),r=require("./AvatarBase.js");require("../../_tslib-ccfac372.js"),require("styled-components"),require("../../styles/constants/theme.js");exports.ImageAvatar=function(s){var a=s.bordered,t=void 0!==a&&a,i=s.imageUrl,o=s.shape,n=void 0===o?"round":o,u=s.size,d=void 0===u?32:u;return e.jsx(r.AvatarBase,{backgroundSize:"contain",backgroundUrl:i,bordered:t,shape:n,size:d})};
1
+ "use strict";var e=require("react/jsx-runtime"),r=require("./AvatarBase.js");require("../../_tslib-ccfac372.js"),require("styled-components"),require("../../styles/constants/theme.js");exports.ImageAvatar=function(a){var s=a.bordered,t=void 0!==s&&s,i=a.imageUrl,o=a.shape,n=void 0===o?"round":o,u=a.size,d=void 0===u?32:u;return e.jsx(r.AvatarBase,{backgroundColor:"transparent",backgroundSize:"contain",backgroundUrl:i,bordered:t,shape:n,size:d})};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zonos/amino",
3
- "version": "5.1.23",
3
+ "version": "5.1.24",
4
4
  "description": "Core UI components for Amino",
5
5
  "repository": "git@github.com:Zonos/amino.git",
6
6
  "license": "MIT",