@corva/ui 0.54.0-1 → 0.54.0-3

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.
@@ -2,7 +2,7 @@
2
2
  import PropTypes from 'prop-types';
3
3
  declare type AvatarComponentProps = PropTypes.InferProps<typeof avatarComponentPropTypes>;
4
4
  export declare const AvatarComponent: {
5
- ({ displayName, showTooltip, size, className, imgSrc, alt, classes, }: AvatarComponentProps): JSX.Element;
5
+ ({ displayName, showTooltip, size, className, imgSrc, alt, classes, "data-testid": dataTestId, }: AvatarComponentProps): JSX.Element;
6
6
  propTypes: {
7
7
  displayName: PropTypes.Requireable<string>;
8
8
  showTooltip: PropTypes.Requireable<boolean>;
@@ -10,6 +10,7 @@ export declare const AvatarComponent: {
10
10
  className: PropTypes.Requireable<string>;
11
11
  imgSrc: PropTypes.Requireable<string>;
12
12
  alt: PropTypes.Requireable<string>;
13
+ 'data-testid': PropTypes.Requireable<string>;
13
14
  classes: PropTypes.Validator<NonNullable<PropTypes.InferProps<{
14
15
  avatar: PropTypes.Requireable<string>;
15
16
  }>>>;
@@ -21,6 +22,7 @@ export declare const AvatarComponent: {
21
22
  className: any;
22
23
  imgSrc: any;
23
24
  alt: any;
25
+ 'data-testid': string;
24
26
  };
25
27
  };
26
28
  declare const avatarComponentPropTypes: {
@@ -30,6 +32,7 @@ declare const avatarComponentPropTypes: {
30
32
  className: PropTypes.Requireable<string>;
31
33
  imgSrc: PropTypes.Requireable<string>;
32
34
  alt: PropTypes.Requireable<string>;
35
+ 'data-testid': PropTypes.Requireable<string>;
33
36
  classes: PropTypes.Validator<NonNullable<PropTypes.InferProps<{
34
37
  avatar: PropTypes.Requireable<string>;
35
38
  }>>>;
@@ -41,6 +44,7 @@ declare const _default: import("react").ComponentType<Pick<Pick<Pick<PropTypes.I
41
44
  className: PropTypes.Requireable<string>;
42
45
  imgSrc: PropTypes.Requireable<string>;
43
46
  alt: PropTypes.Requireable<string>;
47
+ 'data-testid': PropTypes.Requireable<string>;
44
48
  classes: PropTypes.Validator<NonNullable<PropTypes.InferProps<{
45
49
  avatar: PropTypes.Requireable<string>;
46
50
  }>>>;
@@ -51,16 +55,18 @@ declare const _default: import("react").ComponentType<Pick<Pick<Pick<PropTypes.I
51
55
  className: PropTypes.Requireable<string>;
52
56
  imgSrc: PropTypes.Requireable<string>;
53
57
  alt: PropTypes.Requireable<string>;
58
+ 'data-testid': PropTypes.Requireable<string>;
54
59
  classes: PropTypes.Validator<NonNullable<PropTypes.InferProps<{
55
60
  avatar: PropTypes.Requireable<string>;
56
61
  }>>>;
57
- }, "size" | "className" | "displayName" | "classes" | "alt" | "imgSrc" | "showTooltip">>>, "size" | "className" | "displayName" | "classes" | "alt" | "imgSrc" | "showTooltip"> & Pick<PropTypes.InferProps<{
62
+ }, "size" | "className" | "data-testid" | "displayName" | "classes" | "alt" | "imgSrc" | "showTooltip">>>, "size" | "className" | "data-testid" | "displayName" | "classes" | "alt" | "imgSrc" | "showTooltip"> & Pick<PropTypes.InferProps<{
58
63
  displayName: PropTypes.Requireable<string>;
59
64
  showTooltip: PropTypes.Requireable<boolean>;
60
65
  size: PropTypes.Requireable<number>;
61
66
  className: PropTypes.Requireable<string>;
62
67
  imgSrc: PropTypes.Requireable<string>;
63
68
  alt: PropTypes.Requireable<string>;
69
+ 'data-testid': PropTypes.Requireable<string>;
64
70
  classes: PropTypes.Validator<NonNullable<PropTypes.InferProps<{
65
71
  avatar: PropTypes.Requireable<string>;
66
72
  }>>>;
@@ -71,6 +77,7 @@ declare const _default: import("react").ComponentType<Pick<Pick<Pick<PropTypes.I
71
77
  className: PropTypes.Requireable<string>;
72
78
  imgSrc: PropTypes.Requireable<string>;
73
79
  alt: PropTypes.Requireable<string>;
80
+ 'data-testid': PropTypes.Requireable<string>;
74
81
  classes: PropTypes.Validator<NonNullable<PropTypes.InferProps<{
75
82
  avatar: PropTypes.Requireable<string>;
76
83
  }>>>;
@@ -81,16 +88,18 @@ declare const _default: import("react").ComponentType<Pick<Pick<Pick<PropTypes.I
81
88
  className: PropTypes.Requireable<string>;
82
89
  imgSrc: PropTypes.Requireable<string>;
83
90
  alt: PropTypes.Requireable<string>;
91
+ 'data-testid': PropTypes.Requireable<string>;
84
92
  classes: PropTypes.Validator<NonNullable<PropTypes.InferProps<{
85
93
  avatar: PropTypes.Requireable<string>;
86
94
  }>>>;
87
- }, "size" | "className" | "displayName" | "classes" | "alt" | "imgSrc" | "showTooltip">>>, never>, "classes"> & {
95
+ }, "size" | "className" | "data-testid" | "displayName" | "classes" | "alt" | "imgSrc" | "showTooltip">>>, never>, "classes"> & {
88
96
  size?: number;
89
97
  className?: string;
98
+ 'data-testid'?: string;
90
99
  displayName?: string;
91
100
  alt?: string;
92
101
  imgSrc?: string;
93
102
  showTooltip?: boolean;
94
- } & {}, "size" | "className" | "displayName" | "alt" | "imgSrc" | "showTooltip"> & import("@material-ui/core/styles").StyledComponentProps<"avatar">>;
103
+ } & {}, "size" | "className" | "data-testid" | "displayName" | "alt" | "imgSrc" | "showTooltip"> & import("@material-ui/core/styles").StyledComponentProps<"avatar">>;
95
104
  export default _default;
96
105
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Avatar/index.tsx"],"names":[],"mappings":";AAAA,OAAO,SAAS,MAAM,YAAY,CAAC;AA+DnC,aAAK,oBAAoB,GAAG,SAAS,CAAC,UAAU,CAAC,OAAO,wBAAwB,CAAC,CAAC;AAElF,eAAO,MAAM,eAAe;2EAQzB,oBAAoB,GAAG,WAAW;;;;;;;;;;;;;;;;;;;;CAsBpC,CAAC;AAEF,QAAA,MAAM,wBAAwB;;;;;;;;;;CAU7B,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAaF,wBAKqB"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Avatar/index.tsx"],"names":[],"mappings":";AAAA,OAAO,SAAS,MAAM,YAAY,CAAC;AA+DnC,aAAK,oBAAoB,GAAG,SAAS,CAAC,UAAU,CAAC,OAAO,wBAAwB,CAAC,CAAC;AAElF,eAAO,MAAM,eAAe;sGASzB,oBAAoB,GAAG,WAAW;;;;;;;;;;;;;;;;;;;;;;CAsBpC,CAAC;AAEF,QAAA,MAAM,wBAAwB;;;;;;;;;;;CAW7B,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAcF,wBAKqB"}
@@ -1 +1 @@
1
- import{__assign as t}from'./../../ext-esm/tslib/tslib.es6.js';import{jsx as e}from"react/jsx-runtime";import a from"prop-types";import s from"classnames";import{withStyles as r}from"@material-ui/core/styles";import i from"@material-ui/core/Avatar";import{Tooltip as o}from"../Tooltip/Tooltip.js";import l from"../../utils/main.js";import p from"../../config/theme/palette.mjs.js";var n=function(t){switch(t){case 24:return 12;case 32:return 14;case 40:return 16;case 48:return 20;case 128:return 64;case 200:return 80;default:return Math.floor(t/2)}},m=function(t){return{minWidth:t,width:t,height:t,lineHeight:"".concat(t,"px"),fontSize:n(t)}},c=[p.pastel.p1,p.pastel.p2,p.pastel.p3,p.pastel.p4,p.pastel.p5,p.pastel.p6,p.pastel.p7,p.pastel.p8,p.pastel.p9,p.pastel.p10,p.pastel.p11,p.pastel.p12,p.pastel.p13,p.pastel.p14,p.pastel.p15,p.pastel.p16],u=function(t){return c[Math.abs(l.hashCode(t)%c.length)]},d=function(a){var r=a.displayName,p=a.showTooltip,n=a.size,c=a.className,d=a.imgSrc,f=a.alt,h=a.classes;return e(o,t({title:r,disableFocusListener:!p,disableHoverListener:!p,disableTouchListener:!p},{children:e(i,t({"data-testid":"generic_avatar",alt:f,src:d,className:s(h.avatar,c),style:t(t({},m(Number(n))),{backgroundColor:!!r&&u(r)})},{children:r?l.getNameInitials(r):null}))}))},f={displayName:a.string,showTooltip:a.bool,size:a.number,className:a.string,imgSrc:a.string,alt:a.string,classes:a.shape({avatar:a.string}).isRequired};d.propTypes=f,d.defaultProps={displayName:"",showTooltip:!1,size:32,className:void 0,imgSrc:void 0,alt:void 0};var h=r((function(t){return{avatar:{color:t.palette.common.white,fontWeight:"bold"}}}))(d);export{d as AvatarComponent,h as default};
1
+ import{__assign as t}from'./../../ext-esm/tslib/tslib.es6.js';import{jsx as e}from"react/jsx-runtime";import a from"prop-types";import s from"classnames";import{withStyles as r}from"@material-ui/core/styles";import i from"@material-ui/core/Avatar";import{Tooltip as o}from"../Tooltip/Tooltip.js";import l from"../../utils/main.js";import p from"../../config/theme/palette.mjs.js";var n=function(t){switch(t){case 24:return 12;case 32:return 14;case 40:return 16;case 48:return 20;case 128:return 64;case 200:return 80;default:return Math.floor(t/2)}},m=function(t){return{minWidth:t,width:t,height:t,lineHeight:"".concat(t,"px"),fontSize:n(t)}},c=[p.pastel.p1,p.pastel.p2,p.pastel.p3,p.pastel.p4,p.pastel.p5,p.pastel.p6,p.pastel.p7,p.pastel.p8,p.pastel.p9,p.pastel.p10,p.pastel.p11,p.pastel.p12,p.pastel.p13,p.pastel.p14,p.pastel.p15,p.pastel.p16],u=function(t){return c[Math.abs(l.hashCode(t)%c.length)]},d=function(a){var r=a.displayName,p=a.showTooltip,n=a.size,c=a.className,d=a.imgSrc,f=a.alt,h=a.classes,g=a["data-testid"];return e(o,t({title:r,disableFocusListener:!p,disableHoverListener:!p,disableTouchListener:!p},{children:e(i,t({"data-testid":g,alt:f,src:d,className:s(h.avatar,c),style:t(t({},m(Number(n))),{backgroundColor:!!r&&u(r)})},{children:r?l.getNameInitials(r):null}))}))},f={displayName:a.string,showTooltip:a.bool,size:a.number,className:a.string,imgSrc:a.string,alt:a.string,"data-testid":a.string,classes:a.shape({avatar:a.string}).isRequired};d.propTypes=f,d.defaultProps={displayName:"",showTooltip:!1,size:32,className:void 0,imgSrc:void 0,alt:void 0,"data-testid":"generic_avatar"};var h=r((function(t){return{avatar:{color:t.palette.common.white,fontWeight:"bold"}}}))(d);export{d as AvatarComponent,h as default};
@@ -1,3 +1,4 @@
1
+ export declare const MAX_MOBILE_WIDTH = 959;
1
2
  export declare type BadgeIconStatus = 'warning' | 'error' | 'success';
