"use strict";var i=require('./../../ext-esm/tslib/tslib.es6.js'),e=require("react/jsx-runtime"),o=require("prop-types"),s=require("classnames"),c=require("lodash"),t=require("@material-ui/core"),r=require("../../icons/iconParkIcons.js");function n(i){return i&&"object"==typeof i&&"default"in i?i:{default:i}}require("../../icons/customIcons/icons/AddMessage.js"),require("../../icons/customIcons/icons/Attention.js"),require("../../icons/customIcons/icons/Collapse.js"),require("../../icons/customIcons/icons/Dashboard.js"),require("../../icons/customIcons/icons/Expand.js"),require("../../icons/customIcons/icons/FolderClosed.js"),require("../../icons/customIcons/icons/FolderClosedFilled.js"),require("../../icons/customIcons/icons/FolderOpened.js"),require("../../icons/customIcons/icons/GreaterOrEqual.js"),require("../../icons/customIcons/icons/LessOrEqual.js"),require("../../icons/customIcons/icons/Search.js"),require("../../icons/customIcons/icons/Wellhub.js"),require("../../icons/customIcons/icons/MultiRuler.js"),require("../../icons/customIcons/icons/Checkbox.js"),require("../../icons/customIcons/icons/CheckboxChecked.js"),require("../../icons/customIcons/icons/CheckboxIndeterminate.js"),require("../../icons/customIcons/icons/Radio.js"),require("../../icons/customIcons/icons/RadioChecked.js"),require("../../icons/customIcons/icons/SimulFrac.js"),require("../../icons/customIcons/icons/ZipperFrac.js"),require("../../icons/customIcons/icons/CautionFilled.js"),require("../../icons/customIcons/icons/MoreApp.js");var a=n(o),l=n(s),u=t.makeStyles((function(i){return{rootChip:{"&.MuiChip-root":{backgroundColor:i.palette.background.b9,color:i.palette.primary.text6,textAlign:"center","&:hover":{color:i.palette.primary.contrastText,"& .MuiSvgIcon-root":{color:i.palette.primary.contrastText}},"& span.MuiChip-label":{padding:0}}},tooltip:{marginTop:"10px"},closeIcon:{marginRight:"-2px !important",marginLeft:"2px !important",color:i.palette.primary.text6},sizeSmall:{"&.MuiChip-root":{minWidth:16,height:16,padding:"1px 2px","& span":{fontSize:"11px",lineHeight:"14px"}}},sizeSmallLimited:{"&.MuiChip-root":{padding:"1px 3px"}},sizeMedium:{"&.MuiChip-root":{minWidth:24,height:24,padding:"2px 4px","& span":{fontSize:"14px",lineHeight:"20px"}}},sizeMediumLimited:{"&.MuiChip-root":{padding:"2px 6px"}},sizeMediumClickable:{"&.MuiChip-root":{padding:"2px 6px"}},sizeLarge:{"&.MuiChip-root":{minWidth:32,height:32,padding:"5px 7px","& span":{fontSize:"16px",lineHeight:"22px"}}},sizeLargeLimited:{"&.MuiChip-root":{padding:"5px 8px"}},sizeLargeClickable:{"&.MuiChip-root":{padding:"5px 8px"}}}})),p=function(o){var s=o.classes,n=o.size,a=o.limited,p=o.clickable,d=o.tooltip,m=u();return e.jsx(t.Tooltip,i.__assign({title:d,classes:{tooltip:m.tooltip}},{children:e.jsx(t.Chip,i.__assign({},o,{classes:i.__assign(i.__assign({},s),{root:l.default(s.root,m.rootChip,m["size".concat(c.capitalize(n))],a&&m["size".concat(c.capitalize(n),"Limited")],p&&m["size".concat(c.capitalize(n),"Clickable")])}),clickable:p,deleteIcon:e.jsx(r.CloseSmallIcon,{className:m.closeIcon,size:16})}))}))},d={classes:a.default.shape({root:a.default.string}),size:a.default.oneOf(["small","medium","large"]),limited:a.default.bool,clickable:a.default.bool,label:a.default.string.isRequired,tooltip:a.default.string};p.propTypes=d,p.defaultProps={classes:{},size:"medium",limited:!1,clickable:!1,tooltip:""},module.exports=p;
