@reltio/remotes 1.4.1501 → 1.4.1502

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.
package/3118.js CHANGED
@@ -1,2 +1,2 @@
1
- "use strict";(self.webpackChunk_reltio_remotes=self.webpackChunk_reltio_remotes||[]).push([[3118],{7785:(e,t,n)=>{n.d(t,{Z:()=>k});var r=n(24328),a=n.n(r),o=n(71153),l=n.n(o),i=n(87918),s=n.n(i),c=n(38402),p=n(94079),u=n(95613),d=n(73122),h=n(83348),m=n(55299),g=n(31276),f=n(71543);function b(){return b=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},b.apply(this,arguments)}const x=e=>a().createElement("svg",b({width:24,height:24,viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},e),a().createElement("path",{d:"M10 18h3v-1a1 1 0 011-1h4a1 1 0 011 1v4a1 1 0 01-1 1h-4a1 1 0 01-1-1v-1H8V8H6a1 1 0 01-1-1V3a1 1 0 011-1h6a1 1 0 011 1v4a1 1 0 01-1 1h-2v3h3v-1a1 1 0 011-1h4a1 1 0 011 1v4a1 1 0 01-1 1h-4a1 1 0 01-1-1v-1h-3v5z",fill:"#000",stroke:"none",strokeWidth:1,fillRule:"evenodd"}));function v(){return v=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},v.apply(this,arguments)}const y=e=>a().createElement("svg",v({width:24,height:24,viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},e),a().createElement("rect",{fill:"#000",x:9,y:9,width:6,height:6,rx:1,stroke:"none",strokeWidth:1,fillRule:"evenodd"})),C=(0,n(79692).Z)({container:{"& > $marginWrapper:first-child":{paddingLeft:"4px"}},listItem:{paddingLeft:"1px",paddingTop:"2px",paddingBottom:"2px",transition:"none","&:hover":{"& $itemAfter":{background:"linear-gradient(to right, rgba(235, 235, 235, 0.2), rgba(235, 235, 235, 1) 100%)"}},"&$listItemFocus":{"& $itemAfter":{background:"linear-gradient(to right, rgba(219, 219, 219, 0.2), rgba(219, 219, 219, 1) 100%)"}},"&:focus":{outline:"none"}},listItemFocus:{},icon:{opacity:.29,width:"16px",height:"16px",flexShrink:0,marginRight:"6px",marginLeft:"8px"},recommendedIcon:{width:"18px",height:"18px",marginRight:"5px",marginLeft:"7px",flexShrink:0},logoIcon:{width:"18px",height:"18px",flexShrink:0,marginRight:"4px"},itemAfter:{position:"absolute",right:0,top:0,width:"40px",height:"100%",pointerEvents:"none",background:"linear-gradient(to right, rgba(255, 255, 255, 0.2), #fff 100%)"},itemText:{padding:"0",margin:0,"& span":{fontSize:"0.8125rem",letterSpacing:"normal",whiteSpace:"nowrap"}},checkbox:{opacity:.34,padding:0,marginLeft:"14px","&$checked":{opacity:1,background:"none"}},checked:{},marginWrapper:{display:"flex",alignItems:"center"},defaultCursor:{cursor:"default"},itemTooltip:{margin:"4px 0"},marginText:{marginLeft:"21px"},itemTextWrapper:{display:"flex",alignItems:"center"}}),w=e=>{let{attrType:t={}}=e;const n=C(),r=(e=>{switch(e.type){case d.oS0.TYPE_IMAGE:case d.oS0.TYPE_NESTED:return f.Z;case d.oS0.TYPE_REFERENCE:return x;default:return y}})(t);return a().createElement(r,{className:n.icon})};var O=n(31269);function I(){return I=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},I.apply(this,arguments)}const E=(0,h.Z)((e=>a().createElement("svg",I({width:13,height:18,viewBox:"0 0 13 18",xmlns:"http://www.w3.org/2000/svg"},e),a().createElement("g",{transform:"translate(-3 -1)",stroke:"none",strokeWidth:1,fill:"none",fillRule:"evenodd"},a().createElement("path",{fill:"#FF4081",d:"M5.833 10h3.75v6.667l-3.75 1.666z"}),a().createElement("path",{fill:"#CE0C4E",d:"M13.333 10v8.333l-3.75-1.666V10z"}),a().createElement("circle",{fill:"#FFC058",cx:9.583,cy:7.917,r:6.25}),a().createElement("circle",{fill:"#FFCD7B",cx:9.583,cy:7.917,r:5.417}),a().createElement("path",{fill:"#FFFBB5",d:"M8.333 11.667L5 8.462l.933-.898 2.4 2.308L13.4 5l.933.897z"}))))),k=(0,r.memo)((e=>{let{groupId:t,data:n,checked:r=!1,isFocused:o=!1,isRequired:i=!1,label:h,labelInText:f,level:b,onClick:x=g.ZT,hideCheckBox:v=!1,hideIcon:y=!1,notSelectable:I=!1,disableHorizontalScrollbar:k=!1,style:P={},subItemMargin:S=20,LogoIcon:j,className:T}=e;const L=C(),{attrType:Z}=n||{},R=!(v&&(0,d.QZu)(Z)||I),N=!!j;return a().createElement(u.Z,{value:f||h,className:L.itemTooltip,placement:"bottom-end"},a().createElement(c.Z,{className:l()(L.container,L.listItem,{[L.defaultCursor]:!R},T),onClick:R?()=>x(n,!r,t):void 0,style:P,dense:!0,button:R,classes:{focusVisible:L.listItemFocus,selected:L.listItemFocus},selected:o,tabIndex:-1},!v&&a().createElement(p.Checkbox,{checked:r,disableRipple:!0,disabled:!R,className:l()(L.checkbox,{[L.checked]:r}),tabIndex:-1}),a().createElement(O.Z,{margin:S,level:b,className:L.marginWrapper},a().createElement(a().Fragment,null,!y&&(e=>"recommended"===t?a().createElement(E,{className:L.recommendedIcon,tooltipTitle:s().text("Recommended"),showForDisabled:!0}):a().createElement(w,{attrType:e}))(Z),a().createElement("div",{className:l()(L.itemTextWrapper,{[L.marginText]:y})},N&&a().createElement(j,{className:L.logoIcon}),a().createElement(p.ListItemText,{primary:a().createElement(a().Fragment,null,h,i&&a().createElement(m.Z,null)),className:L.itemText})))),R&&k&&a().createElement("div",{className:L.itemAfter})))}))},24737:(e,t,n)=>{n.d(t,{Z:()=>W});var r=n(24328),a=n.n(r),o=n(13980),l=n.n(o),i=n(71153),s=n.n(i),c=n(17440),p=n(94113),u=n(65549),d=n(79692);const h=(0,d.Z)((e=>({addLabel:{display:"flex",padding:"0 7px",height:"35px",alignItems:"center",fontSize:"13px",fontWeight:"500",color:e.palette.primary.main,cursor:"pointer",textOverflow:"ellipsis",overflow:"hidden",whiteSpace:"nowrap",borderTop:"solid 1px rgba(0, 0, 0, 0.14)",backgroundColor:"rgba(0, 0, 0, 0.03)"},addIcon:{height:"18px",width:"18px",padding:"0 9px"}}))),m=(0,d.Z)({singleValue:{fontSize:"14px",lineHeight:"16px",whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",marginTop:"21px"}});var g=n(36179);const f=e=>{const{selectProps:{onCreate:t,createLabel:n,inputValue:r,components:o},children:l}=e,i=h();return a().createElement(g.Z,e,l,n&&!(0,c.prop)("Group",o)&&a().createElement("span",{className:i.addLabel,onClick:()=>t(r)},a().createElement(u.Z,{className:i.addIcon}),n))};f.propTypes={children:l().element.isRequired,selectProps:l().object.isRequired};const b=f;var x=n(18461),v=n(5190),y=n(31276),C=n(73122),w=n(72436),O=n(94079);function I(){return I=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},I.apply(this,arguments)}function E(e){const{selectProps:{menuIsOpen:t},innerProps:n,children:r}=e,o=m();return!t&&a().createElement(O.Typography,I({className:o.singleValue},n),r)}function k(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),r.forEach((function(t){P(e,t,n[t])}))}return e}function P(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}E.propTypes={children:l().node,innerProps:l().object};const S=(0,d.Z)({control:{height:"auto"},dropdownIndicator:{boxSizing:"content-box",transition:"transform .15s ease",padding:e=>(e.height-24)/2+"px 12px",cursor:"pointer",color:"rgba(0, 0, 0, 0.54)"},valueContainer:{marginLeft:"16px",width:0},formControl:{margin:0},filledInputRoot:{backgroundColor:"rgba(0, 0, 0, 0.03)","&:hover":{backgroundColor:"rgba(0, 0, 0, 0.03)"},"&.focused":{backgroundColor:"rgba(0, 0, 0, 0.03)"}},filledInputUnderline:{"&:before":{display:"none"}},inputLabel:{color:"rgba(0,0,0,0.6)",fontSize:"14px",lineHeight:"16px",paddingLeft:"4px","&.shrink":{paddingLeft:"4px"}}}),j={menu:e=>k({},e,{borderRadius:"0 0 4px 4px",backgroundColor:"#FFFFFFFF",boxShadow:"0 2px 2px 0 rgba(0,0,0,0.14), 0 3px 1px -2px rgba(0,0,0,0.12), 0 1px 5px 0 rgba(0,0,0,0.2)",margin:0}),menuList:e=>k({},e,{maxHeight:"208px",padding:"8px 0"}),group:e=>k({},e,{padding:"0 0 8px 0"}),input:e=>k({},e,{height:"16px",color:"rgba(0, 0, 0, 0.87)",fontSize:"14px",lineHeight:"16px",margin:"16px 0 0",padding:0}),option:e=>k({},e,{fontSize:"13px",lineHeight:"15px",height:"32px"})},T={menuList:e=>k({},e,{padding:0})},L={input:e=>k({},e,{height:"16px",color:"rgba(0, 0, 0, 0.87)",fontSize:"14px",lineHeight:"16px",margin:0,padding:0})};function Z(){return Z=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Z.apply(this,arguments)}function R(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),r.forEach((function(t){N(e,t,n[t])}))}return e}function N(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const F=e=>{let{value:t,label:n,createLabel:o,getOptions:l,options:i,height:u=46,onChange:d=c.identity,onCreate:h,onClear:m=c.identity,components:g,textFieldInputRef:f,TextFieldProps:O,classes:I}=e,k=function(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}(e,["value","label","createLabel","getOptions","options","height","onChange","onCreate","onClear","components","textFieldInputRef","TextFieldProps","classes"]);const P=S({height:u}),N=(0,w.a6)(),[F,z]=(0,r.useState)(!1),W=(0,r.useRef)(null),D=l?x.Z:v.Z,B=(0,c.prop)("ClearIndicator",g)?{}:{IndicatorSeparator:y.Vd,ClearIndicator:y.Vd},H=h?(e,t)=>{h(e,t),z(!1)}:void 0,M=(0,c.prop)("Group",g)?T:{},A=(0,c.isEmpty)(n)?L:{},U=R({},j,M,A),V=R({},P,I);return a().createElement(D,Z({placeholder:"",defaultOptions:!0},k,{value:(0,c.defaultTo)(null,t),loadOptions:l,options:i,cacheOptions:!0,onChange:d,onCreate:H,onClear:m,createLabel:o,classes:V,styles:U,components:R({DropdownIndicator:p.Z,LoadingIndicator:y.Vd,SingleValue:E,Menu:b},B,g),menuPlacement:"auto",TextFieldProps:R({},O,{label:n,variant:"filled",margin:"dense",classes:R({},(0,c.prop)("classes",O),{root:s()(P.formControl,(0,c.path)(["classes","root"],O))}),inputProps:R({},(0,c.prop)("inputProps",O)),InputProps:R({},(0,c.prop)("InputProps",O),{classes:R({},(0,c.path)(["InputProps","classes"],O),{root:s()(P.filledInputRoot,(0,c.path)(["InputProps","classes","root"],O)),underline:s()({[N.filledInputUnderline]:(0,C.O27)(t)},(0,c.path)(["InputProps","classes","underline"],O)),focused:s()("focused",(0,c.path)(["InputProps","classes","focused"],O))})}),InputLabelProps:R({},(0,c.prop)("InputLabelProps",O),{classes:R({},(0,c.path)(["InputLabelProps","classes"],O),{root:s()(P.inputLabel,(0,c.path)(["InputLabelProps","classes","root"],O)),shrink:s()("shrink",(0,c.path)(["InputLabelProps","classes","shrink"],O))}),shrink:!(0,C.O27)(t)||void 0}),ref:f||W}),inputRef:f||W,menuIsOpen:F,onMenuOpen:()=>z(!0),onMenuClose:()=>z(!1)}))},z={value:l().oneOfType([l().object,l().array]),label:l().string.isRequired,getOptions:l().func,options:l().array,onChange:l().func,onCreate:l().func,onClear:l().func,createLabel:l().string,components:l().object,textFieldInputRef:l().object,TextFieldProps:l().object,height:l().number,classes:l().object};F.propTypes=z;const W=F},53180:(e,t,n)=>{n.d(t,{Z:()=>u});var r=n(24328),a=n.n(r),o=n(52730),l=n(71153),i=n.n(l),s=n(94079),c=n(73122),p=n(49885);const u=e=>{let{entity:t,avatarClassName:n,imageClassName:r}=e;const l=(0,o.useSelector)(p.ZP.selectors.getMetadata),u=(0,o.useSelector)(p.ZP.selectors.getAbsoluteImagePath)||"",d=(0,c.uie)(l,u,t),h=(0,c.vPL)(u,(0,c.XH2)(l,t.type)),m=e=>{e.target.onError=null,e.target.src=(0,c.m5F)('\n<svg width="400px" height="400px" viewBox="0 0 400 400" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">\n <title>Group</title>\n <g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">\n <g id="Group" fill-rule="nonzero">\n <rect id="Rectangle" fill="#DFE5E9" x="0" y="0" width="400" height="400"></rect>\n <path d="M0,387.023257 L0,399.918908 L400,399.918908 L400,386.023594 C366.631,377.336524 321.866,364.269931 315.979,359.161654 C308.985,353.083704 270.481,310.508063 270.481,310.508063 L270.481,286.186267 C270.481,286.186267 284.478,266.204006 284.478,261.854473 C284.478,257.515936 285.353,246.219746 291.481,241.011503 C297.61,235.792263 311.607,211.471466 312.481,206.253226 C313.355,201.043983 319.484,188.009379 312.481,185.400259 C305.478,182.801135 307.236,173.244359 308.984,168.026119 C310.733,162.817875 319.484,139.355788 322.981,133.277838 C326.488,127.199888 312.481,108.956041 312.481,108.956041 C312.481,108.956041 294.978,80.2857109 245.975,53.3547939 C196.971,26.4138803 168.967,42.9283105 168.967,42.9283105 L161.964,60.3024507 C161.964,60.3024507 138.341,64.6409874 123.46,77.6765909 C108.589,90.7121943 99.837,106.346921 98.963,115.903698 C98.088,125.460475 103.334,159.339048 105.966,164.557289 C108.589,169.765532 112.96,185.400259 112.96,185.400259 C112.96,185.400259 108.589,183.670842 105.966,188.879085 C103.334,194.097325 112.085,218.419122 112.96,220.159535 C113.834,221.897949 114.718,238.403382 119.963,237.532676 C125.218,236.663969 130.463,251.42799 130.463,251.42799 C130.463,251.42799 143.596,271.41125 144.47,275.759783 C145.344,280.09832 147.967,307.039233 147.967,307.039233 L126.967,331.36103 L102.46,355.682827 C102.459,355.682827 34.042,375.886013 0,387.023257 Z" id="Path" fill="#B3BCC4"></path>\n <path d="M0,387.023257 L0,399.918908 L400,399.918908 L400,386.023594 C366.631,377.336524 321.866,364.269931 315.979,359.161654 C308.985,353.083704 270.481,310.508063 270.481,310.508063 L270.481,286.186267 C270.481,286.186267 284.478,266.204006 284.478,261.854473 C284.478,257.515936 285.353,246.219746 291.481,241.011503 C297.61,235.792263 311.607,211.471466 312.481,206.253226 C313.355,201.043983 319.484,188.009379 312.481,185.400259 C305.478,182.801135 307.236,173.244359 308.984,168.026119 C310.733,162.817875 319.484,139.355788 322.981,133.277838 C326.488,127.199888 312.481,108.956041 312.481,108.956041 C312.481,108.956041 294.978,80.2857109 245.975,53.3547939 C196.971,26.4138803 168.967,42.9283105 168.967,42.9283105 L161.964,60.3024507 C161.964,60.3024507 138.341,64.6409874 123.46,77.6765909 C108.589,90.7121943 99.837,106.346921 98.963,115.903698 C98.088,125.460475 103.334,159.339048 105.966,164.557289 C108.589,169.765532 112.96,185.400259 112.96,185.400259 C112.96,185.400259 108.589,183.670842 105.966,188.879085 C103.334,194.097325 112.085,218.419122 112.96,220.159535 C113.834,221.897949 114.718,238.403382 119.963,237.532676 C125.218,236.663969 130.463,251.42799 130.463,251.42799 C130.463,251.42799 143.596,271.41125 144.47,275.759783 C145.344,280.09832 147.967,307.039233 147.967,307.039233 L126.967,331.36103 L102.46,355.682827 C102.459,355.682827 34.042,375.886013 0,387.023257 Z" id="Path" fill="#B3BCC4"></path>\n <path d="M5.68434189e-14,387.023257 L5.68434189e-14,399.918908 L400,399.918908 L400,386.023594 C366.631,377.336524 321.866,364.269931 315.979,359.161654 C308.985,353.083704 270.481,310.508063 270.481,310.508063 L270.481,286.186267 C270.481,286.186267 284.478,266.204006 284.478,261.854473 C284.478,257.515936 285.353,246.219746 291.481,241.011503 C297.61,235.792263 311.607,211.471466 312.481,206.253226 C313.355,201.043983 319.484,188.009379 312.481,185.400259 C305.478,182.801135 307.236,173.244359 308.984,168.026119 C310.733,162.817875 319.484,139.355788 322.981,133.277838 C326.488,127.199888 312.481,108.956041 312.481,108.956041 C312.481,108.956041 294.978,80.2857109 245.975,53.3547939 C196.971,26.4138803 168.967,42.9283105 168.967,42.9283105 L161.964,60.3024507 C161.964,60.3024507 138.341,64.6409874 123.46,77.6765909 C108.589,90.7121943 99.837,106.346921 98.963,115.903698 C98.088,125.460475 103.334,159.339048 105.966,164.557289 C108.589,169.765532 112.96,185.400259 112.96,185.400259 C112.96,185.400259 108.589,183.670842 105.966,188.879085 C103.334,194.097325 112.085,218.419122 112.96,220.159535 C113.834,221.897949 114.718,238.403382 119.963,237.532676 C125.218,236.663969 130.463,251.42799 130.463,251.42799 C130.463,251.42799 143.596,271.41125 144.47,275.759783 C145.344,280.09832 147.967,307.039233 147.967,307.039233 L126.967,331.36103 L102.46,355.682827 C102.459,355.682827 34.042,375.886013 5.68434189e-14,387.023257 Z" id="Path" fill="#B3BCC4"></path>\n </g>\n </g>\n</svg>\n')};return a().createElement(s.Avatar,{className:i()(n,r),src:d,imgProps:{onError:m}},a().createElement("img",{className:r,src:h,alt:"fallback entity avatar",onError:m}))}},34e3:(e,t,n)=>{n.d(t,{Z:()=>c});var r=n(24328),a=n.n(r),o=n(52730),l=n(49885),i=n(98018);function s(){return s=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},s.apply(this,arguments)}const c=e=>{const t=(0,o.useSelector)(l.ZP.selectors.getAbsoluteImagePath)||"";return a().createElement(i.ZP,s({},e,{storagePath:(n=t,n.endsWith("/")?n:n+"/")}));var n}},31039:(e,t,n)=>{n.d(t,{Z:()=>p});var r=n(24328),a=n.n(r),o=n(52730),l=n(39450),i=n(72383),s=n(49885);const c=(0,r.forwardRef)(((e,t)=>{let{value:n,children:c,screen:p,className:u}=e;const d=(0,o.useDispatch)(),h=(0,r.useContext)(l.m),{generateEntityUrl:m}=(0,r.useContext)(i.v),g=(0,o.useSelector)(s.ZP.selectors.getUIPath),f=(0,r.useCallback)((()=>{d(s.ui.actions.openEntity({uri:n,viewId:h,screen:p}))}),[h,n,d,p]);return a().createElement("a",{ref:t,href:(b=n,m({uiPath:g,uri:b,screen:p})),onClick:e=>{f(),e.stopPropagation(),e.preventDefault()},className:u},c);var b}));c.displayName="EntityUriLink";const p=c},99136:(e,t,n)=>{n.d(t,{Z:()=>c});var r=n(24328),a=n.n(r),o=n(71153),l=n.n(o),i=n(94079);const s=(0,n(79692).Z)({loadingOverlay:{position:"absolute",width:"100%",height:"100%",top:0,left:0,opacity:.37,zIndex:10,backgroundColor:"#fff"},transparent:{backgroundColor:"transparent"},relativePosition:{"&$loadingOverlay":{position:"relative"}}}),c=e=>{let{transparent:t=!1,relativePosition:n=!1,className:r}=e;const o=s();return a().createElement(a().Fragment,null,a().createElement("div",{className:l()(o.loadingOverlay,r,{[o.transparent]:t,[o.relativePosition]:n})},a().createElement(i.LinearProgress,{color:"primary"})))}},83401:(e,t,n)=>{n.d(t,{Z:()=>h});var r=n(24328),a=n.n(r),o=n(94079),l=n(71153),i=n.n(l),s=n(83348),c=n(79692),p=n(41128);const u=(0,c.Z)((e=>({button:{minWidth:"30px",padding:"8px 8px",justifyContent:"start",fill:"rgba(0,0,0,0.54)",textTransform:"none",borderColor:"rgba(0,0,0,0.12)"},icon:{color:"rgba(0,0,0,0.54)",width:"20px",height:"20px","& + $title":{marginLeft:"8px"}},title:{fontSize:"13px",lineHeight:"15px",letterSpacing:0},current:{"& $icon":{color:e.palette.primary.main},backgroundColor:(0,p.U1)(e.palette.primary.main,.12),fill:e.palette.primary.main,color:e.palette.primary.main,"&:hover":{backgroundColor:(0,p.U1)(e.palette.primary.main,.24)}}}))),d=(0,s.Z)(o.Button),h=e=>{let{className:t,classes:n={},modes:r=[],modeId:l,onChange:s}=e;const c=u();return a().createElement(o.ButtonGroup,{className:t},r.map((e=>{let{id:t,title:r,tooltipTitle:o,Icon:p,disabled:u}=e;return a().createElement(d,{disabled:u,showForDisabled:u&&!!o,key:String(t),className:i()(c.button,{[c.current]:l===t},n.button),tooltipTitle:o,onClick:(h=t,()=>s(h)),"data-reltio-id":`reltio-search-mode-${t}`},p&&a().createElement(p,{className:c.icon}),r&&a().createElement("div",{className:c.title},r));var h})))}},18461:(e,t,n)=>{n.d(t,{Z:()=>a});var r=n(27308);const a=(0,n(5407).Z)(r.ZP)},55299:(e,t,n)=>{n.d(t,{Z:()=>l});var r=n(24328),a=n.n(r);const o=(0,n(79692).Z)({mark:{color:"red"}}),l=()=>{const e=o();return a().createElement("span",{className:e.mark},"*")}},94574:(e,t,n)=>{n.d(t,{Z:()=>y});var r=n(71153),a=n.n(r),o=n(17440),l=n(24328),i=n.n(l),s=n(87918),c=n.n(s),p=n(29611),u=n(94079),d=n(87685),h=n(21853),m=n(31276),g=n(22385),f=n(63015);function b(){return b=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},b.apply(this,arguments)}function x(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),r.forEach((function(t){v(e,t,n[t])}))}return e}function v(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const y=(0,l.memo)((e=>{let{value:t,autofocus:n,onSearch:r=m.ZT,rootRef:s,classes:v={},height:y,placeholder:C=c().text("Search")}=e,w=function(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}(e,["value","autofocus","onSearch","rootRef","classes","height","placeholder"]);const O=(0,f.y)({height:y}),[I,E]=(0,l.useState)(""),k=(0,o.pipe)((0,o.tap)(r),E),P=(0,o.isNil)(t)?I:t;return i().createElement(p.Z,b({startAdornment:i().createElement(u.InputAdornment,{position:"start"},i().createElement(h.default,{className:O.icon})),endAdornment:i().createElement(u.InputAdornment,{position:"end"},P.length>0&&i().createElement(g.Z,{icon:d.default,className:O.clearButton,onClick:()=>k("")})),autoFocus:n,classes:x({},v,{input:a()(O.input,v.input),root:a()(O.container,v.root)}),placeholder:C,value:P,onChange:(0,o.pipe)(m.NA,k),disableUnderline:!0,ref:s},w))}))},63015:(e,t,n)=>{n.d(t,{y:()=>r});const r=(0,n(79692).Z)((()=>({container:e=>{let{height:t=36}=e;return{height:t,borderRadius:"2px",alignItems:"center",backgroundColor:"rgba(0,0,0,0.03)",minWidth:"100px"}},icon:{opacity:.67,marginLeft:"10px",marginRight:"6px"},input:{fontSize:"13px",width:"100%"},clearButton:{marginRight:"10px"},white:{backgroundColor:"rgb(255, 255, 255)",boxShadow:"0 1px 3px 0 rgba(0,0,0,0.24)"}})))},97820:(e,t,n)=>{n.d(t,{Z:()=>h});var r=n(24328),a=n.n(r),o=n(71153),l=n.n(o),i=n(87918),s=n.n(i),c=n(79784),p=n(25480),u=n(94574);function d(){return d=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},d.apply(this,arguments)}const h=e=>{let{title:t,className:n,onSearch:r,hideTitle:o,hideSearchInput:i,headerPlacement:h="top",containerWidth:m,containerHeight:g,searchInputOnKeyDown:f,children:b,searchInputRef:x,anchorOrigin:v={vertical:"top",horizontal:"right"},transformOrigin:y={vertical:"top",horizontal:"right"}}=e,C=function(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}(e,["title","className","onSearch","hideTitle","hideSearchInput","headerPlacement","containerWidth","containerHeight","searchInputOnKeyDown","children","searchInputRef","anchorOrigin","transformOrigin"]);const w=(0,p.Z)({containerWidth:m,containerHeight:g}),O=a().createElement(a().Fragment,null,!o&&a().createElement("div",{className:w.header},t),!i&&a().createElement(u.Z,{onSearch:r,autofocus:!0,onKeyDown:f,inputRef:x,classes:{root:w.searchInputContainer},placeholder:s().text("Search & add attributes"),height:40}));return a().createElement(c.ZP,d({anchorOrigin:v,transformOrigin:y},C),a().createElement("div",{className:l()(w.container,n),style:{width:m}},"top"===h&&O,a().createElement("div",{className:w.list},b),"bottom"===h&&O))}},54763:(e,t,n)=>{n.d(t,{t:()=>l});var r=n(24328),a=n(17440),o=n(44890);const l=e=>{let{items:t,open:n,onSelectFocusedItem:l,selectedItems:i,onClose:s}=e;const[c,p]=(0,r.useState)(null),u=(0,r.useRef)(!1),d=(0,r.useCallback)((e=>{let n=null===e?d(-1):e;for(;null!==e&&n<t.length&&(n<=e||n>=0&&(0,o.c)(t[n]));)n+=1;return n!==t.length?n:d(-1)}),[t]),h=(0,r.useCallback)((e=>{let n=null===e?t.length-1:e;for(;null!==e&&n>=0&&(n>=e||(0,o.c)(t[n]));)n-=1;return n<0?t.length-1:n}),[t]),m=(0,r.useCallback)((()=>{if(!(0,a.isNil)(c)){const e=t[c].item;!e.item.notSelectable&&l({item:e.item,groupData:e})}}),[l,t,c]),g=(0,r.useCallback)((e=>{if(0!==t.length)switch(e.key){case"Down":case"ArrowDown":return p(d),e.preventDefault(),!1;case"Up":case"ArrowUp":return p(h),e.preventDefault(),!1;case"Enter":u.current=!0,m();break;case"Tab":s&&s(e);break;default:return}}),[t,d,h,m,s]);return(0,r.useEffect)((()=>{if(u.current){u.current=!1;const e=t.findIndex((e=>e.item.moveTo));e>-1&&p(e)}else p(null)}),[t,n,i]),{focusIndex:c,handleKeyDown:g}}},25480:(e,t,n)=>{n.d(t,{Z:()=>a});var r=n(79692);const a=(0,r.Z)((()=>({container:e=>{let{containerHeight:t=553,containerWidth:n}=e;return{display:"flex",flexDirection:"column",height:t,width:n,flexGrow:1}},header:{marginLeft:"16px",marginTop:"16px",marginBottom:"12px",fontSize:"16px",fontWeight:500,letterSpacing:"0.15px",lineHeight:"24px"},searchInputContainer:{margin:"0 16px 12px 16px",flexShrink:"0"},list:{flexGrow:1,height:0,overflow:"hidden",width:"100%",position:"relative","& ul":{paddingBottom:0,paddingTop:0}}})))},31517:(e,t,n)=>{n.d(t,{Z:()=>f});var r=n(24328),a=n.n(r),o=n(24737),l=n(13980),i=n.n(l),s=n(94079);const c=(0,n(79692).Z)({value:{color:"rgba(0, 0, 0, 0.87)"},placeholder:{color:"rgba(0, 0, 0, 0.38)",fontSize:"14px !important"}}),p=e=>{let{selectProps:{menuIsOpen:t},data:{label:n}}=e;const r=c();return!t&&a().createElement(s.Typography,{variant:"body2",classes:{root:r.value}},n)};p.propTypes={selectProps:i().shape({menuIsOpen:i().bool}),data:i().shape({label:i().string})};const u=p;function d(){return d=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},d.apply(this,arguments)}const h=e=>{const t=c(),{innerProps:n={},children:r}=e;return a().createElement(s.Typography,d({className:t.placeholder},n),r)};function m(){return m=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},m.apply(this,arguments)}h.propTypes={children:i().node,innerProps:i().object,selectProps:i().object.isRequired};const g={SingleValue:u,Placeholder:h},f=(0,r.memo)((e=>{let t=m({},e);return a().createElement(o.Z,m({components:g},t))}))},44890:(e,t,n)=>{n.d(t,{Z:()=>h,c:()=>u});var r=n(24328),a=n.n(r),o=n(13980),l=n.n(o),i=n(50166),s=n(44443);const c=(0,n(79692).Z)({stickyTitlesWrapper:{position:"absolute",top:0,"& > div":{zIndex:1,position:"absolute",top:0,width:"100%",visibility:"hidden"}}});var p=n(56656);const u=e=>e.titleItemIndex===e.index,d=e=>{let{items:t,getItemSize:n,renderItem:o,renderGroupTitle:l,width:d="100%",height:h,fixedTitle:m=!0,itemKey:g=(e=>e),disableHorizontalScrollbar:f,hideSubtitles:b,focusIndex:x=null,onInnerContainerResize:v}=e;const y=c(),C=(0,r.useRef)(null),w=(0,r.useRef)(null),O=(0,r.useRef)(null),I=(0,r.useRef)([0]),E={topMargin:0},k=(0,r.useMemo)((()=>!b||(t||[]).some((e=>null!==e.titleItemIndex))),[t,b]),P=(0,r.useCallback)((e=>{const r=I.current.length;let a=0;t.slice(r-1,e+1).forEach(((e,t)=>{const o=r+t-1;t>0&&(I.current[o]=I.current[o-1]+a),a=n(o,e.item)}))}),[n,t]),S=(0,r.useCallback)((e=>t[e].titleItemIndex),[t]),j=(0,r.useCallback)((e=>t[e]),[t]);(0,r.useEffect)((()=>{requestAnimationFrame((()=>{C.current&&C.current.scrollTo(0)}))}),[t.length]),(0,r.useEffect)((()=>{C.current&&C.current.resetAfterIndex(0),T();const e=(e=>{const t=e.findIndex((e=>e.item.moveTo));if(t>-1){P(t);const e=S(t);return{offset:I.current[t],titleHeight:n(e,j(e).item)}}})(t);if(e&&e.offset&&C.current){const{titleHeight:t}=e,n=e.offset-t;(n<C.current.state.scrollOffset||n>C.current.state.scrollOffset+h)&&requestAnimationFrame((()=>{C.current&&C.current.scrollTo(n-(h-t)/2)}))}}),[P,j,n,S,h,I,t,C]);const T=()=>{O.current&&w.current&&(O.current.style.width=w.current.offsetWidth+"px")},L=(0,r.useCallback)((e=>{let n=null,r=0;return t.some(((t,a)=>{P(a+10);const o=I.current[a+1];return e>=r&&e<o&&(n={index:a,offset:r,listItem:t}),r=o,n})),n}),[P,I,t]),Z=(0,r.useCallback)((e=>n(e,j(e).item)),[j,n]),R=(0,r.useCallback)((e=>{let{index:t,style:n,data:r}=e;const a=j(t);return a.item&&(u(a)&&l(n,a.item)||o(n,a.item,t,r))}),[j,l,o]),{handleOnItemsRendered:N}=(0,p.LW)({items:t,focusIndex:x,listRef:C}),F=(0,r.useCallback)((()=>t.filter((e=>u(e))).map((e=>(e=>a().createElement("div",{className:"stickyTitleItem",style:{visibility:"hidden"},"data-index":e.index,key:e.index},l({height:n(e.index,e.item)},e.item)))(e)))),[n,t,l]);return a().createElement(a().Fragment,null,a().createElement("div",{ref:O,className:y.stickyTitlesWrapper},m&&F()),v&&w.current&&a().createElement(s.Z,{handleHeight:!0,onResize:v,targetDomEl:w.current}),a().createElement(i.VariableSizeList,{ref:C,itemCount:t.length,itemSize:Z,width:d,height:h,itemKey:g,innerRef:w,onScroll:e=>{let{scrollOffset:r,scrollDirection:a}=e;if(!m||!k)return;const o=L(r),l=o&&S(o.index);var i;null!==l&&(i=l,O.current&&[...O.current.querySelectorAll(".stickyTitleItem")].forEach((e=>{e.dataset.index===i.toString()?(e.style.visibility="visible",E.index=i):e.style.visibility="hidden"}))),T();const s=null!==l&&n(l,j(l).item),c=L(r+s+E.topMargin);let p=0;if(c){switch(a){case"forward":c.offset-r>0&&u(c.listItem)&&(p=s-(c.offset-r));break;case"backward":{const e=l>-1&&(d=l,t.findIndex(((e,t)=>u(e)&&d<t))),n=(e=>(P(e),I.current[e]))(e);e>-1&&r<n&&s>=n-r&&(p=s-(n-r))}}(e=>{O.current&&(E.topMargin=-e,O.current.style.top=-e+"px")})(p)}var d},style:f?{overflowX:"hidden"}:void 0,overscanCount:5,onItemsRendered:N},R))};d.propTypes={items:l().arrayOf(l().object).isRequired,getItemSize:l().func.isRequired,renderItem:l().func.isRequired,width:l().oneOfType([l().number,l().string]),height:l().number.isRequired,renderGroupTitle:l().func,fixedTitle:l().bool,hideSubtitles:l().bool,itemKey:l().func,disableHorizontalScrollbar:l().bool,focusIndex:l().number,onInnerContainerResize:l().func};const h=d},56656:(e,t,n)=>{n.d(t,{LG:()=>o,LW:()=>l});var r=n(17440),a=n(24328);const o=e=>{const t=e=>(0,r.flatten)(e.map((e=>[e].concat(e.items?t(e.items):[]))));let n=null;return t(e).map(((e,t)=>(e&&e.items&&(n=t),{item:e,index:t,titleItemIndex:n})))},l=e=>{let{focusIndex:t,listRef:n,items:r}=e;const o=(0,a.useRef)(null),l=(0,a.useRef)(null),i=(0,a.useCallback)((e=>{let{visibleStartIndex:t,visibleStopIndex:n}=e;o.current=t,l.current=n}),[]);return(0,a.useEffect)((()=>{n.current&&null!==t&&0!==r.length&&(t<Math.max(o.current+3,0)?n.current.scrollToItem(Math.max(t-3,0),"start"):t>Math.min(l.current-3,r.length-1)&&n.current.scrollToItem(Math.min(t+3,r.length-1),"end"))}),[t,r.length,n]),{handleOnItemsRendered:i}}},72383:(e,t,n)=>{n.d(t,{v:()=>l});var r=n(24328),a=n.n(r),o=n(73122);const l=a().createContext({generateEntityUrl:o.OuZ,generatePivotingUrl:o.FQ2,generateTagUrl:o.W$R});l.displayName="UrlGeneratorsContext"},39450:(e,t,n)=>{n.d(t,{m:()=>a});var r=n(24328);const a=n.n(r)().createContext(null);a.displayName="ViewIdContext"},71543:(e,t,n)=>{n.d(t,{Z:()=>l});var r=n(24328),a=n.n(r);function o(){return o=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},o.apply(this,arguments)}const l=e=>a().createElement("svg",o({width:24,height:24,viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},e),a().createElement("path",{d:"M14 11v-1a1 1 0 011-1h4a1 1 0 011 1v4a1 1 0 01-1 1h-4a1 1 0 01-1-1v-1h-3v1a1 1 0 01-1 1H6a1 1 0 01-1-1v-4a1 1 0 011-1h4a1 1 0 011 1v1h3z",fill:"#000",stroke:"none",strokeWidth:1,fillRule:"evenodd"}))}}]);
1
+ "use strict";(self.webpackChunk_reltio_remotes=self.webpackChunk_reltio_remotes||[]).push([[3118],{7785:(e,t,n)=>{n.d(t,{Z:()=>k});var r=n(24328),a=n.n(r),o=n(71153),l=n.n(o),i=n(87918),s=n.n(i),c=n(38402),p=n(94079),u=n(95613),d=n(16657),h=n(83348),m=n(55299),g=n(31276),f=n(71543);function b(){return b=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},b.apply(this,arguments)}const x=e=>a().createElement("svg",b({width:24,height:24,viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},e),a().createElement("path",{d:"M10 18h3v-1a1 1 0 011-1h4a1 1 0 011 1v4a1 1 0 01-1 1h-4a1 1 0 01-1-1v-1H8V8H6a1 1 0 01-1-1V3a1 1 0 011-1h6a1 1 0 011 1v4a1 1 0 01-1 1h-2v3h3v-1a1 1 0 011-1h4a1 1 0 011 1v4a1 1 0 01-1 1h-4a1 1 0 01-1-1v-1h-3v5z",fill:"#000",stroke:"none",strokeWidth:1,fillRule:"evenodd"}));function v(){return v=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},v.apply(this,arguments)}const y=e=>a().createElement("svg",v({width:24,height:24,viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},e),a().createElement("rect",{fill:"#000",x:9,y:9,width:6,height:6,rx:1,stroke:"none",strokeWidth:1,fillRule:"evenodd"})),C=(0,n(79692).Z)({container:{"& > $marginWrapper:first-child":{paddingLeft:"4px"}},listItem:{paddingLeft:"1px",paddingTop:"2px",paddingBottom:"2px",transition:"none","&:hover":{"& $itemAfter":{background:"linear-gradient(to right, rgba(235, 235, 235, 0.2), rgba(235, 235, 235, 1) 100%)"}},"&$listItemFocus":{"& $itemAfter":{background:"linear-gradient(to right, rgba(219, 219, 219, 0.2), rgba(219, 219, 219, 1) 100%)"}},"&:focus":{outline:"none"}},listItemFocus:{},icon:{opacity:.29,width:"16px",height:"16px",flexShrink:0,marginRight:"6px",marginLeft:"8px"},recommendedIcon:{width:"18px",height:"18px",marginRight:"5px",marginLeft:"7px",flexShrink:0},logoIcon:{width:"18px",height:"18px",flexShrink:0,marginRight:"4px"},itemAfter:{position:"absolute",right:0,top:0,width:"40px",height:"100%",pointerEvents:"none",background:"linear-gradient(to right, rgba(255, 255, 255, 0.2), #fff 100%)"},itemText:{padding:"0",margin:0,"& span":{fontSize:"0.8125rem",letterSpacing:"normal",whiteSpace:"nowrap"}},checkbox:{opacity:.34,padding:0,marginLeft:"14px","&$checked":{opacity:1,background:"none"}},checked:{},marginWrapper:{display:"flex",alignItems:"center"},defaultCursor:{cursor:"default"},itemTooltip:{margin:"4px 0"},marginText:{marginLeft:"21px"},itemTextWrapper:{display:"flex",alignItems:"center"}}),w=e=>{let{attrType:t={}}=e;const n=C(),r=(e=>{switch(e.type){case d.oS0.TYPE_IMAGE:case d.oS0.TYPE_NESTED:return f.Z;case d.oS0.TYPE_REFERENCE:return x;default:return y}})(t);return a().createElement(r,{className:n.icon})};var O=n(31269);function I(){return I=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},I.apply(this,arguments)}const E=(0,h.Z)((e=>a().createElement("svg",I({width:13,height:18,viewBox:"0 0 13 18",xmlns:"http://www.w3.org/2000/svg"},e),a().createElement("g",{transform:"translate(-3 -1)",stroke:"none",strokeWidth:1,fill:"none",fillRule:"evenodd"},a().createElement("path",{fill:"#FF4081",d:"M5.833 10h3.75v6.667l-3.75 1.666z"}),a().createElement("path",{fill:"#CE0C4E",d:"M13.333 10v8.333l-3.75-1.666V10z"}),a().createElement("circle",{fill:"#FFC058",cx:9.583,cy:7.917,r:6.25}),a().createElement("circle",{fill:"#FFCD7B",cx:9.583,cy:7.917,r:5.417}),a().createElement("path",{fill:"#FFFBB5",d:"M8.333 11.667L5 8.462l.933-.898 2.4 2.308L13.4 5l.933.897z"}))))),k=(0,r.memo)((e=>{let{groupId:t,data:n,checked:r=!1,isFocused:o=!1,isRequired:i=!1,label:h,labelInText:f,level:b,onClick:x=g.ZT,hideCheckBox:v=!1,hideIcon:y=!1,notSelectable:I=!1,disableHorizontalScrollbar:k=!1,style:P={},subItemMargin:S=20,LogoIcon:j,className:T}=e;const L=C(),{attrType:Z}=n||{},R=!(v&&(0,d.QZu)(Z)||I),N=!!j;return a().createElement(u.Z,{value:f||h,className:L.itemTooltip,placement:"bottom-end"},a().createElement(c.Z,{className:l()(L.container,L.listItem,{[L.defaultCursor]:!R},T),onClick:R?()=>x(n,!r,t):void 0,style:P,dense:!0,button:R,classes:{focusVisible:L.listItemFocus,selected:L.listItemFocus},selected:o,tabIndex:-1},!v&&a().createElement(p.Checkbox,{checked:r,disableRipple:!0,disabled:!R,className:l()(L.checkbox,{[L.checked]:r}),tabIndex:-1}),a().createElement(O.Z,{margin:S,level:b,className:L.marginWrapper},a().createElement(a().Fragment,null,!y&&(e=>"recommended"===t?a().createElement(E,{className:L.recommendedIcon,tooltipTitle:s().text("Recommended"),showForDisabled:!0}):a().createElement(w,{attrType:e}))(Z),a().createElement("div",{className:l()(L.itemTextWrapper,{[L.marginText]:y})},N&&a().createElement(j,{className:L.logoIcon}),a().createElement(p.ListItemText,{primary:a().createElement(a().Fragment,null,h,i&&a().createElement(m.Z,null)),className:L.itemText})))),R&&k&&a().createElement("div",{className:L.itemAfter})))}))},24737:(e,t,n)=>{n.d(t,{Z:()=>W});var r=n(24328),a=n.n(r),o=n(13980),l=n.n(o),i=n(71153),s=n.n(i),c=n(17440),p=n(94113),u=n(65549),d=n(79692);const h=(0,d.Z)((e=>({addLabel:{display:"flex",padding:"0 7px",height:"35px",alignItems:"center",fontSize:"13px",fontWeight:"500",color:e.palette.primary.main,cursor:"pointer",textOverflow:"ellipsis",overflow:"hidden",whiteSpace:"nowrap",borderTop:"solid 1px rgba(0, 0, 0, 0.14)",backgroundColor:"rgba(0, 0, 0, 0.03)"},addIcon:{height:"18px",width:"18px",padding:"0 9px"}}))),m=(0,d.Z)({singleValue:{fontSize:"14px",lineHeight:"16px",whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",marginTop:"21px"}});var g=n(36179);const f=e=>{const{selectProps:{onCreate:t,createLabel:n,inputValue:r,components:o},children:l}=e,i=h();return a().createElement(g.Z,e,l,n&&!(0,c.prop)("Group",o)&&a().createElement("span",{className:i.addLabel,onClick:()=>t(r)},a().createElement(u.Z,{className:i.addIcon}),n))};f.propTypes={children:l().element.isRequired,selectProps:l().object.isRequired};const b=f;var x=n(18461),v=n(5190),y=n(31276),C=n(16657),w=n(72436),O=n(94079);function I(){return I=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},I.apply(this,arguments)}function E(e){const{selectProps:{menuIsOpen:t},innerProps:n,children:r}=e,o=m();return!t&&a().createElement(O.Typography,I({className:o.singleValue},n),r)}function k(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),r.forEach((function(t){P(e,t,n[t])}))}return e}function P(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}E.propTypes={children:l().node,innerProps:l().object};const S=(0,d.Z)({control:{height:"auto"},dropdownIndicator:{boxSizing:"content-box",transition:"transform .15s ease",padding:e=>(e.height-24)/2+"px 12px",cursor:"pointer",color:"rgba(0, 0, 0, 0.54)"},valueContainer:{marginLeft:"16px",width:0},formControl:{margin:0},filledInputRoot:{backgroundColor:"rgba(0, 0, 0, 0.03)","&:hover":{backgroundColor:"rgba(0, 0, 0, 0.03)"},"&.focused":{backgroundColor:"rgba(0, 0, 0, 0.03)"}},filledInputUnderline:{"&:before":{display:"none"}},inputLabel:{color:"rgba(0,0,0,0.6)",fontSize:"14px",lineHeight:"16px",paddingLeft:"4px","&.shrink":{paddingLeft:"4px"}}}),j={menu:e=>k({},e,{borderRadius:"0 0 4px 4px",backgroundColor:"#FFFFFFFF",boxShadow:"0 2px 2px 0 rgba(0,0,0,0.14), 0 3px 1px -2px rgba(0,0,0,0.12), 0 1px 5px 0 rgba(0,0,0,0.2)",margin:0}),menuList:e=>k({},e,{maxHeight:"208px",padding:"8px 0"}),group:e=>k({},e,{padding:"0 0 8px 0"}),input:e=>k({},e,{height:"16px",color:"rgba(0, 0, 0, 0.87)",fontSize:"14px",lineHeight:"16px",margin:"16px 0 0",padding:0}),option:e=>k({},e,{fontSize:"13px",lineHeight:"15px",height:"32px"})},T={menuList:e=>k({},e,{padding:0})},L={input:e=>k({},e,{height:"16px",color:"rgba(0, 0, 0, 0.87)",fontSize:"14px",lineHeight:"16px",margin:0,padding:0})};function Z(){return Z=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Z.apply(this,arguments)}function R(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),r.forEach((function(t){N(e,t,n[t])}))}return e}function N(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const F=e=>{let{value:t,label:n,createLabel:o,getOptions:l,options:i,height:u=46,onChange:d=c.identity,onCreate:h,onClear:m=c.identity,components:g,textFieldInputRef:f,TextFieldProps:O,classes:I}=e,k=function(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}(e,["value","label","createLabel","getOptions","options","height","onChange","onCreate","onClear","components","textFieldInputRef","TextFieldProps","classes"]);const P=S({height:u}),N=(0,w.a6)(),[F,z]=(0,r.useState)(!1),W=(0,r.useRef)(null),D=l?x.Z:v.Z,B=(0,c.prop)("ClearIndicator",g)?{}:{IndicatorSeparator:y.Vd,ClearIndicator:y.Vd},H=h?(e,t)=>{h(e,t),z(!1)}:void 0,M=(0,c.prop)("Group",g)?T:{},A=(0,c.isEmpty)(n)?L:{},U=R({},j,M,A),V=R({},P,I);return a().createElement(D,Z({placeholder:"",defaultOptions:!0},k,{value:(0,c.defaultTo)(null,t),loadOptions:l,options:i,cacheOptions:!0,onChange:d,onCreate:H,onClear:m,createLabel:o,classes:V,styles:U,components:R({DropdownIndicator:p.Z,LoadingIndicator:y.Vd,SingleValue:E,Menu:b},B,g),menuPlacement:"auto",TextFieldProps:R({},O,{label:n,variant:"filled",margin:"dense",classes:R({},(0,c.prop)("classes",O),{root:s()(P.formControl,(0,c.path)(["classes","root"],O))}),inputProps:R({},(0,c.prop)("inputProps",O)),InputProps:R({},(0,c.prop)("InputProps",O),{classes:R({},(0,c.path)(["InputProps","classes"],O),{root:s()(P.filledInputRoot,(0,c.path)(["InputProps","classes","root"],O)),underline:s()({[N.filledInputUnderline]:(0,C.O27)(t)},(0,c.path)(["InputProps","classes","underline"],O)),focused:s()("focused",(0,c.path)(["InputProps","classes","focused"],O))})}),InputLabelProps:R({},(0,c.prop)("InputLabelProps",O),{classes:R({},(0,c.path)(["InputLabelProps","classes"],O),{root:s()(P.inputLabel,(0,c.path)(["InputLabelProps","classes","root"],O)),shrink:s()("shrink",(0,c.path)(["InputLabelProps","classes","shrink"],O))}),shrink:!(0,C.O27)(t)||void 0}),ref:f||W}),inputRef:f||W,menuIsOpen:F,onMenuOpen:()=>z(!0),onMenuClose:()=>z(!1)}))},z={value:l().oneOfType([l().object,l().array]),label:l().string.isRequired,getOptions:l().func,options:l().array,onChange:l().func,onCreate:l().func,onClear:l().func,createLabel:l().string,components:l().object,textFieldInputRef:l().object,TextFieldProps:l().object,height:l().number,classes:l().object};F.propTypes=z;const W=F},53180:(e,t,n)=>{n.d(t,{Z:()=>u});var r=n(24328),a=n.n(r),o=n(52730),l=n(71153),i=n.n(l),s=n(94079),c=n(16657),p=n(49885);const u=e=>{let{entity:t,avatarClassName:n,imageClassName:r}=e;const l=(0,o.useSelector)(p.ZP.selectors.getMetadata),u=(0,o.useSelector)(p.ZP.selectors.getAbsoluteImagePath)||"",d=(0,c.uie)(l,u,t),h=(0,c.vPL)(u,(0,c.XH2)(l,t.type)),m=e=>{e.target.onError=null,e.target.src=(0,c.m5F)('\n<svg width="400px" height="400px" viewBox="0 0 400 400" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">\n <title>Group</title>\n <g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">\n <g id="Group" fill-rule="nonzero">\n <rect id="Rectangle" fill="#DFE5E9" x="0" y="0" width="400" height="400"></rect>\n <path d="M0,387.023257 L0,399.918908 L400,399.918908 L400,386.023594 C366.631,377.336524 321.866,364.269931 315.979,359.161654 C308.985,353.083704 270.481,310.508063 270.481,310.508063 L270.481,286.186267 C270.481,286.186267 284.478,266.204006 284.478,261.854473 C284.478,257.515936 285.353,246.219746 291.481,241.011503 C297.61,235.792263 311.607,211.471466 312.481,206.253226 C313.355,201.043983 319.484,188.009379 312.481,185.400259 C305.478,182.801135 307.236,173.244359 308.984,168.026119 C310.733,162.817875 319.484,139.355788 322.981,133.277838 C326.488,127.199888 312.481,108.956041 312.481,108.956041 C312.481,108.956041 294.978,80.2857109 245.975,53.3547939 C196.971,26.4138803 168.967,42.9283105 168.967,42.9283105 L161.964,60.3024507 C161.964,60.3024507 138.341,64.6409874 123.46,77.6765909 C108.589,90.7121943 99.837,106.346921 98.963,115.903698 C98.088,125.460475 103.334,159.339048 105.966,164.557289 C108.589,169.765532 112.96,185.400259 112.96,185.400259 C112.96,185.400259 108.589,183.670842 105.966,188.879085 C103.334,194.097325 112.085,218.419122 112.96,220.159535 C113.834,221.897949 114.718,238.403382 119.963,237.532676 C125.218,236.663969 130.463,251.42799 130.463,251.42799 C130.463,251.42799 143.596,271.41125 144.47,275.759783 C145.344,280.09832 147.967,307.039233 147.967,307.039233 L126.967,331.36103 L102.46,355.682827 C102.459,355.682827 34.042,375.886013 0,387.023257 Z" id="Path" fill="#B3BCC4"></path>\n <path d="M0,387.023257 L0,399.918908 L400,399.918908 L400,386.023594 C366.631,377.336524 321.866,364.269931 315.979,359.161654 C308.985,353.083704 270.481,310.508063 270.481,310.508063 L270.481,286.186267 C270.481,286.186267 284.478,266.204006 284.478,261.854473 C284.478,257.515936 285.353,246.219746 291.481,241.011503 C297.61,235.792263 311.607,211.471466 312.481,206.253226 C313.355,201.043983 319.484,188.009379 312.481,185.400259 C305.478,182.801135 307.236,173.244359 308.984,168.026119 C310.733,162.817875 319.484,139.355788 322.981,133.277838 C326.488,127.199888 312.481,108.956041 312.481,108.956041 C312.481,108.956041 294.978,80.2857109 245.975,53.3547939 C196.971,26.4138803 168.967,42.9283105 168.967,42.9283105 L161.964,60.3024507 C161.964,60.3024507 138.341,64.6409874 123.46,77.6765909 C108.589,90.7121943 99.837,106.346921 98.963,115.903698 C98.088,125.460475 103.334,159.339048 105.966,164.557289 C108.589,169.765532 112.96,185.400259 112.96,185.400259 C112.96,185.400259 108.589,183.670842 105.966,188.879085 C103.334,194.097325 112.085,218.419122 112.96,220.159535 C113.834,221.897949 114.718,238.403382 119.963,237.532676 C125.218,236.663969 130.463,251.42799 130.463,251.42799 C130.463,251.42799 143.596,271.41125 144.47,275.759783 C145.344,280.09832 147.967,307.039233 147.967,307.039233 L126.967,331.36103 L102.46,355.682827 C102.459,355.682827 34.042,375.886013 0,387.023257 Z" id="Path" fill="#B3BCC4"></path>\n <path d="M5.68434189e-14,387.023257 L5.68434189e-14,399.918908 L400,399.918908 L400,386.023594 C366.631,377.336524 321.866,364.269931 315.979,359.161654 C308.985,353.083704 270.481,310.508063 270.481,310.508063 L270.481,286.186267 C270.481,286.186267 284.478,266.204006 284.478,261.854473 C284.478,257.515936 285.353,246.219746 291.481,241.011503 C297.61,235.792263 311.607,211.471466 312.481,206.253226 C313.355,201.043983 319.484,188.009379 312.481,185.400259 C305.478,182.801135 307.236,173.244359 308.984,168.026119 C310.733,162.817875 319.484,139.355788 322.981,133.277838 C326.488,127.199888 312.481,108.956041 312.481,108.956041 C312.481,108.956041 294.978,80.2857109 245.975,53.3547939 C196.971,26.4138803 168.967,42.9283105 168.967,42.9283105 L161.964,60.3024507 C161.964,60.3024507 138.341,64.6409874 123.46,77.6765909 C108.589,90.7121943 99.837,106.346921 98.963,115.903698 C98.088,125.460475 103.334,159.339048 105.966,164.557289 C108.589,169.765532 112.96,185.400259 112.96,185.400259 C112.96,185.400259 108.589,183.670842 105.966,188.879085 C103.334,194.097325 112.085,218.419122 112.96,220.159535 C113.834,221.897949 114.718,238.403382 119.963,237.532676 C125.218,236.663969 130.463,251.42799 130.463,251.42799 C130.463,251.42799 143.596,271.41125 144.47,275.759783 C145.344,280.09832 147.967,307.039233 147.967,307.039233 L126.967,331.36103 L102.46,355.682827 C102.459,355.682827 34.042,375.886013 5.68434189e-14,387.023257 Z" id="Path" fill="#B3BCC4"></path>\n </g>\n </g>\n</svg>\n')};return a().createElement(s.Avatar,{className:i()(n,r),src:d,imgProps:{onError:m}},a().createElement("img",{className:r,src:h,alt:"fallback entity avatar",onError:m}))}},34e3:(e,t,n)=>{n.d(t,{Z:()=>c});var r=n(24328),a=n.n(r),o=n(52730),l=n(49885),i=n(98018);function s(){return s=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},s.apply(this,arguments)}const c=e=>{const t=(0,o.useSelector)(l.ZP.selectors.getAbsoluteImagePath)||"";return a().createElement(i.ZP,s({},e,{storagePath:(n=t,n.endsWith("/")?n:n+"/")}));var n}},31039:(e,t,n)=>{n.d(t,{Z:()=>p});var r=n(24328),a=n.n(r),o=n(52730),l=n(39450),i=n(72383),s=n(49885);const c=(0,r.forwardRef)(((e,t)=>{let{value:n,children:c,screen:p,className:u}=e;const d=(0,o.useDispatch)(),h=(0,r.useContext)(l.m),{generateEntityUrl:m}=(0,r.useContext)(i.v),g=(0,o.useSelector)(s.ZP.selectors.getUIPath),f=(0,r.useCallback)((()=>{d(s.ui.actions.openEntity({uri:n,viewId:h,screen:p}))}),[h,n,d,p]);return a().createElement("a",{ref:t,href:(b=n,m({uiPath:g,uri:b,screen:p})),onClick:e=>{f(),e.stopPropagation(),e.preventDefault()},className:u},c);var b}));c.displayName="EntityUriLink";const p=c},99136:(e,t,n)=>{n.d(t,{Z:()=>c});var r=n(24328),a=n.n(r),o=n(71153),l=n.n(o),i=n(94079);const s=(0,n(79692).Z)({loadingOverlay:{position:"absolute",width:"100%",height:"100%",top:0,left:0,opacity:.37,zIndex:10,backgroundColor:"#fff"},transparent:{backgroundColor:"transparent"},relativePosition:{"&$loadingOverlay":{position:"relative"}}}),c=e=>{let{transparent:t=!1,relativePosition:n=!1,className:r}=e;const o=s();return a().createElement(a().Fragment,null,a().createElement("div",{className:l()(o.loadingOverlay,r,{[o.transparent]:t,[o.relativePosition]:n})},a().createElement(i.LinearProgress,{color:"primary"})))}},83401:(e,t,n)=>{n.d(t,{Z:()=>h});var r=n(24328),a=n.n(r),o=n(94079),l=n(71153),i=n.n(l),s=n(83348),c=n(79692),p=n(41128);const u=(0,c.Z)((e=>({button:{minWidth:"30px",padding:"8px 8px",justifyContent:"start",fill:"rgba(0,0,0,0.54)",textTransform:"none",borderColor:"rgba(0,0,0,0.12)"},icon:{color:"rgba(0,0,0,0.54)",width:"20px",height:"20px","& + $title":{marginLeft:"8px"}},title:{fontSize:"13px",lineHeight:"15px",letterSpacing:0},current:{"& $icon":{color:e.palette.primary.main},backgroundColor:(0,p.U1)(e.palette.primary.main,.12),fill:e.palette.primary.main,color:e.palette.primary.main,"&:hover":{backgroundColor:(0,p.U1)(e.palette.primary.main,.24)}}}))),d=(0,s.Z)(o.Button),h=e=>{let{className:t,classes:n={},modes:r=[],modeId:l,onChange:s}=e;const c=u();return a().createElement(o.ButtonGroup,{className:t},r.map((e=>{let{id:t,title:r,tooltipTitle:o,Icon:p,disabled:u}=e;return a().createElement(d,{disabled:u,showForDisabled:u&&!!o,key:String(t),className:i()(c.button,{[c.current]:l===t},n.button),tooltipTitle:o,onClick:(h=t,()=>s(h)),"data-reltio-id":`reltio-search-mode-${t}`},p&&a().createElement(p,{className:c.icon}),r&&a().createElement("div",{className:c.title},r));var h})))}},18461:(e,t,n)=>{n.d(t,{Z:()=>a});var r=n(27308);const a=(0,n(5407).Z)(r.ZP)},55299:(e,t,n)=>{n.d(t,{Z:()=>l});var r=n(24328),a=n.n(r);const o=(0,n(79692).Z)({mark:{color:"red"}}),l=()=>{const e=o();return a().createElement("span",{className:e.mark},"*")}},94574:(e,t,n)=>{n.d(t,{Z:()=>y});var r=n(71153),a=n.n(r),o=n(17440),l=n(24328),i=n.n(l),s=n(87918),c=n.n(s),p=n(29611),u=n(94079),d=n(87685),h=n(21853),m=n(31276),g=n(22385),f=n(63015);function b(){return b=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},b.apply(this,arguments)}function x(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),r.forEach((function(t){v(e,t,n[t])}))}return e}function v(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const y=(0,l.memo)((e=>{let{value:t,autofocus:n,onSearch:r=m.ZT,rootRef:s,classes:v={},height:y,placeholder:C=c().text("Search")}=e,w=function(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}(e,["value","autofocus","onSearch","rootRef","classes","height","placeholder"]);const O=(0,f.y)({height:y}),[I,E]=(0,l.useState)(""),k=(0,o.pipe)((0,o.tap)(r),E),P=(0,o.isNil)(t)?I:t;return i().createElement(p.Z,b({startAdornment:i().createElement(u.InputAdornment,{position:"start"},i().createElement(h.default,{className:O.icon})),endAdornment:i().createElement(u.InputAdornment,{position:"end"},P.length>0&&i().createElement(g.Z,{icon:d.default,className:O.clearButton,onClick:()=>k("")})),autoFocus:n,classes:x({},v,{input:a()(O.input,v.input),root:a()(O.container,v.root)}),placeholder:C,value:P,onChange:(0,o.pipe)(m.NA,k),disableUnderline:!0,ref:s},w))}))},63015:(e,t,n)=>{n.d(t,{y:()=>r});const r=(0,n(79692).Z)((()=>({container:e=>{let{height:t=36}=e;return{height:t,borderRadius:"2px",alignItems:"center",backgroundColor:"rgba(0,0,0,0.03)",minWidth:"100px"}},icon:{opacity:.67,marginLeft:"10px",marginRight:"6px"},input:{fontSize:"13px",width:"100%"},clearButton:{marginRight:"10px"},white:{backgroundColor:"rgb(255, 255, 255)",boxShadow:"0 1px 3px 0 rgba(0,0,0,0.24)"}})))},97820:(e,t,n)=>{n.d(t,{Z:()=>h});var r=n(24328),a=n.n(r),o=n(71153),l=n.n(o),i=n(87918),s=n.n(i),c=n(79784),p=n(25480),u=n(94574);function d(){return d=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},d.apply(this,arguments)}const h=e=>{let{title:t,className:n,onSearch:r,hideTitle:o,hideSearchInput:i,headerPlacement:h="top",containerWidth:m,containerHeight:g,searchInputOnKeyDown:f,children:b,searchInputRef:x,anchorOrigin:v={vertical:"top",horizontal:"right"},transformOrigin:y={vertical:"top",horizontal:"right"}}=e,C=function(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}(e,["title","className","onSearch","hideTitle","hideSearchInput","headerPlacement","containerWidth","containerHeight","searchInputOnKeyDown","children","searchInputRef","anchorOrigin","transformOrigin"]);const w=(0,p.Z)({containerWidth:m,containerHeight:g}),O=a().createElement(a().Fragment,null,!o&&a().createElement("div",{className:w.header},t),!i&&a().createElement(u.Z,{onSearch:r,autofocus:!0,onKeyDown:f,inputRef:x,classes:{root:w.searchInputContainer},placeholder:s().text("Search & add attributes"),height:40}));return a().createElement(c.ZP,d({anchorOrigin:v,transformOrigin:y},C),a().createElement("div",{className:l()(w.container,n),style:{width:m}},"top"===h&&O,a().createElement("div",{className:w.list},b),"bottom"===h&&O))}},54763:(e,t,n)=>{n.d(t,{t:()=>l});var r=n(24328),a=n(17440),o=n(44890);const l=e=>{let{items:t,open:n,onSelectFocusedItem:l,selectedItems:i,onClose:s}=e;const[c,p]=(0,r.useState)(null),u=(0,r.useRef)(!1),d=(0,r.useCallback)((e=>{let n=null===e?d(-1):e;for(;null!==e&&n<t.length&&(n<=e||n>=0&&(0,o.c)(t[n]));)n+=1;return n!==t.length?n:d(-1)}),[t]),h=(0,r.useCallback)((e=>{let n=null===e?t.length-1:e;for(;null!==e&&n>=0&&(n>=e||(0,o.c)(t[n]));)n-=1;return n<0?t.length-1:n}),[t]),m=(0,r.useCallback)((()=>{if(!(0,a.isNil)(c)){const e=t[c].item;!e.item.notSelectable&&l({item:e.item,groupData:e})}}),[l,t,c]),g=(0,r.useCallback)((e=>{if(0!==t.length)switch(e.key){case"Down":case"ArrowDown":return p(d),e.preventDefault(),!1;case"Up":case"ArrowUp":return p(h),e.preventDefault(),!1;case"Enter":u.current=!0,m();break;case"Tab":s&&s(e);break;default:return}}),[t,d,h,m,s]);return(0,r.useEffect)((()=>{if(u.current){u.current=!1;const e=t.findIndex((e=>e.item.moveTo));e>-1&&p(e)}else p(null)}),[t,n,i]),{focusIndex:c,handleKeyDown:g}}},25480:(e,t,n)=>{n.d(t,{Z:()=>a});var r=n(79692);const a=(0,r.Z)((()=>({container:e=>{let{containerHeight:t=553,containerWidth:n}=e;return{display:"flex",flexDirection:"column",height:t,width:n,flexGrow:1}},header:{marginLeft:"16px",marginTop:"16px",marginBottom:"12px",fontSize:"16px",fontWeight:500,letterSpacing:"0.15px",lineHeight:"24px"},searchInputContainer:{margin:"0 16px 12px 16px",flexShrink:"0"},list:{flexGrow:1,height:0,overflow:"hidden",width:"100%",position:"relative","& ul":{paddingBottom:0,paddingTop:0}}})))},31517:(e,t,n)=>{n.d(t,{Z:()=>f});var r=n(24328),a=n.n(r),o=n(24737),l=n(13980),i=n.n(l),s=n(94079);const c=(0,n(79692).Z)({value:{color:"rgba(0, 0, 0, 0.87)"},placeholder:{color:"rgba(0, 0, 0, 0.38)",fontSize:"14px !important"}}),p=e=>{let{selectProps:{menuIsOpen:t},data:{label:n}}=e;const r=c();return!t&&a().createElement(s.Typography,{variant:"body2",classes:{root:r.value}},n)};p.propTypes={selectProps:i().shape({menuIsOpen:i().bool}),data:i().shape({label:i().string})};const u=p;function d(){return d=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},d.apply(this,arguments)}const h=e=>{const t=c(),{innerProps:n={},children:r}=e;return a().createElement(s.Typography,d({className:t.placeholder},n),r)};function m(){return m=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},m.apply(this,arguments)}h.propTypes={children:i().node,innerProps:i().object,selectProps:i().object.isRequired};const g={SingleValue:u,Placeholder:h},f=(0,r.memo)((e=>{let t=m({},e);return a().createElement(o.Z,m({components:g},t))}))},44890:(e,t,n)=>{n.d(t,{Z:()=>h,c:()=>u});var r=n(24328),a=n.n(r),o=n(13980),l=n.n(o),i=n(50166),s=n(44443);const c=(0,n(79692).Z)({stickyTitlesWrapper:{position:"absolute",top:0,"& > div":{zIndex:1,position:"absolute",top:0,width:"100%",visibility:"hidden"}}});var p=n(56656);const u=e=>e.titleItemIndex===e.index,d=e=>{let{items:t,getItemSize:n,renderItem:o,renderGroupTitle:l,width:d="100%",height:h,fixedTitle:m=!0,itemKey:g=(e=>e),disableHorizontalScrollbar:f,hideSubtitles:b,focusIndex:x=null,onInnerContainerResize:v}=e;const y=c(),C=(0,r.useRef)(null),w=(0,r.useRef)(null),O=(0,r.useRef)(null),I=(0,r.useRef)([0]),E={topMargin:0},k=(0,r.useMemo)((()=>!b||(t||[]).some((e=>null!==e.titleItemIndex))),[t,b]),P=(0,r.useCallback)((e=>{const r=I.current.length;let a=0;t.slice(r-1,e+1).forEach(((e,t)=>{const o=r+t-1;t>0&&(I.current[o]=I.current[o-1]+a),a=n(o,e.item)}))}),[n,t]),S=(0,r.useCallback)((e=>t[e].titleItemIndex),[t]),j=(0,r.useCallback)((e=>t[e]),[t]);(0,r.useEffect)((()=>{requestAnimationFrame((()=>{C.current&&C.current.scrollTo(0)}))}),[t.length]),(0,r.useEffect)((()=>{C.current&&C.current.resetAfterIndex(0),T();const e=(e=>{const t=e.findIndex((e=>e.item.moveTo));if(t>-1){P(t);const e=S(t);return{offset:I.current[t],titleHeight:n(e,j(e).item)}}})(t);if(e&&e.offset&&C.current){const{titleHeight:t}=e,n=e.offset-t;(n<C.current.state.scrollOffset||n>C.current.state.scrollOffset+h)&&requestAnimationFrame((()=>{C.current&&C.current.scrollTo(n-(h-t)/2)}))}}),[P,j,n,S,h,I,t,C]);const T=()=>{O.current&&w.current&&(O.current.style.width=w.current.offsetWidth+"px")},L=(0,r.useCallback)((e=>{let n=null,r=0;return t.some(((t,a)=>{P(a+10);const o=I.current[a+1];return e>=r&&e<o&&(n={index:a,offset:r,listItem:t}),r=o,n})),n}),[P,I,t]),Z=(0,r.useCallback)((e=>n(e,j(e).item)),[j,n]),R=(0,r.useCallback)((e=>{let{index:t,style:n,data:r}=e;const a=j(t);return a.item&&(u(a)&&l(n,a.item)||o(n,a.item,t,r))}),[j,l,o]),{handleOnItemsRendered:N}=(0,p.LW)({items:t,focusIndex:x,listRef:C}),F=(0,r.useCallback)((()=>t.filter((e=>u(e))).map((e=>(e=>a().createElement("div",{className:"stickyTitleItem",style:{visibility:"hidden"},"data-index":e.index,key:e.index},l({height:n(e.index,e.item)},e.item)))(e)))),[n,t,l]);return a().createElement(a().Fragment,null,a().createElement("div",{ref:O,className:y.stickyTitlesWrapper},m&&F()),v&&w.current&&a().createElement(s.Z,{handleHeight:!0,onResize:v,targetDomEl:w.current}),a().createElement(i.VariableSizeList,{ref:C,itemCount:t.length,itemSize:Z,width:d,height:h,itemKey:g,innerRef:w,onScroll:e=>{let{scrollOffset:r,scrollDirection:a}=e;if(!m||!k)return;const o=L(r),l=o&&S(o.index);var i;null!==l&&(i=l,O.current&&[...O.current.querySelectorAll(".stickyTitleItem")].forEach((e=>{e.dataset.index===i.toString()?(e.style.visibility="visible",E.index=i):e.style.visibility="hidden"}))),T();const s=null!==l&&n(l,j(l).item),c=L(r+s+E.topMargin);let p=0;if(c){switch(a){case"forward":c.offset-r>0&&u(c.listItem)&&(p=s-(c.offset-r));break;case"backward":{const e=l>-1&&(d=l,t.findIndex(((e,t)=>u(e)&&d<t))),n=(e=>(P(e),I.current[e]))(e);e>-1&&r<n&&s>=n-r&&(p=s-(n-r))}}(e=>{O.current&&(E.topMargin=-e,O.current.style.top=-e+"px")})(p)}var d},style:f?{overflowX:"hidden"}:void 0,overscanCount:5,onItemsRendered:N},R))};d.propTypes={items:l().arrayOf(l().object).isRequired,getItemSize:l().func.isRequired,renderItem:l().func.isRequired,width:l().oneOfType([l().number,l().string]),height:l().number.isRequired,renderGroupTitle:l().func,fixedTitle:l().bool,hideSubtitles:l().bool,itemKey:l().func,disableHorizontalScrollbar:l().bool,focusIndex:l().number,onInnerContainerResize:l().func};const h=d},56656:(e,t,n)=>{n.d(t,{LG:()=>o,LW:()=>l});var r=n(17440),a=n(24328);const o=e=>{const t=e=>(0,r.flatten)(e.map((e=>[e].concat(e.items?t(e.items):[]))));let n=null;return t(e).map(((e,t)=>(e&&e.items&&(n=t),{item:e,index:t,titleItemIndex:n})))},l=e=>{let{focusIndex:t,listRef:n,items:r}=e;const o=(0,a.useRef)(null),l=(0,a.useRef)(null),i=(0,a.useCallback)((e=>{let{visibleStartIndex:t,visibleStopIndex:n}=e;o.current=t,l.current=n}),[]);return(0,a.useEffect)((()=>{n.current&&null!==t&&0!==r.length&&(t<Math.max(o.current+3,0)?n.current.scrollToItem(Math.max(t-3,0),"start"):t>Math.min(l.current-3,r.length-1)&&n.current.scrollToItem(Math.min(t+3,r.length-1),"end"))}),[t,r.length,n]),{handleOnItemsRendered:i}}},72383:(e,t,n)=>{n.d(t,{v:()=>l});var r=n(24328),a=n.n(r),o=n(16657);const l=a().createContext({generateEntityUrl:o.OuZ,generatePivotingUrl:o.FQ2,generateTagUrl:o.W$R});l.displayName="UrlGeneratorsContext"},39450:(e,t,n)=>{n.d(t,{m:()=>a});var r=n(24328);const a=n.n(r)().createContext(null);a.displayName="ViewIdContext"},71543:(e,t,n)=>{n.d(t,{Z:()=>l});var r=n(24328),a=n.n(r);function o(){return o=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},o.apply(this,arguments)}const l=e=>a().createElement("svg",o({width:24,height:24,viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},e),a().createElement("path",{d:"M14 11v-1a1 1 0 011-1h4a1 1 0 011 1v4a1 1 0 01-1 1h-4a1 1 0 01-1-1v-1h-3v1a1 1 0 01-1 1H6a1 1 0 01-1-1v-4a1 1 0 011-1h4a1 1 0 011 1v1h3z",fill:"#000",stroke:"none",strokeWidth:1,fillRule:"evenodd"}))}}]);
2
2
  //# sourceMappingURL=3118.js.map
package/3270.js CHANGED
@@ -1,2 +1,2 @@
1
- "use strict";(self.webpackChunk_reltio_remotes=self.webpackChunk_reltio_remotes||[]).push([[3270],{8598:(e,t,n)=>{n.d(t,{Z:()=>r});var a=n(95038),o=n.n(a);const r=function(){function e(e){var t=void 0===e?{}:e,n=t.locale,a=t.instance,r=t.moment;this.yearFormat="YYYY",this.yearMonthFormat="MMMM YYYY",this.dateTime12hFormat="MMMM Do hh:mm a",this.dateTime24hFormat="MMMM Do HH:mm",this.time12hFormat="hh:mm A",this.time24hFormat="HH:mm",this.dateFormat="MMMM Do",this.moment=a||r||o(),this.locale=n}return e.prototype.parse=function(e,t){return""===e?null:this.moment(e,t,!0)},e.prototype.date=function(e){if(null===e)return null;var t=this.moment(e);return t.locale(this.locale),t},e.prototype.isValid=function(e){return this.moment(e).isValid()},e.prototype.isNull=function(e){return null===e},e.prototype.getDiff=function(e,t){return e.diff(t)},e.prototype.isAfter=function(e,t){return e.isAfter(t)},e.prototype.isBefore=function(e,t){return e.isBefore(t)},e.prototype.isAfterDay=function(e,t){return e.isAfter(t,"day")},e.prototype.isBeforeDay=function(e,t){return e.isBefore(t,"day")},e.prototype.isBeforeYear=function(e,t){return e.isBefore(t,"year")},e.prototype.isAfterYear=function(e,t){return e.isAfter(t,"year")},e.prototype.startOfDay=function(e){return e.clone().startOf("day")},e.prototype.endOfDay=function(e){return e.clone().endOf("day")},e.prototype.format=function(e,t){return e.locale(this.locale),e.format(t)},e.prototype.formatNumber=function(e){return e},e.prototype.getHours=function(e){return e.get("hours")},e.prototype.addDays=function(e,t){return t<0?e.clone().subtract(Math.abs(t),"days"):e.clone().add(t,"days")},e.prototype.setHours=function(e,t){return e.clone().hours(t)},e.prototype.getMinutes=function(e){return e.get("minutes")},e.prototype.setMinutes=function(e,t){return e.clone().minutes(t)},e.prototype.getSeconds=function(e){return e.get("seconds")},e.prototype.setSeconds=function(e,t){return e.clone().seconds(t)},e.prototype.getMonth=function(e){return e.get("month")},e.prototype.isSameDay=function(e,t){return e.isSame(t,"day")},e.prototype.isSameMonth=function(e,t){return e.isSame(t,"month")},e.prototype.isSameYear=function(e,t){return e.isSame(t,"year")},e.prototype.isSameHour=function(e,t){return e.isSame(t,"hour")},e.prototype.setMonth=function(e,t){return e.clone().month(t)},e.prototype.getMeridiemText=function(e){return"am"===e?"AM":"PM"},e.prototype.startOfMonth=function(e){return e.clone().startOf("month")},e.prototype.endOfMonth=function(e){return e.clone().endOf("month")},e.prototype.getNextMonth=function(e){return e.clone().add(1,"month")},e.prototype.getPreviousMonth=function(e){return e.clone().subtract(1,"month")},e.prototype.getMonthArray=function(e){for(var t=[e.clone().startOf("year")];t.length<12;){var n=t[t.length-1];t.push(this.getNextMonth(n))}return t},e.prototype.getYear=function(e){return e.get("year")},e.prototype.setYear=function(e,t){return e.clone().set("year",t)},e.prototype.mergeDateAndTime=function(e,t){return this.setMinutes(this.setHours(e,this.getHours(t)),this.getMinutes(t))},e.prototype.getWeekdays=function(){return this.moment.weekdaysShort(!0)},e.prototype.isEqual=function(e,t){return null===e&&null===t||this.moment(e).isSame(t)},e.prototype.getWeekArray=function(e){for(var t=e.clone().startOf("month").startOf("week"),n=e.clone().endOf("month").endOf("week"),a=0,o=t,r=[];o.isBefore(n);){var l=Math.floor(a/7);r[l]=r[l]||[],r[l].push(o),o=o.clone().add(1,"day"),a+=1}return r},e.prototype.getYearRange=function(e,t){for(var n=this.moment(e).startOf("year"),a=this.moment(t).endOf("year"),o=[],r=n;r.isBefore(a);)o.push(r),r=r.clone().add(1,"year");return o},e.prototype.getCalendarHeaderText=function(e){return this.format(e,this.yearMonthFormat)},e.prototype.getYearText=function(e){return this.format(e,"YYYY")},e.prototype.getDatePickerHeaderText=function(e){return this.format(e,"ddd, MMM D")},e.prototype.getDateTimePickerHeaderText=function(e){return this.format(e,"MMM D")},e.prototype.getMonthText=function(e){return this.format(e,"MMMM")},e.prototype.getDayText=function(e){return this.format(e,"D")},e.prototype.getHourText=function(e,t){return this.format(e,t?"hh":"HH")},e.prototype.getMinuteText=function(e){return this.format(e,"mm")},e.prototype.getSecondText=function(e){return this.format(e,"ss")},e}()},27604:(e,t,n)=>{var a=n(71600);t.Z=void 0;var o=a(n(24328)),r=(0,a(n(50175)).default)(o.default.createElement("path",{d:"M3 17.25V21h3.75L17.81 9.94l-3.75-3.75L3 17.25zM20.71 7.04c.39-.39.39-1.02 0-1.41l-2.34-2.34a.9959.9959 0 00-1.41 0l-1.83 1.83 3.75 3.75 1.83-1.83z"}),"Edit");t.Z=r},71519:(e,t,n)=>{var a=n(71600);t.Z=void 0;var o=a(n(24328)),r=(0,a(n(50175)).default)(o.default.createElement("path",{d:"M9.31 17l2.44-2.44L14.19 17l1.06-1.06-2.44-2.44 2.44-2.44L14.19 10l-2.44 2.44L9.31 10l-1.06 1.06 2.44 2.44-2.44 2.44L9.31 17zM19 3h-1V1h-2v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V8h14v11z"}),"EventBusy");t.Z=r},99144:(e,t,n)=>{var a=n(71600);t.Z=void 0;var o=a(n(24328)),r=(0,a(n(50175)).default)(o.default.createElement("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z"}),"Info");t.Z=r},67766:(e,t,n)=>{var a=n(71600);t.Z=void 0;var o=a(n(24328)),r=(0,a(n(50175)).default)(o.default.createElement("path",{d:"M15.41 16.59L10.83 12l4.58-4.59L14 6l-6 6 6 6 1.41-1.41z"}),"KeyboardArrowLeft");t.Z=r},42767:(e,t,n)=>{var a=n(71600);t.Z=void 0;var o=a(n(24328)),r=(0,a(n(50175)).default)(o.default.createElement("path",{d:"M8.59 16.59L13.17 12 8.59 7.41 10 6l6 6-6 6-1.41-1.41z"}),"KeyboardArrowRight");t.Z=r},47603:(e,t,n)=>{var a=n(71600);t.Z=void 0;var o=a(n(24328)),r=(0,a(n(50175)).default)(o.default.createElement(o.default.Fragment,null,o.default.createElement("path",{transform:"scale(1.2, 1.2)",fill:"none",d:"M0 0h20v20H0V0z"}),o.default.createElement("path",{transform:"scale(1.2, 1.2)",d:"M15.95 10.78c.03-.25.05-.51.05-.78s-.02-.53-.06-.78l1.69-1.32c.15-.12.19-.34.1-.51l-1.6-2.77c-.1-.18-.31-.24-.49-.18l-1.99.8c-.42-.32-.86-.58-1.35-.78L12 2.34c-.03-.2-.2-.34-.4-.34H8.4c-.2 0-.36.14-.39.34l-.3 2.12c-.49.2-.94.47-1.35.78l-1.99-.8c-.18-.07-.39 0-.49.18l-1.6 2.77c-.1.18-.06.39.1.51l1.69 1.32c-.04.25-.07.52-.07.78s.02.53.06.78L2.37 12.1c-.15.12-.19.34-.1.51l1.6 2.77c.1.18.31.24.49.18l1.99-.8c.42.32.86.58 1.35.78l.3 2.12c.04.2.2.34.4.34h3.2c.2 0 .37-.14.39-.34l.3-2.12c.49-.2.94-.47 1.35-.78l1.99.8c.18.07.39 0 .49-.18l1.6-2.77c.1-.18.06-.39-.1-.51l-1.67-1.32zM10 13c-1.65 0-3-1.35-3-3s1.35-3 3-3 3 1.35 3 3-1.35 3-3 3z"})),"Settings");t.Z=r},72753:(e,t,n)=>{var a=n(71600);t.Z=void 0;var o=a(n(24328)),r=(0,a(n(50175)).default)(o.default.createElement("path",{d:"M12 4.5C7 4.5 2.73 7.61 1 12c1.73 4.39 6 7.5 11 7.5s9.27-3.11 11-7.5c-1.73-4.39-6-7.5-11-7.5zM12 17c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5zm0-8c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3z"}),"Visibility");t.Z=r},32528:(e,t,n)=>{n.d(t,{Z:()=>r});var a=n(13688),o=n(48852);const r=e=>t=>(0,o.l)(a.X,e,t)},58662:(e,t,n)=>{n.d(t,{Z:()=>b});var a=n(13980),o=n.n(a),r=n(24328),l=n.n(r),i=n(71153),s=n.n(i),c=n(94079),u=n(87918),p=n.n(u),d=n(31276),m=n(17440);const f=(0,n(79692).Z)({pagination:{display:"flex",alignItems:"center",justifyContent:"flex-end",height:"56px",borderTop:"1px solid rgba(0,0,0,0.12)",boxShadow:"none"},caption:{color:"rgba(0,0,0,0.6)",fontSize:"12px",lineHeight:"16px"},selectRoot:{marginLeft:"5px",marginRight:"36px"},select:{color:"rgba(0,0,0,0.6)",fontSize:"12px",lineHeight:"16px",textAlign:"right"},actions:{marginLeft:"32px"}});function h(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){y(e,t,n[t])}))}return e}function y(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const g=e=>{let{classes:t={},count:n,rowsPerPageOptions:a,page:o,onChangePage:i,rowsPerPage:u,onChangeRowsPerPage:y,basicTableRef:g,labelRowsPerPage:b}=e;const v=f(),x=(0,r.useCallback)((()=>{(0,m.pathOr)(m.identity,["current","resetScrollbarPosition"],g)()}),[g]),E=(0,r.useCallback)((e=>{i(e),x()}),[i,x]),S=(0,r.useCallback)((e=>{i(0),y(e),x()}),[i,y,x]);return l().createElement(c.TablePagination,{classes:h({},t,{root:s()(v.pagination,t.root),select:s()(v.select,t.select),caption:v.caption,selectRoot:v.selectRoot,actions:v.actions}),component:"div",labelRowsPerPage:b||p().text("Rows per page:"),labelDisplayedRows:e=>{let{from:t,to:n,count:a}=e;return p().text("${fromRow}-${toRow} of ${countRows}",{fromRow:p().number(t,"0,0"),toRow:p().number(n,"0,0"),countRows:p().number(a,"0,0")})},count:n,rowsPerPageOptions:a,page:o,onChangePage:(0,m.pipe)((0,m.nthArg)(1),E),rowsPerPage:u,onChangeRowsPerPage:(0,m.pipe)(d.NA,S)})};g.propTypes={classes:o().object,rowsPerPageOptions:o().arrayOf(o().number),count:o().number,page:o().number,onChangePage:o().func,rowsPerPage:o().number,onChangeRowsPerPage:o().func,basicTableRef:o().shape({current:o().object}),labelRowsPerPage:o().string};const b=l().memo(g)},81137:(e,t,n)=>{n.d(t,{Z:()=>c});var a=n(24328),o=n.n(a),r=n(87918),l=n.n(r),i=n(94079);const s=(0,n(79692).Z)({paper:{minHeight:"180px"},title:{padding:"16px 16px 10px 16px",fontSize:"20px",fontWeight:500,letterSpacing:"0.25px",lineHeight:"24px"},content:{padding:"0 16px"},contentText:{marginBottom:0,fontSize:"16px",letterSpacing:"0.15px",lineHeight:"24px"},actionButtons:{display:"flex",paddingTop:"4px",fontSize:"14px",fontWeight:500,letterSpacing:0,lineHeight:"16px","& > div":{marginLeft:"auto"}},discardButton:{marginRight:"8px"}}),c=e=>{let{open:t,title:n,content:a,onCancel:r,cancelCaption:c=l().text("Cancel"),onDiscard:u,discardCaption:p="",onSave:d,saveCaption:m=l().text("Save"),disabledSave:f=!1}=e;const h=s();return o().createElement(i.Dialog,{open:t,onClose:r,classes:{paperScrollPaper:h.paper}},o().createElement(i.DialogTitle,{classes:{root:h.title}},n),o().createElement(i.DialogContent,{classes:{root:h.content}},o().createElement(i.DialogContentText,{classes:{root:h.contentText}},a)),o().createElement(i.DialogActions,{className:h.actionButtons,disableSpacing:!0},r&&o().createElement(i.Button,{onClick:r},c),o().createElement("div",null,u&&o().createElement(i.Button,{onClick:u,classes:{root:h.discardButton}},p),o().createElement(i.Button,{onClick:d,color:"primary",disabled:f,autoFocus:!0},m))))}},68439:(e,t,n)=>{n.d(t,{Z:()=>m});var a=n(24328),o=n.n(a),r=n(52730),l=n(71153),i=n.n(l),s=n(94079),c=n(73122),u=n(49885),p=n(95613);const d=(0,n(79692).Z)({"entityType-overflow":{textOverflow:"ellipsis",overflow:"hidden",whiteSpace:"nowrap"},"entityType-small":{padding:"1px 4px",fontSize:"10px",lineHeight:"normal",marginRight:"12px",borderRadius:"2px",flexShrink:0},"entityType-medium":{padding:"2px 8px 3px",borderRadius:"2px",fontSize:"13px",fontWeight:500,lineHeight:"15px",marginRight:"16px",flexShrink:0}}),m=e=>{let{entity:t,className:n,size:a="small"}=e;const l=d(),m=(0,r.useSelector)(u.ZP.selectors.getMetadata),f=t.type,h=(0,c.nt9)(m,f)||{},y=(0,c.VD3)(m,h,"typeColor")||c.rSc.palette.primary.main,g=(0,c.jFi)(m,t);return o().createElement(p.Z,{value:g,placement:"top"},o().createElement(s.Typography,{style:{backgroundColor:y,color:c.P6Y.Colors.getColor(y)?"#FFFFFF":"#212121"},className:i()(l[`entityType-${a}`],l["entityType-overflow"],n),component:"div"},g))}},64459:(e,t,n)=>{n.d(t,{Z:()=>g});var a=n(24328),o=n.n(a),r=n(71153),l=n.n(r),i=n(52730),s=n(17440),c=n(94079),u=n(87918),p=n.n(u),d=n(73122),m=n(49885),f=n(53180),h=n(68439);const y=(0,n(79692).Z)((e=>({profileBandWrapper:{flexShrink:0},profileBand:{display:"flex",padding:"16px 12px 16px 16px",alignItems:"flex-start",backgroundColor:"#fff",boxShadow:"0px 1px 0px rgba(0, 0, 0, 0.12)",marginBottom:"1px","&:after":{content:'""',minHeight:"inherit",fontSize:0}},inactive:{background:e.inactiveBackground},profileIcon:{marginRight:"12px"},imageProfileIcon:{width:"48px",height:"48px"},profileInfo:{display:"flex",flexDirection:"column",flex:"1 1 50%"},badge:{},label:{lineHeight:"1.2",letterSpacing:"0.25px",color:e.palette.text.primary,wordBreak:"break-word","&+ $specialInfo":{marginTop:"4px"}},secondaryLabel:{display:"inline-flex",color:e.palette.text.primary,marginTop:"2px",lineHeight:"16px",fontSize:"14px",fontWeight:400,"&+ $businessCard":{marginLeft:"12px"}},businessCard:{color:e.palette.text.secondary,display:"inline-flex",fontSize:"14px",marginTop:"4px",lineHeight:"1.2"},specialInfo:{display:"flex",justifyContent:"space-between",flexWrap:"wrap",width:"100%",marginTop:"8px"},entityType:{display:"flex",flexWrap:"wrap"},entityId:{fontSize:"13px",color:e.palette.text.secondary,whiteSpace:"nowrap",cursor:"pointer","&:hover":{textDecoration:"underline"}}}))),g=e=>{let{className:t,entity:n,children:r,classes:u,renderLabel:g=s.identity}=e;const b=y({classes:u}),v=(0,i.useSelector)(m.ZP.selectors.getMetadata),x=(0,i.useSelector)(m.ZP.selectors.getShowEntityId),E=(0,a.useCallback)((()=>{navigator.clipboard.writeText((0,d.BTI)(n))}),[n]);if((0,s.isNil)(n))return null;const S=(0,d.idV)(n.label),C=n.secondaryLabel,w=(0,d.ptG)(v,n),T=(0,d.Fn9)(n),P=n.uri,O=(0,d.BTI)(n);return o().createElement("div",{className:l()(b.profileBandWrapper,t)},o().createElement("div",{className:l()(b.profileBand,{[b.inactive]:!T}),"data-entity-uri":P},o().createElement(f.Z,{key:n.uri,entity:n,avatarClassName:b.profileIcon,imageClassName:b.imageProfileIcon}),o().createElement("div",{className:b.profileInfo},o().createElement("div",null,o().createElement(c.Typography,{variant:"h6",className:b.label},g(S)),C&&o().createElement(c.Typography,{variant:"subtitle2",className:b.secondaryLabel},C),w&&o().createElement(c.Typography,{variant:"subtitle1",className:b.businessCard},w)),o().createElement("div",{className:b.specialInfo},o().createElement("div",{className:b.entityType},o().createElement(h.Z,{entity:n,size:"medium",className:b.badge}),!(0,d.ZiX)(P)&&x&&o().createElement(c.Tooltip,{title:p().text("Copy to clipboard")},o().createElement(c.Typography,{display:"inline",variant:"body2",className:b.entityId,onClick:E},p().text("Entity ID"),": ",O))))),r&&o().createElement("div",null,r)))}},79618:(e,t,n)=>{n.d(t,{a:()=>M});var a=n(24328),o=n.n(a),r=n(94079),l=n(67766),i=n(42767),s=n(73122),c=n(71153),u=n.n(c),p=n(17440),d=n(87918),m=n.n(d),f=n(79468),h=n(83348),y=n(8818);const g=(0,n(79692).Z)({container:{display:"flex",alignItems:"center"},link:{whiteSpace:"nowrap",marginRight:"9px"}}),b=(0,h.Z)(r.Link),v=e=>{var t;let{className:n,total:r=0,onPrev:c,onNext:d,onSearchResultsClick:h,isPrevDisabled:v,isNextDisabled:x}=e;const E=g(),S=(0,a.useContext)(f.T),{OPEN_RESULTS:C,SEARCH_RESULT:w,SEARCH_RESULTS:T,NEXT_PROFILE:P,PREVIOUS_PROFILE:O}=(0,p.mergeRight)({OPEN_RESULTS:m().text("Go to search results"),SEARCH_RESULT:m().text("Search result"),SEARCH_RESULTS:m().text("Search results"),PREVIOUS_PROFILE:m().text("Go to previous profile"),NEXT_PROFILE:m().text("Go to next profile")},null!==(t=null==S?void 0:S.profileBand)&&void 0!==t?t:{});return o().createElement("div",{className:u()(E.container,n)},o().createElement(b,{className:E.link,component:"button",variant:"caption",onClick:h,underline:"none",tooltipTitle:C},(0,s.k7L)(r,1e6)," ",1===r?w:T),o().createElement(y.k,{size:"L",icon:l.Z,tooltipTitle:O,onClick:c,disabled:v,showForDisabled:!0}),o().createElement(y.k,{size:"L",icon:i.Z,tooltipTitle:P,onClick:d,disabled:x,showForDisabled:!0}))};var x=n(52730),E=n(49885),S=n(39450),C=n(54198),w=n(85229);function T(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){P(e,t,n[t])}))}return e}function P(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class O{constructor(e){var t=this;let{data:{query:n,sortField:a,sortOrder:o},tenant:r,searchTenant:l,apiPath:i,dtssPath:c,globalSearchRequestOptions:u}=e;this.query=void 0,this.sortField=void 0,this.sortOrder=void 0,this.tenant=void 0,this.searchTenant=void 0,this.apiPath=void 0,this.dtssPath=void 0,this.globalSearchRequestOptions=void 0,this.isDT=()=>this.tenant!==this.searchTenant,this.getQueryFilter=()=>({rawFilter:this.query}),this.getEntities=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const a=[t.getQueryFilter(),...e],o=T({},t.globalSearchRequestOptions,{sort:t.sortField,order:t.sortOrder,select:"uri,label,type",scoreEnabled:!1},n);return t.isDT()?(0,s.uqV)({filters:a,options:o,customerTenant:t.tenant,dataTenant:t.searchTenant,dtssPath:t.dtssPath}):(0,s.ZOr)(a,o)},this.checkEntity=e=>this.getEntities([{filter:"equals",fieldName:"uri",values:[e]}],{offset:0,max:1}).then((t=>t&&t.length>0&&t[0].uri===e)),this.requestEntities=(e,t)=>this.getEntities([],{offset:t,max:e}),this.requestTotal=()=>{const e=[this.getQueryFilter()],t=this.globalSearchRequestOptions;return(this.isDT()?(0,s.J$m)({filters:e,options:t,customerTenant:this.tenant,dataTenant:this.searchTenant,dtssPath:this.dtssPath}):(0,s.j_Q)(e,t)).then((e=>e.total))},this.query=n,this.sortField=a,this.sortOrder=o,this.tenant=r,this.searchTenant=l,this.apiPath=i,this.dtssPath=c,this.globalSearchRequestOptions=u}}function k(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){R(e,t,n[t])}))}return e}function R(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class D{constructor(e){var t=this;let{data:n,tenant:a,apiPath:o}=e;this.searchBody=void 0,this.tenant=void 0,this.apiPath=void 0,this.getEntities=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const a=[{rawFilter:t.searchBody.filter},...e];return(0,s.P2h)({apiPath:t.apiPath,tenant:t.tenant,searchBody:k({},t.searchBody,{filter:e.length?(0,s.Uqd)()(a):t.searchBody.filter}),options:n})},this.checkEntity=e=>this.getEntities([{filter:"equals",fieldName:"id",values:[(0,s.BTI)({uri:e})]}],{from:0,max:1}).then((t=>t&&t.length>0&&t[0].uri===e)),this.requestEntities=(e,t)=>this.getEntities([],{from:t,max:e}),this.requestTotal=()=>(0,s.dED)({apiPath:this.apiPath,tenant:this.tenant,searchBody:this.searchBody}).then((e=>e.count)),this.searchBody=n,this.tenant=a,this.apiPath=o}}function N(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){Z(e,t,n[t])}))}return e}function Z(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const I=(e,t)=>(0,p.pipe)((0,p.map)((0,p.prop)("uri")),(0,p.reject)((e=>t.includes(e))))(e),j=()=>{const e=(0,w._)(),t=(0,w._)(),n=(0,w._)(),{uri:o,index:r,total:l,tenant:i,cache:c}=(0,x.useSelector)(E.ZP.selectors.getSearchNavigationData)||{},{type:u,data:p}=(0,x.useSelector)(E.ZP.selectors.getSearchProviderData)||{},d=(0,x.useSelector)(E.ZP.selectors.getTenant),m=(0,x.useSelector)(E.ZP.selectors.getApiPath),f=(0,x.useSelector)(E.ZP.selectors.getDtssPath),h=(0,x.useSelector)((e=>E.ZP.selectors.getGlobalSearchRequestOptions(e,["ovOnly"]))),y=(0,a.useContext)(S.m),g=(0,x.useDispatch)(),[b,v]=(0,a.useState)(!1),T=(0,a.useMemo)((()=>((e,t)=>{switch(e){case"search":return new O(t);case"graphsearch":return new D(t)}})(u,{data:p,tenant:d,searchTenant:i,apiPath:m,dtssPath:f,globalSearchRequestOptions:h})),[u,p,d,i,m,f,h]),P=(0,a.useCallback)((e=>{g(E.yC.actions.updateSearchNavigationDataFields(e))}),[g]),k=(0,a.useCallback)((e=>{const t=d!==i?(0,s.wwR)({uri:e,dataTenant:i}):e;g(E.ui.actions.openEntity({uri:t,viewId:y,source:"navigation"}))}),[g,y,d,i]),R=(0,a.useCallback)((()=>{g(E.ui.actions.openPerspective({perspectiveId:u,viewId:y}))}),[g,u,y]);(0,a.useEffect)((()=>{r>=l?P({index:l-1}):r<0&&P({index:0})}),[l,r,P]);const Z=(0,C.u)();(0,a.useEffect)((()=>{const e=Z(((e,t)=>{switch(e.type){case E.yC.constants.UPDATE_SEARCH_NAVIGATION_DATA_ON_MERGE:{const n=E.ZP.selectors.getSearchNavigationData(t);n&&P(((e,t)=>{const{winnerUri:n,losersUris:a=[]}=t,o=((e,t)=>{let{uri:n,index:a,total:o,cache:r}=e;if(t&&t!==n){if(r&&r.includes(n)){r=[...r];const e=r.indexOf(t);let l=r.indexOf(n);e>=0&&(r.splice(e,1),o--,e<l&&a--),l=r.indexOf(n),r.splice(l,1,t)}return n=t,N({},e,{uri:n,index:a,cache:r,total:o})}return e})(e,n);return((e,t)=>{const{cache:n=[],index:a,total:o,uri:r}=e,l=t.filter((e=>n.includes(e)));if(0===l.length)return e;const i=o-l.length,s=n.indexOf(r);let c=a;for(const e of l)n.indexOf(e)<s&&c--;const u=n.filter((e=>!l.includes(e)));return N({},e,{cache:u,index:c,total:i})})(o,a)})(n,e.payload));break}}}));return()=>e()}),[Z,P]);const j=(0,a.useCallback)(((e,a,o)=>{v(!0),t(T.requestTotal()).then((e=>P({total:e})));const r=o+1;return n(T.requestEntities(15,r)).then((t=>{if(t){if(t.length){const n=I(t,e);if(n.length>0)return P({cache:e.concat(n),uri:n[0],index:r+t.length-n.length}),void k(n[0]);if(o+t.length<a-1)return j(e,a-t.length,o+t.length)}P({index:r})}})).finally((()=>{v(!1)}))}),[T,P,k]),M=(0,a.useCallback)(((e,a)=>{v(!0),t(T.requestTotal()).then((e=>P({total:e})));const o=a-1,r=Math.max(0,a-15),l=15+Math.min(0,a-15);return n(T.requestEntities(l,r)).then((t=>{if(t){if(t.length){const n=I(t,e);if(n.length>0)return P({cache:n.concat(e),uri:n[n.length-1],index:o-(t.length-n.length)}),void k(n[n.length-1]);if(a-t.length>0)return M(e,a-t.length)}P({index:0})}})).finally((()=>{v(!1)}))}),[T,P,k]),A=(0,a.useCallback)(((t,n,a,o)=>{if(n<t.length){const r=t[n];return v(!0),e(T.checkEntity(r)).then((e=>{if(!e){const e=[...t];return e.splice(n,1),A(e,n,a-1,o)}P({index:o+1,uri:r,cache:t,total:a}),k(r)})).finally((()=>{v(!1)}))}if(!(o>=a-1))return j(t,a,o);P({cache:t,total:a,index:a-1})}),[T,P,k,j]),L=(0,a.useCallback)(((t,n,a,o)=>{if(n>-1){const r=t[n];return v(!0),e(T.checkEntity(r)).then((e=>{if(!e){const e=[...t];return e.splice(n,1),L(e,n-1,a-1,o-1)}P({index:o-1,uri:r,cache:t,total:a}),k(r)})).finally((()=>{v(!1)}))}if(!(o<=0))return M(t,o);P({index:0,cache:t,total:a})}),[T,P,k,M]),F=(0,a.useCallback)((()=>{if(c&&o){const e=c.indexOf(o)-1;L(c,e,l,r)}}),[L,c,o,l,r]),B=(0,a.useCallback)((()=>{if(c&&o){const e=c.indexOf(o)+1;A(c,e,l,r)}}),[A,c,o,l,r]);return{total:l,onPrev:F,onNext:B,onSearchResultsClick:R,isPrevDisabled:b||r<=0,isNextDisabled:b||r>=l-1}},M=e=>{let{className:t}=e;const{total:n,onPrev:a,onNext:r,onSearchResultsClick:l,isPrevDisabled:i,isNextDisabled:c}=j();return(()=>{const{cache:e}=(0,x.useSelector)(E.ZP.selectors.getSearchNavigationData)||{},t=(0,x.useSelector)(E.ZP.selectors.getMode),n=(0,x.useSelector)(E.ZP.selectors.getEntity);return(0,s.uzs)(t)&&(null==e?void 0:e.includes(null==n?void 0:n.uri))})()?o().createElement(v,{className:t,total:n,onPrev:a,onNext:r,onSearchResultsClick:l,isPrevDisabled:i,isNextDisabled:c}):null}},54013:(e,t,n)=>{n.d(t,{Z:()=>u});var a=n(24328),o=n.n(a),r=n(47603),l=n(87918),i=n.n(l),s=n(8818),c=n(55847);const u=e=>{let{items:t,menuId:n}=e;return o().createElement(c.Z,{buttonComponent:s.k,buttonProps:{icon:r.Z,tooltipTitle:i().text("Settings"),size:"L"},menuId:n,menuItems:t})}},3409:(e,t,n)=>{n.d(t,{Z:()=>d});var a=n(24328),o=n.n(a),r=n(52730),l=n(49885),i=n(94079),s=n(17440),c=n(87918),u=n.n(c);const p=(0,n(79692).Z)({root:{display:"flex",alignItems:"flex-start"},slice:{fontWeight:500},cancelButton:{width:"88px",flexShrink:0,marginLeft:"15px"}}),d=()=>{const e=p(),t=(0,r.useSelector)(l.ZP.selectors.getHistoryEvent),n=(0,r.useDispatch)(),a=(0,s.pipe)(l.N5.history.actions.clearHistoryEvent,n);return t?o().createElement("div",{className:e.root},o().createElement(i.Typography,{component:"div"},u().text("You are viewing a historic slice:")," ",o().createElement("span",{className:e.slice},u().date(t.aStamp,"llll"))),o().createElement(i.Button,{className:e.cancelButton,variant:"contained",color:"primary",onClick:a},u().text("Cancel"))):null}},54198:(e,t,n)=>{n.d(t,{G:()=>l,u:()=>i});var a=n(24328),o=n.n(a);const r=(0,a.createContext)(null);r.displayName="ActionsHookContext";const l=e=>{let{children:t,hook:n}=e;return o().createElement(r.Provider,{value:n},t)},i=()=>{const e=(0,a.useContext)(r);if(!e)throw new Error("ActionsHookContext must be provided");return e}},79468:(e,t,n)=>{n.d(t,{T:()=>o});var a=n(24328);const o=n.n(a)().createContext({profileBand:{}});o.displayName="LabelsContext"},7718:(e,t,n)=>{n.d(t,{C:()=>f});var a=n(24328),o=n(52730),r=n(17440),l=n(73122),i=n(49885);function s(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){c(e,t,n[t])}))}return e}function c(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const u=(e,t)=>t.filter((t=>t.replyId!==e)),p=(e,t)=>{const n=e.replies.findIndex((e=>{let{replyId:n}=e;return n===t.replyId})),a=[...e.replies];return a[n]=t,a},d=[],m=e=>console.error("Collaboration error",e),f=e=>{let{objectIds:t=d,objectTypes:n,enabled:c=!0}=e;const f=(0,o.useSelector)(i.ZP.selectors.getEntity),h=(0,o.useSelector)(i.ZP.selectors.getTenant),y=(0,o.useSelector)(i.ZP.selectors.getCollaborationPath),g=(0,o.useSelector)(i.ZP.selectors.isCollaborationEnabled)&&c,[b,v]=(0,a.useState)(null),[x,E]=(0,a.useState)([]),[S,C]=(0,a.useState)(null),[w,T]=(0,a.useState)(null),[P,O]=(0,a.useState)(!1),[k,R]=(0,a.useState)(!1),[D,N]=(0,a.useState)({}),Z=(0,a.useCallback)((e=>{C((t=>s({},t,e)))}),[]),I=null==f?void 0:f.uri,j=(0,a.useCallback)((function(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(g&&I&&!(0,l.ZiX)(I)){const n=e=>{console.warn("Collaboration error",e),C(null)};(0,r.pipe)(l.$oF,(0,r.andThen)((0,r.map)((0,r.props)(["objectId","comments"]))),(0,r.andThen)(r.fromPairs),(0,r.andThen)(t?C:Z),(0,r.otherwise)(n))({uris:e,tenant:h,collaborationPath:y})}else C(null)}),[Z,y,I,g,h]);(0,a.useEffect)((()=>{j(t,!0)}),[t,j]);const M=(0,a.useCallback)(((e,t)=>{(0,l.liG)({collaborationPath:y,tenant:h,relatedObjectUri:e,pageToken:t}).then((e=>{let{items:n,nextPageToken:a}=e;E((e=>t?(0,r.uniqBy)((0,r.prop)("commentId"),[...e,...n]):n)),v(a)})).catch(m)}),[y,h]),A=(0,a.useCallback)((e=>{R(!0),(0,l.d7q)({collaborationPath:y,tenant:h,commentId:e}).then(T).catch(m).finally((()=>R(!1)))}),[y,h]),L=(0,a.useCallback)((e=>{let{content:t,namedUsers:n,objectType:a,uri:o,relatedObjectUris:r}=e;O(!0);const i={objectId:o,content:t,relatedObjectUris:r,objectType:a,visibility:"public",namedUsers:n,permanentLink:`${window.location.href}&commentId=${encodeURIComponent("{commentId}")}`};return(0,l.Yrx)({collaborationPath:y,tenant:h,data:i}).then((e=>{let[t]=e;return((e,t)=>{T(e),C((n=>s({},n,{[t]:[...n[t]||[],{commentId:e.commentId,replies:0,status:"open"}]}))),E((t=>[e,...t]))})(t,o)})).catch(m).finally((()=>O(!1)))}),[y,h]),F=(0,a.useCallback)((e=>{let{content:t,namedUsers:n,objectType:a,uri:o,relatedObjectUris:i,commentId:c,replies:u}=e;O(!0);const p={objectId:o,content:t,relatedObjectUris:i,objectType:a,visibility:"public",namedUsers:n,commentId:c,replies:u};return(0,l.uAg)({collaborationPath:y,tenant:h,data:p}).then((e=>(e=>{T(e),E((0,r.map)((0,r.when)((0,r.propEq)("commentId",e.commentId),(0,r.always)(e))))})(s({},e,{replies:u})))).catch(m).finally((()=>O(!1)))}),[y,h]),B=(0,a.useCallback)((e=>{let{uri:t,commentId:n}=e;O(!0),(0,l.YFy)({collaborationPath:y,tenant:h,commentId:n}).then((()=>((e,t)=>{T(null),C((n=>{const a=n[t]||[];return s({},n,{[t]:a.filter((t=>t.commentId!==e))})})),E((t=>t.filter((t=>t.commentId!==e))))})(n,t))).catch(m).finally((()=>O(!1)))}),[y,h]),U=(0,a.useCallback)(((e,t,n,a)=>{const o="resolve"===e.action?"resolved":"open",{replyId:r}=e;T("resolved"===o?e=>{if(e)return null}:t=>{if(t)return s({},t,{replies:a?u(r,t.replies):[...t.replies,e]})}),C((e=>s({},e,{[t]:(e[t]||[]).map((e=>e.commentId===n?s({},e,{status:o,replies:a?e.replies-1:e.replies+1}):e))}))),E((t=>t.map((t=>t.commentId===n?s({},t,{status:o,replies:a?u(e.replyId,t.replies):[...t.replies,e]}):t))))}),[]),z=(0,a.useCallback)((e=>{let{uri:t,commentId:n,reply:a}=e;O(!0),(0,l.Mfr)({collaborationPath:y,tenant:h,commentId:n,replyId:a.replyId}).then((()=>U(a,t,n,!0))).catch(m).finally((()=>O(!1)))}),[y,U,h]),_=(0,a.useCallback)(((e,t)=>{T((t=>{if(t)return s({},t,{replies:p(t,e)})})),E((n=>n.map((n=>n.commentId===t?s({},n,{replies:p(n,e)}):n))))}),[]),H=(0,a.useCallback)((e=>{let{content:t,namedUsers:n,commentId:a,replyId:o}=e;O(!0);const r={content:t,namedUsers:n};return(0,l.ufV)({collaborationPath:y,tenant:h,commentId:a,replyId:o,data:r}).then((e=>_(e,a))).catch(m).finally((()=>O(!1)))}),[y,h,_]),W=(0,a.useCallback)((e=>{let{content:t,namedUsers:n,commentId:a,action:o,uri:r}=e;O(!0);const i={content:t,action:o,namedUsers:n};return(0,l.PP2)({collaborationPath:y,tenant:h,commentId:a,data:i}).then((e=>{let[t]=e;return U(t,r,a)})).catch(m).finally((()=>O(!1)))}),[y,h,U]),V=(0,a.useCallback)((e=>{let{commentId:t,uri:n}=e;W({content:"",namedUsers:[],commentId:t,action:"resolve",uri:n})}),[W]),q=(0,a.useCallback)((e=>{let{commentId:t,uri:n}=e;W({content:"",namedUsers:[],commentId:t,action:"reopen",uri:n})}),[W]);return{clearCurrentComment:(0,a.useCallback)((()=>{T(null)}),[]),comments:x,commentsMap:S,getCommentState:(e,t)=>(0,r.pathOr)({},[e,t],D),updateCommentState:(e,t,n)=>{N((a=>{const o=[e,t],l=(0,r.path)(o,a);return(0,r.assocPath)(o,(0,r.mergeRight)(l,n),a)}))},clearCommentState:(e,t)=>N((0,r.dissocPath)([e,t])),createComment:L,createReply:W,currentComment:w,deleteComment:B,editComment:F,getComment:A,getComments:M,getCommentsCount:j,loading:k,objectTypes:n,pageToken:b,reOpenThread:q,resolveThread:V,sending:P,deleteReply:z,editReply:H}}},37152:(e,t,n)=>{n.d(t,{a:()=>m});var a=n(24328),o=n(52730),r=n(17440),l=n(49885),i=n(73122),s=n(85229),c=n(30634);function u(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){p(e,t,n[t])}))}return e}function p(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const d=(0,r.when)(r.identity,(0,r.pipe)(i.VGB,r.length,(0,r.times)((e=>e+1)))),m=e=>{let{sorting:t,filter:n,page:p,rowsPerPage:m,config:f,entity:h,relationActivityFilter:y,mode:g,searchByOv:b=!1}=e;const[v,x]=(0,a.useState)(!1),E=(0,o.useDispatch)(),S=(0,o.useSelector)(l.ZP.selectors.getTenant),C=(0,o.useSelector)(l.ZP.selectors.getMetadata),w=(0,o.useSelector)(l.ZP.selectors.getDtssPath),{activityFilter:T,globalFilter:P}=(0,o.useSelector)(l.ZP.selectors.getGlobalSearchRequestOptions)||{},O=(0,o.useSelector)(l.ZP.selectors.getProfileLastLoadedTime),k=(0,s._)(),R=e=>{const t=(0,r.when)(i.Kn2,(0,r.prop)("uri")),n=(0,r.pipe)(t,(0,i.pQZ)(C));return(0,r.evolve)({entityTypes:(0,r.filter)((0,i.kuw)(C)),inRelations:(0,r.filter)(n),outRelations:(0,r.filter)(n),nextEntry:R})(e)},D=f.suggested,N=(0,a.useMemo)((()=>({searchByOv:b})),[b]),Z=(0,a.useCallback)((()=>{if(null!=h&&h.uri){const e=u({},R(f.content),{sortBy:null==t?void 0:t.field,order:null==t?void 0:t.order,returnDates:!0,returnObjects:!0,activeness:{relation:y||i.Ng6.ALL,entity:T},max:m,offset:p*m,filter:(0,i.vyX)(P,n)||void 0,suggested:d(D)}),a=[e].concat((0,r.ifElse)(r.identity,(0,r.pipe)(i.VGB,(t=>t.map(((t,n)=>u({},t,{id:e.suggested[n]}))))),(0,r.always)([]))(D)),o=(0,r.cond)([[(0,r.pipe)((0,r.prop)("uri"),i.ZiX),()=>Promise.resolve([{total:0}])],[i.biM,e=>(0,i.n_1)({entityUri:e.uri,configs:a,customerTenant:S,dataTenant:e.dataTenant,dtssPath:w,options:N})],[r.T,e=>(0,i.N6e)(e.uri,a,N)]]);x(!0),k(o(h)).then((e=>{let[{connections:t,total:n}]=e;E(l.N5.relations.actions.relationsLoaded({id:f.id,connections:t,total:n}))})).finally((()=>{x(!1)}))}}),[T,C,f,E,w,null==h?void 0:h.uri,null==h?void 0:h.dataTenant,n,P,p,y,m,k,t,S,N,O]),I=(0,a.useRef)(!1);I.current=!1,(0,a.useEffect)((()=>{I.current=!0,Z()}),[Z]);const j=(0,c.D)(g);return(0,a.useEffect)((()=>{g!==i.ARY.Viewing||I.current||j===g||(I.current=!0,Z())}),[Z,g,j]),{isLoading:v,reload:Z}}},55451:(e,t,n)=>{n.r(t),n.d(t,{default:()=>Yt});var a=n(24328),o=n.n(a),r=n(52730),l=n(8598),i=n(36138),s=n(44443),c=n(22664),u=n(87451),p=n(39450),d=n(585),m=n(49885),f=n(17440),h=n(73122),y=n(20562),g=n(37152),b=n(7718),v=n(41564),x=n(31274),E=n(40715),S=n(99136),C=n(58662);function w(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){T(e,t,n[t])}))}return e}function T(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const P={relationsTable:{},attributesTable:{}};var O=n(26180),k=n(31276),R=n(86361),D=n(87918),N=n.n(D);const Z="relation.type",I="relation.attributes",j=[{id:"entity.label",get label(){return N().text("Profile")},dataTypeDefinition:{type:h.oS0.TYPE_STRING},hideable:!1,filterable:!1,initialWidth:280,autoResize:!1},{id:Z,get label(){return N().text("Type")}},{id:"relation.label",get label(){return N().text("Directional Label")},filterable:!1,dataTypeDefinition:{type:h.oS0.TYPE_STRING}},{id:"relation.activeness.startDate",get label(){return N().text("Start Date")},dataTypeDefinition:{type:h.oS0.TYPE_ACTIVENESS_DATE}},{id:"relation.activeness.endDate",get label(){return N().text("End Date")},dataTypeDefinition:{type:h.oS0.TYPE_ACTIVENESS_DATE}},{id:I,get label(){return N().text("Attributes")},sortable:!1,filterable:!1,maxAttrsToShow:7}],M=(0,f.pluck)("id",j),A=[Z,I],L=[20,50,100],F=(0,f.pipe)(h.Tde,(0,f.concat)("relation.")),B=(0,f.pipe)((0,f.map)((e=>({id:F(e.uri),label:e.label,description:null==e?void 0:e.description,dataTypeDefinition:(0,h.PFL)(e)}))),(0,f.uniqBy)((0,f.prop)("id")));function U(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){z(e,t,n[t])}))}return e}function z(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const _="CHANGE_RELATION_TYPE",H="APPLY_SAVED_STATE",W="SAVE_CURRENT_STATE",V=U({},O.ZP.actions,{changeRelationType:(0,k.zD)(_),applySavedState:(0,k.zD)(H),saveCurrentState:(0,k.zD)(W)}),q=(0,f.assoc)("page",0),Y=e=>(0,f.pipe)((0,f.prop)("visibleColumns"),(0,f.ifElse)((0,f.always)(e.currentRelationType),(0,f.without)(A),(0,f.concat)(A)),(0,f.intersection)(M))(e),G=e=>(0,f.path)(["visibleColumnsForRelationTypes",`${e.currentRelationType}`],e),$=e=>{const t=(0,f.either)(G,Y)(e);return O.ZP.changeVisibleColumns(e,t)},X=(0,f.pipe)((0,f.propOr)(null,"filters"),(0,f.unless)(f.isNil,(0,f.filter)((e=>{let{filter:t,value:n}=e;return(0,h.jtL)(t,n)})))),K=e=>{const{currentRelationType:t,visibleColumns:n}=e;return(0,f.evolve)({visibleColumnsForRelationTypes:(0,f.assoc)(`${t}`,n)},e)},Q=(0,f.pipe)(K,(0,f.pick)(["currentRelationType","visibleColumnsForRelationTypes","filters","sorting"]));var J=n(37754),ee=n(94079),te=n(92778),ne=n(30553),ae=n(51229),oe=n(54013),re=n(1876),le=n(60894),ie=n(79026),se=n(79692);const ce=(0,se.Z)({select:{fontSize:"13px",color:"rgba(0,0,0,.6)",paddingLeft:"15px","&&":{paddingRight:"35px"}},selectMenu:{"& li":{fontSize:"13px",height:"32px"}},textField:{maxWidth:"100%"}}),ue=e=>{let{value:t,onChange:n,relationTypes:r,className:l}=e;const i=ce(),s=(0,a.useMemo)((()=>(0,f.pipe)((0,f.map)((e=>{let{label:t,uri:n}=e;return{label:t,value:n}})),(0,f.concat)([{value:"",label:N().text("All types")}]))(r)),[r]);return o().createElement("div",{className:l},o().createElement(ie.Z,{displayEmpty:!0,disableUnderline:!0,classes:{select:i.select},TextFieldProps:{classes:{root:i.textField}},MenuProps:{classes:{list:i.selectMenu}},value:t||"",entries:s,onChange:e=>n(e||null)}))},pe=(0,se.Z)((e=>({header:{height:"56px",boxSizing:"border-box",paddingRight:"10px"},title:{fontSize:"16px"},total:{fontSize:"14px",color:e.palette.text.secondary,flexShrink:0,marginRight:"5px"},relationTypeSelector:{margin:"0px 10px 0 30px",overflow:"hidden"}}))),de=(0,a.memo)((e=>{let{total:t,filteringEnabled:n,onToggleFilters:r,columnsData:l,selectedColumns:i,currentRelationType:s,onRelationTypeChange:c,relationTypes:u,onChangeColumns:p,searchByOv:d,onToggleSearchByOv:m}=e;const f=pe(),h=(0,a.useMemo)((()=>[{selected:d,selectable:!0,text:N().text("Search by OV only"),onClick:m,id:"showNonOv"}]),[m,d]);return o().createElement(te.Z,{title:N().text("Relationships"),classes:{root:f.header,title:f.title}},u.length>0&&o().createElement(ue,{className:f.relationTypeSelector,value:s,onChange:c,relationTypes:u}),o().createElement(ne.Z,{height:28,margin:20}),o().createElement(ee.Typography,{variant:"caption",className:f.total},1===t?N().text("${count} record",{count:t}):N().text("${count} records",{count:t})),o().createElement(ae.Z,null),o().createElement(oe.Z,{items:h,menuId:"relationships-view-settings"}),o().createElement(re.Z,{enabled:n,onClick:r}),o().createElement(ne.Z,{height:28,margin:8}),o().createElement(le.Z,{columnsData:l,selectedColumns:i,onChangeColumns:p}))}));var me=n(74402),fe=n(97946),he=n(85709),ye=n(25461),ge=n(92332),be=n(98448),ve=n(67353);const xe=(0,se.Z)((e=>({headCell:{display:"flex",alignItems:"center",height:"100%",width:"100%",fontSize:"12px",color:e.palette.text.secondary,background:"linear-gradient(0deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.06)), #FFFFFF"},rowCell:{fontSize:"13px",overflow:"hidden",overflowWrap:"break-word"},inactiveRowCell:{opacity:.6},defaultWrapper:{padding:"15px 25px 0 25px","&:last-child":{paddingBottom:"15px"}},entityCell:{display:"flex",alignItems:"flex-start",padding:"15px"},entityAvatar:{transform:"scale(0.5)",margin:"-10px 0 -10px -10px"},inactiveEntityAvatar:{overflow:"initial","&:after":{content:'""',position:"absolute",backgroundColor:"rgb(209, 206, 206)",border:"1px solid rgba(0, 0, 0, 1)",borderRadius:"2px",width:"12px",right:0,bottom:0,height:"12px"},"& > img":{borderRadius:"50%",overflow:"hidden"}},entityLabel:{color:e.palette.primary.main,textDecoration:"none",fontWeight:500},attributesWrapper:{padding:"15px 25px 10px 25px",color:"rgba(0,0,0,0.87)"},commentsContainer:{marginLeft:"auto"},description:{marginLeft:"-22px"}}))),Ee=(0,ve.Z)((e=>{const t=xe(),{description:n}=null==e?void 0:e.headCellData;return o().createElement("div",{className:t.headCell},o().createElement(ge.default,e),o().createElement(be.Z,{description:n,className:t.description}))}));var Se=n(71153),Ce=n.n(Se),we=n(19603),Te=n(34e3),Pe=n(31039),Oe=n(94646);const ke=e=>{let{value:{entity:t,entityType:n,relation:a},isInactiveRelation:l}=e;const i=xe(),s=(0,r.useSelector)(m.ZP.selectors.getEntityUri);return o().createElement("div",{className:Ce()(i.entityCell,we.U)},o().createElement(Te.Z,{className:Ce()(i.entityAvatar,{[i.inactiveEntityAvatar]:l}),entityType:n}),o().createElement(Pe.Z,{value:(0,h.wwR)({uri:t.entityUri,dataTenant:t.dataTenant}),className:i.entityLabel},(0,h.idV)(t.entityLabel)),o().createElement("div",{className:i.commentsContainer,onClick:e=>e.stopPropagation()},o().createElement(Oe.Z,{uri:a.relationUri,relatedObjectUris:(0,h.wp9)(h.q7e.RELATION,{entityUri:s,connection:{relation:a,entity:t}}),objectType:h.q7e.RELATION,allowOnlyOneComment:!0})))};var Re=n(80931);const De=e=>{let{columnData:t,value:{attributes:n,attributeTypes:a}}=e;const r=xe();return o().createElement("div",{className:r.attributesWrapper,onClick:e=>e.stopPropagation()},o().createElement(Re.Z,{max:t.maxAttrsToShow,entity:{attributes:n},attrTypes:a,drawLines:!1}))};var Ne=n(72768);const Ze=e=>{let{value:t,columnData:{dataTypeDefinition:n}}=e;const a=xe();return o().createElement("div",{className:a.defaultWrapper},o().createElement(Ne.Z,{value:t,dataTypeDefinition:n}))};function Ie(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const je=(0,f.pipe)((0,f.split)("."),(0,f.slice)(2,1/0)),Me=e=>{if(e.startsWith("relation.attributes")){const t=je(e);return t.length>1?t.slice(0,-1):null}return null},Ae=e=>{switch(e){case"entity.label":return ke;case"relation.attributes":return De;default:return Ze}},Le=(0,f.map)((e=>function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){Ie(e,t,n[t])}))}return e}({sortable:!0,resizable:!0},e,{headCellRenderer:Ee,nestedPath:Me(e.id),rowCellValueRenderer:Ae(e.id)}))),Fe=(0,f.cond)([[(0,f.pathEq)(["columnData","id"],"relation.attributes"),e=>{let{columnData:t,cell:n}=e;const a=(0,f.pipe)((0,f.path)(["values",0,"attributes"]),f.values,f.length)(n);return a>t.maxAttrsToShow?26*t.maxAttrsToShow+49:26*a+25}],[f.T,ye.Z]]);function Be(){return Be=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(e[a]=n[a])}return e},Be.apply(this,arguments)}const Ue=e=>{let{cell:t,CellValueRenderer:n}=e,a=function(e,t){if(null==e)return{};var n,a,o=function(e,t){if(null==e)return{};var n,a,o={},r=Object.keys(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}(e,["cell","CellValueRenderer"]);const r=xe();return o().createElement("div",{className:Ce()(r.rowCell,{[r.inactiveRowCell]:a.isInactiveRelation})},t.values.map(((e,t)=>o().createElement(n,Be({key:t,value:e},a)))))};var ze=n(22983),_e=n(43054),He=n(55847),We=n(22385),Ve=n(81137),qe=n(83348);const Ye=(0,se.Z)((e=>({menuItem:{minHeight:"32px",color:e.palette.text.secondary},menuText:{color:e.palette.text.primary,fontSize:"13px",lineHeight:"15px",letterSpacing:0,marginLeft:"16px"},buttons:{display:"flex",alignItems:"center",paddingRight:"5px"}}))),Ge=(0,qe.Z)(ee.MenuItem),$e=(0,a.forwardRef)(((e,t)=>{let{item:n,onMenuClose:a=k.ZT}=e;const r=Ye(),{icon:l,disabled:i,text:s,tooltip:c,onClick:u}=n;return o().createElement(Ge,{tooltipTitle:c,showForDisabled:!0,classes:{root:r.menuItem},onClick:e=>{a(),u(e)},disabled:i,ref:t},l,o().createElement(ee.Typography,{classes:{root:r.menuText}},s))}));$e.displayName="MenuItemRenderer";const Xe=$e,Ke=e=>{let{disableDelete:t,connection:{entity:n,relation:l},onMenuOpen:i=k.ZT,onMenuClose:s=k.ZT,onDelete:c}=e;const u=Ye(),p=(0,r.useSelector)(m.ZP.selectors.getMetadata),d=(0,f.pipe)((0,f.prop)("relationType"),(0,h.V3K)(p),(0,h.uGe)(h.BDP.DELETE))(l),y=!t&&d,[g,b]=(0,a.useState)(!1),v=()=>b(!1),x=[{disabled:!y,text:N().text("Delete"),icon:o().createElement(ze.Z,null),tooltip:y?null:N().text("You don't have permissions to delete"),onClick:()=>b(!0)}],E=(0,a.useCallback)((()=>{g||s()}),[g,s]);return o().createElement("div",{className:u.buttons},o().createElement(He.Z,{MenuItemRenderer:Xe,menuId:"relationships-table-actions",buttonComponent:We.Z,buttonProps:{icon:_e.Z,size:"S"},menuItems:x,onMenuOpen:i,onMenuClose:E}),o().createElement(Ve.Z,{open:g,title:N().text('Do you want to delete relationship "${label}"?',{label:(S=(0,h.idV)(n.entityLabel),S.length>17?`${S.substring(0,17)}...`:S)}),content:N().text("This relationship will be removed and all the values in the relationship will be permanently deleted. Are you sure you want to delete this relationship?"),onSave:(0,f.pipe)(v,s,c),onDiscard:(0,f.pipe)(v,s),saveCaption:N().text("Delete"),discardCaption:N().text("Cancel")}));var S},Qe=(0,se.Z)({tableContainer:{flex:1,overflow:"hidden",display:"flex",zIndex:0},hoveredRowRightContentWrapper:{width:"100%",pointerEvents:"none!important"},menuButtonContainer:{position:"absolute",top:"calc(50% - 12px)",right:0,pointerEvents:"all"},tooltipAnchor:{width:"100%",height:"1px"}});function Je(){return Je=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(e[a]=n[a])}return e},Je.apply(this,arguments)}const et=(0,a.memo)((e=>{let{metadata:t,connections:n,columnsData:r,sorting:l,onSort:i,filters:s,onFilter:c,onRowClick:u,tableRef:p,onDelete:d,readOnly:m}=e;const y=Qe(),g=(0,a.useMemo)((()=>((e,t,n)=>(n||[]).map((n=>(0,f.pipe)((0,f.reduce)(((t,a)=>{let{id:o}=a;return(0,f.assoc)(o,((e,t,n)=>{let{entity:a,relation:o}=t;switch(n){case"entity.label":return{entity:a,entityType:(0,h.nt9)(e,a.entityType),relation:o};case"relation.type":return o.relationType;case"relation.label":return o.relationLabel;case"relation.activeness.startDate":return o.startDate;case"relation.activeness.endDate":return o.endDate;case"relation.attributes":return{attributes:o.object.attributes,attributeTypes:(0,h.V3K)(e,o.relationType).attributes};default:return((e,t)=>(0,f.pipe)((0,f.path)(["object","attributes"]),(0,h.tT_)(e))(t))(je(n),o)}})(e,n,o),t)}),{}),(0,f.assoc)("rawValue",n))(t))))(t,r,n)),[t,n,r]),b=(0,a.useMemo)((()=>Le(r)),[r]),{getDynamicRowCellHeight:v,changeRowCellHeight:x}=(0,me.Z)(),E=(0,a.useCallback)((0,f.either)(v,Fe),[v,Fe]),[S,C]=(0,a.useState)(null),w=(0,a.useCallback)((e=>{const t=!(0,h.Fn9)(e.rowValue.rawValue.relation);return o().createElement(fe.Z,Je({onChangeHeight:x},e),o().createElement(Ue,Je({},e,{isInactiveRelation:t})))}),[x]),[T,P]=(0,a.useState)(!1),O=(0,a.useCallback)((()=>P(!0)),[]),k=(0,a.useCallback)((()=>{C(null),P(!1)}),[]),R=(0,a.useCallback)((e=>C((t=>T?t:e))),[T]),D=(0,a.useMemo)((()=>{const e=null!=S?g[S].rawValue:null,t=!(0,h.Fn9)(null==e?void 0:e.relation);return e&&o().createElement(o().Fragment,null,o().createElement(ee.Tooltip,{key:e.relation.relationUri,open:t,title:N().text("Inactive")},o().createElement("div",{className:y.tooltipAnchor})),o().createElement("div",{className:y.menuButtonContainer},o().createElement(Ke,{disableDelete:m,connection:e,onMenuOpen:O,onMenuClose:k,onDelete:()=>d(e.relation.relationUri)})))}),[d,g,S]);return o().createElement("div",{className:y.tableContainer},o().createElement(he.Z,{fixFirstColumn:!0,columnsData:b,rowsData:g,sorting:l,onSort:i,filters:s,onFilter:c,defaultColumnWidth:250,defaultColumnMinWidth:200,headRowHeight:48,getRowCellHeight:E,renderRowCell:w,onRowClick:u,ref:p,hoverStateEnabled:!0,hoverRowIndex:S,onRowHover:R,hoveredRowRightContent:D,classes:{hoveredRowRightContentWrapper:y.hoveredRowRightContentWrapper}}))}));var tt=n(85229),nt=n(85965),at=n(39417),ot=n(10237),rt=n(63149),lt=n(48017),it=n(96955),st=n(66095),ct=n(20982),ut=n(99144),pt=n(65549),dt=n(52017),mt=n(90186);const ft=(0,se.Z)((()=>({tableRow:{"& + &":{marginTop:"4px"},margin:"auto",maxWidth:"448px"}})));function ht(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const yt=(0,a.memo)((e=>{let{readOnly:t,relation:n,metadata:r,selectedAttributeTypes:l,onDeleteCrosswalk:i,onEditCrosswalk:s}=e;const c=ft(),u=(0,h.V3K)(r,n.type),p=(0,a.useMemo)((()=>function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];return(0,f.pipe)((0,f.propOr)([],"crosswalks"),(0,f.map)((0,f.assoc)("ownerType","entity")),(0,mt.o)(e.type,t))(e)}(n,l)),[n,l]),[d,m]=(0,a.useState)([]),y=(0,a.useCallback)((e=>{i({entityUri:n.uri,crosswalkId:e})}),[i,n.uri]),g=(0,a.useCallback)((e=>{s(function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){ht(e,t,n[t])}))}return e}({entityUri:n.uri},e))}),[s,n.uri]);return o().createElement("div",null,p.map((e=>{let{source:n,crosswalksByTypes:a}=e;return o().createElement("div",{key:n,className:c.tableRow},o().createElement(dt.Z,{source:n,crosswalksByTypes:a,expanded:d.includes(n),disableEditCrosswalk:!(0,h.Zm0)(u)||t,disableDeleteCrosswalk:!(0,h.a14)(u)||t,onEdit:g,onDelete:y,onToggleExpanded:()=>{m((0,f.ifElse)((0,f.includes)(n),(0,f.without)([n]),(0,f.append)(n)))}}))})))}));var gt=n(79769);const bt=(0,se.Z)((e=>({header:{display:"flex",flexDirection:"row",alignItems:"center",padding:"20px 12px",borderBottom:"1px solid rgba(0, 0, 0, 0.12)"},title:{fontWeight:500,fontSize:"20px",lineHeight:"23px",letterSpacing:"0.25px",color:e.palette.text.primary,marginLeft:"12px"},hint:{color:e.palette.text.secondary,display:"flex",flexDirection:"row",alignItems:"center",alignSelf:"flex-start",margin:"4px 14px 10px"},hintText:{marginLeft:"8px",fontSize:"12px",lineHeight:"16px"},buttons:{display:"flex",padding:"8px 6px 4px"},buttonLabel:{fontSize:"14px",fontWeight:500,lineHeight:"16px"},icon:{fontSize:"18px",marginRight:"8px"},editor:{paddingLeft:25,margin:"auto",maxWidth:"448px",boxSizing:"border-box",marginBottom:"4px"},tableContainer:{overflowY:"auto",overflowX:"hidden",paddingLeft:"16px",paddingRight:"6px"}}))),vt=(0,qe.Z)(ee.Button),xt=(0,a.memo)((e=>{let{className:t,readOnly:n,relation:l,selectedAttributeTypes:i,onAddCrosswalk:s,onDeleteCrosswalk:c,onEditCrosswalk:u}=e;const p=bt(),d=(0,r.useSelector)(m.ZP.selectors.getMetadata),f=(0,h.V3K)(d,l.type),[y,g]=(0,a.useState)(!1),b=(0,h.mkC)(f)&&!n;return o().createElement("div",{className:t},o().createElement("div",{className:p.header},o().createElement("span",{className:p.title},N().text("Legend"))),o().createElement("div",{className:p.buttons},o().createElement(vt,{color:"primary",showForDisabled:!0,disabled:!b,tooltipTitle:b?null:N().text("You don't have permissions to add crosswalk"),onClick:()=>g(!0)},o().createElement(pt.Z,{className:p.icon}),o().createElement("div",{className:p.buttonLabel},N().text("Crosswalk")))),o().createElement("div",{className:p.hint},o().createElement(ut.Z,{className:p.icon}),o().createElement("span",{className:p.hintText},N().text("You can drag a crosswalk to add values to attributes swimlanes"))),o().createElement("div",{className:p.tableContainer},y&&o().createElement(gt.Z,{className:p.editor,onAdd:e=>s({entity:l,crosswalk:e}),onClose:()=>g(!1)}),o().createElement(yt,{readOnly:n,metadata:d,relation:l,selectedAttributeTypes:i,onDeleteCrosswalk:c,onEditCrosswalk:u})))}));var Et=n(95613),St=n(23147),Ct=n(94111),wt=n(64459),Tt=n(68439);const Pt=(0,se.Z)((e=>({entityInfo:{flex:"0 1 auto",overflow:"hidden",minWidth:"100px"},entityLabelContainer:{display:"flex",alignItems:"center",overflow:"hidden"},entityLabel:{lineHeight:"1.2",letterSpacing:"0.25px",color:e.palette.text.primary},infoIcon:{fontSize:"16px",color:e.palette.text.secondary,marginLeft:"5px"},profileBand:{margin:"-10px",maxWidth:"500px"},entityTypeBadge:{marginTop:"7px"}}))),Ot=e=>{let{entity:t}=e;const n=Pt(),a=(0,h.idV)(t.label);return o().createElement("div",{className:n.entityInfo},o().createElement("div",{className:n.entityLabelContainer},o().createElement(Et.Z,{value:a},o().createElement(ee.Typography,{variant:"h6",className:n.entityLabel,noWrap:!0},a)),o().createElement(Ct.Z,{title:o().createElement(wt.Z,{className:n.profileBand,entity:t}),placement:"right"},o().createElement(ut.Z,{className:n.infoIcon}))),o().createElement(Tt.Z,{className:n.entityTypeBadge,entity:t,size:"medium"}))},kt=(0,se.Z)((e=>({root:{flexShrink:0,overflow:"hidden",width:"110px"},label:{color:e.palette.text.secondary,fontSize:"13px"}}))),Rt=e=>{let{relation:t}=e;const n=kt(),{direction:a,relationLabel:r}=t;return o().createElement("div",{className:n.root},o().createElement(Et.Z,{value:r},o().createElement(ee.Typography,{variant:"subtitle2",className:n.label,align:"center",noWrap:!0},r)),o().createElement("svg",{width:"110",height:"12",fill:"black",fillOpacity:"0.3"},"out"===a&&o().createElement("polygon",{points:"94 0, 110 6, 94 12, 94 9, 0 9, 0 3, 94 3"}),"bidirectional"===a&&o().createElement("polygon",{points:"94 0, 110 6, 94 12, 94 9, 16 9, 16 12, 0 6, 16 0, 16 3, 94 3"}),"in"===a&&o().createElement("polygon",{points:"16 12, 0 6, 16 0, 16 3, 110 3, 110 9, 16 9"})))};var Dt=n(8459),Nt=n(27604);const Zt=(0,se.Z)((()=>({root:{"&:hover $editButton":{visibility:"visible"}},editButton:{visibility:"hidden",marginLeft:"4px",marginBottom:"4px"},paper:{width:"150px",border:"3px solid rgba(0, 0, 0, 0.3)",borderRadius:"4px",boxSizing:"border-box",overflow:"hidden"}}))),It=e=>{let{value:t=null,onChange:n,readOnly:r}=e;const l=Zt(),i=(0,a.useRef)(),[s,c]=(0,a.useState)(!1),u=()=>c(!1),[p,d]=(0,a.useState)(t),m=()=>{p!==t&&n(p),u()};return o().createElement("span",{ref:i,className:l.root},t&&(0,h.p6d)(t),o().createElement(We.Z,{disabled:r,icon:Nt.Z,size:"XXS",className:l.editButton,onClick:()=>c(!0)}),o().createElement(ee.Popover,{classes:{paper:l.paper},open:s,anchorEl:i.current,anchorOrigin:{vertical:"top",horizontal:"left"},transformOrigin:{vertical:14,horizontal:20},onKeyUp:e=>{"Enter"===e.key?m():"Escape"===e.key&&u()},onBackdropClick:m},o().createElement(Dt.Z,{InputProps:{autoFocus:!0,disableUnderline:!0,fullWidth:!0},size:"small",hiddenLabel:!0,label:void 0,value:p&&new Date(p),onChange:e=>d(e&&e.valueOf())})))},jt=(0,se.Z)((e=>({relationBand:{flexShrink:0,boxShadow:"inset 0px -1px 0px rgba(0,0,0,0.06)",padding:"16px 19px"},inactiveRelationBand:{opacity:.6,background:"rgba(185, 188, 197, 0.18)"},toolbar:{display:"flex",alignItems:"center",gap:"16px",marginBottom:"10px"},mainInfo:{display:"flex",gap:"16px",marginLeft:"40px"},detailsInfo:{display:"flex",gap:"34px",marginLeft:"40px",marginTop:"17px",color:e.palette.text.secondary,fontSize:"13px"},detailTitle:{color:e.palette.text.primary,flexShrink:0,marginRight:"4px"},directionalLabel:{display:"flex",overflow:"hidden","& span":{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"}},relationDate:{flexShrink:0},commentsContainer:{marginRight:"18px"}})));function Mt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){At(e,t,n[t])}))}return e}function At(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const Lt=(0,a.memo)((e=>{let{readOnly:t,entity:n,connection:a,onNavigateBack:r,onDelete:l,onChangeActivenessDate:i}=e;const s=!(0,h.Fn9)(a.relation),c=jt();return o().createElement("div",{className:Ce()(c.relationBand,we.U,{[c.inactiveRelationBand]:s})},o().createElement("div",{className:c.toolbar},o().createElement(We.Z,{icon:St.Z,size:"S",onClick:()=>r()}),o().createElement(ee.Typography,{variant:"subtitle2",display:"inline"},N().text("Back to relationships")),o().createElement(ae.Z,null),o().createElement("div",{className:c.commentsContainer},o().createElement(Oe.Z,{uri:a.relation.relationUri,relatedObjectUris:(0,h.wp9)(h.q7e.RELATION,{entityUri:null==n?void 0:n.uri,connection:a}),objectType:h.q7e.RELATION,allowOnlyOneComment:!0})),o().createElement(Ke,{connection:a,onDelete:l,disableDelete:t})),o().createElement("div",{className:c.mainInfo},o().createElement(Ot,{entity:n}),o().createElement(Rt,{relation:a.relation}),o().createElement(Ot,{entity:Mt({},a.entity.object,{dataTenant:a.entity.dataTenant})})),o().createElement("div",{className:c.detailsInfo},o().createElement("div",{className:c.directionalLabel},o().createElement("span",{className:c.detailTitle},N().text("Directional label:")),o().createElement(Et.Z,{value:a.relation.relationLabel},o().createElement("span",null,a.relation.relationLabel))),o().createElement("div",{className:c.relationDate},o().createElement("span",{className:c.detailTitle},N().text("Start date:")),o().createElement(It,{value:a.relation.startDate,onChange:e=>i("startDate",e),readOnly:t})),o().createElement("div",{className:c.relationDate},o().createElement("span",{className:c.detailTitle},N().text("End date:")),o().createElement(It,{value:a.relation.endDate,onChange:e=>i("endDate",e),readOnly:t}))))})),Ft=e=>{console.error(e),d.Z.addError({title:N().text("Error"),message:(0,h.xU7)(e,N().text("Something went wrong"))})};var Bt=n(58651),Ut=n(13896);const zt=(0,se.Z)({detailsView:{position:"absolute",top:0,left:0,right:0,bottom:0,overflow:"hidden"},locked:{pointerEvents:"none"},resizablePanesWrapper:{flexGrow:1},pane:{position:"absolute",top:0,left:0,right:0,bottom:0,display:"flex",flexDirection:"column",overflow:"hidden"}}),_t=(0,a.memo)((e=>{let{entity:t,connection:n,visibleColumns:r,onClose:l,onDeleteConnection:i,onChangeConnection:s,onChangeVisibleColumns:c,readOnly:u}=e;const p=zt(),d=(()=>{const[e,t]=(0,a.useState)([]),n=(0,a.useRef)([]),o=(0,a.useCallback)((0,h.DsO)((()=>{t([...n.current])}),50),[]),r=(0,a.useCallback)((e=>{n.current=e,o(e)}),[o]),l=(0,a.useCallback)(((e,t)=>{e&&r(t?[e]:[])}),[r]),[i,s]=(0,a.useState)([]),c=(0,a.useCallback)((e=>{e&&s((t=>{return n=[e],a=t,(0,f.concat)(n.filter((e=>!(0,f.any)((0,h.aFF)(e),a))),a.filter((e=>!(0,f.any)((0,h.aFF)(e),n))));var n,a}))}),[]);return{highlightedCrosswalks:(0,a.useMemo)((()=>[...e,...i]),[e,i]),focusedCrosswalks:i,toggleCrosswalkFocus:c,setCrosswalkHighlighted:l}})(),[m,y]=(0,a.useState)(-480),g=(0,a.useCallback)((e=>{let{percentageSize:t}=e;return y(t)}),[]),[b,v]=(0,a.useState)(),[x,E]=(0,a.useState)(!1),S=n.relation.relationUri,C=(0,tt._)(),w=(0,a.useCallback)((()=>E(!0)),[]),T=(0,a.useCallback)((()=>E(!1)),[]),P=(0,a.useCallback)((0,f.pipe)(i,w),[]),[O,k]=(0,a.useMemo)((()=>{const e=e=>{e.errorCode===h.Xt7.CROSSWALK_NOT_FOUND?(Ft(e),t()):e.errorCode===h.Xt7.OBJECT_NOT_FOUND?l(e):(Ft(e),T())},t=()=>{C((0,h._vs)(S)).then((e=>{s((0,f.assocPath)(["relation","object"],e,n)),T()})).catch(e)};return[e,t]}),[n,T,s,l]),{modifiedEntity:R,crosswalksMap:D,newlyCreatedAttributes:N,onPinAttribute:Z,onIgnoreAttribute:I,onAddAttribute:j,onEditAttribute:M,onDeleteAttribute:A}=(0,nt.Q)({entity:n.relation.object,onModify:k,onError:O,onLoad:w}),{addCrosswalk:L,deleteCrosswalk:F,editCrosswalk:B}=(0,at.P)({onSuccess:k,onError:O,onLoad:w}),U=(0,a.useCallback)(((e,t)=>{w(),(t?(0,h.rj2)({entityUri:S,attributeName:e,value:t}).then((()=>s((0,f.assocPath)(["relation",e],t,n)))):(0,h.X78)({entityUri:S,attributeName:e}).then((()=>s((0,f.dissocPath)(["relation",e],n))))).then(T).catch(O)}),[n,w,T,O]);return o().createElement(ot.Z,{className:p.detailsView},o().createElement(rt.hR,d,o().createElement(Ut.DndProvider,{backend:Bt.default},o().createElement(lt.Z,null),o().createElement(it.Z,{className:Ce()(p.resizablePanesWrapper,{[p.locked]:x}),orientation:"vertical",size:m,minSize:600,maxSize:-480,allowResize:!0,onChange:g},o().createElement("div",{className:p.pane},o().createElement(Lt,{readOnly:u,entity:t,connection:n,onNavigateBack:l,onDelete:P,onChangeActivenessDate:U}),o().createElement(st.R,{attributeUris:N},o().createElement(ct.Z,{readOnly:u,entity:R,crosswalksMap:D,isLoading:x,onPin:Z,onIgnore:I,onEdit:M,onAdd:j,onDelete:A,selectedAttributeTypes:b,onSelectAttributeTypes:v,visibleColumns:r,onChangeVisibleColumns:c}))),o().createElement(xt,{readOnly:u,className:p.pane,relation:n.relation.object,selectedAttributeTypes:b,onAddCrosswalk:L,onDeleteCrosswalk:F,onEditCrosswalk:B})))))})),Ht=(0,se.Z)({relationshipsView:{position:"absolute",top:0,left:0,right:0,bottom:0,overflowX:"hidden",overflowY:"auto",fontFamily:"Roboto, Helvetica, Arial, sans-serif",display:"flex",flexDirection:"column"},"@global div[role=tooltip]":{fontFamily:"Roboto, Helvetica, Arial, sans-serif"},"@global div[role=presentation]":{fontFamily:"Roboto, Helvetica, Arial, sans-serif"},pane:{display:"flex",flexDirection:"column",flex:1,overflow:"hidden",position:"relative"}}),Wt=(0,r.connect)(((e,t)=>{let{config:{id:n}}=t;return{entity:m.ZP.selectors.getEntity(e),metadata:m.ZP.selectors.getMetadata(e),connections:m.ZP.selectors.getConnectionsByViewId(e,n),total:m.ZP.selectors.getTotalByViewId(e,n)}}))((e=>{let{config:t,entity:n,metadata:r,connections:l,total:i,saveState:s,getSavedState:c,dispatch:u}=e;const p=Ht(),d=(0,a.useRef)(),T=(0,h.biM)(n),[k,D]=(0,a.useState)(!1),{type:N}=n||{},[{visibleColumns:Z,filters:I,page:F,rowsPerPage:z,sorting:Y,currentRelationType:ee,stateToSave:te,entityTypeOfAppliedSavedState:ne},{changeColumns:ae,toggleFilters:oe,changeFilter:re,changePage:le,changeRowsPerPage:ie,toggleSort:se,changeRelationType:ce,saveCurrentState:ue,applySavedState:pe}]=(e=>{let{defaultColumns:t,defaultSorting:n,defaultRowsPerPage:o}=e;const r={visibleColumns:t,filters:null,sorting:n,page:0,rowsPerPage:o,currentRelationType:null,stateToSave:null,visibleColumnsForRelationTypes:{},entityTypeOfAppliedSavedState:null},[l,i]=(0,a.useReducer)(((e,t)=>{switch(t.type){case _:{const n=t.payload;return(0,f.pipe)(K,(0,f.assoc)("currentRelationType",n),$,q)(e)}case H:{const{savedState:n,entityTypeUri:a}=t.payload,o=n?G(n):e.visibleColumns;return U({},e,n,{filters:n?X(n):e.filters,visibleColumns:o,entityTypeOfAppliedSavedState:a})}case W:return U({},e,{stateToSave:Q(e)});default:return O.ZP.reducer(e,t)}}),r);return[l,(0,R.o)({actions:V,dispatch:i})]})({defaultColumns:M,defaultRowsPerPage:L[0],defaultSorting:{field:M[0],order:"asc"}}),me=ne===N,{isLoading:fe,relationsTableSavedState:he,attributesTableSavedState:ye,updateRelationsTableSavedState:ge,updateAttributesTableSavedState:be}=(e=>{var t;let{getSavedState:n,saveState:o,entityTypeUri:r}=e;const[l,i]=(0,a.useState)(P),[s,c]=(0,a.useState)(null);(0,y.D)((()=>{s&&(i(w({},l,{relationsTable:s})),c(null))}),[r]);const[u,p]=(0,a.useState)(!0);return(0,a.useEffect)((()=>{n().then((e=>{i(e||P)})).then((e=>p(!1))).catch((e=>p(!1)))}),[]),{isLoading:u,relationsTableSavedState:null===(t=l.relationsTable)||void 0===t?void 0:t[r],attributesTableSavedState:l.attributesTable,updateRelationsTableSavedState:e=>{const t=w({},l.relationsTable,{[r]:e});c(t),o(w({},l,{relationsTable:t}))},updateAttributesTableSavedState:e=>{o(w({},l,{attributesTable:e}))}}})({getSavedState:c,saveState:s,entityTypeUri:N}),[ve,xe]=(0,a.useState)();(0,a.useEffect)((()=>{fe||pe({savedState:he,entityTypeUri:N})}),[fe,N]),(0,a.useEffect)((()=>{fe||xe(null==ye?void 0:ye.visibleColumns)}),[fe]),(0,y.D)((()=>{me&&ge(te)}),[te]),(0,y.D)((()=>{le(0)}),[n]);const[Ee,Se]=(0,a.useState)(),Ce=(0,a.useCallback)((()=>{Se(null)}),[]),we=(0,a.useMemo)((()=>{const e=(0,h.io3)(r,N);return r.relationTypes.filter((0,f.both)((0,h.uGe)(h.BDP.READ),(t=>{let{startObject:n,endObject:a}=t;return e.some((0,f.either)((0,f.equals)(n.objectTypeURI),(0,f.equals)(a.objectTypeURI)))})))}),[r,N]),Te=(0,a.useMemo)((()=>((e,t)=>t?(0,f.pipe)((0,f.find)((e=>e.uri===t)),h.DK$,B,(0,f.concat)(j),(0,f.reject)((e=>{let{id:t}=e;return A.includes(t)})))(e):(e=>{return t=(0,f.assoc)("dataTypeDefinition",(e=>({type:h.oS0.TYPE_SELECT,options:e.map((e=>{let{uri:t,label:n}=e;return{value:t,label:n}}))}))(e)),e=>(0,f.adjust)(e.findIndex((0,f.propEq)("id","relation.type")),t,e);var t})(e)(j))(we,ee)),[we,ee]),Pe=(0,a.useMemo)((()=>Z.map((e=>Te.find((0,f.propEq)("id",e)))).filter(f.identity)),[Z,Te]),Oe=(0,a.useMemo)((()=>{const e=(0,f.pipe)((0,f.when)((0,f.always)(ee),(0,f.filter)((0,f.propEq)("uri",ee))),(0,f.map)((0,f.prop)("uri")))(we);return{id:t.id,content:{inRelations:e,outRelations:e}}}),[t.id,ee,we]),ke=(0,a.useMemo)((()=>((e,t)=>{const n=(0,J.Tz)(t,e);return(new h.MEy).addClause(n).build()})(I,Pe)),[I,Pe]),{isLoading:Re,reload:De}=(0,g.a)({page:F,rowsPerPage:z,config:Oe,entity:me?n:null,filter:ke,mode:h.ARY.Viewing,sorting:Y,searchByOv:k}),Ne=!me||Re,Ze=(0,a.useCallback)((0,f.pipe)(se,ue),[se,ue]),Ie=(0,a.useCallback)((0,f.pipe)(re,ue),[re,ue]),je=(0,a.useCallback)((0,f.pipe)(oe,ue),[oe,ue]),Me=(0,a.useCallback)((0,f.pipe)(ae,ue),[ae,ue]),Ae=(0,a.useCallback)((0,f.pipe)(ce,ue),[ce,ue]),Le=(0,a.useCallback)((e=>{xe(e),be({visibleColumns:e})}),[be]),Fe=null==l?void 0:l[Ee],Be=(0,a.useCallback)((e=>{u(m.N5.relations.actions.relationsLoaded({id:t.id,connections:(0,f.update)(Ee,e,l),total:i}))}),[Fe]),[Ue,ze]=(0,a.useMemo)((()=>[(0,h.w3p)(l),[h.q7e.RELATION]]),[l]),_e=(0,b.C)({objectIds:Ue,objectTypes:ze,enabled:!T}),He=(0,a.useMemo)((()=>(0,h.Px$)(l)),[l]),We=(0,a.useCallback)((e=>{Ft(e),e.errorCode===h.Xt7.OBJECT_NOT_FOUND&&De()}),[De]),Ve=(0,a.useCallback)((e=>{(0,f.pipe)(h.VGk,(0,f.andThen)(De),(0,f.otherwise)(We))(e)}),[De,We]),qe=(0,a.useCallback)((()=>{(0,f.pipe)(h.VGk,(0,f.andThen)((0,f.pipe)(Ce,De)),(0,f.otherwise)((e=>{e.errorCode===h.Xt7.OBJECT_NOT_FOUND&&Ce(),We(e)})))(Fe.relation.relationUri)}),[Fe,De,Ce,We]),Ye=(0,a.useCallback)((e=>{e&&We(e),Ce()}),[We,Ce]),Ge=(0,a.useCallback)((()=>{D(f.not)}),[D]);return o().createElement(v.e,{collaboration:_e},o().createElement(x.X.Provider,{value:He},o().createElement("div",{className:p.relationshipsView},o().createElement(E.n,{entity:n}),o().createElement(de,{total:i,filteringEnabled:!!I,onToggleFilters:je,columnsData:Te,selectedColumns:Z,onChangeColumns:Me,relationTypes:we,currentRelationType:ee,onRelationTypeChange:Ae,searchByOv:k,onToggleSearchByOv:Ge}),o().createElement("div",{className:p.pane},Ne&&o().createElement(S.Z,null),o().createElement(et,{readOnly:T,metadata:r,connections:l,columnsData:Pe,sorting:Y,onSort:Ze,filters:I,onFilter:Ie,onRowClick:Se,tableRef:d,onDelete:Ve}),o().createElement(C.Z,{count:i,rowsPerPageOptions:L,page:F,onChangePage:le,rowsPerPage:z,onChangeRowsPerPage:ie,basicTableRef:d})),Fe&&o().createElement(_t,{readOnly:T,entity:n,visibleColumns:ve,onChangeVisibleColumns:Le,connection:Fe,onClose:Ye,onDeleteConnection:qe,onChangeConnection:Be}))))}));function Vt(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const qt=(0,i.createGenerateClassName)({productionPrefix:"relationshipsPerspective",disableGlobal:!0}),Yt=e=>{let{config:t,store:n,onResize:f,saveState:y,getSavedState:g}=e;const b=(0,a.useCallback)((0,h.aYu)(g),[g]),v=(0,a.useContext)(u.Y),x=m.ZP.selectors.getShowAttributeDescription(n.getState()),E=(0,a.useMemo)((()=>function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){Vt(e,t,n[t])}))}return e}({},v,{showDescription:x})),[v,x]);return o().createElement(r.Provider,{store:n},o().createElement(p.m.Provider,{value:t.id},o().createElement(u.Y.Provider,{value:E},o().createElement(i.StylesProvider,{generateClassName:qt},o().createElement(c.MuiPickersUtilsProvider,{utils:l.Z},o().createElement(s.Z,{handleHeight:!0,onResize:(e,t)=>null==f?void 0:f(Math.floor(e),Math.floor(t))}),t&&o().createElement(Wt,{config:t,saveState:y,getSavedState:b}),o().createElement(d.Z,null))))))}},46847:(e,t,n)=>{function a(){var e=this.constructor.getDerivedStateFromProps(this.props,this.state);null!=e&&this.setState(e)}function o(e){this.setState(function(t){var n=this.constructor.getDerivedStateFromProps(e,t);return null!=n?n:null}.bind(this))}function r(e,t){try{var n=this.props,a=this.state;this.props=e,this.state=t,this.__reactInternalSnapshotFlag=!0,this.__reactInternalSnapshot=this.getSnapshotBeforeUpdate(n,a)}finally{this.props=n,this.state=a}}function l(e){var t=e.prototype;if(!t||!t.isReactComponent)throw new Error("Can only polyfill class components");if("function"!=typeof e.getDerivedStateFromProps&&"function"!=typeof t.getSnapshotBeforeUpdate)return e;var n=null,l=null,i=null;if("function"==typeof t.componentWillMount?n="componentWillMount":"function"==typeof t.UNSAFE_componentWillMount&&(n="UNSAFE_componentWillMount"),"function"==typeof t.componentWillReceiveProps?l="componentWillReceiveProps":"function"==typeof t.UNSAFE_componentWillReceiveProps&&(l="UNSAFE_componentWillReceiveProps"),"function"==typeof t.componentWillUpdate?i="componentWillUpdate":"function"==typeof t.UNSAFE_componentWillUpdate&&(i="UNSAFE_componentWillUpdate"),null!==n||null!==l||null!==i){var s=e.displayName||e.name,c="function"==typeof e.getDerivedStateFromProps?"getDerivedStateFromProps()":"getSnapshotBeforeUpdate()";throw Error("Unsafe legacy lifecycles will not be called for components using new component APIs.\n\n"+s+" uses "+c+" but also contains the following legacy lifecycles:"+(null!==n?"\n "+n:"")+(null!==l?"\n "+l:"")+(null!==i?"\n "+i:"")+"\n\nThe above lifecycles should be removed. Learn more about this warning here:\nhttps://fb.me/react-async-component-lifecycle-hooks")}if("function"==typeof e.getDerivedStateFromProps&&(t.componentWillMount=a,t.componentWillReceiveProps=o),"function"==typeof t.getSnapshotBeforeUpdate){if("function"!=typeof t.componentDidUpdate)throw new Error("Cannot polyfill getSnapshotBeforeUpdate() for components that do not define componentDidUpdate() on the prototype");t.componentWillUpdate=r;var u=t.componentDidUpdate;t.componentDidUpdate=function(e,t,n){var a=this.__reactInternalSnapshotFlag?this.__reactInternalSnapshot:n;u.call(this,e,t,a)}}return e}n.r(t),n.d(t,{polyfill:()=>l}),a.__suppressDeprecationWarning=!0,o.__suppressDeprecationWarning=!0,r.__suppressDeprecationWarning=!0}}]);
1
+ "use strict";(self.webpackChunk_reltio_remotes=self.webpackChunk_reltio_remotes||[]).push([[3270],{8598:(e,t,n)=>{n.d(t,{Z:()=>r});var a=n(95038),o=n.n(a);const r=function(){function e(e){var t=void 0===e?{}:e,n=t.locale,a=t.instance,r=t.moment;this.yearFormat="YYYY",this.yearMonthFormat="MMMM YYYY",this.dateTime12hFormat="MMMM Do hh:mm a",this.dateTime24hFormat="MMMM Do HH:mm",this.time12hFormat="hh:mm A",this.time24hFormat="HH:mm",this.dateFormat="MMMM Do",this.moment=a||r||o(),this.locale=n}return e.prototype.parse=function(e,t){return""===e?null:this.moment(e,t,!0)},e.prototype.date=function(e){if(null===e)return null;var t=this.moment(e);return t.locale(this.locale),t},e.prototype.isValid=function(e){return this.moment(e).isValid()},e.prototype.isNull=function(e){return null===e},e.prototype.getDiff=function(e,t){return e.diff(t)},e.prototype.isAfter=function(e,t){return e.isAfter(t)},e.prototype.isBefore=function(e,t){return e.isBefore(t)},e.prototype.isAfterDay=function(e,t){return e.isAfter(t,"day")},e.prototype.isBeforeDay=function(e,t){return e.isBefore(t,"day")},e.prototype.isBeforeYear=function(e,t){return e.isBefore(t,"year")},e.prototype.isAfterYear=function(e,t){return e.isAfter(t,"year")},e.prototype.startOfDay=function(e){return e.clone().startOf("day")},e.prototype.endOfDay=function(e){return e.clone().endOf("day")},e.prototype.format=function(e,t){return e.locale(this.locale),e.format(t)},e.prototype.formatNumber=function(e){return e},e.prototype.getHours=function(e){return e.get("hours")},e.prototype.addDays=function(e,t){return t<0?e.clone().subtract(Math.abs(t),"days"):e.clone().add(t,"days")},e.prototype.setHours=function(e,t){return e.clone().hours(t)},e.prototype.getMinutes=function(e){return e.get("minutes")},e.prototype.setMinutes=function(e,t){return e.clone().minutes(t)},e.prototype.getSeconds=function(e){return e.get("seconds")},e.prototype.setSeconds=function(e,t){return e.clone().seconds(t)},e.prototype.getMonth=function(e){return e.get("month")},e.prototype.isSameDay=function(e,t){return e.isSame(t,"day")},e.prototype.isSameMonth=function(e,t){return e.isSame(t,"month")},e.prototype.isSameYear=function(e,t){return e.isSame(t,"year")},e.prototype.isSameHour=function(e,t){return e.isSame(t,"hour")},e.prototype.setMonth=function(e,t){return e.clone().month(t)},e.prototype.getMeridiemText=function(e){return"am"===e?"AM":"PM"},e.prototype.startOfMonth=function(e){return e.clone().startOf("month")},e.prototype.endOfMonth=function(e){return e.clone().endOf("month")},e.prototype.getNextMonth=function(e){return e.clone().add(1,"month")},e.prototype.getPreviousMonth=function(e){return e.clone().subtract(1,"month")},e.prototype.getMonthArray=function(e){for(var t=[e.clone().startOf("year")];t.length<12;){var n=t[t.length-1];t.push(this.getNextMonth(n))}return t},e.prototype.getYear=function(e){return e.get("year")},e.prototype.setYear=function(e,t){return e.clone().set("year",t)},e.prototype.mergeDateAndTime=function(e,t){return this.setMinutes(this.setHours(e,this.getHours(t)),this.getMinutes(t))},e.prototype.getWeekdays=function(){return this.moment.weekdaysShort(!0)},e.prototype.isEqual=function(e,t){return null===e&&null===t||this.moment(e).isSame(t)},e.prototype.getWeekArray=function(e){for(var t=e.clone().startOf("month").startOf("week"),n=e.clone().endOf("month").endOf("week"),a=0,o=t,r=[];o.isBefore(n);){var l=Math.floor(a/7);r[l]=r[l]||[],r[l].push(o),o=o.clone().add(1,"day"),a+=1}return r},e.prototype.getYearRange=function(e,t){for(var n=this.moment(e).startOf("year"),a=this.moment(t).endOf("year"),o=[],r=n;r.isBefore(a);)o.push(r),r=r.clone().add(1,"year");return o},e.prototype.getCalendarHeaderText=function(e){return this.format(e,this.yearMonthFormat)},e.prototype.getYearText=function(e){return this.format(e,"YYYY")},e.prototype.getDatePickerHeaderText=function(e){return this.format(e,"ddd, MMM D")},e.prototype.getDateTimePickerHeaderText=function(e){return this.format(e,"MMM D")},e.prototype.getMonthText=function(e){return this.format(e,"MMMM")},e.prototype.getDayText=function(e){return this.format(e,"D")},e.prototype.getHourText=function(e,t){return this.format(e,t?"hh":"HH")},e.prototype.getMinuteText=function(e){return this.format(e,"mm")},e.prototype.getSecondText=function(e){return this.format(e,"ss")},e}()},27604:(e,t,n)=>{var a=n(71600);t.Z=void 0;var o=a(n(24328)),r=(0,a(n(50175)).default)(o.default.createElement("path",{d:"M3 17.25V21h3.75L17.81 9.94l-3.75-3.75L3 17.25zM20.71 7.04c.39-.39.39-1.02 0-1.41l-2.34-2.34a.9959.9959 0 00-1.41 0l-1.83 1.83 3.75 3.75 1.83-1.83z"}),"Edit");t.Z=r},71519:(e,t,n)=>{var a=n(71600);t.Z=void 0;var o=a(n(24328)),r=(0,a(n(50175)).default)(o.default.createElement("path",{d:"M9.31 17l2.44-2.44L14.19 17l1.06-1.06-2.44-2.44 2.44-2.44L14.19 10l-2.44 2.44L9.31 10l-1.06 1.06 2.44 2.44-2.44 2.44L9.31 17zM19 3h-1V1h-2v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V8h14v11z"}),"EventBusy");t.Z=r},99144:(e,t,n)=>{var a=n(71600);t.Z=void 0;var o=a(n(24328)),r=(0,a(n(50175)).default)(o.default.createElement("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z"}),"Info");t.Z=r},67766:(e,t,n)=>{var a=n(71600);t.Z=void 0;var o=a(n(24328)),r=(0,a(n(50175)).default)(o.default.createElement("path",{d:"M15.41 16.59L10.83 12l4.58-4.59L14 6l-6 6 6 6 1.41-1.41z"}),"KeyboardArrowLeft");t.Z=r},42767:(e,t,n)=>{var a=n(71600);t.Z=void 0;var o=a(n(24328)),r=(0,a(n(50175)).default)(o.default.createElement("path",{d:"M8.59 16.59L13.17 12 8.59 7.41 10 6l6 6-6 6-1.41-1.41z"}),"KeyboardArrowRight");t.Z=r},47603:(e,t,n)=>{var a=n(71600);t.Z=void 0;var o=a(n(24328)),r=(0,a(n(50175)).default)(o.default.createElement(o.default.Fragment,null,o.default.createElement("path",{transform:"scale(1.2, 1.2)",fill:"none",d:"M0 0h20v20H0V0z"}),o.default.createElement("path",{transform:"scale(1.2, 1.2)",d:"M15.95 10.78c.03-.25.05-.51.05-.78s-.02-.53-.06-.78l1.69-1.32c.15-.12.19-.34.1-.51l-1.6-2.77c-.1-.18-.31-.24-.49-.18l-1.99.8c-.42-.32-.86-.58-1.35-.78L12 2.34c-.03-.2-.2-.34-.4-.34H8.4c-.2 0-.36.14-.39.34l-.3 2.12c-.49.2-.94.47-1.35.78l-1.99-.8c-.18-.07-.39 0-.49.18l-1.6 2.77c-.1.18-.06.39.1.51l1.69 1.32c-.04.25-.07.52-.07.78s.02.53.06.78L2.37 12.1c-.15.12-.19.34-.1.51l1.6 2.77c.1.18.31.24.49.18l1.99-.8c.42.32.86.58 1.35.78l.3 2.12c.04.2.2.34.4.34h3.2c.2 0 .37-.14.39-.34l.3-2.12c.49-.2.94-.47 1.35-.78l1.99.8c.18.07.39 0 .49-.18l1.6-2.77c.1-.18.06-.39-.1-.51l-1.67-1.32zM10 13c-1.65 0-3-1.35-3-3s1.35-3 3-3 3 1.35 3 3-1.35 3-3 3z"})),"Settings");t.Z=r},72753:(e,t,n)=>{var a=n(71600);t.Z=void 0;var o=a(n(24328)),r=(0,a(n(50175)).default)(o.default.createElement("path",{d:"M12 4.5C7 4.5 2.73 7.61 1 12c1.73 4.39 6 7.5 11 7.5s9.27-3.11 11-7.5c-1.73-4.39-6-7.5-11-7.5zM12 17c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5zm0-8c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3z"}),"Visibility");t.Z=r},32528:(e,t,n)=>{n.d(t,{Z:()=>r});var a=n(13688),o=n(48852);const r=e=>t=>(0,o.l)(a.X,e,t)},58662:(e,t,n)=>{n.d(t,{Z:()=>b});var a=n(13980),o=n.n(a),r=n(24328),l=n.n(r),i=n(71153),s=n.n(i),c=n(94079),u=n(87918),p=n.n(u),d=n(31276),m=n(17440);const f=(0,n(79692).Z)({pagination:{display:"flex",alignItems:"center",justifyContent:"flex-end",height:"56px",borderTop:"1px solid rgba(0,0,0,0.12)",boxShadow:"none"},caption:{color:"rgba(0,0,0,0.6)",fontSize:"12px",lineHeight:"16px"},selectRoot:{marginLeft:"5px",marginRight:"36px"},select:{color:"rgba(0,0,0,0.6)",fontSize:"12px",lineHeight:"16px",textAlign:"right"},actions:{marginLeft:"32px"}});function h(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){y(e,t,n[t])}))}return e}function y(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const g=e=>{let{classes:t={},count:n,rowsPerPageOptions:a,page:o,onChangePage:i,rowsPerPage:u,onChangeRowsPerPage:y,basicTableRef:g,labelRowsPerPage:b}=e;const v=f(),x=(0,r.useCallback)((()=>{(0,m.pathOr)(m.identity,["current","resetScrollbarPosition"],g)()}),[g]),E=(0,r.useCallback)((e=>{i(e),x()}),[i,x]),S=(0,r.useCallback)((e=>{i(0),y(e),x()}),[i,y,x]);return l().createElement(c.TablePagination,{classes:h({},t,{root:s()(v.pagination,t.root),select:s()(v.select,t.select),caption:v.caption,selectRoot:v.selectRoot,actions:v.actions}),component:"div",labelRowsPerPage:b||p().text("Rows per page:"),labelDisplayedRows:e=>{let{from:t,to:n,count:a}=e;return p().text("${fromRow}-${toRow} of ${countRows}",{fromRow:p().number(t,"0,0"),toRow:p().number(n,"0,0"),countRows:p().number(a,"0,0")})},count:n,rowsPerPageOptions:a,page:o,onChangePage:(0,m.pipe)((0,m.nthArg)(1),E),rowsPerPage:u,onChangeRowsPerPage:(0,m.pipe)(d.NA,S)})};g.propTypes={classes:o().object,rowsPerPageOptions:o().arrayOf(o().number),count:o().number,page:o().number,onChangePage:o().func,rowsPerPage:o().number,onChangeRowsPerPage:o().func,basicTableRef:o().shape({current:o().object}),labelRowsPerPage:o().string};const b=l().memo(g)},81137:(e,t,n)=>{n.d(t,{Z:()=>c});var a=n(24328),o=n.n(a),r=n(87918),l=n.n(r),i=n(94079);const s=(0,n(79692).Z)({paper:{minHeight:"180px"},title:{padding:"16px 16px 10px 16px",fontSize:"20px",fontWeight:500,letterSpacing:"0.25px",lineHeight:"24px"},content:{padding:"0 16px"},contentText:{marginBottom:0,fontSize:"16px",letterSpacing:"0.15px",lineHeight:"24px"},actionButtons:{display:"flex",paddingTop:"4px",fontSize:"14px",fontWeight:500,letterSpacing:0,lineHeight:"16px","& > div":{marginLeft:"auto"}},discardButton:{marginRight:"8px"}}),c=e=>{let{open:t,title:n,content:a,onCancel:r,cancelCaption:c=l().text("Cancel"),onDiscard:u,discardCaption:p="",onSave:d,saveCaption:m=l().text("Save"),disabledSave:f=!1}=e;const h=s();return o().createElement(i.Dialog,{open:t,onClose:r,classes:{paperScrollPaper:h.paper}},o().createElement(i.DialogTitle,{classes:{root:h.title}},n),o().createElement(i.DialogContent,{classes:{root:h.content}},o().createElement(i.DialogContentText,{classes:{root:h.contentText}},a)),o().createElement(i.DialogActions,{className:h.actionButtons,disableSpacing:!0},r&&o().createElement(i.Button,{onClick:r},c),o().createElement("div",null,u&&o().createElement(i.Button,{onClick:u,classes:{root:h.discardButton}},p),o().createElement(i.Button,{onClick:d,color:"primary",disabled:f,autoFocus:!0},m))))}},68439:(e,t,n)=>{n.d(t,{Z:()=>m});var a=n(24328),o=n.n(a),r=n(52730),l=n(71153),i=n.n(l),s=n(94079),c=n(16657),u=n(49885),p=n(95613);const d=(0,n(79692).Z)({"entityType-overflow":{textOverflow:"ellipsis",overflow:"hidden",whiteSpace:"nowrap"},"entityType-small":{padding:"1px 4px",fontSize:"10px",lineHeight:"normal",marginRight:"12px",borderRadius:"2px",flexShrink:0},"entityType-medium":{padding:"2px 8px 3px",borderRadius:"2px",fontSize:"13px",fontWeight:500,lineHeight:"15px",marginRight:"16px",flexShrink:0}}),m=e=>{let{entity:t,className:n,size:a="small"}=e;const l=d(),m=(0,r.useSelector)(u.ZP.selectors.getMetadata),f=t.type,h=(0,c.nt9)(m,f)||{},y=(0,c.VD3)(m,h,"typeColor")||c.rSc.palette.primary.main,g=(0,c.jFi)(m,t);return o().createElement(p.Z,{value:g,placement:"top"},o().createElement(s.Typography,{style:{backgroundColor:y,color:c.P6Y.Colors.getColor(y)?"#FFFFFF":"#212121"},className:i()(l[`entityType-${a}`],l["entityType-overflow"],n),component:"div"},g))}},64459:(e,t,n)=>{n.d(t,{Z:()=>g});var a=n(24328),o=n.n(a),r=n(71153),l=n.n(r),i=n(52730),s=n(17440),c=n(94079),u=n(87918),p=n.n(u),d=n(16657),m=n(49885),f=n(53180),h=n(68439);const y=(0,n(79692).Z)((e=>({profileBandWrapper:{flexShrink:0},profileBand:{display:"flex",padding:"16px 12px 16px 16px",alignItems:"flex-start",backgroundColor:"#fff",boxShadow:"0px 1px 0px rgba(0, 0, 0, 0.12)",marginBottom:"1px","&:after":{content:'""',minHeight:"inherit",fontSize:0}},inactive:{background:e.inactiveBackground},profileIcon:{marginRight:"12px"},imageProfileIcon:{width:"48px",height:"48px"},profileInfo:{display:"flex",flexDirection:"column",flex:"1 1 50%"},badge:{},label:{lineHeight:"1.2",letterSpacing:"0.25px",color:e.palette.text.primary,wordBreak:"break-word","&+ $specialInfo":{marginTop:"4px"}},secondaryLabel:{display:"inline-flex",color:e.palette.text.primary,marginTop:"2px",lineHeight:"16px",fontSize:"14px",fontWeight:400,"&+ $businessCard":{marginLeft:"12px"}},businessCard:{color:e.palette.text.secondary,display:"inline-flex",fontSize:"14px",marginTop:"4px",lineHeight:"1.2"},specialInfo:{display:"flex",justifyContent:"space-between",flexWrap:"wrap",width:"100%",marginTop:"8px"},entityType:{display:"flex",flexWrap:"wrap"},entityId:{fontSize:"13px",color:e.palette.text.secondary,whiteSpace:"nowrap",cursor:"pointer","&:hover":{textDecoration:"underline"}}}))),g=e=>{let{className:t,entity:n,children:r,classes:u,renderLabel:g=s.identity}=e;const b=y({classes:u}),v=(0,i.useSelector)(m.ZP.selectors.getMetadata),x=(0,i.useSelector)(m.ZP.selectors.getShowEntityId),E=(0,a.useCallback)((()=>{navigator.clipboard.writeText((0,d.BTI)(n))}),[n]);if((0,s.isNil)(n))return null;const S=(0,d.idV)(n.label),C=n.secondaryLabel,w=(0,d.ptG)(v,n),T=(0,d.Fn9)(n),P=n.uri,O=(0,d.BTI)(n);return o().createElement("div",{className:l()(b.profileBandWrapper,t)},o().createElement("div",{className:l()(b.profileBand,{[b.inactive]:!T}),"data-entity-uri":P},o().createElement(f.Z,{key:n.uri,entity:n,avatarClassName:b.profileIcon,imageClassName:b.imageProfileIcon}),o().createElement("div",{className:b.profileInfo},o().createElement("div",null,o().createElement(c.Typography,{variant:"h6",className:b.label},g(S)),C&&o().createElement(c.Typography,{variant:"subtitle2",className:b.secondaryLabel},C),w&&o().createElement(c.Typography,{variant:"subtitle1",className:b.businessCard},w)),o().createElement("div",{className:b.specialInfo},o().createElement("div",{className:b.entityType},o().createElement(h.Z,{entity:n,size:"medium",className:b.badge}),!(0,d.ZiX)(P)&&x&&o().createElement(c.Tooltip,{title:p().text("Copy to clipboard")},o().createElement(c.Typography,{display:"inline",variant:"body2",className:b.entityId,onClick:E},p().text("Entity ID"),": ",O))))),r&&o().createElement("div",null,r)))}},79618:(e,t,n)=>{n.d(t,{a:()=>M});var a=n(24328),o=n.n(a),r=n(94079),l=n(67766),i=n(42767),s=n(16657),c=n(71153),u=n.n(c),p=n(17440),d=n(87918),m=n.n(d),f=n(79468),h=n(83348),y=n(8818);const g=(0,n(79692).Z)({container:{display:"flex",alignItems:"center"},link:{whiteSpace:"nowrap",marginRight:"9px"}}),b=(0,h.Z)(r.Link),v=e=>{var t;let{className:n,total:r=0,onPrev:c,onNext:d,onSearchResultsClick:h,isPrevDisabled:v,isNextDisabled:x}=e;const E=g(),S=(0,a.useContext)(f.T),{OPEN_RESULTS:C,SEARCH_RESULT:w,SEARCH_RESULTS:T,NEXT_PROFILE:P,PREVIOUS_PROFILE:O}=(0,p.mergeRight)({OPEN_RESULTS:m().text("Go to search results"),SEARCH_RESULT:m().text("Search result"),SEARCH_RESULTS:m().text("Search results"),PREVIOUS_PROFILE:m().text("Go to previous profile"),NEXT_PROFILE:m().text("Go to next profile")},null!==(t=null==S?void 0:S.profileBand)&&void 0!==t?t:{});return o().createElement("div",{className:u()(E.container,n)},o().createElement(b,{className:E.link,component:"button",variant:"caption",onClick:h,underline:"none",tooltipTitle:C},(0,s.k7L)(r,1e6)," ",1===r?w:T),o().createElement(y.k,{size:"L",icon:l.Z,tooltipTitle:O,onClick:c,disabled:v,showForDisabled:!0}),o().createElement(y.k,{size:"L",icon:i.Z,tooltipTitle:P,onClick:d,disabled:x,showForDisabled:!0}))};var x=n(52730),E=n(49885),S=n(39450),C=n(54198),w=n(85229);function T(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){P(e,t,n[t])}))}return e}function P(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class O{constructor(e){var t=this;let{data:{query:n,sortField:a,sortOrder:o},tenant:r,searchTenant:l,apiPath:i,dtssPath:c,globalSearchRequestOptions:u}=e;this.query=void 0,this.sortField=void 0,this.sortOrder=void 0,this.tenant=void 0,this.searchTenant=void 0,this.apiPath=void 0,this.dtssPath=void 0,this.globalSearchRequestOptions=void 0,this.isDT=()=>this.tenant!==this.searchTenant,this.getQueryFilter=()=>({rawFilter:this.query}),this.getEntities=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const a=[t.getQueryFilter(),...e],o=T({},t.globalSearchRequestOptions,{sort:t.sortField,order:t.sortOrder,select:"uri,label,type",scoreEnabled:!1},n);return t.isDT()?(0,s.uqV)({filters:a,options:o,customerTenant:t.tenant,dataTenant:t.searchTenant,dtssPath:t.dtssPath}):(0,s.ZOr)(a,o)},this.checkEntity=e=>this.getEntities([{filter:"equals",fieldName:"uri",values:[e]}],{offset:0,max:1}).then((t=>t&&t.length>0&&t[0].uri===e)),this.requestEntities=(e,t)=>this.getEntities([],{offset:t,max:e}),this.requestTotal=()=>{const e=[this.getQueryFilter()],t=this.globalSearchRequestOptions;return(this.isDT()?(0,s.J$m)({filters:e,options:t,customerTenant:this.tenant,dataTenant:this.searchTenant,dtssPath:this.dtssPath}):(0,s.j_Q)(e,t)).then((e=>e.total))},this.query=n,this.sortField=a,this.sortOrder=o,this.tenant=r,this.searchTenant=l,this.apiPath=i,this.dtssPath=c,this.globalSearchRequestOptions=u}}function k(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){R(e,t,n[t])}))}return e}function R(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class D{constructor(e){var t=this;let{data:n,tenant:a,apiPath:o}=e;this.searchBody=void 0,this.tenant=void 0,this.apiPath=void 0,this.getEntities=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const a=[{rawFilter:t.searchBody.filter},...e];return(0,s.P2h)({apiPath:t.apiPath,tenant:t.tenant,searchBody:k({},t.searchBody,{filter:e.length?(0,s.Uqd)()(a):t.searchBody.filter}),options:n})},this.checkEntity=e=>this.getEntities([{filter:"equals",fieldName:"id",values:[(0,s.BTI)({uri:e})]}],{from:0,max:1}).then((t=>t&&t.length>0&&t[0].uri===e)),this.requestEntities=(e,t)=>this.getEntities([],{from:t,max:e}),this.requestTotal=()=>(0,s.dED)({apiPath:this.apiPath,tenant:this.tenant,searchBody:this.searchBody}).then((e=>e.count)),this.searchBody=n,this.tenant=a,this.apiPath=o}}function N(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){Z(e,t,n[t])}))}return e}function Z(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const I=(e,t)=>(0,p.pipe)((0,p.map)((0,p.prop)("uri")),(0,p.reject)((e=>t.includes(e))))(e),j=()=>{const e=(0,w._)(),t=(0,w._)(),n=(0,w._)(),{uri:o,index:r,total:l,tenant:i,cache:c}=(0,x.useSelector)(E.ZP.selectors.getSearchNavigationData)||{},{type:u,data:p}=(0,x.useSelector)(E.ZP.selectors.getSearchProviderData)||{},d=(0,x.useSelector)(E.ZP.selectors.getTenant),m=(0,x.useSelector)(E.ZP.selectors.getApiPath),f=(0,x.useSelector)(E.ZP.selectors.getDtssPath),h=(0,x.useSelector)((e=>E.ZP.selectors.getGlobalSearchRequestOptions(e,["ovOnly"]))),y=(0,a.useContext)(S.m),g=(0,x.useDispatch)(),[b,v]=(0,a.useState)(!1),T=(0,a.useMemo)((()=>((e,t)=>{switch(e){case"search":return new O(t);case"graphsearch":return new D(t)}})(u,{data:p,tenant:d,searchTenant:i,apiPath:m,dtssPath:f,globalSearchRequestOptions:h})),[u,p,d,i,m,f,h]),P=(0,a.useCallback)((e=>{g(E.yC.actions.updateSearchNavigationDataFields(e))}),[g]),k=(0,a.useCallback)((e=>{const t=d!==i?(0,s.wwR)({uri:e,dataTenant:i}):e;g(E.ui.actions.openEntity({uri:t,viewId:y,source:"navigation"}))}),[g,y,d,i]),R=(0,a.useCallback)((()=>{g(E.ui.actions.openPerspective({perspectiveId:u,viewId:y}))}),[g,u,y]);(0,a.useEffect)((()=>{r>=l?P({index:l-1}):r<0&&P({index:0})}),[l,r,P]);const Z=(0,C.u)();(0,a.useEffect)((()=>{const e=Z(((e,t)=>{switch(e.type){case E.yC.constants.UPDATE_SEARCH_NAVIGATION_DATA_ON_MERGE:{const n=E.ZP.selectors.getSearchNavigationData(t);n&&P(((e,t)=>{const{winnerUri:n,losersUris:a=[]}=t,o=((e,t)=>{let{uri:n,index:a,total:o,cache:r}=e;if(t&&t!==n){if(r&&r.includes(n)){r=[...r];const e=r.indexOf(t);let l=r.indexOf(n);e>=0&&(r.splice(e,1),o--,e<l&&a--),l=r.indexOf(n),r.splice(l,1,t)}return n=t,N({},e,{uri:n,index:a,cache:r,total:o})}return e})(e,n);return((e,t)=>{const{cache:n=[],index:a,total:o,uri:r}=e,l=t.filter((e=>n.includes(e)));if(0===l.length)return e;const i=o-l.length,s=n.indexOf(r);let c=a;for(const e of l)n.indexOf(e)<s&&c--;const u=n.filter((e=>!l.includes(e)));return N({},e,{cache:u,index:c,total:i})})(o,a)})(n,e.payload));break}}}));return()=>e()}),[Z,P]);const j=(0,a.useCallback)(((e,a,o)=>{v(!0),t(T.requestTotal()).then((e=>P({total:e})));const r=o+1;return n(T.requestEntities(15,r)).then((t=>{if(t){if(t.length){const n=I(t,e);if(n.length>0)return P({cache:e.concat(n),uri:n[0],index:r+t.length-n.length}),void k(n[0]);if(o+t.length<a-1)return j(e,a-t.length,o+t.length)}P({index:r})}})).finally((()=>{v(!1)}))}),[T,P,k]),M=(0,a.useCallback)(((e,a)=>{v(!0),t(T.requestTotal()).then((e=>P({total:e})));const o=a-1,r=Math.max(0,a-15),l=15+Math.min(0,a-15);return n(T.requestEntities(l,r)).then((t=>{if(t){if(t.length){const n=I(t,e);if(n.length>0)return P({cache:n.concat(e),uri:n[n.length-1],index:o-(t.length-n.length)}),void k(n[n.length-1]);if(a-t.length>0)return M(e,a-t.length)}P({index:0})}})).finally((()=>{v(!1)}))}),[T,P,k]),A=(0,a.useCallback)(((t,n,a,o)=>{if(n<t.length){const r=t[n];return v(!0),e(T.checkEntity(r)).then((e=>{if(!e){const e=[...t];return e.splice(n,1),A(e,n,a-1,o)}P({index:o+1,uri:r,cache:t,total:a}),k(r)})).finally((()=>{v(!1)}))}if(!(o>=a-1))return j(t,a,o);P({cache:t,total:a,index:a-1})}),[T,P,k,j]),L=(0,a.useCallback)(((t,n,a,o)=>{if(n>-1){const r=t[n];return v(!0),e(T.checkEntity(r)).then((e=>{if(!e){const e=[...t];return e.splice(n,1),L(e,n-1,a-1,o-1)}P({index:o-1,uri:r,cache:t,total:a}),k(r)})).finally((()=>{v(!1)}))}if(!(o<=0))return M(t,o);P({index:0,cache:t,total:a})}),[T,P,k,M]),F=(0,a.useCallback)((()=>{if(c&&o){const e=c.indexOf(o)-1;L(c,e,l,r)}}),[L,c,o,l,r]),B=(0,a.useCallback)((()=>{if(c&&o){const e=c.indexOf(o)+1;A(c,e,l,r)}}),[A,c,o,l,r]);return{total:l,onPrev:F,onNext:B,onSearchResultsClick:R,isPrevDisabled:b||r<=0,isNextDisabled:b||r>=l-1}},M=e=>{let{className:t}=e;const{total:n,onPrev:a,onNext:r,onSearchResultsClick:l,isPrevDisabled:i,isNextDisabled:c}=j();return(()=>{const{cache:e}=(0,x.useSelector)(E.ZP.selectors.getSearchNavigationData)||{},t=(0,x.useSelector)(E.ZP.selectors.getMode),n=(0,x.useSelector)(E.ZP.selectors.getEntity);return(0,s.uzs)(t)&&(null==e?void 0:e.includes(null==n?void 0:n.uri))})()?o().createElement(v,{className:t,total:n,onPrev:a,onNext:r,onSearchResultsClick:l,isPrevDisabled:i,isNextDisabled:c}):null}},54013:(e,t,n)=>{n.d(t,{Z:()=>u});var a=n(24328),o=n.n(a),r=n(47603),l=n(87918),i=n.n(l),s=n(8818),c=n(55847);const u=e=>{let{items:t,menuId:n}=e;return o().createElement(c.Z,{buttonComponent:s.k,buttonProps:{icon:r.Z,tooltipTitle:i().text("Settings"),size:"L"},menuId:n,menuItems:t})}},3409:(e,t,n)=>{n.d(t,{Z:()=>d});var a=n(24328),o=n.n(a),r=n(52730),l=n(49885),i=n(94079),s=n(17440),c=n(87918),u=n.n(c);const p=(0,n(79692).Z)({root:{display:"flex",alignItems:"flex-start"},slice:{fontWeight:500},cancelButton:{width:"88px",flexShrink:0,marginLeft:"15px"}}),d=()=>{const e=p(),t=(0,r.useSelector)(l.ZP.selectors.getHistoryEvent),n=(0,r.useDispatch)(),a=(0,s.pipe)(l.N5.history.actions.clearHistoryEvent,n);return t?o().createElement("div",{className:e.root},o().createElement(i.Typography,{component:"div"},u().text("You are viewing a historic slice:")," ",o().createElement("span",{className:e.slice},u().date(t.aStamp,"llll"))),o().createElement(i.Button,{className:e.cancelButton,variant:"contained",color:"primary",onClick:a},u().text("Cancel"))):null}},54198:(e,t,n)=>{n.d(t,{G:()=>l,u:()=>i});var a=n(24328),o=n.n(a);const r=(0,a.createContext)(null);r.displayName="ActionsHookContext";const l=e=>{let{children:t,hook:n}=e;return o().createElement(r.Provider,{value:n},t)},i=()=>{const e=(0,a.useContext)(r);if(!e)throw new Error("ActionsHookContext must be provided");return e}},79468:(e,t,n)=>{n.d(t,{T:()=>o});var a=n(24328);const o=n.n(a)().createContext({profileBand:{}});o.displayName="LabelsContext"},7718:(e,t,n)=>{n.d(t,{C:()=>f});var a=n(24328),o=n(52730),r=n(17440),l=n(16657),i=n(49885);function s(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){c(e,t,n[t])}))}return e}function c(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const u=(e,t)=>t.filter((t=>t.replyId!==e)),p=(e,t)=>{const n=e.replies.findIndex((e=>{let{replyId:n}=e;return n===t.replyId})),a=[...e.replies];return a[n]=t,a},d=[],m=e=>console.error("Collaboration error",e),f=e=>{let{objectIds:t=d,objectTypes:n,enabled:c=!0}=e;const f=(0,o.useSelector)(i.ZP.selectors.getEntity),h=(0,o.useSelector)(i.ZP.selectors.getTenant),y=(0,o.useSelector)(i.ZP.selectors.getCollaborationPath),g=(0,o.useSelector)(i.ZP.selectors.isCollaborationEnabled)&&c,[b,v]=(0,a.useState)(null),[x,E]=(0,a.useState)([]),[S,C]=(0,a.useState)(null),[w,T]=(0,a.useState)(null),[P,O]=(0,a.useState)(!1),[k,R]=(0,a.useState)(!1),[D,N]=(0,a.useState)({}),Z=(0,a.useCallback)((e=>{C((t=>s({},t,e)))}),[]),I=null==f?void 0:f.uri,j=(0,a.useCallback)((function(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(g&&I&&!(0,l.ZiX)(I)){const n=e=>{console.warn("Collaboration error",e),C(null)};(0,r.pipe)(l.$oF,(0,r.andThen)((0,r.map)((0,r.props)(["objectId","comments"]))),(0,r.andThen)(r.fromPairs),(0,r.andThen)(t?C:Z),(0,r.otherwise)(n))({uris:e,tenant:h,collaborationPath:y})}else C(null)}),[Z,y,I,g,h]);(0,a.useEffect)((()=>{j(t,!0)}),[t,j]);const M=(0,a.useCallback)(((e,t)=>{(0,l.liG)({collaborationPath:y,tenant:h,relatedObjectUri:e,pageToken:t}).then((e=>{let{items:n,nextPageToken:a}=e;E((e=>t?(0,r.uniqBy)((0,r.prop)("commentId"),[...e,...n]):n)),v(a)})).catch(m)}),[y,h]),A=(0,a.useCallback)((e=>{R(!0),(0,l.d7q)({collaborationPath:y,tenant:h,commentId:e}).then(T).catch(m).finally((()=>R(!1)))}),[y,h]),L=(0,a.useCallback)((e=>{let{content:t,namedUsers:n,objectType:a,uri:o,relatedObjectUris:r}=e;O(!0);const i={objectId:o,content:t,relatedObjectUris:r,objectType:a,visibility:"public",namedUsers:n,permanentLink:`${window.location.href}&commentId=${encodeURIComponent("{commentId}")}`};return(0,l.Yrx)({collaborationPath:y,tenant:h,data:i}).then((e=>{let[t]=e;return((e,t)=>{T(e),C((n=>s({},n,{[t]:[...n[t]||[],{commentId:e.commentId,replies:0,status:"open"}]}))),E((t=>[e,...t]))})(t,o)})).catch(m).finally((()=>O(!1)))}),[y,h]),F=(0,a.useCallback)((e=>{let{content:t,namedUsers:n,objectType:a,uri:o,relatedObjectUris:i,commentId:c,replies:u}=e;O(!0);const p={objectId:o,content:t,relatedObjectUris:i,objectType:a,visibility:"public",namedUsers:n,commentId:c,replies:u};return(0,l.uAg)({collaborationPath:y,tenant:h,data:p}).then((e=>(e=>{T(e),E((0,r.map)((0,r.when)((0,r.propEq)("commentId",e.commentId),(0,r.always)(e))))})(s({},e,{replies:u})))).catch(m).finally((()=>O(!1)))}),[y,h]),B=(0,a.useCallback)((e=>{let{uri:t,commentId:n}=e;O(!0),(0,l.YFy)({collaborationPath:y,tenant:h,commentId:n}).then((()=>((e,t)=>{T(null),C((n=>{const a=n[t]||[];return s({},n,{[t]:a.filter((t=>t.commentId!==e))})})),E((t=>t.filter((t=>t.commentId!==e))))})(n,t))).catch(m).finally((()=>O(!1)))}),[y,h]),U=(0,a.useCallback)(((e,t,n,a)=>{const o="resolve"===e.action?"resolved":"open",{replyId:r}=e;T("resolved"===o?e=>{if(e)return null}:t=>{if(t)return s({},t,{replies:a?u(r,t.replies):[...t.replies,e]})}),C((e=>s({},e,{[t]:(e[t]||[]).map((e=>e.commentId===n?s({},e,{status:o,replies:a?e.replies-1:e.replies+1}):e))}))),E((t=>t.map((t=>t.commentId===n?s({},t,{status:o,replies:a?u(e.replyId,t.replies):[...t.replies,e]}):t))))}),[]),z=(0,a.useCallback)((e=>{let{uri:t,commentId:n,reply:a}=e;O(!0),(0,l.Mfr)({collaborationPath:y,tenant:h,commentId:n,replyId:a.replyId}).then((()=>U(a,t,n,!0))).catch(m).finally((()=>O(!1)))}),[y,U,h]),_=(0,a.useCallback)(((e,t)=>{T((t=>{if(t)return s({},t,{replies:p(t,e)})})),E((n=>n.map((n=>n.commentId===t?s({},n,{replies:p(n,e)}):n))))}),[]),H=(0,a.useCallback)((e=>{let{content:t,namedUsers:n,commentId:a,replyId:o}=e;O(!0);const r={content:t,namedUsers:n};return(0,l.ufV)({collaborationPath:y,tenant:h,commentId:a,replyId:o,data:r}).then((e=>_(e,a))).catch(m).finally((()=>O(!1)))}),[y,h,_]),W=(0,a.useCallback)((e=>{let{content:t,namedUsers:n,commentId:a,action:o,uri:r}=e;O(!0);const i={content:t,action:o,namedUsers:n};return(0,l.PP2)({collaborationPath:y,tenant:h,commentId:a,data:i}).then((e=>{let[t]=e;return U(t,r,a)})).catch(m).finally((()=>O(!1)))}),[y,h,U]),V=(0,a.useCallback)((e=>{let{commentId:t,uri:n}=e;W({content:"",namedUsers:[],commentId:t,action:"resolve",uri:n})}),[W]),q=(0,a.useCallback)((e=>{let{commentId:t,uri:n}=e;W({content:"",namedUsers:[],commentId:t,action:"reopen",uri:n})}),[W]);return{clearCurrentComment:(0,a.useCallback)((()=>{T(null)}),[]),comments:x,commentsMap:S,getCommentState:(e,t)=>(0,r.pathOr)({},[e,t],D),updateCommentState:(e,t,n)=>{N((a=>{const o=[e,t],l=(0,r.path)(o,a);return(0,r.assocPath)(o,(0,r.mergeRight)(l,n),a)}))},clearCommentState:(e,t)=>N((0,r.dissocPath)([e,t])),createComment:L,createReply:W,currentComment:w,deleteComment:B,editComment:F,getComment:A,getComments:M,getCommentsCount:j,loading:k,objectTypes:n,pageToken:b,reOpenThread:q,resolveThread:V,sending:P,deleteReply:z,editReply:H}}},37152:(e,t,n)=>{n.d(t,{a:()=>m});var a=n(24328),o=n(52730),r=n(17440),l=n(49885),i=n(16657),s=n(85229),c=n(30634);function u(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){p(e,t,n[t])}))}return e}function p(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const d=(0,r.when)(r.identity,(0,r.pipe)(i.VGB,r.length,(0,r.times)((e=>e+1)))),m=e=>{let{sorting:t,filter:n,page:p,rowsPerPage:m,config:f,entity:h,relationActivityFilter:y,mode:g,searchByOv:b=!1}=e;const[v,x]=(0,a.useState)(!1),E=(0,o.useDispatch)(),S=(0,o.useSelector)(l.ZP.selectors.getTenant),C=(0,o.useSelector)(l.ZP.selectors.getMetadata),w=(0,o.useSelector)(l.ZP.selectors.getDtssPath),{activityFilter:T,globalFilter:P}=(0,o.useSelector)(l.ZP.selectors.getGlobalSearchRequestOptions)||{},O=(0,o.useSelector)(l.ZP.selectors.getProfileLastLoadedTime),k=(0,s._)(),R=e=>{const t=(0,r.when)(i.Kn2,(0,r.prop)("uri")),n=(0,r.pipe)(t,(0,i.pQZ)(C));return(0,r.evolve)({entityTypes:(0,r.filter)((0,i.kuw)(C)),inRelations:(0,r.filter)(n),outRelations:(0,r.filter)(n),nextEntry:R})(e)},D=f.suggested,N=(0,a.useMemo)((()=>({searchByOv:b})),[b]),Z=(0,a.useCallback)((()=>{if(null!=h&&h.uri){const e=u({},R(f.content),{sortBy:null==t?void 0:t.field,order:null==t?void 0:t.order,returnDates:!0,returnObjects:!0,activeness:{relation:y||i.Ng6.ALL,entity:T},max:m,offset:p*m,filter:(0,i.vyX)(P,n)||void 0,suggested:d(D)}),a=[e].concat((0,r.ifElse)(r.identity,(0,r.pipe)(i.VGB,(t=>t.map(((t,n)=>u({},t,{id:e.suggested[n]}))))),(0,r.always)([]))(D)),o=(0,r.cond)([[(0,r.pipe)((0,r.prop)("uri"),i.ZiX),()=>Promise.resolve([{total:0}])],[i.biM,e=>(0,i.n_1)({entityUri:e.uri,configs:a,customerTenant:S,dataTenant:e.dataTenant,dtssPath:w,options:N})],[r.T,e=>(0,i.N6e)(e.uri,a,N)]]);x(!0),k(o(h)).then((e=>{let[{connections:t,total:n}]=e;E(l.N5.relations.actions.relationsLoaded({id:f.id,connections:t,total:n}))})).finally((()=>{x(!1)}))}}),[T,C,f,E,w,null==h?void 0:h.uri,null==h?void 0:h.dataTenant,n,P,p,y,m,k,t,S,N,O]),I=(0,a.useRef)(!1);I.current=!1,(0,a.useEffect)((()=>{I.current=!0,Z()}),[Z]);const j=(0,c.D)(g);return(0,a.useEffect)((()=>{g!==i.ARY.Viewing||I.current||j===g||(I.current=!0,Z())}),[Z,g,j]),{isLoading:v,reload:Z}}},55451:(e,t,n)=>{n.r(t),n.d(t,{default:()=>Yt});var a=n(24328),o=n.n(a),r=n(52730),l=n(8598),i=n(36138),s=n(44443),c=n(22664),u=n(87451),p=n(39450),d=n(585),m=n(49885),f=n(17440),h=n(16657),y=n(20562),g=n(37152),b=n(7718),v=n(41564),x=n(31274),E=n(40715),S=n(99136),C=n(58662);function w(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){T(e,t,n[t])}))}return e}function T(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const P={relationsTable:{},attributesTable:{}};var O=n(26180),k=n(31276),R=n(86361),D=n(87918),N=n.n(D);const Z="relation.type",I="relation.attributes",j=[{id:"entity.label",get label(){return N().text("Profile")},dataTypeDefinition:{type:h.oS0.TYPE_STRING},hideable:!1,filterable:!1,initialWidth:280,autoResize:!1},{id:Z,get label(){return N().text("Type")}},{id:"relation.label",get label(){return N().text("Directional Label")},filterable:!1,dataTypeDefinition:{type:h.oS0.TYPE_STRING}},{id:"relation.activeness.startDate",get label(){return N().text("Start Date")},dataTypeDefinition:{type:h.oS0.TYPE_ACTIVENESS_DATE}},{id:"relation.activeness.endDate",get label(){return N().text("End Date")},dataTypeDefinition:{type:h.oS0.TYPE_ACTIVENESS_DATE}},{id:I,get label(){return N().text("Attributes")},sortable:!1,filterable:!1,maxAttrsToShow:7}],M=(0,f.pluck)("id",j),A=[Z,I],L=[20,50,100],F=(0,f.pipe)(h.Tde,(0,f.concat)("relation.")),B=(0,f.pipe)((0,f.map)((e=>({id:F(e.uri),label:e.label,description:null==e?void 0:e.description,dataTypeDefinition:(0,h.PFL)(e)}))),(0,f.uniqBy)((0,f.prop)("id")));function U(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){z(e,t,n[t])}))}return e}function z(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const _="CHANGE_RELATION_TYPE",H="APPLY_SAVED_STATE",W="SAVE_CURRENT_STATE",V=U({},O.ZP.actions,{changeRelationType:(0,k.zD)(_),applySavedState:(0,k.zD)(H),saveCurrentState:(0,k.zD)(W)}),q=(0,f.assoc)("page",0),Y=e=>(0,f.pipe)((0,f.prop)("visibleColumns"),(0,f.ifElse)((0,f.always)(e.currentRelationType),(0,f.without)(A),(0,f.concat)(A)),(0,f.intersection)(M))(e),G=e=>(0,f.path)(["visibleColumnsForRelationTypes",`${e.currentRelationType}`],e),$=e=>{const t=(0,f.either)(G,Y)(e);return O.ZP.changeVisibleColumns(e,t)},X=(0,f.pipe)((0,f.propOr)(null,"filters"),(0,f.unless)(f.isNil,(0,f.filter)((e=>{let{filter:t,value:n}=e;return(0,h.jtL)(t,n)})))),K=e=>{const{currentRelationType:t,visibleColumns:n}=e;return(0,f.evolve)({visibleColumnsForRelationTypes:(0,f.assoc)(`${t}`,n)},e)},Q=(0,f.pipe)(K,(0,f.pick)(["currentRelationType","visibleColumnsForRelationTypes","filters","sorting"]));var J=n(37754),ee=n(94079),te=n(92778),ne=n(30553),ae=n(51229),oe=n(54013),re=n(1876),le=n(60894),ie=n(79026),se=n(79692);const ce=(0,se.Z)({select:{fontSize:"13px",color:"rgba(0,0,0,.6)",paddingLeft:"15px","&&":{paddingRight:"35px"}},selectMenu:{"& li":{fontSize:"13px",height:"32px"}},textField:{maxWidth:"100%"}}),ue=e=>{let{value:t,onChange:n,relationTypes:r,className:l}=e;const i=ce(),s=(0,a.useMemo)((()=>(0,f.pipe)((0,f.map)((e=>{let{label:t,uri:n}=e;return{label:t,value:n}})),(0,f.concat)([{value:"",label:N().text("All types")}]))(r)),[r]);return o().createElement("div",{className:l},o().createElement(ie.Z,{displayEmpty:!0,disableUnderline:!0,classes:{select:i.select},TextFieldProps:{classes:{root:i.textField}},MenuProps:{classes:{list:i.selectMenu}},value:t||"",entries:s,onChange:e=>n(e||null)}))},pe=(0,se.Z)((e=>({header:{height:"56px",boxSizing:"border-box",paddingRight:"10px"},title:{fontSize:"16px"},total:{fontSize:"14px",color:e.palette.text.secondary,flexShrink:0,marginRight:"5px"},relationTypeSelector:{margin:"0px 10px 0 30px",overflow:"hidden"}}))),de=(0,a.memo)((e=>{let{total:t,filteringEnabled:n,onToggleFilters:r,columnsData:l,selectedColumns:i,currentRelationType:s,onRelationTypeChange:c,relationTypes:u,onChangeColumns:p,searchByOv:d,onToggleSearchByOv:m}=e;const f=pe(),h=(0,a.useMemo)((()=>[{selected:d,selectable:!0,text:N().text("Search by OV only"),onClick:m,id:"showNonOv"}]),[m,d]);return o().createElement(te.Z,{title:N().text("Relationships"),classes:{root:f.header,title:f.title}},u.length>0&&o().createElement(ue,{className:f.relationTypeSelector,value:s,onChange:c,relationTypes:u}),o().createElement(ne.Z,{height:28,margin:20}),o().createElement(ee.Typography,{variant:"caption",className:f.total},1===t?N().text("${count} record",{count:t}):N().text("${count} records",{count:t})),o().createElement(ae.Z,null),o().createElement(oe.Z,{items:h,menuId:"relationships-view-settings"}),o().createElement(re.Z,{enabled:n,onClick:r}),o().createElement(ne.Z,{height:28,margin:8}),o().createElement(le.Z,{columnsData:l,selectedColumns:i,onChangeColumns:p}))}));var me=n(74402),fe=n(97946),he=n(85709),ye=n(25461),ge=n(92332),be=n(98448),ve=n(67353);const xe=(0,se.Z)((e=>({headCell:{display:"flex",alignItems:"center",height:"100%",width:"100%",fontSize:"12px",color:e.palette.text.secondary,background:"linear-gradient(0deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.06)), #FFFFFF"},rowCell:{fontSize:"13px",overflow:"hidden",overflowWrap:"break-word"},inactiveRowCell:{opacity:.6},defaultWrapper:{padding:"15px 25px 0 25px","&:last-child":{paddingBottom:"15px"}},entityCell:{display:"flex",alignItems:"flex-start",padding:"15px"},entityAvatar:{transform:"scale(0.5)",margin:"-10px 0 -10px -10px"},inactiveEntityAvatar:{overflow:"initial","&:after":{content:'""',position:"absolute",backgroundColor:"rgb(209, 206, 206)",border:"1px solid rgba(0, 0, 0, 1)",borderRadius:"2px",width:"12px",right:0,bottom:0,height:"12px"},"& > img":{borderRadius:"50%",overflow:"hidden"}},entityLabel:{color:e.palette.primary.main,textDecoration:"none",fontWeight:500},attributesWrapper:{padding:"15px 25px 10px 25px",color:"rgba(0,0,0,0.87)"},commentsContainer:{marginLeft:"auto"},description:{marginLeft:"-22px"}}))),Ee=(0,ve.Z)((e=>{const t=xe(),{description:n}=null==e?void 0:e.headCellData;return o().createElement("div",{className:t.headCell},o().createElement(ge.default,e),o().createElement(be.Z,{description:n,className:t.description}))}));var Se=n(71153),Ce=n.n(Se),we=n(19603),Te=n(34e3),Pe=n(31039),Oe=n(94646);const ke=e=>{let{value:{entity:t,entityType:n,relation:a},isInactiveRelation:l}=e;const i=xe(),s=(0,r.useSelector)(m.ZP.selectors.getEntityUri);return o().createElement("div",{className:Ce()(i.entityCell,we.U)},o().createElement(Te.Z,{className:Ce()(i.entityAvatar,{[i.inactiveEntityAvatar]:l}),entityType:n}),o().createElement(Pe.Z,{value:(0,h.wwR)({uri:t.entityUri,dataTenant:t.dataTenant}),className:i.entityLabel},(0,h.idV)(t.entityLabel)),o().createElement("div",{className:i.commentsContainer,onClick:e=>e.stopPropagation()},o().createElement(Oe.Z,{uri:a.relationUri,relatedObjectUris:(0,h.wp9)(h.q7e.RELATION,{entityUri:s,connection:{relation:a,entity:t}}),objectType:h.q7e.RELATION,allowOnlyOneComment:!0})))};var Re=n(80931);const De=e=>{let{columnData:t,value:{attributes:n,attributeTypes:a}}=e;const r=xe();return o().createElement("div",{className:r.attributesWrapper,onClick:e=>e.stopPropagation()},o().createElement(Re.Z,{max:t.maxAttrsToShow,entity:{attributes:n},attrTypes:a,drawLines:!1}))};var Ne=n(72768);const Ze=e=>{let{value:t,columnData:{dataTypeDefinition:n}}=e;const a=xe();return o().createElement("div",{className:a.defaultWrapper},o().createElement(Ne.Z,{value:t,dataTypeDefinition:n}))};function Ie(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const je=(0,f.pipe)((0,f.split)("."),(0,f.slice)(2,1/0)),Me=e=>{if(e.startsWith("relation.attributes")){const t=je(e);return t.length>1?t.slice(0,-1):null}return null},Ae=e=>{switch(e){case"entity.label":return ke;case"relation.attributes":return De;default:return Ze}},Le=(0,f.map)((e=>function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){Ie(e,t,n[t])}))}return e}({sortable:!0,resizable:!0},e,{headCellRenderer:Ee,nestedPath:Me(e.id),rowCellValueRenderer:Ae(e.id)}))),Fe=(0,f.cond)([[(0,f.pathEq)(["columnData","id"],"relation.attributes"),e=>{let{columnData:t,cell:n}=e;const a=(0,f.pipe)((0,f.path)(["values",0,"attributes"]),f.values,f.length)(n);return a>t.maxAttrsToShow?26*t.maxAttrsToShow+49:26*a+25}],[f.T,ye.Z]]);function Be(){return Be=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(e[a]=n[a])}return e},Be.apply(this,arguments)}const Ue=e=>{let{cell:t,CellValueRenderer:n}=e,a=function(e,t){if(null==e)return{};var n,a,o=function(e,t){if(null==e)return{};var n,a,o={},r=Object.keys(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}(e,["cell","CellValueRenderer"]);const r=xe();return o().createElement("div",{className:Ce()(r.rowCell,{[r.inactiveRowCell]:a.isInactiveRelation})},t.values.map(((e,t)=>o().createElement(n,Be({key:t,value:e},a)))))};var ze=n(22983),_e=n(43054),He=n(55847),We=n(22385),Ve=n(81137),qe=n(83348);const Ye=(0,se.Z)((e=>({menuItem:{minHeight:"32px",color:e.palette.text.secondary},menuText:{color:e.palette.text.primary,fontSize:"13px",lineHeight:"15px",letterSpacing:0,marginLeft:"16px"},buttons:{display:"flex",alignItems:"center",paddingRight:"5px"}}))),Ge=(0,qe.Z)(ee.MenuItem),$e=(0,a.forwardRef)(((e,t)=>{let{item:n,onMenuClose:a=k.ZT}=e;const r=Ye(),{icon:l,disabled:i,text:s,tooltip:c,onClick:u}=n;return o().createElement(Ge,{tooltipTitle:c,showForDisabled:!0,classes:{root:r.menuItem},onClick:e=>{a(),u(e)},disabled:i,ref:t},l,o().createElement(ee.Typography,{classes:{root:r.menuText}},s))}));$e.displayName="MenuItemRenderer";const Xe=$e,Ke=e=>{let{disableDelete:t,connection:{entity:n,relation:l},onMenuOpen:i=k.ZT,onMenuClose:s=k.ZT,onDelete:c}=e;const u=Ye(),p=(0,r.useSelector)(m.ZP.selectors.getMetadata),d=(0,f.pipe)((0,f.prop)("relationType"),(0,h.V3K)(p),(0,h.uGe)(h.BDP.DELETE))(l),y=!t&&d,[g,b]=(0,a.useState)(!1),v=()=>b(!1),x=[{disabled:!y,text:N().text("Delete"),icon:o().createElement(ze.Z,null),tooltip:y?null:N().text("You don't have permissions to delete"),onClick:()=>b(!0)}],E=(0,a.useCallback)((()=>{g||s()}),[g,s]);return o().createElement("div",{className:u.buttons},o().createElement(He.Z,{MenuItemRenderer:Xe,menuId:"relationships-table-actions",buttonComponent:We.Z,buttonProps:{icon:_e.Z,size:"S"},menuItems:x,onMenuOpen:i,onMenuClose:E}),o().createElement(Ve.Z,{open:g,title:N().text('Do you want to delete relationship "${label}"?',{label:(S=(0,h.idV)(n.entityLabel),S.length>17?`${S.substring(0,17)}...`:S)}),content:N().text("This relationship will be removed and all the values in the relationship will be permanently deleted. Are you sure you want to delete this relationship?"),onSave:(0,f.pipe)(v,s,c),onDiscard:(0,f.pipe)(v,s),saveCaption:N().text("Delete"),discardCaption:N().text("Cancel")}));var S},Qe=(0,se.Z)({tableContainer:{flex:1,overflow:"hidden",display:"flex",zIndex:0},hoveredRowRightContentWrapper:{width:"100%",pointerEvents:"none!important"},menuButtonContainer:{position:"absolute",top:"calc(50% - 12px)",right:0,pointerEvents:"all"},tooltipAnchor:{width:"100%",height:"1px"}});function Je(){return Je=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(e[a]=n[a])}return e},Je.apply(this,arguments)}const et=(0,a.memo)((e=>{let{metadata:t,connections:n,columnsData:r,sorting:l,onSort:i,filters:s,onFilter:c,onRowClick:u,tableRef:p,onDelete:d,readOnly:m}=e;const y=Qe(),g=(0,a.useMemo)((()=>((e,t,n)=>(n||[]).map((n=>(0,f.pipe)((0,f.reduce)(((t,a)=>{let{id:o}=a;return(0,f.assoc)(o,((e,t,n)=>{let{entity:a,relation:o}=t;switch(n){case"entity.label":return{entity:a,entityType:(0,h.nt9)(e,a.entityType),relation:o};case"relation.type":return o.relationType;case"relation.label":return o.relationLabel;case"relation.activeness.startDate":return o.startDate;case"relation.activeness.endDate":return o.endDate;case"relation.attributes":return{attributes:o.object.attributes,attributeTypes:(0,h.V3K)(e,o.relationType).attributes};default:return((e,t)=>(0,f.pipe)((0,f.path)(["object","attributes"]),(0,h.tT_)(e))(t))(je(n),o)}})(e,n,o),t)}),{}),(0,f.assoc)("rawValue",n))(t))))(t,r,n)),[t,n,r]),b=(0,a.useMemo)((()=>Le(r)),[r]),{getDynamicRowCellHeight:v,changeRowCellHeight:x}=(0,me.Z)(),E=(0,a.useCallback)((0,f.either)(v,Fe),[v,Fe]),[S,C]=(0,a.useState)(null),w=(0,a.useCallback)((e=>{const t=!(0,h.Fn9)(e.rowValue.rawValue.relation);return o().createElement(fe.Z,Je({onChangeHeight:x},e),o().createElement(Ue,Je({},e,{isInactiveRelation:t})))}),[x]),[T,P]=(0,a.useState)(!1),O=(0,a.useCallback)((()=>P(!0)),[]),k=(0,a.useCallback)((()=>{C(null),P(!1)}),[]),R=(0,a.useCallback)((e=>C((t=>T?t:e))),[T]),D=(0,a.useMemo)((()=>{const e=null!=S?g[S].rawValue:null,t=!(0,h.Fn9)(null==e?void 0:e.relation);return e&&o().createElement(o().Fragment,null,o().createElement(ee.Tooltip,{key:e.relation.relationUri,open:t,title:N().text("Inactive")},o().createElement("div",{className:y.tooltipAnchor})),o().createElement("div",{className:y.menuButtonContainer},o().createElement(Ke,{disableDelete:m,connection:e,onMenuOpen:O,onMenuClose:k,onDelete:()=>d(e.relation.relationUri)})))}),[d,g,S]);return o().createElement("div",{className:y.tableContainer},o().createElement(he.Z,{fixFirstColumn:!0,columnsData:b,rowsData:g,sorting:l,onSort:i,filters:s,onFilter:c,defaultColumnWidth:250,defaultColumnMinWidth:200,headRowHeight:48,getRowCellHeight:E,renderRowCell:w,onRowClick:u,ref:p,hoverStateEnabled:!0,hoverRowIndex:S,onRowHover:R,hoveredRowRightContent:D,classes:{hoveredRowRightContentWrapper:y.hoveredRowRightContentWrapper}}))}));var tt=n(85229),nt=n(85965),at=n(39417),ot=n(10237),rt=n(63149),lt=n(48017),it=n(96955),st=n(66095),ct=n(20982),ut=n(99144),pt=n(65549),dt=n(52017),mt=n(90186);const ft=(0,se.Z)((()=>({tableRow:{"& + &":{marginTop:"4px"},margin:"auto",maxWidth:"448px"}})));function ht(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const yt=(0,a.memo)((e=>{let{readOnly:t,relation:n,metadata:r,selectedAttributeTypes:l,onDeleteCrosswalk:i,onEditCrosswalk:s}=e;const c=ft(),u=(0,h.V3K)(r,n.type),p=(0,a.useMemo)((()=>function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];return(0,f.pipe)((0,f.propOr)([],"crosswalks"),(0,f.map)((0,f.assoc)("ownerType","entity")),(0,mt.o)(e.type,t))(e)}(n,l)),[n,l]),[d,m]=(0,a.useState)([]),y=(0,a.useCallback)((e=>{i({entityUri:n.uri,crosswalkId:e})}),[i,n.uri]),g=(0,a.useCallback)((e=>{s(function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){ht(e,t,n[t])}))}return e}({entityUri:n.uri},e))}),[s,n.uri]);return o().createElement("div",null,p.map((e=>{let{source:n,crosswalksByTypes:a}=e;return o().createElement("div",{key:n,className:c.tableRow},o().createElement(dt.Z,{source:n,crosswalksByTypes:a,expanded:d.includes(n),disableEditCrosswalk:!(0,h.Zm0)(u)||t,disableDeleteCrosswalk:!(0,h.a14)(u)||t,onEdit:g,onDelete:y,onToggleExpanded:()=>{m((0,f.ifElse)((0,f.includes)(n),(0,f.without)([n]),(0,f.append)(n)))}}))})))}));var gt=n(79769);const bt=(0,se.Z)((e=>({header:{display:"flex",flexDirection:"row",alignItems:"center",padding:"20px 12px",borderBottom:"1px solid rgba(0, 0, 0, 0.12)"},title:{fontWeight:500,fontSize:"20px",lineHeight:"23px",letterSpacing:"0.25px",color:e.palette.text.primary,marginLeft:"12px"},hint:{color:e.palette.text.secondary,display:"flex",flexDirection:"row",alignItems:"center",alignSelf:"flex-start",margin:"4px 14px 10px"},hintText:{marginLeft:"8px",fontSize:"12px",lineHeight:"16px"},buttons:{display:"flex",padding:"8px 6px 4px"},buttonLabel:{fontSize:"14px",fontWeight:500,lineHeight:"16px"},icon:{fontSize:"18px",marginRight:"8px"},editor:{paddingLeft:25,margin:"auto",maxWidth:"448px",boxSizing:"border-box",marginBottom:"4px"},tableContainer:{overflowY:"auto",overflowX:"hidden",paddingLeft:"16px",paddingRight:"6px"}}))),vt=(0,qe.Z)(ee.Button),xt=(0,a.memo)((e=>{let{className:t,readOnly:n,relation:l,selectedAttributeTypes:i,onAddCrosswalk:s,onDeleteCrosswalk:c,onEditCrosswalk:u}=e;const p=bt(),d=(0,r.useSelector)(m.ZP.selectors.getMetadata),f=(0,h.V3K)(d,l.type),[y,g]=(0,a.useState)(!1),b=(0,h.mkC)(f)&&!n;return o().createElement("div",{className:t},o().createElement("div",{className:p.header},o().createElement("span",{className:p.title},N().text("Legend"))),o().createElement("div",{className:p.buttons},o().createElement(vt,{color:"primary",showForDisabled:!0,disabled:!b,tooltipTitle:b?null:N().text("You don't have permissions to add crosswalk"),onClick:()=>g(!0)},o().createElement(pt.Z,{className:p.icon}),o().createElement("div",{className:p.buttonLabel},N().text("Crosswalk")))),o().createElement("div",{className:p.hint},o().createElement(ut.Z,{className:p.icon}),o().createElement("span",{className:p.hintText},N().text("You can drag a crosswalk to add values to attributes swimlanes"))),o().createElement("div",{className:p.tableContainer},y&&o().createElement(gt.Z,{className:p.editor,onAdd:e=>s({entity:l,crosswalk:e}),onClose:()=>g(!1)}),o().createElement(yt,{readOnly:n,metadata:d,relation:l,selectedAttributeTypes:i,onDeleteCrosswalk:c,onEditCrosswalk:u})))}));var Et=n(95613),St=n(23147),Ct=n(94111),wt=n(64459),Tt=n(68439);const Pt=(0,se.Z)((e=>({entityInfo:{flex:"0 1 auto",overflow:"hidden",minWidth:"100px"},entityLabelContainer:{display:"flex",alignItems:"center",overflow:"hidden"},entityLabel:{lineHeight:"1.2",letterSpacing:"0.25px",color:e.palette.text.primary},infoIcon:{fontSize:"16px",color:e.palette.text.secondary,marginLeft:"5px"},profileBand:{margin:"-10px",maxWidth:"500px"},entityTypeBadge:{marginTop:"7px"}}))),Ot=e=>{let{entity:t}=e;const n=Pt(),a=(0,h.idV)(t.label);return o().createElement("div",{className:n.entityInfo},o().createElement("div",{className:n.entityLabelContainer},o().createElement(Et.Z,{value:a},o().createElement(ee.Typography,{variant:"h6",className:n.entityLabel,noWrap:!0},a)),o().createElement(Ct.Z,{title:o().createElement(wt.Z,{className:n.profileBand,entity:t}),placement:"right"},o().createElement(ut.Z,{className:n.infoIcon}))),o().createElement(Tt.Z,{className:n.entityTypeBadge,entity:t,size:"medium"}))},kt=(0,se.Z)((e=>({root:{flexShrink:0,overflow:"hidden",width:"110px"},label:{color:e.palette.text.secondary,fontSize:"13px"}}))),Rt=e=>{let{relation:t}=e;const n=kt(),{direction:a,relationLabel:r}=t;return o().createElement("div",{className:n.root},o().createElement(Et.Z,{value:r},o().createElement(ee.Typography,{variant:"subtitle2",className:n.label,align:"center",noWrap:!0},r)),o().createElement("svg",{width:"110",height:"12",fill:"black",fillOpacity:"0.3"},"out"===a&&o().createElement("polygon",{points:"94 0, 110 6, 94 12, 94 9, 0 9, 0 3, 94 3"}),"bidirectional"===a&&o().createElement("polygon",{points:"94 0, 110 6, 94 12, 94 9, 16 9, 16 12, 0 6, 16 0, 16 3, 94 3"}),"in"===a&&o().createElement("polygon",{points:"16 12, 0 6, 16 0, 16 3, 110 3, 110 9, 16 9"})))};var Dt=n(8459),Nt=n(27604);const Zt=(0,se.Z)((()=>({root:{"&:hover $editButton":{visibility:"visible"}},editButton:{visibility:"hidden",marginLeft:"4px",marginBottom:"4px"},paper:{width:"150px",border:"3px solid rgba(0, 0, 0, 0.3)",borderRadius:"4px",boxSizing:"border-box",overflow:"hidden"}}))),It=e=>{let{value:t=null,onChange:n,readOnly:r}=e;const l=Zt(),i=(0,a.useRef)(),[s,c]=(0,a.useState)(!1),u=()=>c(!1),[p,d]=(0,a.useState)(t),m=()=>{p!==t&&n(p),u()};return o().createElement("span",{ref:i,className:l.root},t&&(0,h.p6d)(t),o().createElement(We.Z,{disabled:r,icon:Nt.Z,size:"XXS",className:l.editButton,onClick:()=>c(!0)}),o().createElement(ee.Popover,{classes:{paper:l.paper},open:s,anchorEl:i.current,anchorOrigin:{vertical:"top",horizontal:"left"},transformOrigin:{vertical:14,horizontal:20},onKeyUp:e=>{"Enter"===e.key?m():"Escape"===e.key&&u()},onBackdropClick:m},o().createElement(Dt.Z,{InputProps:{autoFocus:!0,disableUnderline:!0,fullWidth:!0},size:"small",hiddenLabel:!0,label:void 0,value:p&&new Date(p),onChange:e=>d(e&&e.valueOf())})))},jt=(0,se.Z)((e=>({relationBand:{flexShrink:0,boxShadow:"inset 0px -1px 0px rgba(0,0,0,0.06)",padding:"16px 19px"},inactiveRelationBand:{opacity:.6,background:"rgba(185, 188, 197, 0.18)"},toolbar:{display:"flex",alignItems:"center",gap:"16px",marginBottom:"10px"},mainInfo:{display:"flex",gap:"16px",marginLeft:"40px"},detailsInfo:{display:"flex",gap:"34px",marginLeft:"40px",marginTop:"17px",color:e.palette.text.secondary,fontSize:"13px"},detailTitle:{color:e.palette.text.primary,flexShrink:0,marginRight:"4px"},directionalLabel:{display:"flex",overflow:"hidden","& span":{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"}},relationDate:{flexShrink:0},commentsContainer:{marginRight:"18px"}})));function Mt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){At(e,t,n[t])}))}return e}function At(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const Lt=(0,a.memo)((e=>{let{readOnly:t,entity:n,connection:a,onNavigateBack:r,onDelete:l,onChangeActivenessDate:i}=e;const s=!(0,h.Fn9)(a.relation),c=jt();return o().createElement("div",{className:Ce()(c.relationBand,we.U,{[c.inactiveRelationBand]:s})},o().createElement("div",{className:c.toolbar},o().createElement(We.Z,{icon:St.Z,size:"S",onClick:()=>r()}),o().createElement(ee.Typography,{variant:"subtitle2",display:"inline"},N().text("Back to relationships")),o().createElement(ae.Z,null),o().createElement("div",{className:c.commentsContainer},o().createElement(Oe.Z,{uri:a.relation.relationUri,relatedObjectUris:(0,h.wp9)(h.q7e.RELATION,{entityUri:null==n?void 0:n.uri,connection:a}),objectType:h.q7e.RELATION,allowOnlyOneComment:!0})),o().createElement(Ke,{connection:a,onDelete:l,disableDelete:t})),o().createElement("div",{className:c.mainInfo},o().createElement(Ot,{entity:n}),o().createElement(Rt,{relation:a.relation}),o().createElement(Ot,{entity:Mt({},a.entity.object,{dataTenant:a.entity.dataTenant})})),o().createElement("div",{className:c.detailsInfo},o().createElement("div",{className:c.directionalLabel},o().createElement("span",{className:c.detailTitle},N().text("Directional label:")),o().createElement(Et.Z,{value:a.relation.relationLabel},o().createElement("span",null,a.relation.relationLabel))),o().createElement("div",{className:c.relationDate},o().createElement("span",{className:c.detailTitle},N().text("Start date:")),o().createElement(It,{value:a.relation.startDate,onChange:e=>i("startDate",e),readOnly:t})),o().createElement("div",{className:c.relationDate},o().createElement("span",{className:c.detailTitle},N().text("End date:")),o().createElement(It,{value:a.relation.endDate,onChange:e=>i("endDate",e),readOnly:t}))))})),Ft=e=>{console.error(e),d.Z.addError({title:N().text("Error"),message:(0,h.xU7)(e,N().text("Something went wrong"))})};var Bt=n(58651),Ut=n(13896);const zt=(0,se.Z)({detailsView:{position:"absolute",top:0,left:0,right:0,bottom:0,overflow:"hidden"},locked:{pointerEvents:"none"},resizablePanesWrapper:{flexGrow:1},pane:{position:"absolute",top:0,left:0,right:0,bottom:0,display:"flex",flexDirection:"column",overflow:"hidden"}}),_t=(0,a.memo)((e=>{let{entity:t,connection:n,visibleColumns:r,onClose:l,onDeleteConnection:i,onChangeConnection:s,onChangeVisibleColumns:c,readOnly:u}=e;const p=zt(),d=(()=>{const[e,t]=(0,a.useState)([]),n=(0,a.useRef)([]),o=(0,a.useCallback)((0,h.DsO)((()=>{t([...n.current])}),50),[]),r=(0,a.useCallback)((e=>{n.current=e,o(e)}),[o]),l=(0,a.useCallback)(((e,t)=>{e&&r(t?[e]:[])}),[r]),[i,s]=(0,a.useState)([]),c=(0,a.useCallback)((e=>{e&&s((t=>{return n=[e],a=t,(0,f.concat)(n.filter((e=>!(0,f.any)((0,h.aFF)(e),a))),a.filter((e=>!(0,f.any)((0,h.aFF)(e),n))));var n,a}))}),[]);return{highlightedCrosswalks:(0,a.useMemo)((()=>[...e,...i]),[e,i]),focusedCrosswalks:i,toggleCrosswalkFocus:c,setCrosswalkHighlighted:l}})(),[m,y]=(0,a.useState)(-480),g=(0,a.useCallback)((e=>{let{percentageSize:t}=e;return y(t)}),[]),[b,v]=(0,a.useState)(),[x,E]=(0,a.useState)(!1),S=n.relation.relationUri,C=(0,tt._)(),w=(0,a.useCallback)((()=>E(!0)),[]),T=(0,a.useCallback)((()=>E(!1)),[]),P=(0,a.useCallback)((0,f.pipe)(i,w),[]),[O,k]=(0,a.useMemo)((()=>{const e=e=>{e.errorCode===h.Xt7.CROSSWALK_NOT_FOUND?(Ft(e),t()):e.errorCode===h.Xt7.OBJECT_NOT_FOUND?l(e):(Ft(e),T())},t=()=>{C((0,h._vs)(S)).then((e=>{s((0,f.assocPath)(["relation","object"],e,n)),T()})).catch(e)};return[e,t]}),[n,T,s,l]),{modifiedEntity:R,crosswalksMap:D,newlyCreatedAttributes:N,onPinAttribute:Z,onIgnoreAttribute:I,onAddAttribute:j,onEditAttribute:M,onDeleteAttribute:A}=(0,nt.Q)({entity:n.relation.object,onModify:k,onError:O,onLoad:w}),{addCrosswalk:L,deleteCrosswalk:F,editCrosswalk:B}=(0,at.P)({onSuccess:k,onError:O,onLoad:w}),U=(0,a.useCallback)(((e,t)=>{w(),(t?(0,h.rj2)({entityUri:S,attributeName:e,value:t}).then((()=>s((0,f.assocPath)(["relation",e],t,n)))):(0,h.X78)({entityUri:S,attributeName:e}).then((()=>s((0,f.dissocPath)(["relation",e],n))))).then(T).catch(O)}),[n,w,T,O]);return o().createElement(ot.Z,{className:p.detailsView},o().createElement(rt.hR,d,o().createElement(Ut.DndProvider,{backend:Bt.default},o().createElement(lt.Z,null),o().createElement(it.Z,{className:Ce()(p.resizablePanesWrapper,{[p.locked]:x}),orientation:"vertical",size:m,minSize:600,maxSize:-480,allowResize:!0,onChange:g},o().createElement("div",{className:p.pane},o().createElement(Lt,{readOnly:u,entity:t,connection:n,onNavigateBack:l,onDelete:P,onChangeActivenessDate:U}),o().createElement(st.R,{attributeUris:N},o().createElement(ct.Z,{readOnly:u,entity:R,crosswalksMap:D,isLoading:x,onPin:Z,onIgnore:I,onEdit:M,onAdd:j,onDelete:A,selectedAttributeTypes:b,onSelectAttributeTypes:v,visibleColumns:r,onChangeVisibleColumns:c}))),o().createElement(xt,{readOnly:u,className:p.pane,relation:n.relation.object,selectedAttributeTypes:b,onAddCrosswalk:L,onDeleteCrosswalk:F,onEditCrosswalk:B})))))})),Ht=(0,se.Z)({relationshipsView:{position:"absolute",top:0,left:0,right:0,bottom:0,overflowX:"hidden",overflowY:"auto",fontFamily:"Roboto, Helvetica, Arial, sans-serif",display:"flex",flexDirection:"column"},"@global div[role=tooltip]":{fontFamily:"Roboto, Helvetica, Arial, sans-serif"},"@global div[role=presentation]":{fontFamily:"Roboto, Helvetica, Arial, sans-serif"},pane:{display:"flex",flexDirection:"column",flex:1,overflow:"hidden",position:"relative"}}),Wt=(0,r.connect)(((e,t)=>{let{config:{id:n}}=t;return{entity:m.ZP.selectors.getEntity(e),metadata:m.ZP.selectors.getMetadata(e),connections:m.ZP.selectors.getConnectionsByViewId(e,n),total:m.ZP.selectors.getTotalByViewId(e,n)}}))((e=>{let{config:t,entity:n,metadata:r,connections:l,total:i,saveState:s,getSavedState:c,dispatch:u}=e;const p=Ht(),d=(0,a.useRef)(),T=(0,h.biM)(n),[k,D]=(0,a.useState)(!1),{type:N}=n||{},[{visibleColumns:Z,filters:I,page:F,rowsPerPage:z,sorting:Y,currentRelationType:ee,stateToSave:te,entityTypeOfAppliedSavedState:ne},{changeColumns:ae,toggleFilters:oe,changeFilter:re,changePage:le,changeRowsPerPage:ie,toggleSort:se,changeRelationType:ce,saveCurrentState:ue,applySavedState:pe}]=(e=>{let{defaultColumns:t,defaultSorting:n,defaultRowsPerPage:o}=e;const r={visibleColumns:t,filters:null,sorting:n,page:0,rowsPerPage:o,currentRelationType:null,stateToSave:null,visibleColumnsForRelationTypes:{},entityTypeOfAppliedSavedState:null},[l,i]=(0,a.useReducer)(((e,t)=>{switch(t.type){case _:{const n=t.payload;return(0,f.pipe)(K,(0,f.assoc)("currentRelationType",n),$,q)(e)}case H:{const{savedState:n,entityTypeUri:a}=t.payload,o=n?G(n):e.visibleColumns;return U({},e,n,{filters:n?X(n):e.filters,visibleColumns:o,entityTypeOfAppliedSavedState:a})}case W:return U({},e,{stateToSave:Q(e)});default:return O.ZP.reducer(e,t)}}),r);return[l,(0,R.o)({actions:V,dispatch:i})]})({defaultColumns:M,defaultRowsPerPage:L[0],defaultSorting:{field:M[0],order:"asc"}}),me=ne===N,{isLoading:fe,relationsTableSavedState:he,attributesTableSavedState:ye,updateRelationsTableSavedState:ge,updateAttributesTableSavedState:be}=(e=>{var t;let{getSavedState:n,saveState:o,entityTypeUri:r}=e;const[l,i]=(0,a.useState)(P),[s,c]=(0,a.useState)(null);(0,y.D)((()=>{s&&(i(w({},l,{relationsTable:s})),c(null))}),[r]);const[u,p]=(0,a.useState)(!0);return(0,a.useEffect)((()=>{n().then((e=>{i(e||P)})).then((e=>p(!1))).catch((e=>p(!1)))}),[]),{isLoading:u,relationsTableSavedState:null===(t=l.relationsTable)||void 0===t?void 0:t[r],attributesTableSavedState:l.attributesTable,updateRelationsTableSavedState:e=>{const t=w({},l.relationsTable,{[r]:e});c(t),o(w({},l,{relationsTable:t}))},updateAttributesTableSavedState:e=>{o(w({},l,{attributesTable:e}))}}})({getSavedState:c,saveState:s,entityTypeUri:N}),[ve,xe]=(0,a.useState)();(0,a.useEffect)((()=>{fe||pe({savedState:he,entityTypeUri:N})}),[fe,N]),(0,a.useEffect)((()=>{fe||xe(null==ye?void 0:ye.visibleColumns)}),[fe]),(0,y.D)((()=>{me&&ge(te)}),[te]),(0,y.D)((()=>{le(0)}),[n]);const[Ee,Se]=(0,a.useState)(),Ce=(0,a.useCallback)((()=>{Se(null)}),[]),we=(0,a.useMemo)((()=>{const e=(0,h.io3)(r,N);return r.relationTypes.filter((0,f.both)((0,h.uGe)(h.BDP.READ),(t=>{let{startObject:n,endObject:a}=t;return e.some((0,f.either)((0,f.equals)(n.objectTypeURI),(0,f.equals)(a.objectTypeURI)))})))}),[r,N]),Te=(0,a.useMemo)((()=>((e,t)=>t?(0,f.pipe)((0,f.find)((e=>e.uri===t)),h.DK$,B,(0,f.concat)(j),(0,f.reject)((e=>{let{id:t}=e;return A.includes(t)})))(e):(e=>{return t=(0,f.assoc)("dataTypeDefinition",(e=>({type:h.oS0.TYPE_SELECT,options:e.map((e=>{let{uri:t,label:n}=e;return{value:t,label:n}}))}))(e)),e=>(0,f.adjust)(e.findIndex((0,f.propEq)("id","relation.type")),t,e);var t})(e)(j))(we,ee)),[we,ee]),Pe=(0,a.useMemo)((()=>Z.map((e=>Te.find((0,f.propEq)("id",e)))).filter(f.identity)),[Z,Te]),Oe=(0,a.useMemo)((()=>{const e=(0,f.pipe)((0,f.when)((0,f.always)(ee),(0,f.filter)((0,f.propEq)("uri",ee))),(0,f.map)((0,f.prop)("uri")))(we);return{id:t.id,content:{inRelations:e,outRelations:e}}}),[t.id,ee,we]),ke=(0,a.useMemo)((()=>((e,t)=>{const n=(0,J.Tz)(t,e);return(new h.MEy).addClause(n).build()})(I,Pe)),[I,Pe]),{isLoading:Re,reload:De}=(0,g.a)({page:F,rowsPerPage:z,config:Oe,entity:me?n:null,filter:ke,mode:h.ARY.Viewing,sorting:Y,searchByOv:k}),Ne=!me||Re,Ze=(0,a.useCallback)((0,f.pipe)(se,ue),[se,ue]),Ie=(0,a.useCallback)((0,f.pipe)(re,ue),[re,ue]),je=(0,a.useCallback)((0,f.pipe)(oe,ue),[oe,ue]),Me=(0,a.useCallback)((0,f.pipe)(ae,ue),[ae,ue]),Ae=(0,a.useCallback)((0,f.pipe)(ce,ue),[ce,ue]),Le=(0,a.useCallback)((e=>{xe(e),be({visibleColumns:e})}),[be]),Fe=null==l?void 0:l[Ee],Be=(0,a.useCallback)((e=>{u(m.N5.relations.actions.relationsLoaded({id:t.id,connections:(0,f.update)(Ee,e,l),total:i}))}),[Fe]),[Ue,ze]=(0,a.useMemo)((()=>[(0,h.w3p)(l),[h.q7e.RELATION]]),[l]),_e=(0,b.C)({objectIds:Ue,objectTypes:ze,enabled:!T}),He=(0,a.useMemo)((()=>(0,h.Px$)(l)),[l]),We=(0,a.useCallback)((e=>{Ft(e),e.errorCode===h.Xt7.OBJECT_NOT_FOUND&&De()}),[De]),Ve=(0,a.useCallback)((e=>{(0,f.pipe)(h.VGk,(0,f.andThen)(De),(0,f.otherwise)(We))(e)}),[De,We]),qe=(0,a.useCallback)((()=>{(0,f.pipe)(h.VGk,(0,f.andThen)((0,f.pipe)(Ce,De)),(0,f.otherwise)((e=>{e.errorCode===h.Xt7.OBJECT_NOT_FOUND&&Ce(),We(e)})))(Fe.relation.relationUri)}),[Fe,De,Ce,We]),Ye=(0,a.useCallback)((e=>{e&&We(e),Ce()}),[We,Ce]),Ge=(0,a.useCallback)((()=>{D(f.not)}),[D]);return o().createElement(v.e,{collaboration:_e},o().createElement(x.X.Provider,{value:He},o().createElement("div",{className:p.relationshipsView},o().createElement(E.n,{entity:n}),o().createElement(de,{total:i,filteringEnabled:!!I,onToggleFilters:je,columnsData:Te,selectedColumns:Z,onChangeColumns:Me,relationTypes:we,currentRelationType:ee,onRelationTypeChange:Ae,searchByOv:k,onToggleSearchByOv:Ge}),o().createElement("div",{className:p.pane},Ne&&o().createElement(S.Z,null),o().createElement(et,{readOnly:T,metadata:r,connections:l,columnsData:Pe,sorting:Y,onSort:Ze,filters:I,onFilter:Ie,onRowClick:Se,tableRef:d,onDelete:Ve}),o().createElement(C.Z,{count:i,rowsPerPageOptions:L,page:F,onChangePage:le,rowsPerPage:z,onChangeRowsPerPage:ie,basicTableRef:d})),Fe&&o().createElement(_t,{readOnly:T,entity:n,visibleColumns:ve,onChangeVisibleColumns:Le,connection:Fe,onClose:Ye,onDeleteConnection:qe,onChangeConnection:Be}))))}));function Vt(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const qt=(0,i.createGenerateClassName)({productionPrefix:"relationshipsPerspective",disableGlobal:!0}),Yt=e=>{let{config:t,store:n,onResize:f,saveState:y,getSavedState:g}=e;const b=(0,a.useCallback)((0,h.aYu)(g),[g]),v=(0,a.useContext)(u.Y),x=m.ZP.selectors.getShowAttributeDescription(n.getState()),E=(0,a.useMemo)((()=>function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),a.forEach((function(t){Vt(e,t,n[t])}))}return e}({},v,{showDescription:x})),[v,x]);return o().createElement(r.Provider,{store:n},o().createElement(p.m.Provider,{value:t.id},o().createElement(u.Y.Provider,{value:E},o().createElement(i.StylesProvider,{generateClassName:qt},o().createElement(c.MuiPickersUtilsProvider,{utils:l.Z},o().createElement(s.Z,{handleHeight:!0,onResize:(e,t)=>null==f?void 0:f(Math.floor(e),Math.floor(t))}),t&&o().createElement(Wt,{config:t,saveState:y,getSavedState:b}),o().createElement(d.Z,null))))))}},46847:(e,t,n)=>{function a(){var e=this.constructor.getDerivedStateFromProps(this.props,this.state);null!=e&&this.setState(e)}function o(e){this.setState(function(t){var n=this.constructor.getDerivedStateFromProps(e,t);return null!=n?n:null}.bind(this))}function r(e,t){try{var n=this.props,a=this.state;this.props=e,this.state=t,this.__reactInternalSnapshotFlag=!0,this.__reactInternalSnapshot=this.getSnapshotBeforeUpdate(n,a)}finally{this.props=n,this.state=a}}function l(e){var t=e.prototype;if(!t||!t.isReactComponent)throw new Error("Can only polyfill class components");if("function"!=typeof e.getDerivedStateFromProps&&"function"!=typeof t.getSnapshotBeforeUpdate)return e;var n=null,l=null,i=null;if("function"==typeof t.componentWillMount?n="componentWillMount":"function"==typeof t.UNSAFE_componentWillMount&&(n="UNSAFE_componentWillMount"),"function"==typeof t.componentWillReceiveProps?l="componentWillReceiveProps":"function"==typeof t.UNSAFE_componentWillReceiveProps&&(l="UNSAFE_componentWillReceiveProps"),"function"==typeof t.componentWillUpdate?i="componentWillUpdate":"function"==typeof t.UNSAFE_componentWillUpdate&&(i="UNSAFE_componentWillUpdate"),null!==n||null!==l||null!==i){var s=e.displayName||e.name,c="function"==typeof e.getDerivedStateFromProps?"getDerivedStateFromProps()":"getSnapshotBeforeUpdate()";throw Error("Unsafe legacy lifecycles will not be called for components using new component APIs.\n\n"+s+" uses "+c+" but also contains the following legacy lifecycles:"+(null!==n?"\n "+n:"")+(null!==l?"\n "+l:"")+(null!==i?"\n "+i:"")+"\n\nThe above lifecycles should be removed. Learn more about this warning here:\nhttps://fb.me/react-async-component-lifecycle-hooks")}if("function"==typeof e.getDerivedStateFromProps&&(t.componentWillMount=a,t.componentWillReceiveProps=o),"function"==typeof t.getSnapshotBeforeUpdate){if("function"!=typeof t.componentDidUpdate)throw new Error("Cannot polyfill getSnapshotBeforeUpdate() for components that do not define componentDidUpdate() on the prototype");t.componentWillUpdate=r;var u=t.componentDidUpdate;t.componentDidUpdate=function(e,t,n){var a=this.__reactInternalSnapshotFlag?this.__reactInternalSnapshot:n;u.call(this,e,t,a)}}return e}n.r(t),n.d(t,{polyfill:()=>l}),a.__suppressDeprecationWarning=!0,o.__suppressDeprecationWarning=!0,r.__suppressDeprecationWarning=!0}}]);
2
2
  //# sourceMappingURL=3270.js.map