"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("classnames"),r=require("@material-ui/core"),i=require("lodash"),a=require("./utils.js");function n(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var o=n(t),s=r.makeStyles((function(){return{icon:{borderRadius:function(e){return e.radius||"29%"}}}}));exports.AppIcon=function(t){var r=t.alt,n=void 0===r?"app icon":r,u=t.appDevType,c=void 0===u?"ui":u,d=t.className,l=t["data-testid"],p=void 0===l?"":l,f=t.height,h=void 0===f?16:f,m=t.iconUrl,v=void 0===m?null:m,g=t.radius,j=t.segment,y=t.width,q=void 0===y?16:y,x=s({radius:null!=g?g:0,width:q}),w=i.castArray(j),A=a.getIconComponentBySegment(w,c),I="AppIcon_".concat(p,"_").concat(v||"");return v?e.jsx("img",{alt:n,className:o.default(x.icon,d),"data-testid":I,height:h,onError:function(e){e.currentTarget.src=a.getAppIcon(w,c)},src:v,width:q}):e.jsx(A,{"data-testid":I,className:o.default(x.icon,d),width:q,height:h})};
//# sourceMappingURL=AppIcon.js.map