2
3
  export declare type AssetData = {
3
4
  status: BadgeIconStatus;
@@ -1 +1 @@
1
- {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../src/components/StatusBadge/constants.ts"],"names":[],"mappings":"AAIA,oBAAY,eAAe,GAAG,SAAS,GAAG,OAAO,GAAG,SAAS,CAAC;AAE9D,oBAAY,SAAS,GAAG;IACtB,MAAM,EAAE,eAAe,CAAC;IACxB,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,MAAM,CAAC;IACjB,EAAE,EAAE,MAAM,CAAC;CACZ,CAAC;AAEF,aAAK,iBAAiB,GAAG;IACvB,OAAO,EAAE,SAAS,CAAC;IACnB,OAAO,EAAE,SAAS,CAAC;IACnB,KAAK,EAAE,OAAO,CAAC;CAChB,CAAC;AAEF,eAAO,MAAM,mBAAmB,EAAE,iBAIjC,CAAC;AAEF,eAAO,MAAM,WAAW;;;;;CAKvB,CAAC;AAEF,eAAO,MAAM,OAAO,kEAAkE,CAAC;AAEvF,eAAO,MAAM,QAAQ;;;CAGpB,CAAA;AAED,aAAK,YAAY,GAAG;IAAE,KAAK,EAAE,OAAO,CAAC;IAAC,KAAK,EAAE,OAAO,CAAA;CAAE,CAAC;AAEvD,eAAO,MAAM,SAAS,EAAE,YAGvB,CAAC"}
1
+ {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../src/components/StatusBadge/constants.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,gBAAgB,MAAM,CAAC;AAEpC,oBAAY,eAAe,GAAG,SAAS,GAAG,OAAO,GAAG,SAAS,CAAC;AAE9D,oBAAY,SAAS,GAAG;IACtB,MAAM,EAAE,eAAe,CAAC;IACxB,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,MAAM,CAAC;IACjB,EAAE,EAAE,MAAM,CAAC;CACZ,CAAC;AAEF,aAAK,iBAAiB,GAAG;IACvB,OAAO,EAAE,SAAS,CAAC;IACnB,OAAO,EAAE,SAAS,CAAC;IACnB,KAAK,EAAE,OAAO,CAAC;CAChB,CAAC;AAEF,eAAO,MAAM,mBAAmB,EAAE,iBAIjC,CAAC;AAEF,eAAO,MAAM,WAAW;;;;;CAKvB,CAAC;AAEF,eAAO,MAAM,OAAO,kEAAkE,CAAC;AAEvF,eAAO,MAAM,QAAQ;;;CAGpB,CAAA;AAED,aAAK,YAAY,GAAG;IAAE,KAAK,EAAE,OAAO,CAAC;IAAC,KAAK,EAAE,OAAO,CAAA;CAAE,CAAC;AAEvD,eAAO,MAAM,SAAS,EAAE,YAGvB,CAAC"}
@@ -1 +1 @@
1
- import r from"@material-ui/icons/Warning";import{GppGoodIcon as s}from"../Icons/GppGoodIcon.js";import{GppBadIcon as a}from"../Icons/GppBadIcon.js";var n,o,e={success:"success",warning:"warning",error:"error"},i=((n={})[e.success]=s,n[e.warning]=r,n.DQWarning=a,n[e.error]=a,n),c="Recommendations may be incorrect based on data quality errors",m=((o={})[e.success]="Everything is Validated",o[e.warning]=c,o),t={small:"small",large:"large"};export{i as BADGE_ICONS,e as BADGE_ICON_STATUSES,t as ICON_SIZE,m as TOOLTIPS,c as WARNING};
1
+ import r from"@material-ui/icons/Warning";import{GppGoodIcon as s}from"../Icons/GppGoodIcon.js";import{GppBadIcon as a}from"../Icons/GppBadIcon.js";var n,o,e=959,i={success:"success",warning:"warning",error:"error"},c=((n={})[i.success]=s,n[i.warning]=r,n.DQWarning=a,n[i.error]=a,n),m="Recommendations may be incorrect based on data quality errors",t=((o={})[i.success]="Everything is Validated",o[i.warning]=m,o),g={small:"small",large:"large"};export{c as BADGE_ICONS,i as BADGE_ICON_STATUSES,g as ICON_SIZE,e as MAX_MOBILE_WIDTH,t as TOOLTIPS,m as WARNING};
@@ -2,11 +2,11 @@
2
2
  import { BadgeIconStatus, AssetData } from '~/components/StatusBadge/constants';
3
3
  declare type StatusBadgeProps = {
4
4
  assetsData?: AssetData[];
5
+ appWidth: number;
5
6
  iconType?: BadgeIconStatus;
6
- isMobile: boolean;
7
7
  lastTimestamp: number;
8
8
  warningMessage?: string;
9
9
  };
10
- export declare const StatusBadge: ({ assetsData, iconType, isMobile, lastTimestamp, warningMessage, }: StatusBadgeProps) => JSX.Element;
10
+ export declare const StatusBadge: ({ assetsData, appWidth, iconType, lastTimestamp, warningMessage, }: StatusBadgeProps) => JSX.Element;
11
11
  export {};
12
12
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/StatusBadge/index.tsx"],"names":[],"mappings":";AAIA,OAAO,EAKL,eAAe,EACf,SAAS,EACV,MAAM,oCAAoC,CAAC;AA2D5C,aAAK,gBAAgB,GAAG;IACtB,UAAU,CAAC,EAAE,SAAS,EAAE,CAAC;IACzB,QAAQ,CAAC,EAAE,eAAe,CAAC;IAC3B,QAAQ,EAAE,OAAO,CAAC;IAClB,aAAa,EAAE,MAAM,CAAC;IACtB,cAAc,CAAC,EAAE,MAAM,CAAC;CACzB,CAAC;AAEF,eAAO,MAAM,WAAW,uEAMrB,gBAAgB,KAAG,WA6CrB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/StatusBadge/index.tsx"],"names":[],"mappings":";AAIA,OAAO,EAML,eAAe,EACf,SAAS,EACV,MAAM,oCAAoC,CAAC;AA2D5C,aAAK,gBAAgB,GAAG;IACtB,UAAU,CAAC,EAAE,SAAS,EAAE,CAAC;IACzB,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,CAAC,EAAE,eAAe,CAAC;IAC3B,aAAa,EAAE,MAAM,CAAC;IACtB,cAAc,CAAC,EAAE,MAAM,CAAC;CACzB,CAAC;AAEF,eAAO,MAAM,WAAW,uEAMrB,gBAAgB,KAAG,WA8CrB,CAAC"}
@@ -1 +1 @@
1
- import{__assign as e}from'./../../ext-esm/tslib/tslib.es6.js';import{jsx as t,jsxs as n}from"react/jsx-runtime";import a from"moment";import i from"classnames";import{makeStyles as o,Typography as r}from"@material-ui/core";import{Tooltip as s}from"../Tooltip/Tooltip.js";import{TOOLTIPS as p,WARNING as l,ICON_SIZE as c,BADGE_ICON_STATUSES as m}from"./constants.js";import{DQStatusIcon as d}from"./DQStatusIcon.js";import{DQUnvalidatedContent as g}from"./DQUnvalidatedContent.js";var f=o((function(e){return{statusBadgeWrapper:{backgroundColor:e.palette.background.b4,display:"flex",height:30},statusBadgeContent:{display:"flex",flexDirection:function(e){return e.isWarningTypeIcon?"row-reverse":"initial"},justifyContent:function(e){return e.isWarningTypeIcon&&"flex-end"},padding:"12px 0 2px 2px",whiteSpace:"nowrap",width:"calc(100% - 140px)"},text:{fontSize:"10px",lineHeight:"12px",alignSelf:"center"},timestamp:{color:e.palette.primary.text6,marginLeft:function(e){var t=e.isWarningTypeIcon,n=e.isIconType;return!t&&n&&8}},warningMessage:{color:e.palette.primary.text1,marginLeft:4,textOverflow:"ellipsis",overflow:"hidden",fontSize:"12px"},badgeIconWarning:{marginLeft:8},popper:function(t){return{"& .MuiTooltip-tooltip":{maxWidth:455,width:t.isScrollable?455:439,padding:4,fontSize:12,boxShadow:"0px 0px 4px 2px rgb(0 0 0 / 12%)",fontWeight:400,lineHeight:"16px",letterSpacing:"0.4px",backgroundColor:e.palette.background.b9}}}}})),u=function(o){var u,x=o.assetsData,h=void 0===x?[]:x,b=o.iconType,y=o.isMobile,v=o.lastTimestamp,w=o.warningMessage,T=b==m.warning,S=b==m.error,W=f({isWarningTypeIcon:T,isIconType:!!b,isScrollable:(null==h?void 0:h.length)>5}),I=p[b];return T&&w&&(I="".concat(p[b],". ").concat(w)),S&&(I=t(g,{assetsData:h})),t("div",e({className:W.statusBadgeWrapper},{children:n("div",e({className:W.statusBadgeContent},{children:[T&&!y&&t(r,e({className:i(W.text,W.warningMessage),variant:"body1"},{children:w?"".concat(l,". ").concat(w):l})),b&&t(s,e({PopperProps:S&&{className:W.popper},placement:"top",title:I},{children:t("div",{children:t(d,{className:i((u={},u[W.badgeIconWarning]=T,u)),color:b,iconType:b,size:c.small})})})),n(r,e({className:i(W.text,W.timestamp),variant:"body1"},{children:["Last Update: ",a.unix(v).format("M/D/YYYY h:mm a")]}))]}))}))};export{u as StatusBadge};
1
+ import{__assign as t}from'./../../ext-esm/tslib/tslib.es6.js';import{jsx as e,jsxs as n}from"react/jsx-runtime";import a from"moment";import i from"classnames";import{makeStyles as o,Typography as r}from"@material-ui/core";import{Tooltip as p}from"../Tooltip/Tooltip.js";import{TOOLTIPS as s,WARNING as l,ICON_SIZE as c,BADGE_ICON_STATUSES as m,MAX_MOBILE_WIDTH as d}from"./constants.js";import{DQStatusIcon as g}from"./DQStatusIcon.js";import{DQUnvalidatedContent as f}from"./DQUnvalidatedContent.js";var u=o((function(t){return{statusBadgeWrapper:{backgroundColor:t.palette.background.b4,display:"flex",height:30},statusBadgeContent:{display:"flex",flexDirection:function(t){return t.isWarningTypeIcon?"row-reverse":"initial"},justifyContent:function(t){return t.isWarningTypeIcon&&"flex-end"},padding:"12px 0 2px 2px",whiteSpace:"nowrap",width:"calc(100% - 140px)"},text:{fontSize:"10px",lineHeight:"12px",alignSelf:"center"},timestamp:{color:t.palette.primary.text6,marginLeft:function(t){var e=t.isWarningTypeIcon,n=t.isIconType;return!e&&n&&8}},warningMessage:{color:t.palette.primary.text1,marginLeft:4,textOverflow:"ellipsis",overflow:"hidden",fontSize:"12px"},badgeIconWarning:{marginLeft:8},popper:function(e){return{"& .MuiTooltip-tooltip":{maxWidth:455,width:e.isScrollable?455:439,padding:4,fontSize:12,boxShadow:"0px 0px 4px 2px rgb(0 0 0 / 12%)",fontWeight:400,lineHeight:"16px",letterSpacing:"0.4px",backgroundColor:t.palette.background.b9}}}}})),x=function(o){var x,h=o.assetsData,b=void 0===h?[]:h,y=o.appWidth,v=o.iconType,w=o.lastTimestamp,T=o.warningMessage,W=v==m.warning,S=v==m.error,I=y<d,j=u({isWarningTypeIcon:W,isIconType:!!v,isScrollable:(null==b?void 0:b.length)>5}),C=s[v];return W&&T&&(C="".concat(s[v],". ").concat(T)),S&&(C=e(f,{assetsData:b})),e("div",t({className:j.statusBadgeWrapper},{children:n("div",t({className:j.statusBadgeContent},{children:[W&&!I&&e(r,t({className:i(j.text,j.warningMessage),variant:"body1"},{children:T?"".concat(l,". ").concat(T):l})),v&&e(p,t({PopperProps:S&&{className:j.popper},placement:"top",title:C},{children:e("div",{children:e(g,{className:i((x={},x[j.badgeIconWarning]=W,x)),color:v,iconType:v,size:c.small})})})),n(r,t({className:i(j.text,j.timestamp),variant:"body1"},{children:["Last Update: ",a.unix(w).format("M/D/YYYY h:mm a")]}))]}))}))};export{x as StatusBadge};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@corva/ui",
3
- "version": "0.54.0-1",
3
+ "version": "0.54.0-3",
4
4
  "description": "Shared components/utils for Corva ui projects",
5
5
  "keywords": [
6
6
  "corva-ui"