@reltio/remotes 1.4.1395 → 1.4.1397

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.
Files changed (82) hide show
  1. package/1219.js +1 -1
  2. package/1219.js.map +1 -1
  3. package/1268.js +1 -1
  4. package/1268.js.map +1 -1
  5. package/1375.js +1 -1
  6. package/1375.js.map +1 -1
  7. package/1689.js +1 -1
  8. package/1689.js.map +1 -1
  9. package/2114.js +1 -1
  10. package/2114.js.map +1 -1
  11. package/2890.js +1 -1
  12. package/2890.js.map +1 -1
  13. package/3149.js +1 -1
  14. package/3149.js.map +1 -1
  15. package/3273.js +1 -1
  16. package/3273.js.map +1 -1
  17. package/3540.js +1 -1
  18. package/3540.js.map +1 -1
  19. package/3602.js +1 -1
  20. package/3602.js.map +1 -1
  21. package/4015.js +1 -1
  22. package/4015.js.map +1 -1
  23. package/447.js +1 -1
  24. package/447.js.map +1 -1
  25. package/461.js +1 -1
  26. package/461.js.map +1 -1
  27. package/4843.js +1 -1
  28. package/4881.js +1 -1
  29. package/4881.js.map +1 -1
  30. package/4889.js +1 -1
  31. package/4889.js.map +1 -1
  32. package/5400.js +1 -1
  33. package/5400.js.map +1 -1
  34. package/5601.js +1 -1
  35. package/5601.js.map +1 -1
  36. package/5709.js +1 -1
  37. package/5709.js.map +1 -1
  38. package/5720.js +1 -1
  39. package/5720.js.map +1 -1
  40. package/5937.js +1 -1
  41. package/5937.js.map +1 -1
  42. package/6103.js +1 -1
  43. package/6103.js.map +1 -1
  44. package/6210.js +2 -0
  45. package/6210.js.map +1 -0
  46. package/6312.js +1 -1
  47. package/6312.js.map +1 -1
  48. package/6617.js +1 -1
  49. package/6617.js.map +1 -1
  50. package/6669.js +1 -1
  51. package/6669.js.map +1 -1
  52. package/6710.js +1 -1
  53. package/6710.js.map +1 -1
  54. package/6913.js +1 -1
  55. package/6913.js.map +1 -1
  56. package/7937.js +1 -1
  57. package/7937.js.map +1 -1
  58. package/8051.js +1 -1
  59. package/8051.js.map +1 -1
  60. package/810.js +2 -0
  61. package/810.js.map +1 -0
  62. package/8183.js +1 -1
  63. package/8183.js.map +1 -1
  64. package/8443.js +1 -1
  65. package/8443.js.map +1 -1
  66. package/8684.js +1 -1
  67. package/8684.js.map +1 -1
  68. package/8847.js +1 -1
  69. package/8847.js.map +1 -1
  70. package/9043.js +1 -1
  71. package/9043.js.map +1 -1
  72. package/9630.js +1 -1
  73. package/9630.js.map +1 -1
  74. package/99.js +1 -1
  75. package/99.js.map +1 -1
  76. package/package.json +1 -1
  77. package/remoteEntry.js +1 -1
  78. package/remoteEntry.js.map +1 -1
  79. package/4678.js +0 -2
  80. package/4678.js.map +0 -1
  81. package/9211.js +0 -2
  82. package/9211.js.map +0 -1
package/99.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"99.js","mappings":"uaAEA,MAQA,EAR4DA,GAEpD,2BAAKC,MAAO,GAAIC,OAAQ,GAAIC,QAAQ,YAAYC,MAAM,8BAAiCJ,GACnF,0BAAMK,EAAE,4BAA4BC,KAAK,eAAeC,SAAS,UAAUC,OAAO,OAAOC,YAAa,KCHrGC,GAAYC,E,SAAAA,IAAYC,IAAD,CAChC,sBAAuB,CACnBC,MAAOD,EAAME,QAAQC,QAAQC,MAEjCC,UAAW,CACPC,SAAU,WACVC,MAAO,MACPC,OAAQ,MACRC,UAAW,cAEfC,OAAQ,CACJC,QAAS,YCJXC,EAAe,IAAwB,IAAvB,QAACC,EAAD,QAAUC,GAAa,EACzC,MAAMC,EAASjB,IAEf,OACI,kBAAC,EAAAkB,QAAD,CAASC,MAAOJ,EAAUK,IAAAA,KAAU,qBAAuBA,IAAAA,KAAU,WACjE,kBAAC,EAAAC,WAAD,CAAYL,QAASA,EAASM,QAAS,CAACC,KAAMN,EAAOL,SAChDG,EACG,oCACI,kBAACS,EAAD,CAAYC,UAAWR,EAAO,yBAC9B,kBAACS,EAAA,QAAD,CAAWvB,MAAM,UAAUsB,UAAWR,EAAOV,aAG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AAa/nB,EAAIqiB,QAAQM,EAAS,MAGrD,GAFyBqE,EAAeY,EAAoBI,GAEtC,CAClB,MAAMH,EAAaJ,GAAAA,GACnBtD,EACKiE,OACAve,MAAM7F,IACH2jB,EAAqBJ,EAAMM,GAC3BT,EAAUx5B,QAAQs1B,YAAY,CAC1BC,OAAQ,cACRx1B,GAAIk6B,EACJ7nB,IAAKgoB,EACLvE,OAAQvrB,EAAQurB,OAChBzf,KAAAA,OAGP8F,OAAOne,IACJw8B,EAAMx8B,WAGd47B,EAAKpD,O,sICjNjB,MAqUA,GACIj3B,WAAY,CACR,IAAK,CAtUT,gBACA,aACA,WACA,qBACA,eACA,aACA,YACA,cACA,SACA,gBACA,gBACA,cACA,UACA,gBACA,iBACA,cACA,OACA,QACA,OACA,KACA,WACA,aACA,QACA,OACA,gBACA,YACA,YACA,QACA,sBACA,8BACA,gBACA,kBACA,oBACA,mBACA,SACA,KACA,KACA,IACA,aACA,UACA,kBACA,YACA,UACA,UACA,oBACA,MACA,KACA,KACA,WACA,YACA,oBACA,MACA,WACA,4BACA,OACA,eACA,YACA,SACA,YACA,cACA,cACA,gBACA,cACA,YACA,mBACA,eACA,aACA,eACA,cACA,SACA,OACA,KACA,KACA,KACA,KACA,aACA,+BACA,6BACA,WACA,oBACA,gBACA,UACA,SACA,cACA,iBACA,KACA,cACA,kBACA,KACA,MACA,YACA,IACA,KACA,KACA,KACA,KACA,eACA,mBACA,UACA,YACA,aACA,WACA,OACA,eACA,iBACA,iBACA,oBACA,QACA,aACA,aACA,eACA,eACA,cACA,cACA,OACA,mBACA,YACA,eACA,MACA,QACA,SACA,MACA,OACA,OACA,aACA,SACA,UACA,WACA,QACA,SACA,cACA,SACA,WACA,oBACA,qBACA,WACA,cACA,OACA,aACA,sBACA,mBACA,eACA,iBACA,SACA,YACA,YACA,YACA,gBACA,sBACA,iBACA,IACA,SACA,OACA,OACA,mBACA,cACA,YACA,qBACA,mBACA,UACA,SACA,SACA,KACA,KACA,QACA,OACA,kBACA,QACA,UACA,mBACA,mBACA,QACA,eACA,cACA,eACA,QACA,QACA,cACA,aACA,eACA,yBACA,0BACA,SACA,SACA,mBACA,oBACA,iBACA,kBACA,oBACA,iBACA,eACA,QACA,eACA,iBACA,cACA,SACA,UACA,UACA,cACA,kBACA,iBACA,aACA,KACA,YACA,OACA,KACA,KACA,qBACA,sBACA,UACA,eACA,gBACA,eACA,eACA,YACA,gBACA,iBACA,SACA,UACA,aACA,gBACA,gBACA,UACA,aACA,aACA,QACA,SACA,eACA,eACA,IACA,WACA,KACA,KACA,mBACA,IACA,KACA,KACA,mBACA,IACA,aAuFgC,aAAc,cAC1Cm7B,IAAK,CAAC,MAAO,SAAU,MAAO,QAAS,WACvCC,KAAM,CAAC,OAAQ,OACfC,OAAQ,CAAC,OACTC,EAAG,CAAC,SAERziB,KAAM,CAzFN,UACA,eACA,gBACA,mBACA,QACA,MACA,SACA,UACA,OACA,UACA,WACA,OACA,OACA,QACA,IACA,SACA,OACA,gBACA,UACA,MACA,SACA,SACA,OACA,YACA,mBACA,iBACA,gBACA,gBACA,QACA,QACA,iBACA,iBACA,OACA,SACA,UACA,QACA,OACA,OACA,UACA,WACA,OACA,OACA,MACA,iBACA,eACA,cACA,SACA,UACA,OACA,OACA,UACA,WACA,OACA,OACA,IACA,MACA,SACA,MACA,WACA,cACA,eACA,QACA,WACA,WACA,OACA,OACA,QACA,WACA,WACA,OACA,QACA,WACA,gBACA,SACA,SACA,gBACA,SACA,QACA,OAWuB,IAAK,OAAQ,QAAS,SAAU,SAAU,Q,wcC1U9D,MAAM0iB,EAAmB,KAC5B,MAAM,kBAACC,EAAD,YAAoBC,GAAeC,IAAAA,UACnC,WAAC17B,EAAD,KAAa6Y,GAAQ8iB,EACrB3wB,EAAoB,CACtBywB,YAAaA,EAAY96B,OAAOkY,GAChC2iB,kBAAmB,EAAF,GAAMA,EAAsBx7B,GAC7C47B,qBAAqB,GAEzB,OAAQnC,GAAiBiC,GAAAA,CAAajC,EAAMzuB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koB,QAAQC,QAAQ,CAAC,CAAC2F,MAAO,MAC9D,CACI8P,EAAAA,IACCvlC,IACGwlC,EAAAA,EAAAA,KAAgC,CAC5BngC,UAAWrF,EAAOuF,IAClB8/B,QAASA,EACTI,eAAgBvmB,EAChBwmB,WAAY1lC,EAAO0lC,WACnB3B,SAAAA,EACA91B,QAAAA,KAGZ,CAAChT,EAAAA,EAAI+E,IAAW2lC,EAAAA,EAAAA,KAAsB3lC,EAAOuF,IAAK8/B,EAASp3B,MAE/D61B,GAAa,GACb3kB,EAAY6Z,EAAQh5B,IACf4f,MAAK,IAA4B,KAA1B,YAACgmB,EAAD,MAAcnQ,IAAY,EAC9Bn0B,EAAS4B,EAAAA,GAAAA,UAAAA,QAAAA,gBAA0C,CAACQ,GAAInC,EAAOmC,GAAIkiC,YAAAA,EAAanQ,MAAAA,QAEnF1V,SAAQ,KACL+jB,GAAa,SAI1B,CACCE,EACA9jC,EACAqB,EACAD,EACAyiC,EACA/jC,MAAAA,OAND,EAMCA,EAAQuF,IACRvF,MAAAA,OAPD,EAOCA,EAAQ0lC,WACRtrB,EACA6pB,EACAzS,EACAmS,EACAtS,EACAlS,EACAukB,EACAxkB,EACAjR,IAEE43B,GAAmBtiC,EAAAA,EAAAA,SAAgB,GACzCsiC,EAAiBliC,SAAU,GAC3BjK,EAAAA,EAAAA,YAAU,KACNmsC,EAAiBliC,SAAU,EAC3BghC,MACD,CAACA,IACJ,MAAMmB,GAAWztB,EAAAA,EAAAA,GAAY7W,GAO7B,OANA9H,EAAAA,EAAAA,YAAU,KACF8H,IAASukC,EAAAA,IAAAA,SAAiBF,EAAiBliC,SAAWmiC,IAAatkC,IACnEqkC,EAAiBliC,SAAU,EAC3BghC,OAEL,CAACA,EAAenjC,EAAMskC,IAClB,CAACjC,UAAAA,EAAWlJ,OAAQgK,K","sources":["webpack://@reltio/remotes/../components/src/icons/Filter.tsx","webpack://@reltio/remotes/../components/src/components/BasicTableView/BasicTableHeader/FilterButton/styles.js","webpack://@reltio/remotes/../components/src/components/BasicTableView/BasicTableHeader/FilterButton/FilterButton.js","webpack://@reltio/remotes/../components/src/components/ExpandableSearchInput/styles.ts","webpack://@reltio/remotes/../components/src/components/ExpandableSearchInput/ExpandableSearchInput.tsx","webpack://@reltio/remotes/../components/src/components/HideOnShrink/HideOnShrink.js","webpack://@reltio/remotes/../components/src/components/ModeSwitcherSelect/styles.ts","webpack://@reltio/remotes/../components/src/components/ModeSwitcherSelect/ModeSwitcherSelect.tsx","webpack://@reltio/remotes/../components/src/components/ProfileMatchCard/styles.ts","webpack://@reltio/remotes/../components/src/components/ProfileMatchCard/ProfileMatchCard.tsx","webpack://@reltio/remotes/../components/src/components/RelationEditor/styles.js","webpack://@reltio/remotes/../components/src/components/RelationEditor/RelationEditor.js","webpack://@reltio/remotes/../components/src/components/RelationEditor/index.js","webpack://@reltio/remotes/../components/src/components/ReltioGridLayout/helpers.js","webpack://@reltio/remotes/../components/src/components/ReltioGridLayout/icons/ResizeIcon.svg.ts","webpack://@reltio/remotes/../components/src/components/ReltioGridLayout/styles.js","webpack://@reltio/remotes/../components/src/components/ReltioGridLayout/ReltioGridLayout.js","webpack://@reltio/remotes/../components/src/components/ReltioMap/MapControls/MapControlContainer/MapControlContrainer.tsx","webpack://@reltio/remotes/../components/src/icons/Radius.tsx","webpack://@reltio/remotes/../components/src/icons/Draw.tsx","webpack://@reltio/remotes/../components/src/components/ReltioMap/MapControls/TopRightMapControls/styles.ts","webpack://@reltio/remotes/../components/src/components/ReltioMap/MapControls/TopRightMapControls/TopRightMapControls.tsx","webpack://@reltio/remotes/../components/src/components/ReltioMap/MapControls/TopCenterMapControls/styles.ts","webpack://@reltio/remotes/../components/src/components/ReltioMap/MapControls/TopCenterMapControls/TopCenterMapControls.tsx","webpack://@reltio/remotes/../components/src/components/ReltioMap/helpers/index.ts","webpack://@reltio/remotes/../components/src/components/ReltioMap/EntityMarker/icons/marker.inline.svg.ts","webpack://@reltio/remotes/../components/src/components/ReltioMap/EntityMarker/styles.ts","webpack://@reltio/remotes/../components/src/components/ReltioMap/EntityMarker/EntityMarker.tsx","webpack://@reltio/remotes/../components/src/components/ReltioMap/EntityMarker/icons/marker-hover.inline.svg.ts","webpack://@reltio/remotes/../components/src/components/ReltioMap/styles.ts","webpack://@reltio/remotes/../components/src/components/ReltioMap/index.tsx","webpack://@reltio/remotes/../components/src/components/VerticalDivider/VerticalDivider.js","webpack://@reltio/remotes/../components/src/components/history/hooks/useHistoryDiff.ts","webpack://@reltio/remotes/../components/src/components/workflow/cards/GenericWorkflowTaskCard/styles.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/DueDateField/styles.ts","webpack://@reltio/remotes/../components/src/components/workflow/hooks/useWorkflowDueDate.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/DueDateField/DueDateField.tsx","webpack://@reltio/remotes/../components/src/components/workflow/hooks/useWorkflowPriority.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/PrioritySelector/PrioritySelector.tsx","webpack://@reltio/remotes/../components/src/components/workflow/components/LineDecorator/styles.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/LineDecorator/LineDecorator.tsx","webpack://@reltio/remotes/../components/src/components/workflow/hooks/useWorkflowColor.ts","webpack://@reltio/remotes/../components/src/icons/CollaborationIcon.tsx","webpack://@reltio/remotes/../components/src/components/workflow/cards/GenericWorkflowTaskCard/GenericWorkflowTaskCard.tsx","webpack://@reltio/remotes/../components/src/icons/DcrTaskIcon.tsx","webpack://@reltio/remotes/../components/src/components/workflow/constants/operations.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/helpers/helpers.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/helpers/attributesHelpers.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/helpers/mergeHelpers.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/components/ShowMoreLink/styles.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/components/ShowMoreLink/ShowMoreLink.tsx","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/components/ChangeView/styles.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/components/ChangeView/ChangeView.tsx","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/contexts/AttributesChangesContext.tsx","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/components/DiffRenderer/styles.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/components/DiffRenderer/DiffRenderer.tsx","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/components/DCRChangesList/styles.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/components/DCRChangesList/DCRChangesList.tsx","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/helpers/contextHelpers.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/styles.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/AttributesChanges.tsx","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/hooks/useCollapsibleList.ts","webpack://@reltio/remotes/../components/src/components/workflow/helpers/dcrHelpers.ts","webpack://@reltio/remotes/../components/src/components/workflow/hooks/useChangeRequest.ts","webpack://@reltio/remotes/../components/src/components/workflow/cards/DataChangeRequestTaskCard/DataChangeRequestTaskCard.tsx","webpack://@reltio/remotes/../components/src/components/workflow/cards/PotentialMatchTaskCard/styles.ts","webpack://@reltio/remotes/../components/src/icons/PmTaskIcon.tsx","webpack://@reltio/remotes/../components/src/components/workflow/cards/PotentialMatchTaskCard/PotentialMatchTaskCard.tsx","webpack://@reltio/remotes/../components/src/icons/DefaultTaskIcon.tsx","webpack://@reltio/remotes/../components/src/icons/DeleteRequestTaskIcon.tsx","webpack://@reltio/remotes/../components/src/components/workflow/cards/WorkflowTaskCardsFactory.tsx","webpack://@reltio/remotes/../components/src/components/workflow/cards/WorkflowTaskCard.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AddWorkflowDialog/styles.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AddWorkflowDialog/AddWorkflowDialog.tsx","webpack://@reltio/remotes/../components/src/components/workflow/hooks/useWorkflowDefinitions.ts","webpack://@reltio/remotes/../components/src/components/workflow/hooks/useWorkflowProcessInstance.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AddWorkflowButton/styles.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AddWorkflowButton/AddWorkflowButton.tsx","webpack://@reltio/remotes/../components/src/components/workflow/hooks/useWorkflowTasks.ts","webpack://@reltio/remotes/../components/src/constants/map.ts","webpack://@reltio/remotes/../components/src/contexts/EntityMarkerContext/index.ts","webpack://@reltio/remotes/../components/src/contexts/InterceptHandlersContext/index.ts","webpack://@reltio/remotes/../components/src/contexts/ProfilePerspectiveViewContext/index.ts","webpack://@reltio/remotes/../components/src/contexts/SandboxAPIContext/index.ts","webpack://@reltio/remotes/../components/src/hooks/useAPI/API.ts","webpack://@reltio/remotes/../components/src/hooks/useAPI/helpers.ts","webpack://@reltio/remotes/../components/src/hooks/helpers/sanitizerOptions.ts","webpack://@reltio/remotes/../components/src/hooks/useHtmlSanitizer.ts","webpack://@reltio/remotes/../components/src/hooks/useAPI/useAPI.ts","webpack://@reltio/remotes/../components/src/hooks/useCommentsEntitiesMap.ts","webpack://@reltio/remotes/../components/src/hooks/useConfigPermissions.ts","webpack://@reltio/remotes/../components/src/hooks/useRelationsLoader.ts"],"sourcesContent":["import React from 'react';\n\nconst SvgFilter: React.FC<React.SVGProps<SVGSVGElement>> = (props) => {\n return (\n <svg width={18} height={18} viewBox=\"0 0 18 18\" xmlns=\"http://www.w3.org/2000/svg\" {...props}>\n <path d=\"M18 2V0H0v2l7 8v8l4-2v-6z\" fill=\"currentColor\" fillRule=\"nonzero\" stroke=\"none\" strokeWidth={1} />\n </svg>\n );\n};\n\nexport default SvgFilter;\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles((theme) => ({\n 'filterIcon--enabled': {\n color: theme.palette.primary.main\n },\n closeIcon: {\n position: 'absolute',\n right: '3px',\n bottom: '3px',\n transform: 'scale(0.5)'\n },\n button: {\n padding: '11px'\n }\n}));\n","import React from 'react';\nimport PropTypes from 'prop-types';\nimport i18n from 'ui-i18n';\nimport {IconButton as IconButton} from '@material-ui/core';\nimport CloseIcon from '@material-ui/icons/Close';\nimport {Tooltip as Tooltip} from '@material-ui/core';\nimport FilterIcon from '../../../../icons/Filter';\nimport {useStyles} from './styles';\n\nconst FilterButton = ({enabled, onClick}) => {\n const styles = useStyles();\n\n return (\n <Tooltip title={enabled ? i18n.text('Clear all filters') : i18n.text('Filter')}>\n <IconButton onClick={onClick} classes={{root: styles.button}}>\n {enabled ? (\n <>\n <FilterIcon className={styles['filterIcon--enabled']} />\n <CloseIcon color=\"primary\" className={styles.closeIcon} />\n </>\n ) : (\n <FilterIcon />\n )}\n </IconButton>\n </Tooltip>\n );\n};\n\nFilterButton.propTypes = {\n enabled: PropTypes.bool,\n onClick: PropTypes.func\n};\n\nexport default FilterButton;\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles({\n searchButton: {\n marginLeft: 'auto !important',\n marginRight: '-4px',\n padding: '8px'\n },\n input: {\n flex: '1 0 200px',\n marginLeft: '70px',\n fontSize: '14px',\n background: 'rgba(0,0,0,0.03) 2px',\n padding: '4px 0',\n marginRight: '4px'\n },\n startAdornment: {\n color: 'rgba(0,0,0,0.54)',\n paddingLeft: '8px'\n }\n});\n","import React, {useState, useEffect} from 'react';\nimport i18n from 'ui-i18n';\nimport {always, F, pipe, propEq, T, tap, trim, when} from 'ramda';\nimport CloseIcon from '@material-ui/icons/Close';\nimport {IconButton as IconButton} from '@material-ui/core';\nimport {Input as Input} from '@material-ui/core';\nimport {InputAdornment as InputAdornment} from '@material-ui/core';\nimport SearchIcon from '@material-ui/icons/Search';\nimport {SmallIconButton} from '../SmallIconButton';\nimport {getValue} from '../../core';\n\nimport {useStyles} from './styles';\n\ntype Props = {\n query: string;\n onChange: (value: string) => void;\n};\n\nexport const ExpandableSearchInput = ({query, onChange}: Props) => {\n const [value, setValue] = useState(query);\n const [isOpen, setIsOpen] = useState(!!query);\n useEffect(() => {\n setValue(query);\n }, [query]);\n const styles = useStyles();\n const hasValue = value && value.length;\n\n return isOpen ? (\n <Input\n className={styles.input}\n value={value}\n autoFocus={true}\n placeholder={i18n.text('Search')}\n disableUnderline={true}\n onChange={pipe(getValue, setValue)}\n startAdornment={\n <InputAdornment position=\"start\">\n <SearchIcon className={styles.startAdornment} />\n </InputAdornment>\n }\n endAdornment={\n <InputAdornment position=\"end\">\n {hasValue && (\n <SmallIconButton\n size=\"S\"\n icon={CloseIcon}\n onClick={pipe(F, setIsOpen, always(''), tap(onChange), setValue)}\n />\n )}\n </InputAdornment>\n }\n onKeyPress={when(propEq('key', 'Enter'), pipe(always(value), trim, onChange))}\n />\n ) : (\n <IconButton className={styles.searchButton} onClick={pipe(T, setIsOpen)}>\n <SearchIcon />\n </IconButton>\n );\n};\n","import PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactResizeDetector from 'react-resize-detector';\n\nconst EmptyStub = () => <div style={{display: 'none'}} />;\n\nconst HideOnShrink = ({widthToHide, children}) => (\n <ReactResizeDetector\n handleWidth={true}\n render={({width}) => (width > widthToHide ? <>{children}</> : <EmptyStub />)}\n />\n);\n\nHideOnShrink.propTypes = {\n children: PropTypes.node,\n widthToHide: PropTypes.number.isRequired\n};\n\nexport default HideOnShrink;\n","import {makeStyles} from '@material-ui/core/styles';\n\nconst MAX_WIDTH_SELECT = 200;\nconst SELECT_PADDING_RIGHT = 32;\nconst SELECT_PADDING_LEFT = 12;\nconst CALCULATED_MAX_WIDTH_SELECT = MAX_WIDTH_SELECT - SELECT_PADDING_LEFT - SELECT_PADDING_RIGHT;\n\nexport const useStyles = makeStyles((theme) => ({\n root: {\n maxWidth: CALCULATED_MAX_WIDTH_SELECT,\n paddingTop: '9px',\n paddingBottom: '9px'\n },\n outlined: {\n paddingRight: SELECT_PADDING_RIGHT,\n paddingLeft: SELECT_PADDING_LEFT\n },\n arrowIcon: {\n fontSize: '18px',\n top: 'calc(50% - 9px)',\n right: '12px',\n color: theme.palette.text.secondary\n },\n currentValue: {\n display: 'flex',\n alignItems: 'center'\n },\n currentValueIcon: {\n fontSize: '18px',\n marginRight: '8px',\n color: theme.palette.text.secondary\n },\n currentValueText: {\n fontSize: '14px',\n lineHeight: '16px',\n textTransform: 'uppercase',\n fontWeight: 500,\n color: theme.palette.text.primary,\n whiteSpace: 'nowrap',\n textOverflow: 'ellipsis',\n overflow: 'hidden'\n },\n menuItem: {\n padding: '9px 12px 7px'\n },\n firstMenuItemButton: {\n borderTop: '1px solid #e4e4e4'\n },\n menuItemInner: {\n display: 'flex',\n alignItems: 'flex-start'\n },\n menuItemIcon: {\n fontSize: '18px',\n color: theme.palette.text.secondary,\n marginRight: '9px'\n },\n menuItemLabel: {\n fontSize: '14px',\n lineHeight: '16px',\n fontWeight: 500,\n color: theme.palette.text.primary\n },\n menuItemDescription: {\n fontSize: '10px',\n lineHeight: '16px',\n color: theme.palette.text.secondary\n }\n}));\n","import React from 'react';\nimport {propEq} from 'ramda';\nimport classnames from 'classnames';\nimport {Select as Select} from '@material-ui/core';\nimport {MenuItem as MenuItem} from '@material-ui/core';\nimport {Box as Box} from '@material-ui/core';\nimport {Typography as Typography} from '@material-ui/core';\nimport {Tooltip as Tooltip} from '@material-ui/core';\nimport {useStyles} from './styles';\n\ntype Option = {\n label: string;\n value: string;\n description: string;\n icon: React.ElementType;\n};\n\ntype Button = Option & {\n onClick: (value: string) => void;\n};\n\ntype ModeSwitcherSelectProps = {\n optionsGroup: Option[];\n buttonsGroup: Button[];\n value: string;\n onChange?: (value: string) => void;\n disabled?: boolean;\n};\n\ntype MenuItemProps = React.ComponentPropsWithoutRef<typeof MenuItem>;\n\nconst isButton = (value: Option | Button): value is Button => 'onClick' in value;\n\nexport const ModeSwitcherSelect = ({\n optionsGroup,\n buttonsGroup,\n value,\n onChange,\n disabled = false\n}: ModeSwitcherSelectProps) => {\n const styles = useStyles();\n\n const handleChange = (e: React.ChangeEvent<{value: string}>) => {\n const {value} = e.target;\n const isOption = optionsGroup.some(propEq('value', value));\n if (isOption) onChange(value);\n };\n\n const renderMenuItems = (items: (Option | Button)[]) => {\n const firstButtonIdx = items.findIndex(isButton);\n\n return items.map((item, idx) => {\n const {value, description, icon: IconComponent} = item;\n\n const menuItemProps: MenuItemProps = {\n value: value,\n className: styles.menuItem\n };\n\n if (isButton(item)) {\n menuItemProps.onClick = () => item.onClick(value);\n menuItemProps.className = classnames(menuItemProps.className, {\n [styles.firstMenuItemButton]: idx === firstButtonIdx\n });\n }\n\n return (\n <MenuItem key={value} {...menuItemProps} data-reltio-id={`reltio-profile-select-mode-${value}`}>\n <Box className={styles.menuItemInner}>\n <IconComponent className={styles.menuItemIcon} />\n <Box>\n <Typography className={styles.menuItemLabel}>{value}</Typography>\n <Typography className={styles.menuItemDescription}>{description}</Typography>\n </Box>\n </Box>\n </MenuItem>\n );\n });\n };\n\n return (\n <Select\n classes={{\n root: styles.root,\n icon: styles.arrowIcon,\n outlined: styles.outlined\n }}\n value={value}\n onChange={handleChange}\n variant=\"outlined\"\n renderValue={(value) => {\n const {icon: IconComponent, label = value} = optionsGroup.find(propEq('value', value)) || {};\n return (\n <Box className={styles.currentValue}>\n {IconComponent && <IconComponent className={styles.currentValueIcon} />}\n <Tooltip title={label}>\n <Typography className={styles.currentValueText}>{label}</Typography>\n </Tooltip>\n </Box>\n );\n }}\n MenuProps={{\n anchorOrigin: {\n vertical: 'bottom',\n horizontal: 'right'\n },\n transformOrigin: {\n vertical: 'top',\n horizontal: 'right'\n },\n getContentAnchorEl: null\n }}\n disabled={disabled}\n data-reltio-id=\"reltio-profile-select-mode\"\n >\n {renderMenuItems([...optionsGroup, ...buttonsGroup])}\n </Select>\n );\n};\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles({\n root: {\n display: 'flex',\n flexDirection: 'column',\n paddingRight: '12px',\n paddingTop: '8px',\n paddingBottom: '8px',\n '& + &': {\n borderTop: '1px solid rgba(0,0,0, 0.12)'\n }\n },\n profileCardWrapper: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n gap: '4px'\n },\n profileCardContainer: {\n flexGrow: 1,\n paddingBottom: '8px',\n paddingTop: '8px'\n },\n rulesContainer: {\n paddingLeft: '52px',\n marginBottom: '8px'\n }\n});\n","import React from 'react';\nimport {Entity, Metadata, Match} from '@reltio/mdm-sdk';\nimport {useStyles} from './styles';\nimport ProfileCard from '../ProfileCard/ProfileCard';\nimport MatchRulesBlock from '../MatchRulesBlock/MatchRulesBlock';\nimport classnames from 'classnames';\n\ntype Props = {\n entitiesMap: {\n [key: string]: Pick<Entity, 'uri' | 'type' | 'label'>;\n };\n entity: Entity;\n match: Match;\n metadata: Metadata;\n children?: React.ReactNode;\n className?: string;\n};\n\nexport const ProfileMatchCard = ({children, entitiesMap, entity, match, metadata, className}: Props) => {\n const styles = useStyles();\n return (\n <div className={classnames(styles.root, className)}>\n <div className={styles.profileCardWrapper}>\n <ProfileCard entity={match.object} classes={{container: styles.profileCardContainer}} />\n {children}\n </div>\n <div className={styles.rulesContainer}>\n {match.matchRules && (\n <MatchRulesBlock match={match} metadata={metadata} entitiesMap={entitiesMap} entity={entity} />\n )}\n </div>\n </div>\n );\n};\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles({\n editor: {\n display: 'flex',\n flexDirection: 'column',\n padding: '0 24px 5px',\n overflowX: 'hidden'\n },\n title: {\n color: 'rgba(0, 0, 0, 0.6)',\n fontSize: '16px',\n letterSpacing: '0.15px',\n lineHeight: '24px',\n margin: '17px 0 24px'\n },\n item: {\n marginBottom: '20px'\n },\n dense: {\n marginBottom: 0\n },\n actionButtons: {\n display: 'flex',\n justifyContent: 'flex-end',\n margin: '0 8px 10px',\n\n '& > button': {\n fontSize: '14px',\n lineHeight: '16px',\n marginLeft: '8px',\n padding: '10px 8px',\n backgroundColor: 'rgba(98, 2, 238, 0)'\n }\n }\n});\n","import React, {useCallback, useEffect, useMemo, useRef} from 'react';\nimport i18n from 'ui-i18n';\nimport PropTypes from 'prop-types';\nimport classnames from 'classnames';\nimport {\n allPass,\n always,\n concat,\n differenceWith,\n equals,\n forEach,\n omit,\n path,\n pick,\n pipe,\n prop,\n when,\n uniq,\n propEq\n} from 'ramda';\nimport {Button as Button} from '@material-ui/core';\nimport {Divider as Divider} from '@material-ui/core';\nimport {Typography as Typography} from '@material-ui/core';\nimport {\n AttributeErrorType,\n ConnectionType,\n createTemporaryEntity,\n EntityType,\n findRelatedTemporaryEntities,\n getActivenessAttributes,\n getCreatableAttributeTypes,\n getEntityType,\n getErrorMessage,\n getErrorId,\n MetadataType,\n omitMarks,\n relationEditorAttributeTypesSelectionStrategy,\n RelationsConfigType,\n validateConnection,\n updateConnectionEntityLabel,\n isTempUri,\n isEmptyValue,\n getRelationAttributesList,\n getDefaultRelationTypeObject,\n getInOutRelations\n} from '@reltio/mdm-sdk';\nimport {profile} from '@reltio/mdm-module';\nimport ConnectionRelationTypeSelector from '../ConnectionRelationTypeSelector/ConnectionRelationTypeSelector';\nimport ErrorWrapper from '../ErrorWrapper/ErrorWrapper';\nimport EntitySelector from '../attributes/editMode/EntitySelector/EntitySelector';\nimport AttributesList from '../attributes/editMode/AttributesList';\nimport {withContext} from '../../HOCs';\nimport {ScrollToErrorContext} from '../../contexts';\nimport {useScrollToAttributeError} from '../../hooks';\n\nimport {useStyles} from './styles';\n\nconst areRelatedEntitiesChanged = (initial, actual) =>\n initial.length !== actual.length || initial.some((_, i) => initial[i] !== actual[i]);\n\nconst RelationEditor = ({\n connection,\n modifiedEntity,\n initialConnection,\n initialModifiedEntity,\n allModifiedEntities,\n dispatch,\n config,\n mode,\n metadata,\n globalSearchRequestOptions,\n error,\n highlightedError\n}) => {\n const {relationUri, relationType, direction} = connection.relation;\n const isNew = connection.isNew;\n const styles = useStyles();\n const {ref, errorClassName} = useScrollToAttributeError({highlightedError, isSimple: true});\n const {inRelations: inRelationTypes = [], outRelations: outRelationTypes = []} = useMemo(\n () =>\n getInOutRelations({\n content: connection.parentEntityUri ? config.contentSecondLevel : config.content,\n direction,\n relationType,\n mode,\n metadata\n }),\n [config, direction, relationType, mode, metadata, connection.parentEntityUri]\n );\n const firstLevelRelationAttrTypes = useMemo(\n () => getRelationAttributesList(metadata, relationType),\n [relationType, metadata]\n );\n const attributeListEntity = useMemo(\n () => ({\n attributes: {\n ...profile.relations.selectors.getRelationAttributesFromConnection(connection)\n },\n ...getActivenessAttributes(connection.relation)\n }),\n [connection]\n );\n const relatedTempEntities = useMemo(\n () => findRelatedTemporaryEntities(allModifiedEntities, modifiedEntity),\n [allModifiedEntities, modifiedEntity]\n );\n const relatedTempEntitiesUrisHistory = useRef([]);\n\n const setInitialInfo = useCallback(\n (entity, connection) => {\n dispatch(profile.relations.actions.setInitialInfo(config.id, relationUri, entity, connection));\n },\n [dispatch]\n );\n\n useEffect(() => {\n if (!initialConnection) {\n setInitialInfo(modifiedEntity, connection);\n }\n }, []);\n\n useEffect(() => {\n relatedTempEntitiesUrisHistory.current = pipe(\n concat(relatedTempEntities.map(prop('uri'))),\n uniq\n )(relatedTempEntitiesUrisHistory.current);\n }, [relatedTempEntities]);\n const initialRelatedTempEntities = useRef(relatedTempEntities);\n const defaultRelationType = getDefaultRelationTypeObject(inRelationTypes, outRelationTypes);\n const hasChanges =\n !equals(pick(['entity', 'relation'], initialConnection || {}), pick(['entity', 'relation'], connection)) ||\n !equals(initialModifiedEntity, modifiedEntity) ||\n areRelatedEntitiesChanged(initialRelatedTempEntities.current, relatedTempEntities) ||\n (connection.isNew && !isEmptyValue(path(['relation', 'object', 'attributes'], connection)));\n const applyAction = isNew ? profile.relations.actions.addRelation : profile.relations.actions.editRelation;\n\n const onRelationTypeChange = useCallback(\n pipe(profile.relations.actions.setRelationType(config.id, relationUri), dispatch),\n [config, relationUri, dispatch]\n );\n\n const handleClose = useCallback(\n () => pipe(profile.relations.actions.closeRelationEditor, dispatch)(config.id, relationUri),\n [config, relationUri, dispatch]\n );\n\n const updateModifiedEntityLabel = useCallback(\n (connection) => {\n if (modifiedEntity) {\n const entityType = getEntityType(metadata, modifiedEntity.type);\n return updateConnectionEntityLabel(entityType, modifiedEntity, connection);\n }\n return connection;\n },\n [modifiedEntity, metadata]\n );\n\n const setModifiedEntity = useCallback(\n (entity) => dispatch(profile.modifiedEntities.actions.entityCreated(entity)),\n [dispatch]\n );\n\n const deleteModifiedEntity = useCallback(\n (entityUri) => dispatch(profile.modifiedEntities.actions.entityDeleted(entityUri)),\n [dispatch]\n );\n\n const onChangeEntity = useCallback(\n (entity) => {\n if (modifiedEntity) {\n deleteModifiedEntity(modifiedEntity.uri);\n }\n dispatch(profile.relations.actions.setRelationEntity(config.id, relationUri, entity));\n if (error) {\n dispatch(profile.errors.actions.errorDeactivated(getErrorId(error)));\n }\n },\n [config.id, relationUri, dispatch, modifiedEntity, deleteModifiedEntity, error]\n );\n\n const validate = useCallback(() => {\n const errors = validateConnection(metadata, allModifiedEntities, connection);\n dispatch(profile.errors.actions.errorsSet(errors));\n return errors.length === 0;\n }, [connection, metadata, allModifiedEntities, dispatch]);\n\n const resetErrors = useCallback(() => dispatch(profile.errors.actions.errorsSet([])), [dispatch]);\n\n const onApply = useCallback(\n pipe(\n always(connection),\n when(\n validate,\n pipe(\n omitMarks,\n updateModifiedEntityLabel,\n omit(['initial']),\n applyAction(config.id),\n dispatch,\n always(\n differenceWith(\n equals,\n relatedTempEntitiesUrisHistory.current,\n relatedTempEntities.map(prop('uri'))\n )\n ),\n forEach(deleteModifiedEntity),\n handleClose\n )\n )\n ),\n [connection, config, dispatch, updateModifiedEntityLabel, validate, relatedTempEntities]\n );\n\n const onCancel = useCallback(() => {\n if (modifiedEntity !== initialModifiedEntity) {\n if (initialModifiedEntity) {\n setModifiedEntity(initialModifiedEntity);\n if (modifiedEntity && modifiedEntity.uri !== initialModifiedEntity.uri) {\n deleteModifiedEntity(modifiedEntity.uri);\n }\n } else {\n deleteModifiedEntity(modifiedEntity.uri);\n }\n }\n const initialTempEntities = initialRelatedTempEntities.current;\n const entitiesUrisToDelete = differenceWith(\n equals,\n relatedTempEntitiesUrisHistory.current,\n initialTempEntities.map(prop('uri'))\n );\n entitiesUrisToDelete.forEach(deleteModifiedEntity);\n initialTempEntities.forEach(setModifiedEntity);\n resetErrors();\n handleClose();\n }, [handleClose, setModifiedEntity, deleteModifiedEntity, resetErrors, modifiedEntity, initialModifiedEntity]);\n\n const onAddAttributes = useCallback(\n (params) =>\n pipe(profile.actions.addAttributes, dispatch)(params.map((param) => ({...param, viewId: config.id}))),\n [config.id, dispatch]\n );\n\n const onChangeAttribute = useCallback(\n (params) => pipe(profile.actions.modifyAttribute, dispatch)({...params, viewId: config.id}),\n [config.id, dispatch]\n );\n\n const onDeleteAttribute = useCallback(\n (params) => pipe(profile.actions.removeAttribute, dispatch)({...params, viewId: config.id}),\n [config.id, dispatch]\n );\n\n const onCreateEntity = useCallback(\n (entityTypeUri, initValue) => {\n const entityType = getEntityType(metadata, entityTypeUri);\n const newEntityAttrTypes = pipe(\n relationEditorAttributeTypesSelectionStrategy,\n getCreatableAttributeTypes(mode)\n )(entityType);\n const newEntity = createTemporaryEntity({\n entityTypeUri,\n initValue,\n attributeTypes: newEntityAttrTypes,\n metadata,\n mode\n });\n onChangeEntity(newEntity);\n setModifiedEntity(newEntity);\n },\n [setModifiedEntity, onChangeEntity, mode, metadata]\n );\n const errorMessage = getErrorMessage(error);\n\n const getEntityTypesUris = useCallback(() => {\n const {content, contentSecondLevel} = config;\n\n if (contentSecondLevel && connection.parentEntityUri) {\n return contentSecondLevel.entityTypes;\n }\n\n return content.entityTypes;\n }, [config, connection.parentEntityUri]);\n\n return (\n <>\n <div className={styles.editor}>\n <Typography className={styles.title}>\n {isNew ? i18n.text('Add new item') : i18n.text('Edit item')}\n </Typography>\n {defaultRelationType === null && (\n <ConnectionRelationTypeSelector\n className={styles.item}\n relation={connection.relation}\n inRelationTypes={inRelationTypes}\n outRelationTypes={outRelationTypes}\n onChange={onRelationTypeChange}\n />\n )}\n {Boolean(relationType) && (\n <>\n <div ref={ref} className={errorClassName}>\n <ErrorWrapper errorMessage={errorMessage}>\n <EntitySelector\n className={classnames(styles.item, {\n [styles.dense]:\n errorMessage ||\n (connection.entity && isTempUri(connection.entity.entityUri))\n })}\n entity={connection.entity || {}}\n entityTypesUris={getEntityTypesUris() || []}\n max={config.max || 20}\n globalSearchRequestOptions={globalSearchRequestOptions}\n mode={mode}\n onChange={onChangeEntity}\n onCreate={onCreateEntity}\n metadata={metadata}\n attributeTypesSelectionStrategy={relationEditorAttributeTypesSelectionStrategy}\n />\n </ErrorWrapper>\n </div>\n <AttributesList\n className={styles.item}\n attrTypes={firstLevelRelationAttrTypes}\n entity={attributeListEntity}\n showEmptyEditors={true}\n crosswalks={connection.crosswalks}\n mode={mode}\n parentUri={relationUri}\n onAddAttributes={onAddAttributes}\n onChangeAttribute={onChangeAttribute}\n onDeleteAttribute={onDeleteAttribute}\n />\n </>\n )}\n </div>\n <div className={styles.actionButtons}>\n <Button onClick={onCancel}>{i18n.text('Cancel')}</Button>\n <Button color=\"primary\" disabled={!hasChanges} onClick={onApply}>\n {i18n.text('Apply')}\n </Button>\n </div>\n <Divider />\n </>\n );\n};\n\nRelationEditor.propTypes = {\n connection: ConnectionType,\n modifiedEntity: EntityType,\n initialConnection: ConnectionType,\n initialModifiedEntity: EntityType,\n allModifiedEntities: PropTypes.object,\n dispatch: PropTypes.func,\n config: RelationsConfigType,\n mode: PropTypes.string,\n metadata: MetadataType,\n globalSearchRequestOptions: PropTypes.object,\n error: AttributeErrorType,\n parentEntityUri: PropTypes.string,\n highlightedError: PropTypes.object\n};\n\nexport default withContext(\n ScrollToErrorContext,\n (contextValue, {connection}) => {\n const {error = {}} = contextValue || {};\n const {relationUri, relationType} = connection.relation;\n const isHighlighted = allPass([\n pipe(prop('uri'), isEmptyValue),\n propEq('parentUri', relationUri),\n propEq('attributeTypeUri', relationType)\n ])(error);\n return {highlightedError: isHighlighted ? contextValue : null};\n },\n RelationEditor\n);\n","import RelationEditor from './RelationEditor';\nimport mdmModule, {profile} from '@reltio/mdm-module';\nimport {connect} from 'react-redux';\nimport {getRelationEditorActiveError, isTempUri} from '@reltio/mdm-sdk';\n\nconst getConnectionEntityUri = (props) => profile.relations.selectors.getEntityUriFromConnection(props.connection);\nconst getConnectionRelationUri = (props) => profile.relations.selectors.getRelationUriFromConnection(props.connection);\n\nconst mapStateToProps = (state, ownProps) => {\n const entityUri = getConnectionEntityUri(ownProps);\n const relationUri = getConnectionRelationUri(ownProps);\n const isTempEntity = isTempUri(entityUri);\n return {\n initialConnection: mdmModule.selectors.getInitialConnection(state, ownProps.config.id, relationUri),\n initialModifiedEntity: mdmModule.selectors.getInitialConnectionTempEntity(\n state,\n ownProps.config.id,\n relationUri\n ),\n modifiedEntity: isTempEntity ? mdmModule.selectors.getModifiedEntity(state, entityUri) : null,\n allModifiedEntities: isTempEntity ? mdmModule.selectors.getModifiedEntities(state) : null,\n globalSearchRequestOptions: mdmModule.selectors.getGlobalSearchRequestOptions(state, ['ovOnly']),\n error: getRelationEditorActiveError(ownProps.connection, mdmModule.selectors.getProfileErrors(state))\n };\n};\n\nexport {RelationEditor};\n\nexport default connect(mapStateToProps)(RelationEditor);\n","import {curry, defaultTo, mergeAll, pick, pipe, prop, propEq, __} from 'ramda';\n\nexport const getReltioViewId = (id) => id.split(/\\d+_/)[1];\n\nexport const reltioLayoutItemToReactGridLayoutItem = ({\n x,\n y,\n width,\n height,\n id,\n minWidth,\n minHeight,\n maxWidth,\n maxHeight,\n isStatic\n}) => ({\n x,\n y,\n w: width,\n h: height,\n minW: minWidth,\n minH: minHeight,\n maxW: maxWidth,\n maxH: maxHeight,\n i: id,\n static: isStatic\n});\n\nexport const reactGridLayoutItemToReltioLayoutItem = ({x, y, w, h, maxW, minW, minH, maxH, i, ...obj}) => ({\n x,\n y,\n width: w,\n height: h,\n minWidth: minW,\n minHeight: minH,\n maxWidth: maxW,\n maxHeight: maxH,\n id: i,\n isStatic: obj.static\n});\n\nexport const reltioLayoutToReactGridLayout = (layout) => (layout || []).map(reltioLayoutItemToReactGridLayoutItem);\n\nexport const reactGridLayoutToReltioLayout = (layout) => (layout || []).map(reactGridLayoutItemToReltioLayoutItem);\n\nexport const getReltioLayoutItemById = curry((layout, id) => (layout || []).find(propEq('id', id)));\n\nconst updateExtraPropsInLayoutItem = curry((props, from, to) => mergeAll([to, pick(props, from)]));\n\nexport const copyPropsFromPreviousLayout = curry((props, oldReltioLayout, reltioLayout) =>\n (reltioLayout || []).map((layoutItem) =>\n pipe(\n prop('id'),\n getReltioLayoutItemById(oldReltioLayout),\n defaultTo({}),\n updateExtraPropsInLayoutItem(props, __, layoutItem)\n )(layoutItem)\n )\n);\n\nexport const calcHeight = (height, options) => {\n const {margin, rowHeight} = options;\n\n return Math.ceil((height + margin[1]) / (rowHeight + margin[1]));\n};\n","export const RESIZE_ICON = `<svg width=\"10\" height=\"10\" viewBox=\"0 0 10 10\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path stroke=\"#505050\" stroke-opacity=\".54\" d=\"M9.5 0v10M0 9.5h9M7.5 4v4M4 7.5h3\"/>\n</svg>`;\n","import {makeStyles} from '@material-ui/core/styles';\nimport {svg2Url} from '@reltio/mdm-sdk';\nimport {RESIZE_ICON} from './icons/ResizeIcon.svg';\n\nexport const useStyles = makeStyles((_) => ({\n gridLayout: {\n position: 'relative',\n width: '100%',\n '& .react-grid-item': {\n '&.react-grid-placeholder': {\n background: 'rgba(0, 0, 0, 0.03)',\n border: '2px dashed rgba(0, 0, 0, 0.3)',\n borderRadius: '3px',\n transitionDuration: '100ms',\n zIndex: 7,\n userSelect: 'none',\n '& .react-resizable-handle': {\n display: 'none'\n }\n },\n '&.static .react-resizable-handle': {\n display: 'none'\n },\n '&.cssTransforms': {\n transitionProperty: 'transform'\n },\n '&.resizing': {\n zIndex: 9,\n willChange: 'width, height',\n pointerEvents: 'none'\n },\n '&.react-draggable-dragging': {\n transition: 'none',\n zIndex: 8,\n willChange: 'transform',\n '& .react-resizable-handle': {\n backgroundImage: 'none'\n }\n },\n '& .react-resizable-handle': {\n position: 'absolute',\n width: '17px',\n height: '17px',\n bottom: 0,\n right: 0,\n zIndex: 20,\n backgroundImage: `url('${svg2Url(RESIZE_ICON)}')`,\n backgroundRepeat: 'no-repeat',\n backgroundOrigin: 'content-box',\n boxSizing: 'border-box',\n cursor: 'se-resize'\n },\n '&.fullscreen': {\n visibility: 'visible',\n position: 'unset',\n width: '100% !important',\n height: '100% !important',\n transform: 'translate(0) !important'\n }\n }\n },\n\n gridFullscreen: {\n height: '100% !important',\n overflowY: 'hidden',\n '& .react-resizable-handle, & .react-grid-item': {\n visibility: 'hidden'\n }\n }\n}));\n","import PropTypes from 'prop-types';\nimport React, {useCallback, useMemo, useRef, useState, memo} from 'react';\nimport GridLayout from 'react-grid-layout';\nimport ReactResizeDetector from 'react-resize-detector';\nimport {identity, pipe} from 'ramda';\nimport classnames from 'classnames';\nimport {\n reltioLayoutToReactGridLayout,\n reactGridLayoutToReltioLayout,\n reactGridLayoutItemToReltioLayoutItem,\n copyPropsFromPreviousLayout,\n calcHeight,\n getReltioLayoutItemById\n} from './helpers';\n\nimport {useStyles} from './styles';\n\nconst ReltioGridLayout = ({\n views,\n layout,\n layoutOptions,\n onLayoutChanged,\n draggableHandle,\n LayoutItem,\n onRemove,\n onDrop,\n droppingItem,\n isDroppable,\n classes\n}) => {\n const ref = useRef();\n const styles = useStyles();\n const [fullscreenItemId, setFullscreenItemId] = useState(null);\n const [width, setWidth] = useState(0);\n const {cols, rowHeight, margin} = layoutOptions;\n const processedLayout = useMemo(() => reltioLayoutToReactGridLayout(layout), [layout]);\n const onReltioLayoutChanged = pipe(\n reactGridLayoutToReltioLayout,\n copyPropsFromPreviousLayout(['autosizing'], layout),\n onLayoutChanged\n );\n const handleDrop = (layout, layoutItem, e) => {\n if (onDrop) {\n onDrop(reactGridLayoutToReltioLayout(layout), reactGridLayoutItemToReltioLayoutItem(layoutItem), e);\n }\n };\n const onToggleFullscreen = useCallback((id) => setFullscreenItemId((prevId) => (prevId ? null : id)), []);\n const isFullscreenEnabled = fullscreenItemId !== null;\n\n const onItemHeightResize = useCallback(\n (height, layoutId) => {\n let isLayoutChanged = false;\n\n const newLayout = layout.map((layoutItem) => {\n if (layoutItem.id === layoutId && height) {\n const newHeight = calcHeight(height, layoutOptions);\n\n if (layoutItem.height !== newHeight) {\n isLayoutChanged = true;\n return {\n ...layoutItem,\n minHeight: newHeight,\n maxHeight: newHeight,\n height: newHeight\n };\n }\n }\n return layoutItem;\n });\n\n if (isLayoutChanged) {\n onLayoutChanged(newLayout);\n }\n },\n [layout, layoutOptions, onLayoutChanged]\n );\n\n const getAutosizeComponent = (layoutItemId) => {\n return (\n <ReactResizeDetector\n handleHeight\n onResize={(width, height) => {\n onItemHeightResize(height, layoutItemId);\n }}\n />\n );\n };\n\n return (\n <>\n <ReactResizeDetector\n refreshMode=\"debounce\"\n refreshRate={50}\n handleWidth={true}\n onResize={(width) => setWidth(width)}\n />\n <GridLayout\n innerRef={ref}\n layout={processedLayout}\n cols={cols}\n draggableHandle={draggableHandle}\n autoSize={true}\n rowHeight={rowHeight}\n width={width}\n margin={margin}\n onLayoutChange={onReltioLayoutChanged}\n isResizable={!isFullscreenEnabled}\n isDraggable={!isFullscreenEnabled}\n className={classnames(classes.root, styles.gridLayout, {[styles.gridFullscreen]: isFullscreenEnabled})}\n onDrop={handleDrop}\n droppingItem={droppingItem}\n isDroppable={isDroppable}\n >\n {processedLayout.map((layoutItem) => {\n const isItemFullscreen = fullscreenItemId === layoutItem.i;\n const isAutosize = (getReltioLayoutItemById(layout, layoutItem.i) || {}).autosizing;\n const autosizeComponent = isAutosize ? {AutosizeComponent: getAutosizeComponent(layoutItem.i)} : {};\n return (\n <LayoutItem\n key={layoutItem.i}\n layoutItemConfig={layoutItem}\n views={views}\n onToggleFullscreen={onToggleFullscreen}\n onRemove={onRemove}\n className={classnames({fullscreen: isItemFullscreen}, classes.item)}\n isFullscreen={isItemFullscreen}\n {...autosizeComponent}\n />\n );\n })}\n </GridLayout>\n </>\n );\n};\n\nReltioGridLayout.defaultProps = {\n layoutOptions: {\n cols: 4,\n rowHeight: 30,\n margin: [15, 15]\n },\n onConfigChanged: identity,\n onLayoutChanged: identity,\n classes: {}\n};\nReltioGridLayout.propTypes = {\n views: PropTypes.array,\n layout: PropTypes.array,\n layoutOptions: PropTypes.object,\n onConfigChanged: PropTypes.func,\n onLayoutChanged: PropTypes.func,\n onDrop: PropTypes.func,\n onRemove: PropTypes.func,\n LayoutItem: PropTypes.elementType,\n draggableHandle: PropTypes.string,\n isDroppable: PropTypes.bool,\n droppingItem: PropTypes.object,\n classes: PropTypes.shape({\n root: PropTypes.string,\n item: PropTypes.string\n })\n};\n\nexport default memo(ReltioGridLayout);\n","import React, {useEffect, useState} from 'react';\nimport {createPortal} from 'react-dom';\nimport {MapInstance} from '../../types';\n\ntype Props = {\n children: React.ReactNode;\n className?: string;\n position: number;\n map: MapInstance;\n};\n\nexport const MapControlContainer = ({children, className, position, map}: Props) => {\n const [controlElement, setControlElement] = useState(null);\n\n useEffect(() => {\n const controlDiv = document.createElement('div');\n const divIndex = map.controls[position].length;\n map.controls[position].push(controlDiv);\n setControlElement(controlDiv);\n\n return () => {\n map.controls[position].removeAt(divIndex);\n };\n }, [map, position]);\n\n useEffect(() => {\n if (controlElement && className) {\n controlElement.classList.add(className);\n }\n }, [className, controlElement]);\n\n if (controlElement) {\n return createPortal(children, controlElement);\n }\n\n return null;\n};\n","import React from 'react';\n\nconst SvgRadius: React.FC<React.SVGProps<SVGSVGElement>> = (props) => {\n return (\n <svg width={18} height={18} viewBox=\"0 0 18 18\" xmlns=\"http://www.w3.org/2000/svg\" {...props}>\n <path\n d=\"M10.61 8.568A1.666 1.666 0 119.432 7.39l3.656-3.657a6.668 6.668 0 101.179 1.179L10.61 8.568zm-7.503 6.325A8.333 8.333 0 1114.893 3.107 8.333 8.333 0 013.107 14.893z\"\n fill=\"#000\"\n stroke=\"none\"\n strokeWidth={1}\n fillRule=\"evenodd\"\n opacity={0.54}\n />\n </svg>\n );\n};\n\nexport default SvgRadius;\n","import React from 'react';\n\nconst SvgDraw: React.FC<React.SVGProps<SVGSVGElement>> = (props) => {\n return (\n <svg\n width={24}\n height={24}\n viewBox=\"0 0 24 24\"\n xmlns=\"http://www.w3.org/2000/svg\"\n xmlnsXlink=\"http://www.w3.org/1999/xlink\"\n {...props}\n >\n <defs>\n <path\n d=\"M18.29 11.44a1.49 1.49 0 012.12 0l1.15 1.15c.59.58.59 1.53 0 2.12L16.27 20H13v-3.27zM18.174 4c0 1.71-.26 3.285-.932 4.563-.946 1.798-2.609 2.724-4.906 2.46l-.855-.116c-4.382-.544-6.626.53-6.626 3.609 0 1.968 1.105 2.924 3.267 3.304.692.121 1.306.165 2.234.176L11 18v2l-.698-.003c-1.016-.013-1.71-.063-2.526-.206-3.018-.53-4.921-2.176-4.921-5.274 0-4.819 3.71-6.378 9.52-5.505 1.575.237 2.506-.255 3.098-1.38.451-.858.666-2.02.697-3.307L16.174 4h2zM18 13.97l-3.45 3.45v1.03h1.03L19.03 15 18 13.97z\"\n id=\"Draw_svg__a\"\n />\n </defs>\n <g stroke=\"none\" strokeWidth={1} fill=\"none\" fillRule=\"evenodd\">\n <mask id=\"Draw_svg__b\" fill=\"#fff\">\n <use xlinkHref=\"#Draw_svg__a\" />\n </mask>\n <g mask=\"url(#Draw_svg__b)\" fill=\"#000\" fillOpacity={0.54}>\n <path d=\"M0 0h24v24H0z\" />\n </g>\n </g>\n </svg>\n );\n};\n\nexport default SvgDraw;\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles({\n container: {\n margin: '2px',\n display: 'flex',\n alignItems: 'center'\n },\n button: {\n color: 'rgba(0,0,0,0.54)',\n padding: 0,\n height: '24px',\n width: '24px',\n minWidth: 0\n },\n icon: {\n width: '20px',\n height: '20px'\n }\n});\n","import React from 'react';\nimport i18n from 'ui-i18n';\nimport {Button as Button} from '@material-ui/core';\nimport {withTooltip} from '../../../../HOCs';\nimport HighlightOffIcon from '@material-ui/icons/HighlightOff';\nimport {MAP_DRAWING_MODES} from '../../../../constants';\nimport RadiusIcon from '../../../../icons/Radius';\nimport DrawIcon from '../../../../icons/Draw';\nimport {DrawingMode, DrawingModes} from '../../types';\nimport {useStyles} from './styles';\n\nexport const ButtonWithTooltip = withTooltip(Button);\n\nconst getIcon = (mode: DrawingMode) => {\n switch (mode) {\n case MAP_DRAWING_MODES.CIRCLE:\n return RadiusIcon;\n case MAP_DRAWING_MODES.POLYGON:\n return DrawIcon;\n default:\n return null;\n }\n};\n\ntype Props = {\n onDrawingModeChanged: (value: DrawingMode | null) => void;\n drawingMode: DrawingMode | null;\n drawingModes: DrawingModes;\n hasActiveOverlay: boolean;\n onClearOverlay: () => void;\n};\n\nexport const TopRightMapControls = ({\n drawingMode,\n drawingModes = [],\n hasActiveOverlay,\n onDrawingModeChanged,\n onClearOverlay\n}: Props) => {\n const styles = useStyles();\n\n const changeDrawingModeTo = (drawingMode) => () => {\n onDrawingModeChanged(drawingMode);\n };\n\n return (\n <div className={styles.container}>\n {drawingMode || hasActiveOverlay ? (\n <ButtonWithTooltip\n tooltipTitle={i18n.text('Clear area')}\n className={styles.button}\n onClick={hasActiveOverlay ? onClearOverlay : changeDrawingModeTo(null)}\n >\n <HighlightOffIcon className={styles.icon} />\n </ButtonWithTooltip>\n ) : (\n drawingModes.map((mode) => {\n const Icon = getIcon(mode);\n return (\n <ButtonWithTooltip\n tooltipTitle={i18n.text('Draw area')}\n key={mode}\n className={styles.button}\n onClick={changeDrawingModeTo(mode)}\n >\n <Icon className={styles.icon} />\n </ButtonWithTooltip>\n );\n })\n )}\n </div>\n );\n};\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles({\n container: {\n height: '28px',\n marginRight: '7px',\n marginLeft: 0\n },\n label: {\n fontSize: '11px',\n alignSelf: 'center',\n lineHeight: '13px',\n marginLeft: '2px',\n letterSpacing: 0\n },\n checkbox: {\n width: '20px',\n height: '20px',\n padding: '5px',\n '& svg': {\n width: '16px',\n height: '16px'\n }\n }\n});\n","import React from 'react';\nimport i18n from 'ui-i18n';\nimport {FormControlLabel as FormControlLabel} from '@material-ui/core';\nimport {Checkbox as Checkbox} from '@material-ui/core';\nimport {useStyles} from './styles';\n\ntype Props = {\n isSearchOnMapMove: boolean;\n onChangeIsSearchOnMapMove: (value: boolean) => void;\n};\n\nexport const TopCenterMapControls = ({isSearchOnMapMove, onChangeIsSearchOnMapMove}: Props) => {\n const styles = useStyles();\n const onChange = (event) => {\n onChangeIsSearchOnMapMove(event.target.checked);\n };\n return (\n <FormControlLabel\n classes={{\n root: styles.container,\n label: styles.label\n }}\n control={\n <Checkbox checked={isSearchOnMapMove} onChange={onChange} color=\"primary\" className={styles.checkbox} />\n }\n label={i18n.text('Search as I move the map')}\n />\n );\n};\n","import {MAP_DRAWING_MODES, MAP_MINIMUM_SCALE_RADIUS} from '../../../constants';\nimport {DrawingMode, EntityMarker, Overlay, MapInstance} from '../types';\n\nexport const getMapBoundsPolygon = (map: MapInstance) => {\n const bounds = map.getBounds();\n const ne = bounds.getNorthEast();\n const sw = bounds.getSouthWest();\n const neLat = ne.lat(),\n neLng = ne.lng(),\n swLat = sw.lat(),\n swLng = sw.lng();\n const additionalPoint1 = [];\n const additionalPoint2 = [];\n if (!((neLng === 180 && swLng === -180) || (neLng === -180 && swLng === 180))) {\n // excluding corner case when we see more than one \"map unfolding\" (in this case google maps automatically set 180 and -180),\n // we can't describe map bounds as just rectangle, because lng distance can be more than 180\",\n // so we need to add additional points to have correct polygon\n const center = bounds.getCenter();\n additionalPoint1.push([neLat, center.lng()]);\n additionalPoint2.push([swLat, center.lng()]);\n }\n return [[neLat, neLng], ...additionalPoint1, [neLat, swLng], [swLat, swLng], ...additionalPoint2, [swLat, neLng]];\n};\n\nexport const getDrawingMode = (drawingMode: DrawingMode) => {\n switch (drawingMode) {\n case MAP_DRAWING_MODES.CIRCLE:\n return window.google.maps.drawing.OverlayType.CIRCLE;\n case MAP_DRAWING_MODES.POLYGON:\n return window.google.maps.drawing.OverlayType.POLYGON;\n default:\n return null;\n }\n};\n\nexport const fitMapBoundsForMarkers = (markers: EntityMarker[], map: MapInstance, overlay: Overlay) => {\n const bounds = new window.google.maps.LatLngBounds();\n\n markers.forEach((marker) => bounds.extend(marker.point));\n\n if (markers.length === 1) {\n const center = bounds.getCenter();\n\n bounds.extend(\n new window.google.maps.LatLng(\n center.lat() + MAP_MINIMUM_SCALE_RADIUS,\n center.lng() + MAP_MINIMUM_SCALE_RADIUS\n )\n );\n bounds.extend(\n new window.google.maps.LatLng(\n center.lat() - MAP_MINIMUM_SCALE_RADIUS,\n center.lng() - MAP_MINIMUM_SCALE_RADIUS\n )\n );\n }\n\n map.fitBounds(bounds);\n\n if (overlay) {\n fitMapBoundsForOverlay(map, overlay, bounds);\n }\n};\n\nexport const fitMapBoundsForOverlay = (map: MapInstance, overlay: Overlay, existingBounds?) => {\n if (overlay.path) {\n const bounds = existingBounds || new window.google.maps.LatLngBounds();\n overlay.path.forEach(({lat, lng}) => bounds.extend(new window.google.maps.LatLng(lat, lng)));\n map.fitBounds(bounds);\n }\n};\n","export const MARKER = `<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<svg width=\"22px\" height=\"32px\" viewBox=\"0 0 22 32\" version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n <title>View / Map / Marker / Large</title>\n <defs>\n <radialGradient cx=\"50%\" cy=\"50.2950175%\" fx=\"50%\" fy=\"50.2950175%\" r=\"49.7049825%\" gradientTransform=\"translate(0.500000,0.502950),scale(0.777778,1.000000),rotate(90.000000),scale(1.000000,1.293560),translate(-0.500000,-0.502950)\" id=\"radialGradient-1\">\n <stop stop-color=\"#000000\" offset=\"0%\"></stop>\n <stop stop-color=\"#000000\" stop-opacity=\"0\" offset=\"100%\"></stop>\n </radialGradient>\n <path d=\"M20,1 C20.5522847,1 21,1.44771525 21,2 L21,20 C21,20.5522847 20.5522847,21 20,21 L15.2374606,21.0021908 C14.9306693,21.3935449 14.6510143,21.7632851 14.3885453,22.1256523 C12.8309725,24.2760522 12,26.0137017 12,27.5 C12,28.0522847 11.5522847,28.5 11,28.5 C10.4477153,28.5 10,28.0522847 10,27.5 C10,25.7886708 8.84033182,23.6810997 6.73798027,21.0014567 L2,21 C1.44771525,21 1,20.5522847 1,20 L1,2 C1,1.44771525 1.44771525,1 2,1 L20,1 Z\" id=\"path-2\"></path>\n </defs>\n <g id=\"View-/-Map-/-Marker-/-Large\" stroke=\"none\" stroke-width=\"1\" fill=\"none\" fill-rule=\"evenodd\">\n <ellipse id=\"Oval\" fill=\"url(#radialGradient-1)\" opacity=\"0.12\" cx=\"11\" cy=\"28.5\" rx=\"4.5\" ry=\"3.5\"></ellipse>\n <path d=\"M21,0 C21.5522847,-1.01453063e-16 22,0.44771525 22,1 L22,21 C22,21.5522847 21.5522847,22 21,22 L15.7283832,22.0012846 C15.5422129,22.2445529 15.3664776,22.4802332 15.1984183,22.7122576 C13.7560833,24.7035592 13,26.2846074 13,27.5 L13,27.5 L12.9945143,27.6492623 C12.9181651,28.6841222 12.0543618,29.5 11,29.5 C9.8954305,29.5 9,28.6045695 9,27.5 L9,27.5 L8.99485006,27.3298651 C8.91582184,26.0024976 7.93016704,24.2171459 6.23940611,22.000704 L1,22 C0.44771525,22 6.76353751e-17,21.5522847 0,21 L0,1 C-6.76353751e-17,0.44771525 0.44771525,1.01453063e-16 1,0 L21,0 Z\" id=\"Path-3\" fill=\"#FFFFFF\"></path>\n <mask id=\"mask-3\" fill=\"white\">\n <use xlink:href=\"#path-2\"></use>\n </mask>\n <use id=\"Path-2\" fill=\"#FFFFFF\" fill-rule=\"nonzero\" xlink:href=\"#path-2\"></use>\n <rect id=\"Entity-type\" fill=\"#24A8E8\" mask=\"url(#mask-3)\" x=\"0\" y=\"0\" width=\"22\" height=\"32\"></rect>\n </g>\n</svg>`;\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles({\n popper: {\n maxWidth: '263px',\n minWidth: '150px',\n boxShadow: '0 1px 1px 0 rgba(0,0,0,0.14), 0 2px 1px -1px rgba(0,0,0,0.12), 0 1px 3px 0 rgba(0,0,0,0.2)',\n backgroundColor: 'white',\n borderRadius: '2px'\n }\n});\n","import React, {memo, useCallback, useContext, useRef, useState} from 'react';\nimport {pathEq} from 'ramda';\nimport {Marker, InfoBox, MarkerProps} from '@react-google-maps/api';\nimport ProfileCard from '../../ProfileCard/ProfileCard';\nimport Popper from '../../Popper/Popper';\nimport {debounce, svg2Url} from '@reltio/mdm-sdk';\nimport {EntityMarkerContext} from '../../../contexts';\nimport {MARKER} from './icons/marker.inline.svg';\nimport {HOVERED_MARKER} from './icons/marker-hover.inline.svg';\nimport {EntityMarker as EntityMarkerType} from '../types';\nimport {useStyles} from './styles';\n\nconst HIDE_DEBOUNCE_INTERVAL = 50;\nconst MARKER_WIDTH = 22;\nconst MARKER_HEIGHT = 32;\nconst MARKER_CARD_MARGIN = 8;\n\nconst hoveredMarkerIcon = svg2Url(HOVERED_MARKER);\nconst markerIcon = svg2Url(MARKER);\n\ntype Props = {\n marker: EntityMarkerType;\n onClick: (marker: EntityMarkerType) => void;\n} & Omit<MarkerProps, 'onClick' | 'icon' | 'position' | 'visible' | 'onMouseOver' | 'onMouseOut'>;\n\nconst EntityMarker = ({marker, onClick, ...otherProps}: Props) => {\n const styles = useStyles();\n const popperAnchor = useRef();\n const [hovered, setHovered] = useState(false);\n const {activeEntityUri} = useContext(EntityMarkerContext);\n const isActive = pathEq(['entity', 'uri'], activeEntityUri, marker);\n const position = {lat: marker.point.lat, lng: marker.point.lng};\n const setHoveredDebounced = useCallback(debounce(setHovered, HIDE_DEBOUNCE_INTERVAL), []);\n const onMouseOver = useCallback(() => setHoveredDebounced(true), [setHoveredDebounced]);\n const onMouseOut = useCallback(() => setHoveredDebounced(false), [setHoveredDebounced]);\n const handleClick = useCallback(() => onClick(marker), [onClick, marker]);\n\n return (\n <>\n <Popper\n anchorEl={popperAnchor.current}\n open={hovered}\n className={styles.popper}\n modal={false}\n placement=\"top\"\n >\n <ProfileCard entity={marker.entity} onMouseOver={onMouseOver} onMouseOut={onMouseOut} />\n </Popper>\n <Marker\n icon={{\n url: hovered || isActive ? hoveredMarkerIcon : markerIcon,\n // needed for IE:\n scaledSize: new google.maps.Size(MARKER_WIDTH, MARKER_HEIGHT) //eslint-disable-line\n }}\n position={position}\n onClick={handleClick}\n visible={marker.visible !== false}\n onMouseOver={onMouseOver}\n onMouseOut={onMouseOut}\n {...otherProps}\n />\n <InfoBox\n options={{\n alignBottom: true,\n pane: 'mapPane',\n pixelOffset: new google.maps.Size(0, -(MARKER_HEIGHT + MARKER_CARD_MARGIN)), //eslint-disable-line\n closeBoxURL: '',\n enableEventPropagation: true,\n disableAutoPan: true\n }}\n position={position}\n >\n <span ref={popperAnchor} />\n </InfoBox>\n </>\n );\n};\n\nexport default memo(EntityMarker);\n","export const HOVERED_MARKER = `<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<svg width=\"22px\" height=\"32px\" viewBox=\"0 0 22 32\" version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n <title>View / Map / Marker / Large (hover)</title>\n <defs>\n <radialGradient cx=\"50%\" cy=\"50.2950175%\" fx=\"50%\" fy=\"50.2950175%\" r=\"49.7049825%\" gradientTransform=\"translate(0.500000,0.502950),scale(0.777778,1.000000),rotate(90.000000),scale(1.000000,1.293560),translate(-0.500000,-0.502950)\" id=\"radialGradient-1\">\n <stop stop-color=\"#000000\" offset=\"0%\"></stop>\n <stop stop-color=\"#000000\" stop-opacity=\"0\" offset=\"100%\"></stop>\n </radialGradient>\n <path d=\"M21,0 C21.5522847,-1.01453063e-16 22,0.44771525 22,1 L22,21 C22,21.5522847 21.5522847,22 21,22 L15.7283832,22.0012846 C15.5422129,22.2445529 15.3664776,22.4802332 15.1984183,22.7122576 C13.7560833,24.7035592 13,26.2846074 13,27.5 L13,27.5 L12.9945143,27.6492623 C12.9181651,28.6841222 12.0543618,29.5 11,29.5 C9.8954305,29.5 9,28.6045695 9,27.5 L9,27.5 L8.99485006,27.3298651 C8.91582184,26.0024976 7.93016704,24.2171459 6.23940611,22.000704 L1,22 C0.44771525,22 6.76353751e-17,21.5522847 0,21 L0,1 C-6.76353751e-17,0.44771525 0.44771525,1.01453063e-16 1,0 L21,0 Z\" id=\"path-2\"></path>\n </defs>\n <g id=\"View-/-Map-/-Marker-/-Large-(hover)\" stroke=\"none\" stroke-width=\"1\" fill=\"none\" fill-rule=\"evenodd\">\n <ellipse id=\"Oval\" fill=\"url(#radialGradient-1)\" opacity=\"0.32\" cx=\"11\" cy=\"28.5\" rx=\"6\" ry=\"4.66666667\"></ellipse>\n <mask id=\"mask-3\" fill=\"white\">\n <use xlink:href=\"#path-2\"></use>\n </mask>\n <use id=\"Path-2\" fill=\"#FFFFFF\" xlink:href=\"#path-2\"></use>\n <rect id=\"Entity-type\" fill=\"#24A8E8\" mask=\"url(#mask-3)\" x=\"0\" y=\"0\" width=\"22\" height=\"32\"></rect>\n <path d=\"M20,2 L20,20 L14.755,20 L14.6905172,20.0815309 C14.3562717,20.5012516 14.0578656,20.8886742 13.7817711,21.2616986 L13.5786724,21.5390469 C11.92787,23.8181606 11.079024,25.6311217 11.0052669,27.2674145 L11.0052669,27.2674145 L11,27.5 L10.9968324,27.3203844 C10.9285422,25.3781621 9.75347502,23.1598866 7.22124201,20.0010865 L2,20 L2,2 L20,2 Z\" id=\"Path\" fill=\"#FFFFFF\" fill-rule=\"nonzero\" mask=\"url(#mask-3)\"></path>\n </g>\n</svg>`;\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles({\n mapControlContainer: {\n borderRadius: '2px',\n backgroundColor: '#FFFFFF',\n boxShadow: '0 1px 3px 0 rgba(0,0,0,0.15)',\n margin: '10px'\n }\n});\n","import React, {useCallback, useEffect, useMemo, useRef, useState} from 'react';\nimport {propEq, isEmpty, prop} from 'ramda';\nimport {\n GoogleMap,\n useJsApiLoader,\n GoogleMapProps,\n Polygon,\n DrawingManager,\n MarkerClusterer,\n LoadScriptProps,\n MarkerClustererProps\n} from '@react-google-maps/api';\nimport {MapControlContainer} from './MapControls/MapControlContainer/MapControlContrainer';\nimport {TopRightMapControls} from './MapControls/TopRightMapControls/TopRightMapControls';\nimport {TopCenterMapControls} from './MapControls/TopCenterMapControls/TopCenterMapControls';\nimport {getMapBoundsPolygon, getDrawingMode, fitMapBoundsForMarkers, fitMapBoundsForOverlay} from './helpers';\nimport EntityMarker from './EntityMarker/EntityMarker';\nimport {DEFAULT_GOOGLE_MAP_OPTIONS, DEFAULT_OVERLAY_OPTIONS, MAP_DRAWING_MODES} from '../../constants';\nimport {DrawingModes, EntityMarker as Marker, MapBounds, Overlay, OverlayPath} from './types';\nimport {useStyles} from './styles';\nimport {usePrevious} from '../../hooks';\n\nconst ON_MAP_MOVE_DEBOUNCE_INTERVAL = 1000;\n\ntype Props = {\n markers: Marker[];\n mapKey: string;\n defaultZoom: GoogleMapProps['zoom'];\n defaultCenter: GoogleMapProps['center'];\n loadingElement: JSX.Element;\n isSearchOnMapMove?: boolean;\n isSearchEnabled?: boolean;\n activeOverlay?: Overlay;\n overlayOptions?: google.maps.PolygonOptions | google.maps.CircleOptions;\n drawingModes?: DrawingModes;\n markerClusterer?: boolean;\n markerClustererOptions?: MarkerClustererProps['options'];\n mapOptions?: google.maps.MapOptions;\n mapContainerClassName: string;\n onMapBoundsChanged?: (value: MapBounds | null) => void;\n onOverlayUpdated?: (value: {data: OverlayPath; type: string}) => void;\n onMarkerClicked?: (value: Marker) => void;\n};\n\nconst libraries = ['drawing'] as LoadScriptProps['libraries'];\n\nconst useFitMapBounds = ({markers, activeOverlay, isSearchOnMapMove, map}) => {\n const prevMarkers = usePrevious(markers);\n const prevActiveOverlay = usePrevious(activeOverlay);\n const apiIsLoaded = map && window.google;\n\n useEffect(() => {\n if (apiIsLoaded && !isSearchOnMapMove && markers.length && markers !== prevMarkers) {\n fitMapBoundsForMarkers(markers, map, activeOverlay);\n } else if (apiIsLoaded && activeOverlay && activeOverlay !== prevActiveOverlay) {\n fitMapBoundsForOverlay(map, activeOverlay);\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [map, markers, activeOverlay]);\n};\n\nexport const ReltioMap = ({\n markers = [],\n mapKey,\n defaultZoom,\n defaultCenter,\n loadingElement,\n isSearchOnMapMove,\n isSearchEnabled,\n activeOverlay,\n overlayOptions,\n drawingModes = [],\n markerClusterer,\n markerClustererOptions,\n mapOptions,\n mapContainerClassName,\n onMapBoundsChanged,\n onOverlayUpdated,\n onMarkerClicked\n}: Props) => {\n const styles = useStyles();\n const {isLoaded, loadError} = useJsApiLoader({\n googleMapsApiKey: mapKey,\n libraries\n });\n\n const mapMoveEndTimer = useRef(null);\n const [map, setMap] = useState(null);\n const [polygon, setPolygon] = useState(null);\n const [drawingMode, setDrawingMode] = useState(null);\n\n useFitMapBounds({markers, activeOverlay, map, isSearchOnMapMove});\n\n const allOverlayOptions = useMemo(\n () => ({\n ...DEFAULT_OVERLAY_OPTIONS,\n ...(overlayOptions || {})\n }),\n [overlayOptions]\n );\n\n const googleMapOptions = useMemo(\n () => ({\n ...DEFAULT_GOOGLE_MAP_OPTIONS,\n ...(mapOptions || {})\n }),\n [mapOptions]\n );\n\n const handleChangeIsSearchOnMapMove = useCallback(\n (isSearchOnMapMove: boolean) => {\n onMapBoundsChanged(isSearchOnMapMove ? getMapBoundsPolygon(map) : null);\n setDrawingMode(null);\n clearTimeout(mapMoveEndTimer.current);\n },\n [map, onMapBoundsChanged]\n );\n\n const handleMapMoveStart = useCallback(() => {\n clearTimeout(mapMoveEndTimer.current);\n }, []);\n\n const handleMapMoveEnd = useCallback(() => {\n if (isSearchOnMapMove) {\n onMapBoundsChanged(getMapBoundsPolygon(map));\n }\n }, [isSearchOnMapMove, map, onMapBoundsChanged]);\n\n const handleMapIdle = useCallback(() => {\n if (isSearchOnMapMove) {\n clearTimeout(mapMoveEndTimer.current);\n mapMoveEndTimer.current = setTimeout(handleMapMoveEnd, ON_MAP_MOVE_DEBOUNCE_INTERVAL);\n }\n }, [handleMapMoveEnd, isSearchOnMapMove]);\n\n const handleOverlayChange = useCallback(\n (e, propOverlay?) => {\n const stateOverlay =\n propOverlay ||\n (polygon && {\n type: MAP_DRAWING_MODES.POLYGON,\n overlay: polygon\n });\n\n if (!isEmpty(stateOverlay) && typeof onOverlayUpdated === 'function') {\n const {overlay, type} = stateOverlay;\n\n const typeActions = {\n [MAP_DRAWING_MODES.POLYGON]: () => {\n return overlay\n .getPath()\n .getArray()\n .map((latlng) => [latlng.lat(), latlng.lng()]);\n },\n [MAP_DRAWING_MODES.CIRCLE]: () => {\n return {radius: overlay.getRadius() / 1000, center: overlay.getCenter()};\n }\n };\n\n const data = typeActions[type] && typeActions[type]();\n data && onOverlayUpdated({data, type});\n }\n },\n [onOverlayUpdated, polygon]\n );\n\n const handleOverlayComplete = useCallback(\n (type) => (overlay) => {\n handleOverlayChange(null, {type, overlay});\n overlay.setMap(null);\n setDrawingMode(null);\n },\n [handleOverlayChange]\n );\n\n const handleClearOverlay = useCallback(() => {\n onOverlayUpdated(null);\n }, [onOverlayUpdated]);\n\n const renderMarkers = (clusterer?) => {\n return markers\n .filter(prop('point'))\n .map((marker) => (\n <EntityMarker key={marker.id} marker={marker} clusterer={clusterer} onClick={onMarkerClicked} />\n ));\n };\n\n const renderMarkerClusterer = (options) => {\n return <MarkerClusterer options={options}>{renderMarkers}</MarkerClusterer>;\n };\n\n if (loadError) {\n return null;\n }\n\n if (!isLoaded) {\n return loadingElement;\n }\n\n return (\n <GoogleMap\n mapTypeId={window.google.maps.MapTypeId.ROADMAP}\n options={googleMapOptions}\n onLoad={setMap}\n zoom={defaultZoom}\n center={defaultCenter}\n onZoomChanged={handleMapMoveStart}\n onDragStart={handleMapMoveStart}\n onIdle={handleMapIdle}\n mapContainerClassName={mapContainerClassName}\n >\n {map && isSearchEnabled && Boolean(drawingModes.length) && (\n <MapControlContainer\n className={styles.mapControlContainer}\n position={window.google.maps.ControlPosition.TOP_RIGHT}\n map={map}\n >\n <TopRightMapControls\n hasActiveOverlay={!!activeOverlay}\n drawingModes={drawingModes}\n drawingMode={drawingMode}\n onDrawingModeChanged={setDrawingMode}\n onClearOverlay={handleClearOverlay}\n />\n </MapControlContainer>\n )}\n\n {map && isSearchEnabled && (\n <MapControlContainer\n className={styles.mapControlContainer}\n position={window.google.maps.ControlPosition.TOP_CENTER}\n map={map}\n >\n <TopCenterMapControls\n onChangeIsSearchOnMapMove={handleChangeIsSearchOnMapMove}\n isSearchOnMapMove={isSearchOnMapMove}\n />\n </MapControlContainer>\n )}\n\n {markerClusterer ? renderMarkerClusterer(markerClustererOptions) : renderMarkers()}\n\n {!getDrawingMode(drawingMode) &&\n activeOverlay &&\n propEq('type', MAP_DRAWING_MODES.POLYGON, activeOverlay) && (\n <Polygon\n onLoad={setPolygon}\n path={activeOverlay.path}\n editable={true}\n options={allOverlayOptions}\n onMouseUp={handleOverlayChange}\n onDragEnd={handleOverlayChange}\n />\n )}\n\n {isSearchEnabled && Boolean(drawingModes.length) && (\n <DrawingManager\n onPolygonComplete={handleOverlayComplete(MAP_DRAWING_MODES.POLYGON)}\n onCircleComplete={handleOverlayComplete(MAP_DRAWING_MODES.CIRCLE)}\n drawingMode={getDrawingMode(drawingMode)}\n options={{\n drawingControl: false,\n circleOptions: allOverlayOptions,\n polygonOptions: allOverlayOptions\n }}\n />\n )}\n </GoogleMap>\n );\n};\n","import PropTypes from 'prop-types';\nimport React from 'react';\n\nconst VerticalDivider = ({height, margin}) => (\n <div\n style={{\n width: '1px',\n height: `${height}px`,\n borderLeft: '1px solid rgba(0,0,0,0.38)',\n margin: `0 ${margin}px`,\n flexShrink: '0'\n }}\n />\n);\n\nVerticalDivider.propTypes = {\n height: PropTypes.number,\n margin: PropTypes.number\n};\n\nexport default VerticalDivider;\n","import {useEffect} from 'react';\nimport {useDispatch, useSelector} from 'react-redux';\nimport {evolve, map} from 'ramda';\nimport {entity as History, HistoryDiff, wrapInArrayIfNeeded} from '@reltio/mdm-sdk';\nimport mdmModule, {HistoryMode, profile} from '@reltio/mdm-module';\n\nexport const defaultHistoryDiff: HistoryDiff = {\n appearance: {},\n attributes: {},\n roles: [],\n tags: []\n};\n\nconst fixRefEntity = evolve({\n refEntity: wrapInArrayIfNeeded,\n refRelation: wrapInArrayIfNeeded\n});\n\nconst prepareHistorySlice = (historySlice) => {\n if (historySlice) {\n return evolve({\n attributes: map(map(fixRefEntity))\n })(historySlice);\n }\n return historySlice;\n};\n\nexport const useHistoryDiff = () => {\n const dispatch = useDispatch();\n const historySlice = useSelector(mdmModule.selectors.getHistorySlice);\n const historyDiff = useSelector(mdmModule.selectors.getHistoryDiff);\n const historyMode = useSelector(mdmModule.selectors.getHistoryMode);\n const entity = useSelector(mdmModule.selectors.getEntity);\n\n useEffect(() => {\n if (historySlice) {\n const {aEntity, bEntity} = historySlice;\n const historyManager = History.HistoryManager.createHistoryManager(History.AttributesDiff);\n const historyDiff: HistoryDiff = historyManager.computeEntityHistoryDiff(\n prepareHistorySlice(historyMode === HistoryMode.Current ? entity : bEntity),\n prepareHistorySlice(aEntity)\n );\n dispatch(profile.history.actions.setHistoryDiff(historyDiff));\n }\n }, [historySlice, historyMode, dispatch, entity]);\n\n return historyDiff || defaultHistoryDiff;\n};\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles((theme) => ({\n card: {\n borderBottom: '1px solid rgba(0,0,0,0.06)'\n },\n withBackground: {\n backgroundColor: 'rgba(0, 0, 0, 0.03)'\n },\n lineWrapper: {\n position: 'relative'\n },\n icon: {\n position: 'absolute',\n top: '8px',\n left: '16px',\n width: '32px',\n height: '32px',\n zIndex: 1\n },\n line: ({color}: {color: string}) => ({\n borderLeft: `3px solid ${color}`,\n position: 'absolute',\n left: 0,\n top: 0,\n bottom: 0\n }),\n info: {\n fontSize: '13px',\n color: theme.palette.text.secondary,\n wordWrap: 'break-word',\n lineHeight: '15px'\n },\n commentsInfo: {\n display: 'flex',\n alignItems: 'center',\n marginBottom: '-4px',\n marginTop: '7px'\n },\n commentsIcon: {\n width: '11px',\n height: '11px',\n marginLeft: '2px',\n marginRight: '6px',\n marginTop: '-2px'\n },\n infoValue: {\n color: theme.palette.text.primary\n },\n infoBlock: {\n display: 'flex',\n flexDirection: 'row',\n marginBottom: '5px'\n },\n header: {\n display: 'flex',\n flexDirection: 'row',\n paddingBottom: '12px'\n },\n flex: {\n flex: 1\n },\n caption: {\n fontSize: '16px',\n color: theme.palette.text.primary\n },\n title: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n marginBottom: '-4px'\n },\n flag: {\n height: '13px',\n width: '13px',\n marginTop: '-2px',\n stroke: '#000000',\n fill: 'none',\n margin: '2px 5px 0 5px'\n },\n date: {\n fontSize: '13px',\n color: theme.palette.text.primary\n },\n mainInfo: {\n display: 'flex',\n flexDirection: 'column',\n flex: 1\n },\n controlsBox: {\n marginRight: '16px',\n marginBottom: '12px',\n marginTop: '13px'\n },\n controlsInRow: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'space-between',\n marginBottom: '20px'\n },\n priority: {\n width: '162px'\n },\n comments: {\n marginLeft: '11px'\n }\n}));\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles({\n dueDate: {\n marginTop: 0,\n marginBottom: 0\n },\n dueDateInput: {\n height: '40px'\n },\n inputLabel: {\n fontSize: '14px'\n }\n});\n","import {useState, useCallback, useContext} from 'react';\nimport {useSelector} from 'react-redux';\nimport {updateDueDateForTask, WorkflowTaskData} from '@reltio/mdm-sdk';\nimport mdmModule from '@reltio/mdm-module';\nimport {useSafePromise} from '../../../hooks';\nimport {WorkflowTasksContext} from '../../../contexts/WorkflowTasksContext';\nimport {showWorkflowError} from '../helpers/errors';\nimport {useWorkflowCheckPermission} from './useWorkflowCheckPermission';\nimport {isOpenTask} from '../helpers';\n\nexport const useWorkflowDueDate = ({\n dueDate,\n taskId,\n isOpen\n}: Pick<WorkflowTaskData, 'dueDate' | 'taskId' | 'isOpen'>) => {\n const {updateTaskState} = useContext(WorkflowTasksContext) || {};\n const workflowPath: string = useSelector(mdmModule.selectors.getWorkflowPath);\n const environment: string = useSelector(mdmModule.selectors.getWorkflowEnvironmentUrl);\n const tenant: string = useSelector(mdmModule.selectors.getTenant);\n const safePromise = useSafePromise();\n const [updateRequestIsInProgress, setUpdateRequestIsInProgress] = useState(false);\n const checkWorkflowPermission = useWorkflowCheckPermission();\n const canUpdateTask = checkWorkflowPermission('UPDATE_TASK') && isOpenTask(isOpen);\n\n const updateDueDate = useCallback(\n (newValue: number) => {\n if (workflowPath && canUpdateTask && taskId && newValue && dueDate !== newValue) {\n setUpdateRequestIsInProgress(true);\n safePromise(\n updateDueDateForTask({\n taskId,\n workflowPath,\n environment,\n tenant,\n dueDate: newValue\n })\n )\n .then(() => {\n updateTaskState?.(taskId, {dueDate: newValue});\n })\n .catch(showWorkflowError)\n .finally(() => {\n setUpdateRequestIsInProgress(false);\n });\n }\n },\n [workflowPath, taskId, environment, tenant, updateTaskState, safePromise, dueDate, canUpdateTask]\n );\n return {updateDueDate, updateRequestIsInProgress, readOnly: !canUpdateTask};\n};\n","import React from 'react';\nimport i18n from 'ui-i18n';\nimport classnames from 'classnames';\nimport {pipe} from 'ramda';\nimport {WorkflowTaskData} from '@reltio/mdm-sdk';\n\nimport {useStyles} from './styles';\nimport {DateEditor} from '../../../editors';\nimport {useWorkflowDueDate} from '../../hooks/useWorkflowDueDate';\n\ntype Props = Pick<WorkflowTaskData, 'taskId' | 'dueDate'> & {\n isTaskOpen?: WorkflowTaskData['isOpen'];\n className?: string;\n};\nconst DueDateField = ({taskId, dueDate, isTaskOpen, className}: Props) => {\n const styles = useStyles();\n const {updateDueDate, updateRequestIsInProgress, readOnly} = useWorkflowDueDate({\n dueDate,\n taskId,\n isOpen: isTaskOpen\n });\n\n return (\n <DateEditor\n className={classnames(styles.dueDate, className)}\n disabled={updateRequestIsInProgress || readOnly}\n value={dueDate}\n label={i18n.text('Due date')}\n onChange={pipe((date) => date && date.getTime(), updateDueDate)}\n margin=\"dense\"\n InputProps={{className: styles.dueDateInput}}\n InputLabelProps={{classes: {root: styles.inputLabel}}}\n />\n );\n};\n\nexport default DueDateField;\n","import {useState, useCallback, useContext, useMemo} from 'react';\nimport {useSelector} from 'react-redux';\nimport i18n from 'ui-i18n';\nimport {updatePriorityForTask, WorkflowPriority, WorkflowTaskData} from '@reltio/mdm-sdk';\nimport mdmModule from '@reltio/mdm-module';\nimport {useSafePromise} from '../../../hooks';\nimport {WorkflowTasksContext} from '../../../contexts/WorkflowTasksContext';\nimport {showWorkflowError} from '../helpers/errors';\nimport {useWorkflowCheckPermission} from './useWorkflowCheckPermission';\nimport {isOpenTask} from '../helpers';\n\ntype PriorityOption = {label: string; value: number};\n\nexport const useWorkflowPriority = ({\n priority,\n taskId,\n isOpen\n}: Pick<WorkflowTaskData, 'taskId' | 'priority' | 'isOpen'>) => {\n const {updateTaskState} = useContext(WorkflowTasksContext) || {};\n const workflowPath: string = useSelector(mdmModule.selectors.getWorkflowPath);\n const environment: string = useSelector(mdmModule.selectors.getWorkflowEnvironmentUrl);\n const tenant: string = useSelector(mdmModule.selectors.getTenant);\n const safePromise = useSafePromise();\n const [updateRequestIsInProgress, setUpdateRequestIsInProgress] = useState(false);\n const checkWorkflowPermission = useWorkflowCheckPermission();\n const canUpdateTask = checkWorkflowPermission('UPDATE_TASK') && isOpenTask(isOpen);\n\n const updatePriority = useCallback(\n (newValue: PriorityOption) => {\n const {value: newPriority} = newValue;\n if (workflowPath && canUpdateTask && taskId && priority !== newPriority) {\n setUpdateRequestIsInProgress(true);\n safePromise(\n updatePriorityForTask({\n taskId,\n workflowPath,\n environment,\n tenant,\n priority: newPriority\n })\n )\n .then(() => {\n updateTaskState?.(taskId, {priority: newPriority});\n })\n .catch(showWorkflowError)\n .finally(() => {\n setUpdateRequestIsInProgress(false);\n });\n }\n },\n [workflowPath, taskId, environment, tenant, updateTaskState, safePromise, priority, canUpdateTask]\n );\n\n const priorities: PriorityOption[] = useMemo(\n () => [\n {\n label: i18n.text('Low'),\n value: WorkflowPriority.low\n },\n {\n label: i18n.text('Medium'),\n value: WorkflowPriority.medium\n },\n {\n label: i18n.text('High'),\n value: WorkflowPriority.high\n },\n {\n label: i18n.text('Urgent'),\n value: WorkflowPriority.urgent\n }\n ],\n []\n );\n return {priorities, updatePriority, updateRequestIsInProgress, readOnly: !canUpdateTask};\n};\n","import React from 'react';\nimport i18n from 'ui-i18n';\nimport {propEq} from 'ramda';\nimport {WorkflowTaskData} from '@reltio/mdm-sdk';\n\nimport DropDownSelector from '../../../DropDownSelector/DropDownSelector';\nimport {useWorkflowPriority} from '../../hooks/useWorkflowPriority';\n\ntype Props = Pick<WorkflowTaskData, 'taskId' | 'priority'> & {\n isTaskOpen?: WorkflowTaskData['isOpen'];\n className?: string;\n};\n\nconst PrioritySelector = ({taskId, priority, isTaskOpen, className}: Props) => {\n const {priorities, updatePriority, updateRequestIsInProgress, readOnly} = useWorkflowPriority({\n taskId,\n priority,\n isOpen: isTaskOpen\n });\n const disabled = updateRequestIsInProgress || readOnly;\n\n return (\n <DropDownSelector\n className={className}\n isDisabled={disabled}\n options={priorities}\n onChange={updatePriority}\n hideSelectedOptions={false}\n label={i18n.text('Priority')}\n value={priorities.find(propEq('value', priority))}\n TextFieldProps={{disabled}}\n height={40}\n />\n );\n};\n\nexport default PrioritySelector;\n","import {makeStyles} from '@material-ui/core/styles';\n\nconst pointColor = '#d8d8d8';\nconst lineStyle = '2px solid rgba(0,0,0,0.06)';\nconst pointSize = 6;\nconst blockWidth = 56;\nconst linePadding = 10;\nconst pointPadding = 15;\n\nexport const useStyles = makeStyles({\n decorator: {\n display: 'flex',\n alignItems: 'stretch'\n },\n lineBlock: {\n width: `${blockWidth}px`,\n flexShrink: 0\n },\n withLinePadding: {\n '& $noLine': {\n height: `${linePadding}px`\n },\n '& $line': {\n height: `calc(100% - ${linePadding}px)`\n }\n },\n noLine: {\n height: '0'\n },\n line: {\n height: '100%',\n position: 'relative',\n marginLeft: '31px',\n borderLeft: lineStyle,\n '&:before': {\n position: 'absolute',\n height: pointSize,\n width: pointSize,\n borderRadius: '50%',\n left: -pointSize + 1,\n top: `${pointPadding}px`,\n background: pointColor,\n content: '\"\"',\n display: 'block',\n border: '1px solid white'\n },\n '&$plain': {\n '&:before': {\n width: 0,\n border: 'none'\n }\n },\n '&$last': {\n height: `${pointPadding}px`\n }\n },\n content: {\n flex: 1,\n minWidth: 0\n },\n plain: {},\n last: {},\n rowDivider: {\n marginLeft: 0\n }\n});\n","import React from 'react';\nimport classnames from 'classnames';\nimport {useStyles} from './styles';\nimport {Divider as Divider} from '@material-ui/core';\n\ntype Props = {\n className?: string;\n children: React.ReactNode;\n plain?: boolean;\n first?: boolean;\n last?: boolean;\n transparent?: boolean;\n divider?: boolean;\n};\n\nconst LineDecorator = ({className, children, plain, first, last, transparent, divider}: Props) => {\n const styles = useStyles();\n return (\n <div className={classnames(className, styles.decorator)}>\n <div className={classnames(styles.lineBlock, {[styles.withLinePadding]: first})}>\n {!transparent && (\n <>\n <div className={styles.noLine} />\n <div className={classnames(styles.line, {[styles.plain]: plain}, {[styles.last]: last})} />\n </>\n )}\n </div>\n <div className={styles.content}>\n {children}\n {divider && <Divider className={styles.rowDivider} light variant=\"inset\" />}\n </div>\n </div>\n );\n};\n\nexport default LineDecorator;\n","import {WorkflowTaskData} from '@reltio/mdm-sdk';\n\nlet taskToColor = {};\nconst COLORS = [\n '#DC057B',\n '#5DC003',\n '#FEC92F',\n '#F57F27',\n '#B71137',\n '#056B97',\n '#4499AE',\n '#BD81BE',\n '#5F3577',\n '#A68560',\n '#555962'\n];\nlet colorIndex = 0;\n\nexport const resetTaskToColor = () => {\n taskToColor = {};\n colorIndex = 0;\n};\n\nexport const useWorkflowColor = ({\n processDefinitionDisplayName\n}: Pick<WorkflowTaskData, 'processDefinitionDisplayName'>) => {\n const hash = processDefinitionDisplayName;\n if (!taskToColor[hash]) {\n taskToColor[hash] = COLORS[colorIndex];\n colorIndex++;\n if (colorIndex > COLORS.length - 1) {\n colorIndex = 0;\n }\n }\n return taskToColor[hash];\n};\n","import React from 'react';\n\nconst SvgCollaborationIcon: React.FC<React.SVGProps<SVGSVGElement>> = (props) => {\n return (\n <svg\n width={20}\n height={20}\n viewBox=\"0 0 20 20\"\n xmlns=\"http://www.w3.org/2000/svg\"\n xmlnsXlink=\"http://www.w3.org/1999/xlink\"\n {...props}\n >\n <defs>\n <path\n d=\"M4 17.17L5.17 16H20V4H4v13.17zM20 2c1.1 0 2 .9 2 2v12c0 1.1-.9 2-2 2H6l-4 4V4c0-1.1.9-2 2-2h16zm-3 9H7v2h10v-2zm0-4H7v2h10V7z\"\n id=\"CollaborationIcon_svg__a\"\n />\n </defs>\n <g transform=\"translate(-2 -2)\" stroke=\"none\" strokeWidth={1} fill=\"none\" fillRule=\"evenodd\">\n <mask id=\"CollaborationIcon_svg__b\" fill=\"#fff\">\n <use xlinkHref=\"#CollaborationIcon_svg__a\" />\n </mask>\n <path fillOpacity={0.54} fill=\"#000\" mask=\"url(#CollaborationIcon_svg__b)\" d=\"M0 0h24v24H0z\" />\n </g>\n </svg>\n );\n};\n\nexport default SvgCollaborationIcon;\n","import React, {useState} from 'react';\nimport classnames from 'classnames';\nimport FlagIcon from '@material-ui/icons/Flag';\nimport i18n from 'ui-i18n';\nimport {WorkflowTaskData} from '@reltio/mdm-sdk';\nimport {Tooltip as Tooltip} from '@material-ui/core';\n\nimport {useStyles} from './styles';\n\nimport CollapseButton from '../../../CollapseButton/CollapseButton';\nimport AssigneeSelector from '../../components/AssigneeSelector/AssigneeSelector';\nimport DueDateField from '../../components/DueDateField/DueDateField';\nimport PrioritySelector from '../../components/PrioritySelector/PrioritySelector';\nimport WorkflowComments from '../../components/WorkflowComments';\nimport {getDCRId} from '../../helpers';\nimport TaskActions from '../../components/TaskActions/TaskActions';\nimport LineDecorator from '../../components/LineDecorator/LineDecorator';\nimport {useWorkflowColor} from '../../hooks/useWorkflowColor';\nimport {useWorkflowCheckPermission} from '../../hooks/useWorkflowCheckPermission';\nimport CollaborationIcon from '../../../../icons/CollaborationIcon';\n\ntype Props = {\n task: WorkflowTaskData;\n children?: React.ReactNode;\n actions?: React.ReactNode;\n Icon?: React.ElementType;\n};\n\nconst GenericWorkflowTaskCard = ({task, children, actions, Icon}: Props) => {\n const {\n taskId,\n dueDate,\n priority,\n assignee,\n createdBy,\n createTime,\n displayName: step,\n processDefinitionDisplayName,\n objectURIs,\n processInstanceComments,\n possibleActions,\n isOpen: isTaskOpen\n } = task;\n const dcrId = getDCRId(objectURIs);\n const color = useWorkflowColor({processDefinitionDisplayName});\n const styles = useStyles({color});\n const [isExpanded, setExpanded] = useState(false);\n const checkWorkflowPermission = useWorkflowCheckPermission();\n const canViewComments = checkWorkflowPermission('VIEW_PROCESS_INSTANCE_COMMENTS');\n return (\n <div className={styles.card}>\n <div className={classnames({[styles.withBackground]: isExpanded})}>\n <div className={styles.lineWrapper}>\n <div className={styles.line} />\n {Icon && <Icon className={styles.icon} />}\n <LineDecorator plain first transparent={!isExpanded}>\n <div className={styles.mainInfo}>\n <div className={styles.title}>\n <div className={classnames(styles.caption, styles.flex)}>\n {processDefinitionDisplayName}\n </div>\n <FlagIcon className={styles.flag} />\n <Tooltip title={i18n.text('Due date')}>\n <span className={styles.date}>{i18n.date(dueDate, 'L')}</span>\n </Tooltip>\n <CollapseButton\n isOpen={isExpanded}\n size=\"L\"\n onClick={() => {\n setExpanded(!isExpanded);\n }}\n />\n </div>\n <div className={styles.infoBlock}>\n <div className={styles.flex}>\n {dcrId && (\n <div className={styles.info}>\n {i18n.text('DCR ID')}\n {': '}\n <span className={styles.infoValue}>{dcrId}</span>\n </div>\n )}\n <div className={styles.info}>\n {i18n.text('Created by')}\n {': '}\n <span className={styles.infoValue}>{createdBy}</span> {i18n.text('on')}{' '}\n <span className={styles.infoValue}>{i18n.date(createTime, 'L')}</span>\n </div>\n <div className={styles.info}>\n {i18n.text('Step')}\n {': '}\n <span className={styles.infoValue}>{step}</span>\n </div>\n {canViewComments && processInstanceComments?.length > 0 && (\n <div className={styles.commentsInfo}>\n <CollaborationIcon className={styles.commentsIcon} />\n <div className={styles.infoValue}>{processInstanceComments.length}</div>\n </div>\n )}\n </div>\n {actions || (\n <TaskActions\n taskId={taskId}\n possibleActions={possibleActions}\n assignee={assignee}\n isTaskOpen={isTaskOpen}\n />\n )}\n </div>\n </div>\n </LineDecorator>\n </div>\n {isExpanded && (\n <LineDecorator plain>\n <div className={styles.controlsBox}>\n <div className={styles.controlsInRow}>\n <DueDateField taskId={taskId} dueDate={dueDate} isTaskOpen={isTaskOpen} />\n <PrioritySelector\n taskId={taskId}\n priority={priority}\n className={styles.priority}\n isTaskOpen={isTaskOpen}\n />\n </div>\n <AssigneeSelector taskId={taskId} assignee={assignee} isTaskOpen={isTaskOpen} />\n </div>\n </LineDecorator>\n )}\n </div>\n {isExpanded && (\n <>\n {children}\n {canViewComments && (\n <div className={styles.comments}>\n <WorkflowComments\n taskId={taskId}\n processInstanceComments={processInstanceComments}\n isTaskOpen={isTaskOpen}\n />\n </div>\n )}\n </>\n )}\n </div>\n );\n};\n\nexport default GenericWorkflowTaskCard;\n","import React from 'react';\n\nconst SvgDcrTaskIcon: React.FC<React.SVGProps<SVGSVGElement>> = (props) => {\n return (\n <svg width={28} height={28} viewBox=\"0 0 28 28\" xmlns=\"http://www.w3.org/2000/svg\" {...props}>\n <g stroke=\"none\" strokeWidth={1} fill=\"none\" fillRule=\"evenodd\">\n <circle fill=\"#42A5F5\" cx={14} cy={14} r={14} />\n <path\n d=\"M16.43 9.87c0 1.59 1.25 2.87 2.79 2.87 1.53 0 2.78-1.28 2.78-2.87C22 8.29 20.75 7 19.22 7c-1.54 0-2.79 1.29-2.79 2.87zm1.4 0c0-.79.62-1.43 1.39-1.43.77 0 1.39.64 1.39 1.43 0 .79-.62 1.44-1.39 1.44-.77 0-1.39-.65-1.39-1.44zm-6.26 8.26c0-1.59-1.25-2.87-2.79-2.87-1.53 0-2.78 1.28-2.78 2.87C6 19.71 7.25 21 8.78 21c1.54 0 2.79-1.29 2.79-2.87zM8.09 9.15v4.31h1.39v-2.87h2.78v2.15l2.78-2.87L12.26 7v2.15H8.09zm11.82 9.7v-4.31h-1.39v2.87h-2.78v-2.15l-2.78 2.87L15.74 21v-2.15h4.17z\"\n fill=\"#FFF\"\n opacity={0.87}\n />\n </g>\n </svg>\n );\n};\n\nexport default SvgDcrTaskIcon;\n","export enum OperationTypes {\n ADDED = 'added',\n EDITED = 'edited',\n DELETED = 'deleted',\n PINNED = 'pinned',\n IGNORED = 'ignored',\n PIN_DELETED = 'pin_deleted',\n IGNORE_DELETED = 'ignore_deleted'\n}\n\nexport enum DCRTypes {\n INSERT_ATTRIBUTE = 'INSERT_ATTRIBUTE',\n UPDATE_ATTRIBUTE = 'UPDATE_ATTRIBUTE',\n DELETE_ATTRIBUTE = 'DELETE_ATTRIBUTE',\n PIN_ATTRIBUTE = 'PIN_ATTRIBUTE',\n IGNORE_ATTRIBUTE = 'IGNORE_ATTRIBUTE',\n CREATE_ENTITY = 'CREATE_ENTITY',\n CREATE_RELATIONSHIP = 'CREATE_RELATIONSHIP',\n UPDATE_TAGS = 'UPDATE_TAGS',\n UPDATE_ROLES = 'UPDATE_ROLES',\n UPDATE_START_DATE = 'UPDATE_START_DATE',\n UPDATE_END_DATE = 'UPDATE_END_DATE',\n UPDATE_PROFILE_PIC_BY_URL = 'UPDATE_PROFILE_PIC_BY_URL',\n UPDATE_PROFILE_PIC_BY_URI = 'UPDATE_PROFILE_PIC_BY_URI',\n DELETE_RELATIONSHIP = 'DELETE_RELATIONSHIP'\n}\n","import i18n from 'ui-i18n';\nimport {allPass, always, equals, evolve, pipe, prop, when} from 'ramda';\nimport {AttributeType, DataTypes, getAttrDataTypeDefinition, isUrl} from '@reltio/mdm-sdk';\nimport {DCRTypes, OperationTypes} from '../../../constants/operations';\nimport {DCRAttributeValue, DCRObjectsInfo, EntityInfo, RelationInfo, Value} from '../../../types/dcrTypes';\n\nexport const getOperationType = (type: string, oldValue?: DCRAttributeValue) => {\n switch (type) {\n case DCRTypes.CREATE_RELATIONSHIP:\n case DCRTypes.INSERT_ATTRIBUTE:\n return OperationTypes.ADDED;\n case DCRTypes.UPDATE_TAGS:\n case DCRTypes.UPDATE_ROLES:\n case DCRTypes.UPDATE_ATTRIBUTE:\n return OperationTypes.EDITED;\n case DCRTypes.DELETE_ATTRIBUTE:\n case DCRTypes.DELETE_RELATIONSHIP:\n return OperationTypes.DELETED;\n case DCRTypes.PIN_ATTRIBUTE:\n return oldValue?.pin ? OperationTypes.PIN_DELETED : OperationTypes.PINNED;\n case DCRTypes.IGNORE_ATTRIBUTE:\n return oldValue?.ignored ? OperationTypes.IGNORE_DELETED : OperationTypes.IGNORED;\n }\n};\n\nexport const getOperationLabel = (operation: OperationTypes) => {\n const labels = {\n [OperationTypes.ADDED]: i18n.text('added'),\n [OperationTypes.EDITED]: i18n.text('edited'),\n [OperationTypes.DELETED]: i18n.text('deleted'),\n [OperationTypes.PINNED]: i18n.text('pinned'),\n [OperationTypes.PIN_DELETED]: i18n.text('pin deleted'),\n [OperationTypes.IGNORED]: i18n.text('ignored'),\n [OperationTypes.IGNORE_DELETED]: i18n.text('ignore deleted')\n };\n\n return labels[operation] || '';\n};\n\nexport const getAttributeDescription = (\n attrType: AttributeType,\n value: DCRAttributeValue,\n currentEntityUri: string,\n objectsInfo: DCRObjectsInfo = {}\n) => {\n let objectLabel: string, objectUri: string;\n\n const relation = objectsInfo[value.refObjectURI] as RelationInfo;\n if (relation) {\n objectUri = currentEntityUri === relation.startObjectUri ? relation.endObjectUri : relation.startObjectUri;\n objectLabel =\n currentEntityUri === relation.startObjectUri ? relation.endObjectLabel : relation.startObjectLabel;\n } else if (value.refEntity) {\n objectUri = value.refEntity.objectURI;\n objectLabel = (objectsInfo[objectUri] as EntityInfo).label;\n }\n\n return {\n objectUri,\n objectLabel\n };\n};\n\nexport const getDataTypeDefinition = (attributeType: AttributeType, attributeValue: Value) => {\n return when(\n allPass([pipe(prop('type'), equals(DataTypes.TYPE_STRING)), () => isUrl(attributeValue)]),\n evolve({type: always(DataTypes.TYPE_URL)})\n )(getAttrDataTypeDefinition(attributeType));\n};\n","import {complement, curry, flatten, is, isEmpty, pathOr, propOr, times} from 'ramda';\nimport {\n AttributeType,\n DataTypes,\n getAttributeTypeSubAttributes,\n getLabel,\n getRelationAttributesList,\n getRelationType,\n isEmptyValue,\n isSpecialAttribute,\n Metadata\n} from '@reltio/mdm-sdk';\nimport {DCRAttributes, DCRAttributeValue, DCRChange, EntityInfo, RelationInfo} from '../../../types/dcrTypes';\nimport {Diff} from '../types/diffTypes';\nimport {getFilteredAttrTypes} from '../../../../attributes/helpers/attributesView';\nimport {getOperationType} from './helpers';\nimport {DCRTypes} from '../../../constants/operations';\n\nconst getValues = (attributes: DCRAttributes | DCRChange, attrType: AttributeType) => {\n if ('newValue' in attributes || 'oldValue' in attributes) {\n const {newValue, oldValue, type} = attributes;\n const newAttrValues = pathOr([], ['value', attrType.name])(newValue);\n const oldAttrValues = pathOr([], ['value', attrType.name])(oldValue);\n\n const length = Math.max(newAttrValues.length, oldAttrValues.length);\n return times((index) => {\n const attributeValue = {\n newValue: newAttrValues[index],\n oldValue: oldAttrValues[index],\n type\n };\n\n return [{value: attributeValue}];\n }, length);\n }\n const values = attributes[attrType.name];\n return values ? [values] : [];\n};\n\nconst getEntityChanges = curry((metadata: Metadata, entityInfo: EntityInfo, changes: DCRAttributes) => {\n const attrTypes: AttributeType[] = getFilteredAttrTypes(metadata, entityInfo.type, [], []);\n return getAttributesList(metadata, attrTypes, changes);\n});\n\nconst getRelationChanges = curry(\n (metadata: Metadata, relationInfo: RelationInfo, changes: DCRAttributes, changeType: DCRTypes): Diff[] => {\n const addRelationOperationIfNeeded = (changes: DCRAttributes, changeType: DCRTypes) => {\n if (changeType === DCRTypes.CREATE_RELATIONSHIP || isEmptyValue(changes)) {\n const operation = getOperationType(changeType);\n return operation ? {operation} : {};\n }\n return {};\n };\n\n const relationType = getRelationType(metadata, relationInfo.type);\n const attrTypes = getRelationAttributesList(metadata, relationInfo.type);\n return flatten([\n {\n level: 1,\n label: propOr('', 'label', relationType),\n attributeType: relationType,\n attributeValue: {...relationInfo, ...changes},\n ...addRelationOperationIfNeeded(changes, changeType)\n },\n getAttributesList(metadata, attrTypes, changes, 2)\n ]);\n }\n);\n\nconst getAttributesList = (\n metadata: Metadata,\n attrTypes: AttributeType[],\n attributes: DCRAttributes | DCRChange,\n level = 0\n): Diff[] => {\n return flatten(\n attrTypes\n .map((attrType) => {\n return getValues(attributes, attrType).map((value) => {\n return value.map((attributeValue) => {\n return dcrAttributesFactory(metadata, attrType, attributeValue, level);\n });\n });\n })\n .filter(complement(isEmpty))\n );\n};\n\nconst getSimpleAttributeValue = (attributeType: AttributeType, attributeValue: DCRAttributeValue) => {\n const value = isSpecialAttribute(attributeType) ? attributeValue : attributeValue.value;\n return is(Object, value) ? value : {newValue: attributeValue, type: DCRTypes.INSERT_ATTRIBUTE};\n};\n\nconst dcrAttributesFactory = (\n metadata: Metadata,\n attributeType: AttributeType,\n attributeValue: DCRAttributeValue,\n level: number\n) => {\n switch (attributeType.type) {\n case DataTypes.TYPE_NESTED:\n case DataTypes.TYPE_IMAGE:\n return getNestedAttributeChange(metadata, attributeType, attributeValue, level);\n case DataTypes.TYPE_REFERENCE:\n return getReferenceAttributeChange(metadata, attributeType, attributeValue, level);\n default: {\n const value = getSimpleAttributeValue(attributeType, attributeValue);\n return getSimpleAttributeChange(attributeType, value as DCRChange, level);\n }\n }\n};\n\nconst getNestedAttributeChange = (\n metadata: Metadata,\n attributeType: AttributeType,\n attributeValue: DCRAttributeValue,\n level: number\n) => {\n const attributeTypeList = getAttributeTypeSubAttributes({} as Metadata, attributeType);\n const label = getLabel(attributeType?.label || attributeType?.name);\n return [\n {level, label, attributeType, attributeValue},\n getAttributesList(metadata, attributeTypeList, attributeValue.value as DCRAttributes, level + 1)\n ];\n};\n\nconst getReferenceAttributeChange = (\n metadata: Metadata,\n attributeType: AttributeType,\n attributeValue: DCRAttributeValue,\n level: number\n) => {\n const attributeTypeList = getAttributeTypeSubAttributes(metadata, attributeType);\n const label = attributeType?.label || attributeType?.name;\n\n return [\n {level, label, attributeType, attributeValue},\n getAttributesList(metadata, attributeTypeList, attributeValue.value as DCRAttributes, level + 1)\n ];\n};\n\nconst getDiffParameters = ({newValue, oldValue, type}: DCRChange) => {\n return type === DCRTypes.UPDATE_ATTRIBUTE ? {type, newValue, oldValue} : {type, newValue: oldValue || newValue};\n};\n\nconst getSimpleAttributeChange = (attributeType: AttributeType, attributeValue: DCRChange, level: number) => {\n const {newValue, oldValue, type} = getDiffParameters(attributeValue);\n const operation = getOperationType(type, oldValue as DCRAttributeValue);\n\n const label = attributeType?.label || attributeType?.name;\n\n return {\n attributeType,\n newValue,\n oldValue,\n operation,\n label,\n level\n };\n};\n\nexport {getEntityChanges, getRelationChanges};\n","import {\n concat,\n curry,\n difference,\n flatten,\n identity,\n isNil,\n omit,\n path,\n pick,\n pipe,\n propEq,\n propOr,\n reduce\n} from 'ramda';\nimport {\n Entity,\n EntityAttrTypes,\n generateTempUri,\n getRoleLabel,\n isEmptyValue,\n Metadata,\n Relation\n} from '@reltio/mdm-sdk';\nimport {DCRTypes} from '../../../constants/operations';\nimport {Diff} from '../types/diffTypes';\nimport {getEntityChanges, getRelationChanges} from './attributesHelpers';\n\nimport {\n DCRAttributes,\n DCRAttributeValue,\n DCRChange,\n DCRChanges,\n DCRObjectInfo,\n EntityInfo,\n RelationInfo\n} from '../../../types/dcrTypes';\n\nconst ATTRIBUTE_DELIMITER = '/';\nconst SPECIAL_ATTRIBUTES_NAMES = [\n 'defaultProfilePicValue',\n EntityAttrTypes.tags.name,\n EntityAttrTypes.roles.name,\n EntityAttrTypes.startDate.name,\n EntityAttrTypes.endDate.name\n];\n\nconst prepareStartOrEndDate = ({newValue, oldValue}: DCRChange): DCRChange[] => {\n const parseValue = (value) => (isNaN(value) || isEmptyValue(value) ? value : parseInt(value));\n\n const isExistedValue = (value) => value?.length && !isEmptyValue(value) && !isEmptyValue(value[0]);\n\n const isExistNewValue = isExistedValue(newValue);\n const isExistOldValue = isExistedValue(oldValue);\n if (isExistNewValue && isExistOldValue) {\n return [\n {\n type: DCRTypes.UPDATE_ATTRIBUTE,\n oldValue: {value: parseValue(oldValue[0])},\n newValue: {value: parseValue(newValue[0])}\n }\n ];\n } else if (isExistNewValue) {\n return [\n {\n type: DCRTypes.INSERT_ATTRIBUTE,\n newValue: {value: parseValue(newValue[0])}\n }\n ];\n } else if (isExistOldValue) {\n return [\n {\n type: DCRTypes.DELETE_ATTRIBUTE,\n oldValue: {value: parseValue(oldValue[0])}\n }\n ];\n }\n};\n\nconst prepareRolesOrTags = (metadata: Metadata, change: DCRChange): DCRChange[] => {\n const {newValue = [], oldValue = [], type} = change;\n const getLabel = type === DCRTypes.UPDATE_ROLES ? getRoleLabel(metadata) : identity;\n\n const diffNewValue = difference(newValue, oldValue);\n const diffOldValue = difference(oldValue, newValue);\n\n const items = [];\n\n if (diffNewValue.length) {\n items.push({\n type: DCRTypes.INSERT_ATTRIBUTE,\n newValue: {value: diffNewValue.map(getLabel).join(', ')}\n });\n }\n\n if (diffOldValue.length) {\n items.push({\n type: DCRTypes.DELETE_ATTRIBUTE,\n oldValue: {value: diffOldValue.map(getLabel).join(', ')}\n });\n }\n\n return items;\n};\n\nconst getPath = (change: DCRChange): string => {\n const {type, attributePath, refObjectURI, refAttributeType} = change;\n\n const path = type === DCRTypes.INSERT_ATTRIBUTE ? generateTempUri(attributePath) : attributePath;\n\n if (refObjectURI) {\n const typePath = refAttributeType.split('/attributes/');\n const id = refObjectURI.split(ATTRIBUTE_DELIMITER)[1];\n return [typePath[1], id, path].join(ATTRIBUTE_DELIMITER);\n }\n return path;\n};\n\nconst prepareAttribute = (container: DCRAttributes, change: DCRChange) => {\n const changePath = getPath(change);\n\n const pathArray = changePath.split(ATTRIBUTE_DELIMITER);\n\n let holder: DCRAttributes | DCRAttributeValue = container;\n\n for (let i = 0; i < pathArray.length - 1; i = i + 2) {\n const key = pathArray[i];\n const id = pathArray[i + 1];\n\n const currentValue = (holder[key] || []).find(propEq('id', id));\n\n const newValue = pathArray.length === i + 2 ? change : {};\n const value = currentValue ? currentValue : ({id, value: newValue} as DCRAttributeValue);\n\n const refObjectURI = change.refObjectURI?.indexOf(id) >= 0 && change.refObjectURI;\n if (refObjectURI) {\n value.refObjectURI = refObjectURI;\n }\n\n if (isNil(currentValue)) {\n holder[key] = (holder[key] || []).concat(value);\n }\n\n holder = value.value;\n }\n return container;\n};\n\nconst createEntityOrRelation = (metadata: Metadata, value: Entity | Relation) => {\n const {attributes = {}, startDate, endDate} = value;\n const {roles, tags, defaultProfilePicValue} = value as Entity;\n const newObject = {...attributes} as DCRAttributes;\n\n if (defaultProfilePicValue) {\n newObject['defaultProfilePicValue'] = [defaultProfilePicValue];\n }\n if (roles) {\n newObject[EntityAttrTypes.roles.name] = [\n {\n type: DCRTypes.INSERT_ATTRIBUTE,\n newValue: {value: roles.map(getRoleLabel(metadata)).join(', ')}\n }\n ];\n }\n if (tags) {\n newObject[EntityAttrTypes.tags.name] = [\n {\n type: DCRTypes.INSERT_ATTRIBUTE,\n newValue: {value: tags.join(', ')}\n }\n ];\n }\n if (startDate) {\n newObject[EntityAttrTypes.startDate.name] = [\n {\n type: DCRTypes.INSERT_ATTRIBUTE,\n newValue: {value: startDate}\n }\n ];\n }\n if (endDate) {\n newObject[EntityAttrTypes.endDate.name] = [\n {\n type: DCRTypes.INSERT_ATTRIBUTE,\n newValue: {value: endDate}\n }\n ];\n }\n return newObject;\n};\n\nconst mergeAttributesInChange = (\n metadata: Metadata,\n objectInfo: DCRObjectInfo,\n change: DCRChange,\n container: DCRAttributes = {}\n) => {\n const {type} = change;\n\n switch (type) {\n case DCRTypes.UPDATE_PROFILE_PIC_BY_URL:\n container['defaultProfilePicValue'] = [change.newValue];\n break;\n case DCRTypes.UPDATE_TAGS:\n container[EntityAttrTypes.tags.name] = prepareRolesOrTags(metadata, change);\n break;\n case DCRTypes.UPDATE_ROLES: {\n container[EntityAttrTypes.roles.name] = prepareRolesOrTags(metadata, change);\n break;\n }\n case DCRTypes.UPDATE_START_DATE:\n container[EntityAttrTypes.startDate.name] = prepareStartOrEndDate(change);\n break;\n case DCRTypes.UPDATE_END_DATE:\n container[EntityAttrTypes.endDate.name] = prepareStartOrEndDate(change);\n break;\n case DCRTypes.CREATE_RELATIONSHIP:\n case DCRTypes.CREATE_ENTITY: {\n return {\n ...container,\n ...createEntityOrRelation(metadata, change.newValue as Entity | Relation)\n };\n }\n case DCRTypes.INSERT_ATTRIBUTE:\n case DCRTypes.UPDATE_ATTRIBUTE:\n case DCRTypes.DELETE_ATTRIBUTE:\n case DCRTypes.PIN_ATTRIBUTE:\n case DCRTypes.IGNORE_ATTRIBUTE:\n prepareAttribute(container, change);\n break;\n default:\n break;\n }\n\n return container;\n};\n\nconst updateRelation = (metadata: Metadata, changes: DCRChanges, relationInfo: RelationInfo) => {\n const relationChanges: DCRChange[] = propOr([], relationInfo.uri)(changes);\n return relationChanges.reduce((result: DCRAttributes, change) => {\n return mergeAttributesInChange(metadata, relationInfo, change, result);\n }, {});\n};\n\nconst mergeChanges = (\n metadata: Metadata,\n changes: DCRChanges,\n entityInfo: EntityInfo,\n relationsInfo: RelationInfo[]\n): [Diff[], Diff[]] => {\n const getAttributeChanges = (attributeName: string) =>\n pipe(pick([attributeName]), getEntityChanges(metadata, entityInfo));\n const concatChanges = curry((getters, attributesTree) =>\n reduce((acc, getter) => concat(acc, getter(attributesTree)), [], getters)\n );\n\n const entityInfoChanges: DCRChange[] = propOr([], entityInfo.uri)(changes);\n\n const changesTree = entityInfoChanges.reduce((result: DCRAttributes, change: DCRChange) => {\n return mergeAttributesInChange(metadata, entityInfo, change, result);\n }, {});\n\n const relationsTrees = relationsInfo.map((relationInfo) => updateRelation(metadata, changes, relationInfo));\n\n const entityChanges: Diff[] = concatChanges(\n [\n pipe(omit(SPECIAL_ATTRIBUTES_NAMES), getEntityChanges(metadata, entityInfo)),\n getAttributeChanges(EntityAttrTypes.roles.name),\n getAttributeChanges(EntityAttrTypes.tags.name),\n getAttributeChanges(EntityAttrTypes.startDate.name),\n getAttributeChanges(EntityAttrTypes.endDate.name)\n ],\n changesTree\n );\n\n const relationsChanges: Diff[] = flatten(\n relationsInfo.map((relationInfo, index) => {\n const changeType: DCRTypes = path([relationInfo.uri, 0, 'type'], changes);\n return getRelationChanges(metadata, relationInfo, relationsTrees[index], changeType);\n })\n );\n\n return [entityChanges, relationsChanges];\n};\n\nexport {mergeChanges};\n","import {makeStyles} from '@material-ui/core/styles';\nimport {Theme} from '@material-ui/core';\n\nexport const useStyles = makeStyles((theme: Theme) => ({\n linkLabel: {\n color: theme.palette.primary.main,\n fontSize: '12px',\n letterSpacing: 0,\n lineHeight: '16px'\n }\n}));\n","import React from 'react';\nimport i18n from 'ui-i18n';\nimport {Link as Link} from '@material-ui/core';\n\nimport {useStyles} from './styles';\n\ntype Props = {\n onClick: () => void;\n suggestionsCount: number;\n isExpanded: boolean;\n className?: string;\n};\n\nconst ShowMoreLink = ({suggestionsCount, isExpanded, onClick, className}: Props) => {\n const styles = useStyles();\n return (\n <Link component=\"button\" variant=\"caption\" underline=\"none\" onClick={onClick} className={className}>\n <span className={styles.linkLabel}>\n {isExpanded\n ? i18n.text('View less suggestions')\n : i18n.text('View ${suggestionsCount} more suggestions', {suggestionsCount})}\n </span>\n </Link>\n );\n};\n\nexport default ShowMoreLink;\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles((theme) => ({\n field: {\n fontSize: '12px',\n lineHeight: '20px',\n color: theme.palette.text.primary,\n marginTop: '6px',\n overflow: 'hidden',\n wordBreak: 'break-word'\n },\n fieldName: {\n color: theme.palette.text.secondary,\n marginRight: '8px'\n },\n difference: {\n marginRight: '8px'\n },\n arrow: {\n margin: '0 4px',\n fontSize: '12px',\n color: theme.palette.text.primary\n },\n chip: {\n height: '20px',\n fontSize: '10px',\n fontWeight: 500,\n lineHeight: '16px',\n letterSpacing: 0,\n flexShrink: 0,\n textTransform: 'capitalize',\n color: theme.palette.primary.main,\n borderColor: theme.palette.primary.main,\n '&.edited': {\n color: '#CC7500',\n borderColor: '#CC7500'\n },\n '&.added': {\n color: '#599E0E',\n borderColor: '#599E0E'\n },\n '&.deleted': {\n color: '#CF0E26',\n borderColor: '#CF0E26'\n }\n }\n}));\n","import React from 'react';\nimport classnames from 'classnames';\nimport {isNil} from 'ramda';\nimport ArrowRightAltIcon from '@material-ui/icons/ArrowRightAlt';\nimport {Chip as Chip} from '@material-ui/core';\nimport {OperationTypes} from '../../../../constants/operations';\nimport {getOperationLabel} from '../../helpers/helpers';\n\nimport {useStyles} from './styles';\n\ntype Props = {\n label: React.ReactNode;\n oldValue?: React.ReactNode;\n newValue?: React.ReactNode;\n operation?: OperationTypes;\n className?: string;\n};\n\nconst ChangeView = ({label, oldValue, newValue, operation, className}: Props) => {\n const styles = useStyles();\n const value = oldValue || newValue;\n\n return (\n <div className={classnames(styles.field, className)}>\n <span className={styles.fieldName}>{label}:</span>\n {!isNil(value) && (\n <span className={styles.difference}>\n {value}\n {newValue && oldValue && (\n <>\n <ArrowRightAltIcon className={styles.arrow} />\n {newValue}\n </>\n )}\n </span>\n )}\n {operation && (\n <Chip\n variant=\"outlined\"\n label={getOperationLabel(operation)}\n className={classnames(styles.chip, operation)}\n />\n )}\n </div>\n );\n};\n\nexport default ChangeView;\n","import React from 'react';\nimport {DCRObjectsInfo} from '../../../types/dcrTypes';\n\nexport const AttributesChangesContext = React.createContext<DCRObjectsInfo>(null);\n\nAttributesChangesContext.displayName = 'AttributesChangesContext';\n","import {makeStyles} from '@material-ui/core/styles';\n\ntype StylesProps = {\n level: number;\n};\n\nexport const useStyles = makeStyles((theme) => ({\n linkContainer: {\n textDecoration: 'none',\n cursor: 'pointer',\n marginLeft: '4px'\n },\n linkLabel: {\n color: theme.palette.primary.main,\n fontSize: '12px',\n letterSpacing: 0,\n lineHeight: '16px'\n },\n disabledLink: {\n pointerEvents: 'none',\n cursor: 'default'\n },\n label: {\n color: theme.palette.text.primary\n },\n change: ({level = 0}: StylesProps) => ({\n marginLeft: `${level * 16}px`\n })\n}));\n","import React, {useCallback, useContext, useMemo} from 'react';\nimport {useSelector} from 'react-redux';\nimport {anyPass, ifElse, isNil, hasPath, path, when} from 'ramda';\nimport classnames from 'classnames';\nimport {getAttributeValue, getLabel, isReference} from '@reltio/mdm-sdk';\nimport mdmModule from '@reltio/mdm-module';\nimport ChangeView from '../ChangeView/ChangeView';\nimport {AttributesChangesContext} from '../../contexts/AttributesChangesContext';\nimport {getAttributeDescription, getDataTypeDefinition} from '../../helpers/helpers';\nimport {Diff, RelationAttributeValue} from '../../types/diffTypes';\nimport {ChangeValue, DCRAttributeValue, Value} from '../../../../types/dcrTypes';\nimport DataTypeValue from '../../../../../DataTypeValue/DataTypeValue';\nimport EntityUriLink from '../../../../../EntityUriLink/EntityUriLink';\n\nimport {useStyles} from './styles';\n\nconst DiffRenderer = ({label, level, attributeType, attributeValue, oldValue, newValue, operation}: Diff) => {\n const styles = useStyles({level});\n const entityUri = useSelector(mdmModule.selectors.getEntityUri);\n const objectsInfo = useContext(AttributesChangesContext);\n\n const getLinkDescription = useCallback(() => {\n if (isReference(attributeType)) {\n const value: DCRAttributeValue = when(\n anyPass([hasPath(['value', 'newValue']), hasPath(['value', 'oldValue'])]),\n ifElse(hasPath(['value', 'newValue']), path(['value', 'newValue']), path(['value', 'oldValue']))\n )(attributeValue);\n return getAttributeDescription(attributeType, value, entityUri, objectsInfo);\n } else if ('endObject' in attributeType) {\n const {endObjectUri, endObjectLabel} = attributeValue as RelationAttributeValue;\n return {\n objectUri: endObjectUri,\n objectLabel: endObjectLabel\n };\n }\n }, [attributeType, attributeValue, entityUri, objectsInfo]);\n\n const renderLink = useCallback(() => {\n const {objectUri, objectLabel} = getLinkDescription() || {};\n\n if (!isNil(objectUri) && !isNil(objectLabel)) {\n const isNotExist = objectsInfo[objectUri]?.isExist === false;\n return (\n <EntityUriLink\n value={objectUri}\n className={classnames(styles.linkContainer, {[styles.disabledLink]: isNotExist})}\n >\n <span className={classnames(styles.linkLabel, {[styles.label]: isNotExist})}>\n {getLabel(objectLabel)}\n </span>\n </EntityUriLink>\n );\n }\n return null;\n }, [getLinkDescription, objectsInfo, styles]);\n\n const changeLabel = useMemo(() => {\n return (\n <span>\n {label}\n {renderLink()}\n </span>\n );\n }, [label, renderLink]);\n\n const renderValue = useCallback(\n (value: ChangeValue) => {\n const attrValue: Value = getAttributeValue(value);\n return (\n <DataTypeValue value={attrValue} dataTypeDefinition={getDataTypeDefinition(attributeType, attrValue)} />\n );\n },\n [attributeType]\n );\n\n return (\n <ChangeView\n className={styles.change}\n label={changeLabel}\n oldValue={oldValue && renderValue(oldValue)}\n newValue={newValue && renderValue(newValue)}\n operation={operation}\n />\n );\n};\n\nexport default DiffRenderer;\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles({\n title: {\n fontSize: '12px',\n letterSpacing: 0,\n lineHeight: '16px',\n fontWeight: 500,\n marginTop: '8px'\n }\n});\n","import React from 'react';\nimport {has} from 'ramda';\nimport DiffRenderer from '../DiffRenderer/DiffRenderer';\nimport {Diff, Title} from '../../types/diffTypes';\n\nimport {useStyles} from './styles';\n\ntype Props = {\n changes: (Diff | Title)[];\n};\n\nconst DCRChangesList = ({changes}: Props) => {\n const styles = useStyles();\n return (\n <>\n {changes.map((change, index) => {\n return has('level', change) ? (\n <DiffRenderer {...(change as Diff)} key={index} />\n ) : (\n <div className={styles.title} key={index}>\n {change.label}\n </div>\n );\n })}\n </>\n );\n};\n\nexport default DCRChangesList;\n","import {has, filter, length, pipe} from 'ramda';\n\nexport const getSuggestionsCount = pipe(filter(has('operation')), length);\n","import {makeStyles} from '@material-ui/core/styles';\nimport {Theme} from '@material-ui/core';\n\nexport const useStyles = makeStyles((theme: Theme) => ({\n container: {\n boxSizing: 'border-box',\n border: '1px solid rgba(0,0,0,0.03)',\n borderRadius: '3px',\n backgroundColor: 'rgba(0,0,0,0.03)',\n padding: '10px',\n margin: '12px 16px 12px 0'\n },\n uri: {\n color: theme.palette.primary.main,\n textDecoration: 'none',\n cursor: 'pointer'\n },\n label: {\n fontSize: '12px',\n letterSpacing: 0,\n lineHeight: '16px'\n },\n showMoreLink: {\n marginTop: '8px'\n }\n}));\n","import React, {useMemo} from 'react';\nimport {useSelector} from 'react-redux';\nimport i18n from 'ui-i18n';\nimport {flatten} from 'ramda';\nimport mdmModule from '@reltio/mdm-module';\nimport {getEntityUriForLink, getLabel, Metadata} from '@reltio/mdm-sdk';\nimport {DCRChanges, DCRObjectsInfo, EntityInfo, RelationInfo} from '../../types/dcrTypes';\nimport {Diff, Title} from './types/diffTypes';\nimport {mergeChanges} from './helpers/mergeHelpers';\nimport ShowMoreLink from './components/ShowMoreLink/ShowMoreLink';\nimport DCRChangesList from './components/DCRChangesList/DCRChangesList';\nimport {AttributesChangesContext} from './contexts/AttributesChangesContext';\nimport {useCollapsibleList} from './hooks/useCollapsibleList';\nimport EntityUriLink from '../../../EntityUriLink/EntityUriLink';\n\nimport {useStyles} from './styles';\n\ntype Props = {\n changes: DCRChanges;\n objectsInfo: DCRObjectsInfo;\n entityInfo: EntityInfo;\n relationsInfo?: RelationInfo[];\n max?: number;\n};\n\nconst AttributesChanges = ({changes, objectsInfo, entityInfo, relationsInfo, max}: Props) => {\n const styles = useStyles();\n const metadata: Metadata = useSelector(mdmModule.selectors.getMetadata);\n\n const [mergedEntityChanges, mergedRelationsChanges] = useMemo(\n () => mergeChanges(metadata, changes, entityInfo, relationsInfo),\n [metadata, changes, entityInfo, relationsInfo]\n );\n\n const changesList: (Diff | Title)[] = useMemo(() => {\n const relationshipTitle: Title = {label: i18n.text('Relationships')};\n return mergedRelationsChanges.length > 0\n ? flatten([mergedEntityChanges, relationshipTitle, mergedRelationsChanges])\n : mergedEntityChanges;\n }, [mergedEntityChanges, mergedRelationsChanges]);\n\n const {isExpanded, onToggle, itemsToShow, collapsedSuggestionsCount} = useCollapsibleList(changesList, max);\n\n return (\n <AttributesChangesContext.Provider value={objectsInfo}>\n <div className={styles.container}>\n <EntityUriLink className={styles.uri} value={getEntityUriForLink(entityInfo)}>\n <div className={styles.label}>{getLabel(entityInfo.label)}</div>\n </EntityUriLink>\n <DCRChangesList changes={itemsToShow} />\n {collapsedSuggestionsCount > 0 && (\n <ShowMoreLink\n onClick={onToggle}\n suggestionsCount={collapsedSuggestionsCount}\n isExpanded={isExpanded}\n className={styles.showMoreLink}\n />\n )}\n </div>\n </AttributesChangesContext.Provider>\n );\n};\n\nexport default AttributesChanges;\n","import {useCallback, useMemo, useState} from 'react';\nimport {getSuggestionsCount} from '../helpers/contextHelpers';\nimport {Diff, Title} from '../types/diffTypes';\n\nconst DEFAULT_VISIBLE_ITEMS_COUNT = 3;\n\nexport const useCollapsibleList = (items: (Diff | Title)[], limit = DEFAULT_VISIBLE_ITEMS_COUNT) => {\n const [isExpanded, setIsExpanded] = useState(false);\n const onToggle = useCallback(() => setIsExpanded((value) => !value), []);\n\n const collapsedItems = useMemo(() => items.slice(0, limit), [items, limit]);\n const suggestionsCount = useMemo(() => getSuggestionsCount(items), [items]);\n const visibleSuggestionsCount = useMemo(() => getSuggestionsCount(collapsedItems), [collapsedItems]);\n\n const itemsToShow = isExpanded ? items : collapsedItems;\n const collapsedSuggestionsCount = suggestionsCount - visibleSuggestionsCount;\n\n return {isExpanded, onToggle, itemsToShow, collapsedSuggestionsCount};\n};\n","import {isEntityUri, isRelationUri} from '@reltio/mdm-sdk';\nimport {allPass, concat, curry, equals, filter, keys, map, pathOr, pipe, prop, uniq} from 'ramda';\nimport {\n GroupedObjectsInfo,\n DCRChanges,\n DCRObjectInfo,\n DCRObjectsInfo,\n EntityInfo,\n RelationInfo\n} from '../types/dcrTypes';\n\nexport const getEntitiesObjects = filter(pipe(prop('uri'), isEntityUri));\nexport const getRelationsObjects = filter(pipe(prop('uri'), isRelationUri));\n\nconst getRelations = (objectsWithChanges: DCRObjectInfo, entityUri: string) => {\n return filter(allPass([pipe(prop('uri'), isRelationUri), pipe(prop('startObjectUri'), equals(entityUri))]))(\n objectsWithChanges\n );\n};\n\nexport const extractObjectsFromChangeRequest = (changes: DCRChanges, objectsInfo: DCRObjectsInfo): DCRObjectInfo[] => {\n const getChange = (key) => prop([key], changes);\n return pipe(\n keys,\n filter(getChange),\n map((key) => ({...objectsInfo[key], uri: key}))\n )(objectsInfo);\n};\n\nexport const createEntityRelationsObjectByEntity = curry((objectsWithChanges: DCRObjectInfo, entity: EntityInfo) => {\n return {\n entity,\n relations: getRelations(objectsWithChanges, entity.uri)\n };\n});\n\nexport const createEntityRelationsObjectByRelation = curry((objectsInfo: DCRObjectInfo, relation: RelationInfo) => {\n const entity = objectsInfo[relation.startObjectUri];\n const relations = [relation];\n\n return entity ? {entity: {...entity, uri: relation.startObjectUri}, relations} : {relations};\n});\n\nexport const concatEntityRelationsObjects = (acc: Record<string, GroupedObjectsInfo>, object: GroupedObjectsInfo) => {\n const {entity, relations} = object;\n const {uri: entityUri} = entity;\n\n const mergedRelations = pipe(pathOr([], [entityUri, 'relations']), concat(relations), uniq)(acc);\n\n acc[entityUri] = {\n entity,\n relations: mergedRelations\n };\n\n return acc;\n};\n","import {useCallback, useEffect, useState} from 'react';\nimport {flatten, has, isEmpty, map, partition, path, pipe, reduce, values} from 'ramda';\nimport {getDataChangeRequest, getEntitiesByUris} from '@reltio/mdm-sdk';\nimport {useSafePromise} from '../../../hooks';\nimport {\n concatEntityRelationsObjects,\n createEntityRelationsObjectByEntity,\n createEntityRelationsObjectByRelation,\n extractObjectsFromChangeRequest,\n getEntitiesObjects,\n getRelationsObjects\n} from '../helpers/dcrHelpers';\nimport {GroupedObjectsInfo, ChangeRequest} from '../types/dcrTypes';\nimport {showWorkflowError} from '../helpers/errors';\n\nexport const useChangeRequest = (dcrUri: string) => {\n const [groupedObjects, setGroupedObjects] = useState<GroupedObjectsInfo[]>([]);\n const [dcr, setDcr] = useState<ChangeRequest>(null);\n const safePromise = useSafePromise();\n\n const requestEntities = useCallback((entityUris: string[]) => {\n if (isEmpty(entityUris)) {\n return Promise.resolve([]);\n }\n\n return safePromise(getEntitiesByUris(entityUris, {searchOptions: 'ovOnly', defaultMaxValues: 1}));\n }, []); // eslint-disable-line\n\n useEffect(() => {\n getDataChangeRequest(dcrUri)\n .then((dcr: ChangeRequest) => {\n const {changes, objectsInfo} = dcr;\n\n const objectsWithChanges = extractObjectsFromChangeRequest(changes, objectsInfo);\n\n const entityObjectsWithRelations: GroupedObjectsInfo[] = pipe(\n getEntitiesObjects,\n map(createEntityRelationsObjectByEntity(objectsWithChanges))\n )(objectsWithChanges);\n\n const relationsObjects: GroupedObjectsInfo[] = pipe(\n getRelationsObjects,\n map(createEntityRelationsObjectByRelation(objectsInfo))\n )(objectsWithChanges);\n\n const [relationsObjectsWithEntity, relationsObjectsWithoutEntity] = partition(\n has('entity'),\n relationsObjects\n );\n\n const entityUris: string[] = relationsObjectsWithoutEntity.map(\n path(['relations', 0, 'startObjectUri'])\n );\n\n requestEntities(entityUris)\n .then((entities) => {\n const relationsObjectsWithRequestedEntities = relationsObjectsWithoutEntity.map(\n (relationsObject, index) => {\n return {\n ...relationsObject,\n entity: entities[index]\n };\n }\n );\n\n pipe(\n flatten,\n reduce(concatEntityRelationsObjects, {}),\n values,\n setGroupedObjects\n )([\n entityObjectsWithRelations,\n relationsObjectsWithEntity,\n relationsObjectsWithRequestedEntities\n ]);\n })\n .catch(showWorkflowError);\n\n setDcr(dcr);\n })\n .catch(showWorkflowError);\n }, [dcrUri, requestEntities]);\n\n return {dcr, groupedObjects};\n};\n","import React from 'react';\nimport {WorkflowTaskData} from '@reltio/mdm-sdk';\nimport GenericWorkflowTaskCard from '../GenericWorkflowTaskCard/GenericWorkflowTaskCard';\nimport LineDecorator from '../../components/LineDecorator/LineDecorator';\nimport {getDCRUri} from '../../helpers';\nimport DcrTaskIcon from '../../../../icons/DcrTaskIcon';\nimport AttributesChanges from '../../components/AttributesChanges/AttributesChanges';\nimport {useChangeRequest} from '../../hooks/useChangeRequest';\n\ntype Props = {\n task: WorkflowTaskData;\n};\n\nconst DataChangeRequestTaskCard = ({task}: Props) => {\n const {objectURIs} = task;\n const dcrUri = getDCRUri(objectURIs);\n\n const {dcr, groupedObjects} = useChangeRequest(dcrUri);\n\n return (\n <GenericWorkflowTaskCard task={task} Icon={DcrTaskIcon}>\n {dcr &&\n groupedObjects.map((object, index: number) => (\n <LineDecorator key={index} last={index === groupedObjects.length - 1} divider={true}>\n <AttributesChanges\n entityInfo={object.entity}\n relationsInfo={object.relations}\n changes={dcr.changes}\n objectsInfo={dcr.objectsInfo}\n />\n </LineDecorator>\n ))}\n </GenericWorkflowTaskCard>\n );\n};\n\nexport default DataChangeRequestTaskCard;\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles({\n pmCard: {\n marginLeft: '-15px'\n }\n});\n","import React from 'react';\n\nconst SvgPmTaskIcon: React.FC<React.SVGProps<SVGSVGElement>> = (props) => {\n return (\n <svg width={28} height={28} viewBox=\"0 0 28 28\" xmlns=\"http://www.w3.org/2000/svg\" {...props}>\n <g stroke=\"none\" strokeWidth={1} fill=\"none\" fillRule=\"evenodd\">\n <circle fill=\"#1976D2\" cx={14} cy={14} r={14} />\n <path\n d=\"M22.5 14L18 9.5V13h-3.5L9 7.5 7.5 9l6.04 6H18v3.5l4.5-4.5zm-11.46 1.46L7.5 19 9 20.5l3.54-3.54-1.5-1.5z\"\n fill=\"#FFF\"\n opacity={0.87}\n />\n </g>\n </svg>\n );\n};\n\nexport default SvgPmTaskIcon;\n","import React from 'react';\nimport {useSelector} from 'react-redux';\nimport {WorkflowTaskData} from '@reltio/mdm-sdk';\nimport mdmModule from '@reltio/mdm-module';\n\nimport {useStyles} from './styles';\n\nimport GenericWorkflowTaskCard from '../GenericWorkflowTaskCard/GenericWorkflowTaskCard';\nimport LineDecorator from '../../components/LineDecorator/LineDecorator';\nimport PmTaskIcon from '../../../../icons/PmTaskIcon';\nimport {useMatchesLoader} from '../../../../hooks/useMatchesLoader';\nimport {ProfileMatchCard} from '../../../ProfileMatchCard/ProfileMatchCard';\n\ntype Props = {\n task: WorkflowTaskData;\n};\n\nconst defaultOptions = {\n showTransitiveMatches: true,\n showInactiveEntities: false\n};\n\nconst PotentialMatchTaskCard = ({task}: Props) => {\n const styles = useStyles();\n const {objectURIs} = task;\n const entity = useSelector(mdmModule.selectors.getEntity);\n const metadata = useSelector(mdmModule.selectors.getMetadata);\n const {matches, entitiesMap} = useMatchesLoader({\n enabled: !!entity.uri,\n entity,\n filter: '',\n rowsPerPage: Number.MAX_SAFE_INTEGER,\n page: 0,\n options: defaultOptions\n });\n const match = matches?.find(({object}) => objectURIs.includes(object.uri));\n\n return (\n <GenericWorkflowTaskCard task={task} Icon={PmTaskIcon}>\n {match && (\n <LineDecorator last>\n <div className={styles.pmCard}>\n <ProfileMatchCard metadata={metadata} entity={entity} match={match} entitiesMap={entitiesMap} />\n </div>\n </LineDecorator>\n )}\n </GenericWorkflowTaskCard>\n );\n};\n\nexport default PotentialMatchTaskCard;\n","import React from 'react';\n\nconst SvgDefaultTaskIcon: React.FC<React.SVGProps<SVGSVGElement>> = (props) => {\n return (\n <svg width={28} height={28} viewBox=\"0 0 28 28\" xmlns=\"http://www.w3.org/2000/svg\" {...props}>\n <g stroke=\"none\" strokeWidth={1} fill=\"none\" fillRule=\"evenodd\">\n <circle fill=\"#205191\" cx={14} cy={14} r={14} />\n <path\n d=\"M9.667 20.622c-.92 0-1.667-.744-1.667-1.662V8.99c0-.916.747-1.66 1.667-1.66h2.446A1.993 1.993 0 0114 6l.162.006a1.992 1.992 0 011.725 1.323h2.446c.92 0 1.667.745 1.667 1.662v9.97c0 .917-.747 1.661-1.667 1.661zm9-1.33V8.66h-1.334v1.993h-6.666V8.66H9.333v10.634h9.334zM15.86 14.46v1.302h-5.206V14.46h5.206zm1.494-2v1.302h-6.7V12.46h6.7zM14 7.33c.367 0 .667.298.667.664a.668.668 0 01-1.334 0c0-.366.3-.665.667-.665z\"\n fill=\"#FFF\"\n opacity={0.87}\n />\n </g>\n </svg>\n );\n};\n\nexport default SvgDefaultTaskIcon;\n","import React from 'react';\n\nconst SvgDeleteRequestTaskIcon: React.FC<React.SVGProps<SVGSVGElement>> = (props) => {\n return (\n <svg width={28} height={28} viewBox=\"0 0 28 28\" xmlns=\"http://www.w3.org/2000/svg\" {...props}>\n <g stroke=\"none\" strokeWidth={1} fill=\"none\" fillRule=\"evenodd\" opacity={0.87}>\n <circle fill=\"#0D47A1\" cx={14} cy={14} r={14} />\n <path\n d=\"M8.17 9.824v8.995c0 .886.72 1.606 1.607 1.606h8.352c.192 0 .375-.035.546-.097l1.38 1.382.804-.804-1.32-1.32-1.09-1.089-8.993-8.994-1.092-1.092-1.317-1.317-.803.803L8.17 9.824zm9.316 9.316h-8.03v-8.03l8.03 8.03zM9.777 7.575c-.192 0-.376.033-.55.094L10.42 8.86h.32v.322l1.607 1.606h4.819V8.86h1.284v8.03l1.285 1.286V9.182c0-.887-.72-1.607-1.606-1.607h-2.358a1.931 1.931 0 00-1.818-1.285 1.93 1.93 0 00-1.818 1.285H9.777zm3.533.643c0-.353.29-.643.643-.643.353 0 .642.29.642.643a.644.644 0 01-.642.642.644.644 0 01-.643-.642z\"\n fill=\"#FFF\"\n />\n </g>\n </svg>\n );\n};\n\nexport default SvgDeleteRequestTaskIcon;\n","import React from 'react';\nimport {PredefinedWorkflowProcessType, WorkflowTaskData} from '@reltio/mdm-sdk';\nimport GenericWorkflowTaskCard from './GenericWorkflowTaskCard/GenericWorkflowTaskCard';\nimport DataChangeRequestTaskCard from './DataChangeRequestTaskCard/DataChangeRequestTaskCard';\nimport PotentialMatchTaskCard from './PotentialMatchTaskCard/PotentialMatchTaskCard';\n\nimport DefaultTaskIcon from '../../../icons/DefaultTaskIcon';\nimport DeleteRequestTaskIcon from '../../../icons/DeleteRequestTaskIcon';\n\nexport type FactoryProps = {\n task: WorkflowTaskData;\n};\n\nclass WorkflowTaskCardsFactory {\n static build = ({task}: FactoryProps) => {\n const {processType} = task;\n switch (processType) {\n case PredefinedWorkflowProcessType.dataChangeRequestReview:\n return <DataChangeRequestTaskCard task={task} />;\n case PredefinedWorkflowProcessType.potentialMatchReview:\n return <PotentialMatchTaskCard task={task} />;\n case PredefinedWorkflowProcessType.recommendForDelete:\n return <GenericWorkflowTaskCard task={task} Icon={DeleteRequestTaskIcon} />;\n default:\n return <GenericWorkflowTaskCard task={task} Icon={DefaultTaskIcon} />;\n }\n };\n}\n\nexport default WorkflowTaskCardsFactory;\n","import WorkflowTaskCardsFactory, {FactoryProps} from './WorkflowTaskCardsFactory';\n\nexport const WorkflowTaskCard = ({task}: FactoryProps) => WorkflowTaskCardsFactory.build({task});\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles((theme) => ({\n popoverPaper: {\n width: '464px'\n },\n title: {\n fontSize: '20px',\n fontWeight: 500,\n letterSpacing: '0.25px',\n lineHeight: '24px',\n color: theme.palette.text.primary,\n marginBottom: '17px'\n },\n content: {\n display: 'flex',\n flexDirection: 'column',\n padding: '23px 24px 14px 24px'\n },\n simpleDropDownSelector: {\n marginBottom: '20px'\n },\n inputRoot: {\n paddingTop: '0 !important',\n paddingBottom: '0 !important'\n },\n select: {\n fontSize: '14px'\n },\n footer: {\n display: 'flex',\n justifyContent: 'flex-end',\n padding: '5px 8px 8px',\n borderTop: '1px solid rgba(0,0,0,0.12)'\n },\n cancelButton: {\n marginRight: '8px'\n },\n input: {\n fontSize: '14px'\n }\n}));\n","import React, {useState} from 'react';\nimport i18n from 'ui-i18n';\nimport {TextField as TextField} from '@material-ui/core';\nimport {Portal as Portal} from '@material-ui/core';\nimport {Snackbar as Snackbar} from '@material-ui/core';\nimport {Popover as Popover} from '@material-ui/core';\nimport {Typography as Typography} from '@material-ui/core';\nimport {Button as Button} from '@material-ui/core';\nimport SimpleDropDownSelector from '../../../SimpleDropDownSelector/SimpleDropDownSelector';\nimport {useWorkflowDefinitions} from '../../hooks/useWorkflowDefinitions';\nimport {useWorkflowProcessInstance} from '../../hooks/useWorkflowProcessInstance';\nimport {useStyles} from './styles';\n\ntype Props = {\n anchorEl: Element;\n onClose: () => void;\n};\n\nexport const AddWorkflowDialog = ({anchorEl, onClose}: Props) => {\n const styles = useStyles();\n\n const [comment, setComment] = useState('');\n const [taskType, setTaskType] = useState(null);\n const [isOpenSnackbar, setIsOpenSnackbar] = useState(false);\n\n const {definitions} = useWorkflowDefinitions();\n const {processInstance, loading} = useWorkflowProcessInstance();\n\n const handleChangeComment = (e) => {\n setComment(e.target.value);\n };\n\n const handleChangeTaskType = (value) => {\n setTaskType(value);\n };\n\n const handleStart = () => {\n processInstance(comment, taskType?.value)\n .then(() => {\n setIsOpenSnackbar(true);\n setComment('');\n setTaskType(null);\n onClose();\n })\n .catch(() => {});\n };\n\n const handleCloseSnackbar = () => {\n setIsOpenSnackbar(false);\n };\n\n const open = Boolean(anchorEl);\n\n return (\n <>\n <Popover\n open={open}\n anchorEl={anchorEl}\n onClose={onClose}\n anchorOrigin={{\n vertical: 'bottom',\n horizontal: 'right'\n }}\n transformOrigin={{\n vertical: 'top',\n horizontal: 'right'\n }}\n classes={{\n paper: styles.popoverPaper\n }}\n >\n <div className={styles.content}>\n <Typography className={styles.title}>{i18n.text('Add new workflow')}</Typography>\n <SimpleDropDownSelector\n className={styles.simpleDropDownSelector}\n variant=\"filled\"\n height={40}\n TextFieldProps={{\n InputProps: {\n disableUnderline: true\n }\n }}\n placeholder={i18n.text('Select task type')}\n value={taskType}\n onChange={handleChangeTaskType}\n label={''}\n options={definitions.map((definition) => {\n return {\n value: definition.type,\n label: definition.displayName\n };\n })}\n />\n <TextField\n variant=\"filled\"\n hiddenLabel\n size=\"small\"\n placeholder=\"Type a comment\"\n InputProps={{\n disableUnderline: true,\n classes: {\n input: styles.input,\n root: styles.inputRoot\n }\n }}\n value={comment}\n onChange={handleChangeComment}\n multiline={true}\n />\n </div>\n <div className={styles.footer}>\n <Button disabled={loading} className={styles.cancelButton} onClick={onClose}>\n {i18n.text('Cancel')}\n </Button>\n <Button disabled={loading} color=\"primary\" onClick={handleStart}>\n {i18n.text('Start')}\n </Button>\n </div>\n </Popover>\n <Portal container={document.body}>\n <Snackbar\n open={isOpenSnackbar}\n autoHideDuration={5000}\n onClose={handleCloseSnackbar}\n message={i18n.text('A new workflow has started')}\n />\n </Portal>\n </>\n );\n};\n","import {useEffect, useState} from 'react';\nimport mdmModule from '@reltio/mdm-module';\nimport {Entity, processDefinitions} from '@reltio/mdm-sdk';\nimport {useSelector} from 'react-redux';\n\nconst filterDefinitions = (definitions, entityType) => {\n return definitions.filter(({manualStart, objectTypes}) => {\n return manualStart && (!objectTypes || objectTypes?.some((_entityType) => _entityType === entityType));\n });\n};\n\nexport const useWorkflowDefinitions = () => {\n const [definitions, setDefinitions] = useState([]);\n\n const workflowPath: string = useSelector(mdmModule.selectors.getWorkflowPath);\n const environment: string = useSelector(mdmModule.selectors.getWorkflowEnvironmentUrl);\n const tenant: string = useSelector(mdmModule.selectors.getTenant);\n const entity: Entity = useSelector(mdmModule.selectors.getEntity);\n const entityType = entity.type;\n\n useEffect(() => {\n processDefinitions({workflowPath, environment, tenant}).then(({data}) =>\n setDefinitions(filterDefinitions(data, entityType))\n );\n }, [entityType, workflowPath, environment, tenant]);\n\n return {definitions};\n};\n","import {useCallback, useContext, useState} from 'react';\nimport {useSelector} from 'react-redux';\nimport mdmModule from '@reltio/mdm-module';\nimport {Entity, startProcessInstance} from '@reltio/mdm-sdk';\nimport {WorkflowTasksContext} from '../../../contexts/WorkflowTasksContext';\nimport {showWorkflowError} from '../helpers/errors';\n\nexport const useWorkflowProcessInstance = () => {\n const {loadTasks} = useContext(WorkflowTasksContext);\n const workflowPath: string = useSelector(mdmModule.selectors.getWorkflowPath);\n const environment: string = useSelector(mdmModule.selectors.getWorkflowEnvironmentUrl);\n const tenant: string = useSelector(mdmModule.selectors.getTenant);\n const entity: Entity = useSelector(mdmModule.selectors.getEntity);\n const entityUri = entity.uri;\n const [loading, setLoading] = useState(false);\n\n const processInstance = useCallback(\n (comment, taskType) => {\n setLoading(true);\n\n return startProcessInstance({\n workflowPath,\n tenant,\n environment,\n processType: taskType,\n comment,\n objectURIs: [entityUri]\n })\n .then(() => {\n loadTasks();\n })\n .catch((error) => {\n showWorkflowError(error);\n throw error;\n })\n .finally(() => {\n setLoading(false);\n });\n },\n [entityUri, environment, loadTasks, tenant, workflowPath]\n );\n\n return {processInstance, loading};\n};\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles({\n button: {\n padding: '9px 16px 9px 12px',\n marginLeft: 'auto',\n marginRight: '8px'\n },\n buttonLabel: {\n fontSize: '14px',\n fontWeight: 500,\n lineHeight: '16px'\n },\n icon: {\n fontSize: '18px',\n marginRight: '8px'\n }\n});\n","import React, {useState} from 'react';\nimport i18n from 'ui-i18n';\nimport {Button as Button} from '@material-ui/core';\nimport AddIcon from '@material-ui/icons/Add';\nimport {useWorkflowCheckPermission} from '../../hooks/useWorkflowCheckPermission';\nimport {AddWorkflowDialog} from '../AddWorkflowDialog/AddWorkflowDialog';\nimport {useStyles} from './styles';\n\nexport const AddWorkflowButton = () => {\n const styles = useStyles();\n const [anchorEl, setAnchorEl] = useState(null);\n\n const checkWorkflowPermission = useWorkflowCheckPermission();\n const canStartProcess = checkWorkflowPermission('START_PROCESS_INSTANCE');\n const canViewProcessDefinitions = checkWorkflowPermission('VIEW_PROCESS_DEFINITIONS');\n\n const handleOpen = (e) => setAnchorEl(e.currentTarget);\n const handleClose = () => setAnchorEl(null);\n\n return canStartProcess && canViewProcessDefinitions ? (\n <>\n <Button color=\"primary\" className={styles.button} onClick={handleOpen}>\n <AddIcon className={styles.icon} />\n <div className={styles.buttonLabel}>{i18n.text('Add')}</div>\n </Button>\n <AddWorkflowDialog anchorEl={anchorEl} onClose={handleClose} />\n </>\n ) : null;\n};\n","import {useCallback, useEffect, useState} from 'react';\nimport {useSelector} from 'react-redux';\nimport {filter, flatten, isNil, map, mergeLeft, pipe, prop, propEq, reject, uniqBy, when} from 'ramda';\nimport mdmModule from '@reltio/mdm-module';\nimport {getTasksForEntity, isTempUri, WorkflowTaskData} from '@reltio/mdm-sdk';\nimport {useSafePromise} from '../../../hooks/useSafePromise';\nimport {useWorkflowCheckPermission} from './useWorkflowCheckPermission';\n\ntype Config = {\n processTypes?: string[];\n assignee?: string;\n showClosedTasks?: boolean;\n};\n\nexport const useWorkflowTasks = (config?: Config) => {\n const {processTypes, assignee, showClosedTasks} = config || {};\n const safePromise = useSafePromise();\n const workflowPath: string = useSelector(mdmModule.selectors.getWorkflowPath);\n const environment: string = useSelector(mdmModule.selectors.getWorkflowEnvironmentUrl);\n const isWorkflowEnabled = useSelector(mdmModule.selectors.isWorkflowEnabled);\n const tenant: string = useSelector(mdmModule.selectors.getTenant);\n const entityUri = useSelector(mdmModule.selectors.getEntityUri);\n const isEditableMode = useSelector(mdmModule.selectors.getIsEditableMode);\n const checkWorkflowPermission = useWorkflowCheckPermission();\n const canViewTasks = checkWorkflowPermission('VIEW_TASKS');\n const enabled = !!(workflowPath && environment) && isWorkflowEnabled && canViewTasks;\n const [tasks, setTasks] = useState<WorkflowTaskData[]>(null);\n const [total, setTotal] = useState<number>(0);\n const [loading, setLoading] = useState<boolean>(false);\n\n const loadTasks = useCallback(() => {\n setLoading(true);\n const parsedProcessTypes = !Array.isArray(processTypes) || processTypes.includes('*') ? null : processTypes;\n const requests = (parsedProcessTypes || [null]).map((processType) =>\n getTasksForEntity({\n entityUri,\n workflowPath,\n environment,\n tenant,\n filter: {assignee, processType},\n includeClosed: !!showClosedTasks\n })\n );\n safePromise(Promise.all(requests))\n .then((responses) => {\n const tasks: WorkflowTaskData[] = pipe(\n map(prop('data')),\n reject(isNil),\n flatten,\n uniqBy(prop('taskId')),\n filter(isRequestedTask(parsedProcessTypes, assignee))\n )(responses);\n setTasks(tasks);\n setTotal(tasks.length);\n })\n .catch((error) => {\n console.warn('Workflow error', error);\n })\n .finally(() => {\n setLoading(false);\n });\n }, [entityUri, environment, safePromise, tenant, workflowPath, assignee, showClosedTasks, processTypes]);\n\n useEffect(() => {\n if (entityUri && enabled && !isTempUri(entityUri)) {\n loadTasks();\n } else {\n setTasks(null);\n setTotal(0);\n }\n }, [enabled, entityUri, loadTasks, isEditableMode]);\n\n const updateTaskState = useCallback((taskId: WorkflowTaskData['taskId'], payload: Partial<WorkflowTaskData>) => {\n setTasks(map(when(propEq('taskId', taskId), mergeLeft(payload))));\n }, []);\n\n return {tasks, total, loading, updateTaskState, loadTasks};\n};\n\nconst isRequestedTask = (processTypes: string[], assignee: string) => (task: WorkflowTaskData) =>\n (!processTypes || processTypes.includes(task.processType)) && (!assignee || assignee === task.assignee);\n","export const MAP_DRAWING_MODES = {\n CIRCLE: 'circle',\n POLYGON: 'polygon'\n};\n\nexport const DEFAULT_OVERLAY_OPTIONS = {\n fillColor: 'rgb(242,82,82)',\n fillOpacity: 0.1,\n strokeWeight: 2,\n strokeColor: '#F25252',\n clickable: false,\n editable: true,\n zIndex: 1\n};\n\nexport const DEFAULT_GOOGLE_MAP_OPTIONS = {\n mapTypeControl: false,\n streetViewControl: false,\n fullscreenControl: false\n};\n\nexport const MAP_MINIMUM_SCALE_RADIUS = 0.001;\n","import React from 'react';\n\ntype Value = {\n activeEntityUri?: string;\n};\n\nexport const EntityMarkerContext = React.createContext<Value>({});\nEntityMarkerContext.displayName = 'EntityMarkerContext';\n","import React from 'react';\nimport {InterceptHandlers} from '@reltio/mdm-sdk';\n\nexport const InterceptHandlersContext = React.createContext<InterceptHandlers>({});\n\nInterceptHandlersContext.displayName = 'InterceptHandlersContext';\n","import React from 'react';\n\nexport const ProfilePerspectiveViewContext = React.createContext(false);\n\nProfilePerspectiveViewContext.displayName = 'ProfilePerspectiveViewContext';\n","import React from 'react';\nimport {QxSandboxApi} from '@reltio/mdm-sdk';\n\nexport const SandboxAPIContext = React.createContext<QxSandboxApi>({\n getCurrentPerspectiveId: () => '',\n setEntityUri: () => {},\n showPerspective: () => {}\n});\n","import {\n AccessToken,\n CustomActionTaskParams,\n CustomActionExtension,\n CustomActionViewConfig,\n CustomScriptExtension,\n getAccessToken,\n RequestAction,\n sendRequestFromCustomSandbox,\n sendWorkflowRequest,\n startProcessFromQuery,\n Entity\n} from '@reltio/mdm-sdk';\nimport {isNewUI} from './helpers';\nimport {ProcessRequestParams} from './types';\n\ntype Config = CustomActionExtension | CustomActionViewConfig | CustomScriptExtension;\n\nconst processFromQuery = (\n params: CustomActionTaskParams,\n permissions?: string[] | undefined,\n workflowPath?: string,\n tenant?: string,\n environment?: string\n) => {\n if (!params.processDefinitionId) {\n return new Promise((resolve) => resolve({errorMessage: 'processDefinitionId is empty'}));\n }\n if (!params.searchString) {\n return new Promise((resolve) => resolve({errorMessage: 'searchString is empty'}));\n }\n if (!workflowPath) {\n return new Promise((resolve) => resolve({errorMessage: 'Workflow path is not defined'}));\n }\n const errors = validateParams({url: '/processInstances/_generateFromQuery', ...params}, permissions);\n if (errors) {\n return new Promise((resolve) => resolve(errors));\n }\n\n return startProcessFromQuery({\n workflowPath,\n processType: params.processDefinitionId,\n searchString: params.searchString,\n tenant,\n environment\n });\n};\n\nconst getHeaders = async (params: CustomActionTaskParams, signHandler?: () => Promise<AccessToken>) => {\n const {accessToken} = await signHandler?.();\n return accessToken\n ? {\n ...params.headers,\n Authorization: `Bearer ${accessToken}`\n }\n : params.headers;\n};\n\nconst workflowRequest = async (\n params: CustomActionTaskParams,\n permissions?: string[],\n workflowPath?: string,\n tenant?: string,\n signHandler?: () => Promise<AccessToken>\n) => {\n const {url} = params;\n const errors = validateParams(params, permissions);\n if (errors) {\n return errors;\n }\n const isExternalUrl = url.includes('http:') || url.includes('https:');\n if (!workflowPath && !isExternalUrl) {\n return {errorMessage: 'Workflow path is not defined'};\n }\n const headers = await getHeaders(params, signHandler);\n return await sendWorkflowRequest({\n url,\n method: params.method || 'GET',\n data: params.data,\n tenant,\n headers,\n workflowPath\n });\n};\n\nconst sendApiRequest = async (\n params: CustomActionTaskParams,\n permissions?: string[],\n signHandler?: () => Promise<AccessToken>\n) => {\n const errors = validateParams(params, permissions);\n if (errors) {\n return errors;\n }\n const headers = await getHeaders(params, signHandler);\n return await sendRequestFromCustomSandbox({\n url: params.url,\n method: params.method,\n data: params.data,\n headers,\n noRequestProcessor: true\n });\n};\n\nconst validateParams = (params: CustomActionTaskParams, permissions?: string[]) => {\n const {url} = params;\n if (!url) return {errorMessage: 'URL is empty'};\n const allowed = permissions?.some((permission) => {\n const urlOrigin = url.match(/^(https?:\\/\\/[^:/?#]*).*$/)?.[1];\n const permRegex = new RegExp('^' + permission + '$');\n const decodedPerm = permission.replace(/\\/*$/, '');\n return (\n decodedPerm === url ||\n (urlOrigin && urlOrigin === decodedPerm) ||\n (decodedPerm?.startsWith('/') && url?.startsWith(decodedPerm)) ||\n (permission && permRegex.test(url))\n );\n });\n\n if (!allowed || (permissions?.length || 0) === 0) {\n return {errorMessage: 'Not enough permissions'};\n }\n return false;\n};\n\nexport const processRequest = ({\n name,\n paramObject,\n permissions,\n worker,\n metadata,\n config,\n apiPath,\n servicesPath,\n user,\n workflowPath,\n entity,\n tenant,\n entityUri,\n query,\n openSearch,\n environment,\n getCurrentPerspectiveId,\n showPerspective,\n workflowCheckPermission,\n setEntityUri\n}: ProcessRequestParams) => {\n const handleRequest = (request: Promise<any>) => {\n request\n .then((data) => {\n worker.postMessage({\n action: 'response',\n result: {data, headers: paramObject.params.headers, status: 200},\n ...paramObject.params\n });\n })\n .catch((error) => {\n worker.postMessage({\n action: 'response',\n result: {data: error, headers: paramObject.params.headers, status: 0},\n ...paramObject.params\n });\n });\n };\n const shouldSignRequest = isNewUI(servicesPath);\n const signHandler = shouldSignRequest\n ? () => getAccessToken({servicesPath})\n : () => Promise.resolve({accessToken: ''});\n\n switch (name) {\n case RequestAction.API: {\n const request = sendApiRequest(paramObject.params, permissions, signHandler);\n handleRequest(request);\n break;\n }\n case RequestAction.WORKFLOW: {\n const request = workflowRequest(paramObject.params, permissions, workflowPath, tenant, signHandler);\n handleRequest(request);\n break;\n }\n case RequestAction.WORKFLOW_START_PROCESS_FROM_QUERY: {\n const request = processFromQuery(paramObject.params, permissions, workflowPath, tenant, environment);\n handleRequest(request);\n break;\n }\n case RequestAction.GET_CONFIGURATION: {\n worker.postMessage({action: 'response', result: metadata, ...paramObject.params});\n break;\n }\n case RequestAction.GET_UI_CONFIGURATION: {\n const response = {...config, action: {...config.action}};\n if (response.action.permissions) {\n delete response.action.permissions;\n }\n worker.postMessage({action: 'response', result: response, ...paramObject.params});\n break;\n }\n case RequestAction.SET_ENTITY_URI: {\n const listener = (newEntity: Entity) =>\n worker.postMessage({action: 'response', result: newEntity, ...paramObject.params});\n setEntityUri(paramObject.params.entityUri, listener);\n break;\n }\n case RequestAction.SET_PERSPECTIVE: {\n showPerspective(paramObject.params.perspective);\n worker.postMessage({\n action: 'response',\n result: getCurrentPerspectiveId(),\n ...paramObject.params\n });\n break;\n }\n case RequestAction.GET_PERSPECTIVE: {\n if (getCurrentPerspectiveId) {\n worker.postMessage({\n action: 'response',\n result: getCurrentPerspectiveId(),\n ...paramObject.params\n });\n }\n break;\n }\n case RequestAction.WORKFLOW_CHECK_PERMISSION: {\n worker.postMessage({\n action: 'response',\n result: workflowCheckPermission(paramObject.params.permission),\n ...paramObject.params\n });\n break;\n }\n case RequestAction.GET_SEARCH_QUERY: {\n worker.postMessage({action: 'response', result: query, ...paramObject.params});\n break;\n }\n case RequestAction.OPEN_SEARCH: {\n openSearch({viewId: (config as Config).id, searchState: paramObject.params.searchState || {}});\n break;\n }\n case RequestAction.GET_ENTITY_URI: {\n worker.postMessage({action: 'response', result: entityUri, ...paramObject.params});\n break;\n }\n case RequestAction.GET_ENTITY: {\n worker.postMessage({action: 'response', result: entity, ...paramObject.params});\n break;\n }\n case RequestAction.GET_API_PATH: {\n worker.postMessage({action: 'response', result: apiPath, ...paramObject.params});\n break;\n }\n case RequestAction.WORKFLOW_GET_WORKFLOW_PATH: {\n worker.postMessage({action: 'response', result: workflowPath, ...paramObject.params});\n break;\n }\n case RequestAction.GET_TENANT: {\n worker.postMessage({action: 'response', result: tenant, ...paramObject.params});\n break;\n }\n case RequestAction.GET_USER: {\n worker.postMessage({action: 'response', result: user, ...paramObject.params});\n break;\n }\n case RequestAction.ALERT: {\n worker.postMessage({\n action: 'response',\n result: window.alert(paramObject.params.text),\n ...paramObject.params\n });\n break;\n }\n case RequestAction.CONFIRM: {\n worker.postMessage({\n action: 'response',\n result: window.confirm(paramObject.params.text),\n ...paramObject.params\n });\n break;\n }\n case RequestAction.PROMPT: {\n worker.postMessage({\n action: 'response',\n result: window.prompt(paramObject.params.text, paramObject.params.defaultText || ''),\n ...paramObject.params\n });\n break;\n }\n case RequestAction.OPEN_WINDOW: {\n window.open(paramObject.params.url, '_blank');\n break;\n }\n case RequestAction.RELOAD_PAGE: {\n location.reload();\n break;\n }\n }\n};\n","import nanoid from 'nanoid';\n\nexport const isNewUI = (path?: string): boolean => {\n return path?.includes('/nui');\n};\n\nexport const getWorkerURL = (uiPath: string, tenant: string) => {\n if (isNewUI(uiPath)) {\n return `${uiPath.replace(`${tenant}/`, '')}worker_api.js`;\n } else {\n return `${uiPath}worker_api.js`;\n }\n};\n\nexport const getFilesWithArrayBuffer = (files: FileList) => {\n const readFilePromises = Array.from(files).map((file) => {\n return new Promise((resolve, reject) => {\n const reader = new FileReader();\n reader.onload = (event) => {\n const content = event.target.result;\n const {lastModified, name, size, type} = file;\n resolve({lastModified, name, size, type, content});\n };\n reader.onerror = (error) => {\n reject(error);\n };\n reader.readAsArrayBuffer(file);\n });\n });\n return Promise.all(readFilePromises);\n};\n\nconst processInnerHtml = (parent: HTMLElement, worker: Worker, setTooltip) => {\n let handlersToReset = [];\n const uiActions = parent.getAttribute('ui-actions');\n const uiTooltip = parent.getAttribute('ui-tooltip');\n const id = parent.getAttribute('id') || parent.getAttribute('name');\n if (uiActions) {\n uiActions.split(',').forEach((uiAction) => {\n const handler = (event: Event) => {\n const target = event.target as HTMLInputElement;\n const postEventMessage = (files?) => {\n worker.postMessage({\n action: 'event',\n type: 'uiAction',\n data: {type: uiAction, id, event: {...event, files}}\n });\n };\n if (target.files?.length) {\n getFilesWithArrayBuffer(target.files).then(postEventMessage);\n } else {\n postEventMessage();\n }\n };\n parent.addEventListener(uiAction, handler);\n handlersToReset.push(() => {\n parent.removeEventListener(uiAction, handler);\n });\n });\n parent.removeAttribute('ui-actions');\n }\n if (uiTooltip) {\n setTooltip(uiTooltip);\n }\n parent.childNodes.forEach((child) => {\n if (child.nodeType === 1) {\n //Node.ELEMENT_NODE\n handlersToReset = handlersToReset.concat(processInnerHtml(child as HTMLElement, worker, setTooltip));\n }\n });\n return handlersToReset;\n};\n\ntype ResetHTMLParams = {\n worker: Worker;\n setTooltip: any;\n html?: string;\n innerText?: string;\n setListenersToReset: any;\n setHtml: any;\n};\n\nexport const resetHtml = ({worker, setTooltip, innerText, html, setListenersToReset, setHtml}: ResetHTMLParams) => {\n const docBlock = document.createElement('div');\n docBlock.innerHTML = html || innerText;\n\n const handlersToReset = processInnerHtml(docBlock, worker, setTooltip);\n setListenersToReset(handlersToReset);\n setHtml(docBlock);\n};\n\nconst isURLtoProcess = (processApi: string[], url: string) =>\n (processApi || []).some((request) => {\n const regExp = new RegExp(`^${request}$`);\n return request.replace(/\\/*$/, '') === url || (request && regExp.test(url));\n });\n\nexport const setUpQooxdooRequestInterceptor = ({workerRef, setRequestListeners}) => ({\n processApiRequest: (url, method, headers, data, next) => {\n const requestId = nanoid();\n const options = {url, method, headers, noRequestProcessor: true};\n setRequestListeners(options, next, requestId);\n workerRef.current.postMessage({\n action: 'apiRequest',\n id: requestId,\n url,\n method,\n headers,\n data\n });\n }\n});\n\nexport const setUpQooxdooResponseInterceptor = ({workerRef, setResponseListeners}) => ({\n processApiResponse: (url, method, data, next) => {\n const responseId = nanoid();\n setResponseListeners(next, responseId);\n workerRef.current.postMessage({\n action: 'apiResponse',\n id: responseId,\n url,\n method,\n data\n });\n }\n});\n\nexport const setUpRequestInterceptor = ({\n apiPath,\n reltioPath,\n tenant,\n processApiRequest,\n workerRef,\n setRequestListeners\n}) => ({\n options = {},\n url,\n next\n}: {\n next: (url: string, options: RequestInit) => void;\n abort?: (error: Error) => void;\n url: string;\n options: RequestInit;\n}) => {\n const fakeURL =\n url.startsWith('/') && !url.startsWith(apiPath)\n ? `${reltioPath}/api/${tenant}${url}`\n : `${reltioPath}${url.replace(apiPath, '')}`;\n const isProcessableUrl = isURLtoProcess(processApiRequest, fakeURL);\n if (isProcessableUrl) {\n const requestId = nanoid();\n setRequestListeners(options, next, requestId);\n workerRef.current.postMessage({\n action: 'apiRequest',\n id: requestId,\n url: fakeURL,\n method: options.method,\n headers: {...options.headers, origin: 'ui', requestId},\n data: options.body\n });\n } else {\n next(url, options);\n }\n};\n\nexport const setUpResponseInterceptor = ({\n reltioPath,\n apiPath,\n processApiResponse,\n workerRef,\n setResponseListeners\n}) => ({url, response, next, options, abort}) => {\n if (options?.headers?.origin === 'ui') {\n response\n .json()\n .then((data) => {\n setResponseListeners(next, options.headers.requestId);\n workerRef.current.postMessage({\n action: 'response',\n result: {data, status: response.status},\n id: options?.id,\n name: options?.task?.params?.name\n });\n })\n .catch((error) => {\n abort(error);\n });\n } else {\n const fakeURL = `${reltioPath}${url.replace(apiPath, '')}`;\n const isProcessableUrl = isURLtoProcess(processApiResponse, fakeURL);\n\n if (isProcessableUrl) {\n const responseId = nanoid();\n response\n .json()\n .then((data) => {\n setResponseListeners(next, responseId);\n workerRef.current.postMessage({\n action: 'apiResponse',\n id: responseId,\n url: fakeURL,\n method: options.method,\n data\n });\n })\n .catch((error) => {\n abort(error);\n });\n } else {\n next(response);\n }\n }\n};\n","const defaultAttributes = [\n 'accent-height',\n 'accumulate',\n 'additive',\n 'alignment-baseline',\n 'allowReorder',\n 'alphabetic',\n 'amplitude',\n 'arabic-form',\n 'ascent',\n 'attributeName',\n 'attributeType',\n 'autoReverse',\n 'azimuth',\n 'baseFrequency',\n 'baseline-shift',\n 'baseProfile',\n 'bbox',\n 'begin',\n 'bias',\n 'by',\n 'calcMode',\n 'cap-height',\n 'class',\n 'clip',\n 'clipPathUnits',\n 'clip-path',\n 'clip-rule',\n 'color',\n 'color-interpolation',\n 'color-interpolation-filters',\n 'color-profile',\n 'color-rendering',\n 'contentScriptType',\n 'contentStyleType',\n 'cursor',\n 'cx',\n 'cy',\n 'd',\n 'decelerate',\n 'descent',\n 'diffuseConstant',\n 'direction',\n 'display',\n 'divisor',\n 'dominant-baseline',\n 'dur',\n 'dx',\n 'dy',\n 'edgeMode',\n 'elevation',\n 'enable-background',\n 'end',\n 'exponent',\n 'externalResourcesRequired',\n 'fill',\n 'fill-opacity',\n 'fill-rule',\n 'filter',\n 'filterRes',\n 'filterUnits',\n 'flood-color',\n 'flood-opacity',\n 'font-family',\n 'font-size',\n 'font-size-adjust',\n 'font-stretch',\n 'font-style',\n 'font-variant',\n 'font-weight',\n 'format',\n 'from',\n 'fx',\n 'fy',\n 'g1',\n 'g2',\n 'glyph-name',\n 'glyph-orientation-horizontal',\n 'glyph-orientation-vertical',\n 'glyphRef',\n 'gradientTransform',\n 'gradientUnits',\n 'hanging',\n 'height',\n 'horiz-adv-x',\n 'horiz-origin-x',\n 'id',\n 'ideographic',\n 'image-rendering',\n 'in',\n 'in2',\n 'intercept',\n 'k',\n 'k1',\n 'k2',\n 'k3',\n 'k4',\n 'kernelMatrix',\n 'kernelUnitLength',\n 'kerning',\n 'keyPoints',\n 'keySplines',\n 'keyTimes',\n 'lang',\n 'lengthAdjust',\n 'letter-spacing',\n 'lighting-color',\n 'limitingConeAngle',\n 'local',\n 'marker-end',\n 'marker-mid',\n 'marker-start',\n 'markerHeight',\n 'markerUnits',\n 'markerWidth',\n 'mask',\n 'maskContentUnits',\n 'maskUnits',\n 'mathematical',\n 'max',\n 'media',\n 'method',\n 'min',\n 'mode',\n 'name',\n 'numOctaves',\n 'offset',\n 'opacity',\n 'operator',\n 'order',\n 'orient',\n 'orientation',\n 'origin',\n 'overflow',\n 'overline-position',\n 'overline-thickness',\n 'panose-1',\n 'paint-order',\n 'path',\n 'pathLength',\n 'patternContentUnits',\n 'patternTransform',\n 'patternUnits',\n 'pointer-events',\n 'points',\n 'pointsAtX',\n 'pointsAtY',\n 'pointsAtZ',\n 'preserveAlpha',\n 'preserveAspectRatio',\n 'primitiveUnits',\n 'r',\n 'radius',\n 'refX',\n 'refY',\n 'rendering-intent',\n 'repeatCount',\n 'repeatDur',\n 'requiredExtensions',\n 'requiredFeatures',\n 'restart',\n 'result',\n 'rotate',\n 'rx',\n 'ry',\n 'scale',\n 'seed',\n 'shape-rendering',\n 'slope',\n 'spacing',\n 'specularConstant',\n 'specularExponent',\n 'speed',\n 'spreadMethod',\n 'startOffset',\n 'stdDeviation',\n 'stemh',\n 'stemv',\n 'stitchTiles',\n 'stop-color',\n 'stop-opacity',\n 'strikethrough-position',\n 'strikethrough-thickness',\n 'string',\n 'stroke',\n 'stroke-dasharray',\n 'stroke-dashoffset',\n 'stroke-linecap',\n 'stroke-linejoin',\n 'stroke-miterlimit',\n 'stroke-opacity',\n 'stroke-width',\n 'style',\n 'surfaceScale',\n 'systemLanguage',\n 'tableValues',\n 'target',\n 'targetX',\n 'targetY',\n 'text-anchor',\n 'text-decoration',\n 'text-rendering',\n 'textLength',\n 'to',\n 'transform',\n 'type',\n 'u1',\n 'u2',\n 'underline-position',\n 'underline-thickness',\n 'unicode',\n 'unicode-bidi',\n 'unicode-range',\n 'units-per-em',\n 'v-alphabetic',\n 'v-hanging',\n 'v-ideographic',\n 'v-mathematical',\n 'values',\n 'version',\n 'vert-adv-y',\n 'vert-origin-x',\n 'vert-origin-y',\n 'viewBox',\n 'viewTarget',\n 'visibility',\n 'width',\n 'widths',\n 'word-spacing',\n 'writing-mode',\n 'x',\n 'x-height',\n 'x1',\n 'x2',\n 'xChannelSelector',\n 'y',\n 'y1',\n 'y2',\n 'yChannelSelector',\n 'z',\n 'zoomAndPan'\n];\n\nconst defaultTags = [\n 'animate',\n 'animateColor',\n 'animateMotion',\n 'animateTransform',\n 'mpath',\n 'set',\n 'circle',\n 'ellipse',\n 'line',\n 'polygon',\n 'polyline',\n 'rect',\n 'defs',\n 'glyph',\n 'g',\n 'marker',\n 'mask',\n 'missing-glyph',\n 'pattern',\n 'svg',\n 'switch',\n 'symbol',\n 'font',\n 'font-face',\n 'font-face-format',\n 'font-face-name',\n 'font-face-src',\n 'font-face-uri',\n 'hkern',\n 'vkern',\n 'linearGradient',\n 'radialGradient',\n 'stop',\n 'circle',\n 'ellipse',\n 'image',\n 'line',\n 'path',\n 'polygon',\n 'polyline',\n 'rect',\n 'text',\n 'use',\n 'feDistantLight',\n 'fePointLight',\n 'feSpotLight',\n 'circle',\n 'ellipse',\n 'line',\n 'path',\n 'polygon',\n 'polyline',\n 'rect',\n 'defs',\n 'g',\n 'svg',\n 'symbol',\n 'use',\n 'altGlyph',\n 'altGlyphDef',\n 'altGlyphItem',\n 'glyph',\n 'glyphRef',\n 'textPath',\n 'text',\n 'tref',\n 'tspan',\n 'altGlyph',\n 'textPath',\n 'tref',\n 'tspan',\n 'clipPath',\n 'color-profile',\n 'cursor',\n 'filter',\n 'foreignObject',\n 'script',\n 'style',\n 'view'\n];\n\nexport default {\n attributes: {\n '*': [...defaultAttributes, 'ui-actions', 'ui-tooltip'],\n img: ['src', 'srcset', 'alt', 'title', 'loading'],\n link: ['href', 'rel'],\n iframe: ['src'],\n a: ['href']\n },\n tags: [...defaultTags, 'a', 'link', 'input', 'button', 'iframe', 'img']\n};\n","import sanitizeHtml, {IOptions} from 'sanitize-html';\nimport sanitizeOptions from './helpers/sanitizerOptions';\n\nexport const useHtmlSanitizer = () => {\n const {allowedAttributes, allowedTags} = sanitizeHtml.defaults;\n const {attributes, tags} = sanitizeOptions;\n const options: IOptions = {\n allowedTags: allowedTags.concat(tags),\n allowedAttributes: {...allowedAttributes, ...attributes},\n allowVulnerableTags: true\n };\n return (html: string) => sanitizeHtml(html, options);\n};\n","import {useCallback, useContext, useEffect, useRef, useState, CSSProperties} from 'react';\nimport {useDispatch, useSelector} from 'react-redux';\nimport mdmModule, {ui} from '@reltio/mdm-module';\nimport {\n CustomAction,\n CustomActionTaskParams,\n CustomScriptPlatform,\n CustomActionViewConfig,\n CustomActionExtension,\n Entity,\n initializeWebWorker,\n isEmptyValue,\n ProcessParams\n} from '@reltio/mdm-sdk';\nimport {omit} from 'ramda';\nimport {useWorkflowCheckPermission} from '../../components/workflow';\nimport {useHtmlSanitizer} from '../useHtmlSanitizer';\nimport {InterceptHandlersContext, SandboxAPIContext, SnackbarContext} from '../../contexts';\nimport {processRequest} from './API';\nimport {\n getWorkerURL,\n resetHtml,\n isNewUI,\n setUpResponseInterceptor,\n setUpRequestInterceptor,\n setUpQooxdooRequestInterceptor,\n setUpQooxdooResponseInterceptor\n} from './helpers';\nimport {Request} from './types';\n\ntype Config = CustomActionViewConfig | CustomActionExtension;\n\nexport const useAPI = (config: Config = {} as Config) => {\n const [html, setHtml] = useState<HTMLElement>();\n const [listenersToReset, setListenersToReset] = useState<Array<() => void>>([]);\n const [popupListenersToReset, setPopupListenersToReset] = useState<Array<() => void>>([]);\n const [visible, setVisible] = useState(true);\n const [popup, setPopup] = useState<HTMLElement>();\n const [tooltip, setTooltip] = useState<string>(null);\n const [customStyles, setCustomStyles] = useState<{\n height?: number | string;\n width?: number | string;\n pointerEvents?: CSSProperties['pointerEvents'];\n }>({});\n const workerRef = useRef<Worker>();\n const requestListeners = useRef({});\n const responseListeners = useRef({});\n\n const dispatch = useDispatch();\n const sanitizeHtml = useHtmlSanitizer();\n\n const uiPath = useSelector(mdmModule.selectors.getUIPath);\n const tenant: string = useSelector(mdmModule.selectors.getTenant);\n const workerUrl = getWorkerURL(uiPath, tenant);\n\n const showSnackbarMessage = useContext(SnackbarContext);\n const qxApi = useContext(SandboxAPIContext);\n const interceptHandlers = useContext(InterceptHandlersContext);\n\n const workflowCheckPermission = useWorkflowCheckPermission();\n\n const metadata = useSelector(mdmModule.selectors.getMetadata) || {};\n const entity = useSelector(mdmModule.selectors.getEntity) || ({} as Entity);\n const apiPath: string = useSelector(mdmModule.selectors.getApiPath);\n const servicesPath = useSelector(mdmModule.selectors.getServicesPath);\n const reltioPath = useSelector(mdmModule.selectors.getReltioPath);\n const workflowPath = useSelector(mdmModule.selectors.getWorkflowPath);\n const user = useSelector(mdmModule.selectors.getUser);\n const entityUri = useSelector(mdmModule.selectors.getEntityUri);\n const isEditableMode = useSelector(mdmModule.selectors.getIsEditableMode);\n const environment = useSelector(mdmModule.selectors.getWorkflowEnvironmentUrl);\n const {type: typeSearch, data: search} = useSelector(mdmModule.selectors.getSearchProviderData) || {};\n const searchQuery = typeSearch === 'search' ? search?.query : null;\n const isOldUI = !isNewUI(servicesPath);\n const supportedInterceptHandlers = isOldUI ? qxApi.interceptors : interceptHandlers;\n\n const openSearch = (search) => dispatch(ui.actions.openSearch(search));\n\n let innerText = '';\n let popupText = '';\n const process = ({task, worker}: ProcessParams) => {\n if (task) {\n switch (task.action) {\n case CustomAction.SET_HTML: {\n const sanitizedHtml = sanitizeHtml((task.params as CustomActionTaskParams).html);\n if ((task.params as CustomActionTaskParams).id) {\n const elem = document.getElementById((task.params as CustomActionTaskParams).id as string);\n elem.innerHTML = sanitizedHtml;\n } else if (innerText !== sanitizedHtml) {\n innerText = sanitizedHtml;\n resetHtml({\n worker,\n setTooltip,\n html: sanitizedHtml,\n innerText,\n setListenersToReset,\n setHtml\n });\n }\n break;\n }\n case CustomAction.SHOW_POPUP: {\n const sanitizedPopup = sanitizeHtml(task.params as string);\n popupText = sanitizedPopup;\n resetHtml({\n worker,\n setTooltip,\n html: sanitizedPopup,\n innerText: popupText,\n setListenersToReset: setPopupListenersToReset,\n setHtml: setPopup\n });\n break;\n }\n case CustomAction.HIDE_POPUP: {\n popupText = '';\n setPopup(null);\n break;\n }\n case CustomAction.SET_VISIBILITY: {\n if (task.params === 'visible') {\n setVisible(true);\n resetHtml({\n worker,\n setTooltip,\n innerText,\n setListenersToReset,\n setHtml\n });\n } else {\n setVisible(false);\n }\n break;\n }\n case CustomAction.SET_TOOLTIP: {\n setTooltip(task.params as string);\n break;\n }\n case CustomAction.SET_HEIGHT: {\n setCustomStyles((prev) => ({\n ...prev,\n height: task.params as string | number\n }));\n break;\n }\n case CustomAction.SET_WIDTH: {\n setCustomStyles((prev) => ({\n ...prev,\n width: task.params as string | number\n }));\n break;\n }\n case CustomAction.SET_ENABLED: {\n setCustomStyles((prev) =>\n task.params ? omit(['pointer-events'], prev) : {...prev, 'pointer-events': 'none'}\n );\n break;\n }\n case CustomAction.LOG: {\n console.log(task.params); //eslint-disable-line no-console\n break;\n }\n case CustomAction.MESSAGE: {\n showSnackbarMessage(task.params as string);\n break;\n }\n case CustomAction.REQUEST: {\n if ((task.params as CustomActionTaskParams)?.headers?.origin !== 'ui') {\n processRequest({\n name: (task.params as CustomActionTaskParams).name,\n paramObject: task as Request,\n permissions: config.action.permissions,\n worker,\n metadata,\n config: config as Config,\n user,\n servicesPath,\n apiPath: isOldUI ? apiPath : reltioPath,\n tenant,\n workflowPath,\n entity,\n entityUri,\n environment,\n query: searchQuery,\n openSearch,\n workflowCheckPermission,\n ...qxApi\n });\n } else {\n const {headers, id, url: fakeURL, method, data} = task.params as CustomActionTaskParams;\n const url = fakeURL.replace(reltioPath, apiPath);\n if (requestListeners.current[headers.requestId]) {\n requestListeners.current[headers.requestId].next(url, {\n body: data,\n id,\n task,\n headers,\n method\n });\n requestListeners.current = omit([headers.requestId], requestListeners.current);\n }\n }\n break;\n }\n case CustomAction.RETURN_PROCESSED_API_RESPONSE:\n case CustomAction.RETURN_PROCESSED_API_REQUEST: {\n const {id, data} = task.params as CustomActionTaskParams;\n if (responseListeners.current[id]) {\n responseListeners.current[id].next(data);\n responseListeners.current = omit([id], responseListeners.current);\n }\n break;\n }\n }\n }\n };\n\n const setRequestListeners = (options, next, requestId) => {\n requestListeners.current = {\n ...requestListeners.current,\n [requestId]: {options, next, id: requestId}\n };\n };\n\n const setResponseListeners = (next, responseId) => {\n responseListeners.current = {\n ...responseListeners.current,\n [responseId]: {next}\n };\n };\n\n const qooxdooRequestInterceptor = setUpQooxdooRequestInterceptor({workerRef, setRequestListeners});\n const qooxdooResponseInterceptor = setUpQooxdooResponseInterceptor({workerRef, setResponseListeners});\n const requestInterceptor = setUpRequestInterceptor({\n apiPath,\n reltioPath,\n tenant,\n processApiRequest: config?.action?.processApiRequest,\n workerRef,\n setRequestListeners\n });\n const responseInterceptor = setUpResponseInterceptor({\n reltioPath,\n apiPath,\n processApiResponse: config?.action?.processApiResponse,\n workerRef,\n setResponseListeners\n });\n\n const postEventMessage = (type: string, data: unknown) => {\n workerRef.current?.postMessage({action: 'event', type, data});\n };\n\n useEffect(() => {\n if (!isEmptyValue(config.action) && config.action.platform !== CustomScriptPlatform.CLASSIC) {\n workerRef.current = initializeWebWorker(workerUrl, process, config);\n postEventMessage('updateEntity', entity);\n }\n }, [entity, config]);\n\n useEffect(() => {\n postEventMessage('editMode', isEditableMode);\n }, [isEditableMode]);\n\n useEffect(() => {\n postEventMessage('changeSearchQuery', searchQuery);\n }, [searchQuery]);\n\n useEffect(() => {\n postEventMessage('changeVisibility', visible);\n }, [visible]);\n\n useEffect(\n () => () => {\n listenersToReset.forEach((listener) => listener());\n },\n [listenersToReset]\n );\n //we need to have separate handlers in opposite case main window listeners will be removed on the popup appear\n useEffect(\n () => () => {\n popupListenersToReset.forEach((listener) => listener());\n },\n [popupListenersToReset, listenersToReset]\n );\n\n const onClick = useCallback(() => {\n postEventMessage('execute', null);\n }, [config]);\n\n useEffect(() => {\n if (\n !isEmptyValue(supportedInterceptHandlers) &&\n (config?.action?.processApiRequest || config?.action?.processApiResponse)\n ) {\n const {\n addInternalRequestInterceptor,\n addInternalResponseInterceptor,\n removeInternalRequestInterceptor,\n removeInternalResponseInterceptor\n } = supportedInterceptHandlers;\n\n if (isOldUI) {\n addInternalRequestInterceptor(config?.action?.processApiRequest, qooxdooRequestInterceptor);\n addInternalResponseInterceptor(config?.action?.processApiResponse, qooxdooResponseInterceptor);\n return () => {\n removeInternalRequestInterceptor(qooxdooRequestInterceptor);\n removeInternalResponseInterceptor(qooxdooResponseInterceptor);\n };\n } else {\n addInternalRequestInterceptor(requestInterceptor);\n addInternalResponseInterceptor(responseInterceptor);\n return () => {\n removeInternalRequestInterceptor(requestInterceptor);\n removeInternalResponseInterceptor(responseInterceptor);\n };\n }\n }\n }, [config]);\n\n return {html, visible, tooltip, customStyles, onClick, popup};\n};\n","import {useCallback, useEffect, useState} from 'react';\nimport {concat, difference, isEmpty, map, pipe, prop, reduce, reject, uniq} from 'ramda';\nimport {useSelector} from 'react-redux';\nimport mdm from '@reltio/mdm-module';\nimport {\n ActivityFilters,\n Comment,\n Entity,\n FilterOptions,\n getFilteredEntities,\n isEntityUri,\n getEntity,\n EntitiesMap\n} from '@reltio/mdm-sdk';\nimport {useSafePromise} from './useSafePromise';\n\nconst SELECT_OPTION = 'uri,label,type';\n\nexport const useCommentsEntitiesMap = (comments: Comment[]) => {\n const safePromise = useSafePromise();\n const currentEntityUri = useSelector(mdm.selectors.getEntityUriWithDataTenant);\n\n const [entitiesMap, setEntitiesMap] = useState<EntitiesMap>({});\n\n const getEntities = useCallback(\n (entitiesUris: string[]) => {\n const requestFilters = [\n {\n filter: FilterOptions.EQUALS,\n fieldName: 'uri',\n values: entitiesUris\n }\n ];\n\n const requestOptions = {\n max: entitiesUris.length,\n activeness: ActivityFilters.ALL,\n select: 'uri,label,type'\n };\n return safePromise(getFilteredEntities(requestFilters, requestOptions));\n },\n [safePromise]\n );\n\n const getNotFoundEntity = (entityUri: string) => {\n return getEntity(entityUri, {options: SELECT_OPTION})\n .then((entity: Entity) => ({...entity, uri: entityUri} as Entity))\n .catch(() => ({}));\n };\n\n const addNotFoundEntities = useCallback(\n (entitiesUris: string[], entities: Entity[]) => {\n return safePromise(\n Promise.all((entitiesUris || []).map(getNotFoundEntity))\n ).then((notFoundEntities: Entity[]) => pipe(reject(isEmpty), concat(entities))(notFoundEntities));\n },\n [safePromise]\n );\n\n useEffect(() => {\n const uniqEntitiesUris = pipe(\n reduce((entitiesUris, comment) => {\n const {objectType: type, relatedObjectUris} = comment;\n\n if (type === 'relation' || type === 'potentialMatch') {\n (relatedObjectUris || []).forEach((uri) => {\n if (uri !== currentEntityUri && isEntityUri(uri) && !entitiesMap[uri]) {\n entitiesUris.push(uri);\n }\n });\n }\n return entitiesUris;\n }, []),\n uniq\n )(comments || []);\n\n if (uniqEntitiesUris.length) {\n getEntities(uniqEntitiesUris)\n .then((results: Entity[]) => {\n const getNotFoundUris = pipe(map(prop('uri')), difference(uniqEntitiesUris));\n\n const notFoundEntities = getNotFoundUris(results);\n return addNotFoundEntities(notFoundEntities, results);\n })\n .then((results) => {\n setEntitiesMap((prevEntitiesMap) =>\n results.reduce(\n (entities, entity) => {\n entities[entity.uri] = entity;\n return entities;\n },\n {...prevEntitiesMap}\n )\n );\n })\n .catch(() => {});\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [getEntities, addNotFoundEntities, comments, currentEntityUri]);\n\n return entitiesMap;\n};\n","import {useSelector} from 'react-redux';\nimport mdmModule from '@reltio/mdm-module';\nimport {checkConfigPermission, ConfigPermissions} from '@reltio/mdm-sdk';\nimport {useCallback} from 'react';\n\nconst emptyArray = [];\n\nexport const useConfigPermissions = () => {\n const userRoles = useSelector(mdmModule.selectors.getUserRoles) || emptyArray;\n\n return {\n canCreate: useCallback(checkConfigPermission(ConfigPermissions.CREATE, userRoles), [userRoles]),\n canRead: useCallback(checkConfigPermission(ConfigPermissions.READ, userRoles), [userRoles]),\n canUpdate: useCallback(checkConfigPermission(ConfigPermissions.UPDATE, userRoles), [userRoles]),\n canDelete: useCallback(checkConfigPermission(ConfigPermissions.DELETE, userRoles), [userRoles])\n };\n};\n","import {useCallback, useEffect, useMemo, useRef, useState} from 'react';\nimport {useDispatch, useSelector} from 'react-redux';\nimport {cond, pipe, prop, T, evolve, filter as filterFn, when, identity, times, length, ifElse, always} from 'ramda';\nimport mdm, {profile} from '@reltio/mdm-module';\nimport {\n ActivityFilter,\n addGlobalFilterToQuery,\n Connection,\n Entity,\n getRelationsForDataTenantEntity,\n getRelationsForEntity,\n GlobalSearchRequestOptions,\n isAvailableEntityTypeUri,\n isAvailableRelationTypeUri,\n isDataTenantEntity,\n isObject,\n isTempUri,\n Metadata,\n Mode,\n RelationsContent,\n RelationsViewConfig,\n wrapInArrayIfNeeded\n} from '@reltio/mdm-sdk';\nimport {useSafePromise} from './useSafePromise';\nimport {usePrevious} from './usePrevious';\n\ntype Props = {\n sorting?: {\n field: string;\n order: string;\n };\n filter?: string;\n page: number;\n rowsPerPage: number;\n config: Pick<RelationsViewConfig, 'suggested' | 'content' | 'id'>;\n entity: Entity;\n relationActivityFilter?: ActivityFilter;\n mode: Mode;\n searchByOv?: boolean;\n};\n\nconst buildSuggestedIds = when(\n identity,\n pipe(\n wrapInArrayIfNeeded,\n length,\n times((n) => n + 1)\n )\n);\ntype ConnectionResponse = Array<{connections?: Connection[]; total: number}>;\n\nexport const useRelationsLoader = ({\n sorting,\n filter,\n page,\n rowsPerPage,\n config,\n entity,\n relationActivityFilter,\n mode,\n searchByOv = false\n}: Props) => {\n const [isLoading, setIsLoading] = useState(false);\n const dispatch = useDispatch();\n const tenant = useSelector(mdm.selectors.getTenant) as string;\n const metadata = useSelector(mdm.selectors.getMetadata) as Metadata;\n const dtssPath = useSelector(mdm.selectors.getDtssPath) as string;\n const {activityFilter, globalFilter}: GlobalSearchRequestOptions =\n useSelector(mdm.selectors.getGlobalSearchRequestOptions) || {};\n const safePromise = useSafePromise();\n\n const processContent = (content: RelationsContent) => {\n const getUri = when(isObject, prop('uri'));\n const filterRelation = pipe(getUri, isAvailableRelationTypeUri(metadata));\n\n return evolve({\n entityTypes: filterFn(isAvailableEntityTypeUri(metadata)),\n inRelations: filterFn(filterRelation),\n outRelations: filterFn(filterRelation),\n nextEntry: processContent\n })(content);\n };\n\n const suggested = config.suggested;\n const options = useMemo(\n () => ({\n searchByOv\n }),\n [searchByOv]\n );\n const loadRelations = useCallback(() => {\n if (entity?.uri) {\n const processedConfig = processContent(config.content);\n const requestConfig = {\n ...processedConfig,\n sortBy: sorting?.field,\n order: sorting?.order,\n returnDates: true,\n returnObjects: true,\n activeness: {\n relation: relationActivityFilter || ActivityFilter.ALL,\n entity: activityFilter\n },\n max: rowsPerPage,\n offset: page * rowsPerPage,\n filter: addGlobalFilterToQuery(globalFilter, filter) || undefined,\n suggested: buildSuggestedIds(suggested)\n };\n const configs = [requestConfig].concat(\n ifElse(\n identity,\n pipe(wrapInArrayIfNeeded, (suggested) =>\n suggested.map((config, i) => ({...config, id: requestConfig.suggested[i]}))\n ),\n always([])\n )(suggested)\n );\n\n const request: (entity: Entity) => Promise<ConnectionResponse> = cond([\n [pipe(prop('uri'), isTempUri), () => Promise.resolve([{total: 0}])],\n [\n isDataTenantEntity,\n (entity) =>\n getRelationsForDataTenantEntity({\n entityUri: entity.uri,\n configs: configs,\n customerTenant: tenant,\n dataTenant: entity.dataTenant,\n dtssPath,\n options\n })\n ],\n [T, (entity) => getRelationsForEntity(entity.uri, configs, options)]\n ]);\n setIsLoading(true);\n safePromise(request(entity))\n .then(([{connections, total}]) => {\n dispatch(profile.relations.actions.relationsLoaded({id: config.id, connections, total}));\n })\n .finally(() => {\n setIsLoading(false);\n });\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [\n activityFilter,\n metadata,\n config,\n dispatch,\n dtssPath,\n entity?.uri,\n entity?.dataTenant,\n filter,\n globalFilter,\n page,\n relationActivityFilter,\n rowsPerPage,\n safePromise,\n sorting,\n tenant,\n options\n ]);\n const isRequestSentRef = useRef<boolean>(false);\n isRequestSentRef.current = false;\n useEffect(() => {\n isRequestSentRef.current = true;\n loadRelations();\n }, [loadRelations]);\n const prevMode = usePrevious(mode);\n useEffect(() => {\n if (mode === Mode.Viewing && !isRequestSentRef.current && prevMode !== mode) {\n isRequestSentRef.current = true;\n loadRelations();\n }\n }, [loadRelations, mode, prevMode]);\n return {isLoading, reload: loadRelations};\n};\n"],"names":["props","width","height","viewBox","xmlns","d","fill","fillRule","stroke","strokeWidth","useStyles","makeStyles","theme","color","palette","primary","main","closeIcon","position","right","bottom","transform","button","padding","FilterButton","enabled","onClick","styles","Tooltip","title","i18n","IconButton","classes","root","Filter","className","Close","propTypes","PropTypes","searchButton","marginLeft","marginRight","input","flex","fontSize","background","startAdornment","paddingLeft","ExpandableSearchInput","query","onChange","value","setValue","useState","isOpen","setIsOpen","useEffect","hasValue","length","Input","autoFocus","placeholder","disableUnderline","pipe","getValue","InputAdornment","Search","endAdornment","SmallIconButton","size","icon","CloseIcon","F","always","tap","onKeyPress","when","propEq","trim","T","EmptyStub","style","display","HideOnShrink","widthToHide","children","handleWidth","render","maxWidth","MAX_WIDTH_SELECT","paddingTop","paddingBottom","outlined","paddingRight","arrowIcon","top","text","secondary","currentValue","alignItems","currentValueIcon","currentValueText","lineHeight","textTransform","fontWeight","whiteSpace","textOverflow","overflow","menuItem","firstMenuItemButton","borderTop","menuItemInner","menuItemIcon","menuItemLabel","menuItemDescription","isButton","ModeSwitcherSelect","optionsGroup","buttonsGroup","disabled","Select","e","target","some","variant","renderValue","IconComponent","label","find","Box","Typography","MenuProps","anchorOrigin","vertical","horizontal","transformOrigin","getContentAnchorEl","items","firstButtonIdx","findIndex","map","item","idx","description","menuItemProps","classnames","MenuItem","key","renderMenuItems","flexDirection","profileCardWrapper","gap","profileCardContainer","flexGrow","rulesContainer","marginBottom","ProfileMatchCard","entitiesMap","entity","match","metadata","ProfileCard","object","container","matchRules","MatchRulesBlock","editor","overflowX","letterSpacing","margin","dense","actionButtons","justifyContent","backgroundColor","RelationEditor","connection","modifiedEntity","initialConnection","initialModifiedEntity","allModifiedEntities","dispatch","config","mode","globalSearchRequestOptions","error","highlightedError","relationUri","relationType","direction","relation","isNew","ref","errorClassName","useScrollToAttributeError","isSimple","inRelations","inRelationTypes","outRelations","outRelationTypes","useMemo","getInOutRelations","content","parentEntityUri","contentSecondLevel","firstLevelRelationAttrTypes","getRelationAttributesList","attributeListEntity","attributes","profile","getActivenessAttributes","relatedTempEntities","findRelatedTemporaryEntities","relatedTempEntitiesUrisHistory","useRef","setInitialInfo","useCallback","id","current","concat","prop","uniq","initialRelatedTempEntities","defaultRelationType","getDefaultRelationTypeObject","hasChanges","equals","pick","initial","actual","_","i","isEmptyValue","path","applyAction","onRelationTypeChange","handleClose","updateModifiedEntityLabel","entityType","getEntityType","type","updateConnectionEntityLabel","setModifiedEntity","deleteModifiedEntity","entityUri","onChangeEntity","uri","getErrorId","validate","errors","validateConnection","resetErrors","onApply","omitMarks","omit","differenceWith","forEach","onCancel","initialTempEntities","onAddAttributes","params","param","viewId","onChangeAttribute","onDeleteAttribute","onCreateEntity","entityTypeUri","initValue","newEntityAttrTypes","relationEditorAttributeTypesSelectionStrategy","getCreatableAttributeTypes","newEntity","createTemporaryEntity","attributeTypes","errorMessage","getErrorMessage","getEntityTypesUris","entityTypes","ConnectionRelationTypeSelector","Boolean","ErrorWrapper","EntitySelector","isTempUri","entityTypesUris","max","onCreate","attributeTypesSelectionStrategy","AttributesList","attrTypes","showEmptyEditors","crosswalks","parentUri","Button","Divider","ConnectionType","EntityType","RelationsConfigType","MetadataType","AttributeErrorType","withContext","ScrollToErrorContext","contextValue","allPass","connect","state","ownProps","getConnectionRelationUri","isTempEntity","mdmModule","getRelationEditorActiveError","reltioLayoutItemToReactGridLayoutItem","x","y","minWidth","minHeight","maxHeight","isStatic","w","h","minW","minH","maxW","maxH","static","reactGridLayoutItemToReltioLayoutItem","reactGridLayoutToReltioLayout","layout","getReltioLayoutItemById","curry","updateExtraPropsInLayoutItem","from","to","mergeAll","copyPropsFromPreviousLayout","oldReltioLayout","reltioLayout","layoutItem","defaultTo","__","gridLayout","border","borderRadius","transitionDuration","zIndex","userSelect","transitionProperty","willChange","pointerEvents","transition","backgroundImage","svg2Url","backgroundRepeat","backgroundOrigin","boxSizing","cursor","visibility","gridFullscreen","overflowY","ReltioGridLayout","views","layoutOptions","onLayoutChanged","draggableHandle","LayoutItem","onRemove","onDrop","droppingItem","isDroppable","fullscreenItemId","setFullscreenItemId","setWidth","cols","rowHeight","processedLayout","reltioLayoutToReactGridLayout","onReltioLayoutChanged","onToggleFullscreen","prevId","isFullscreenEnabled","onItemHeightResize","layoutId","isLayoutChanged","newLayout","newHeight","options","Math","ceil","calcHeight","refreshMode","refreshRate","onResize","innerRef","autoSize","onLayoutChange","isResizable","isDraggable","isItemFullscreen","autosizeComponent","autosizing","AutosizeComponent","layoutItemId","handleHeight","layoutItemConfig","fullscreen","isFullscreen","defaultProps","onConfigChanged","identity","memo","MapControlContainer","controlElement","setControlElement","controlDiv","document","createElement","divIndex","controls","push","removeAt","classList","add","createPortal","opacity","xmlnsXlink","xlinkHref","mask","fillOpacity","ButtonWithTooltip","withTooltip","TopRightMapControls","drawingMode","drawingModes","hasActiveOverlay","onDrawingModeChanged","onClearOverlay","changeDrawingModeTo","tooltipTitle","HighlightOff","Icon","MAP_DRAWING_MODES","RadiusIcon","DrawIcon","getIcon","alignSelf","checkbox","TopCenterMapControls","isSearchOnMapMove","onChangeIsSearchOnMapMove","FormControlLabel","control","Checkbox","checked","event","getMapBoundsPolygon","bounds","getBounds","ne","getNorthEast","sw","getSouthWest","neLat","lat","neLng","lng","swLat","swLng","additionalPoint1","additionalPoint2","center","getCenter","getDrawingMode","window","google","maps","drawing","OverlayType","CIRCLE","POLYGON","fitMapBoundsForOverlay","overlay","existingBounds","LatLngBounds","extend","LatLng","fitBounds","popper","boxShadow","hoveredMarkerIcon","markerIcon","marker","otherProps","popperAnchor","hovered","setHovered","activeEntityUri","useContext","EntityMarkerContext","isActive","pathEq","point","setHoveredDebounced","debounce","onMouseOver","onMouseOut","handleClick","Popper","anchorEl","open","modal","placement","url","scaledSize","Size","visible","alignBottom","pane","pixelOffset","closeBoxURL","enableEventPropagation","disableAutoPan","mapControlContainer","libraries","ReltioMap","markers","mapKey","defaultZoom","defaultCenter","loadingElement","isSearchEnabled","activeOverlay","overlayOptions","markerClusterer","markerClustererOptions","mapOptions","mapContainerClassName","onMapBoundsChanged","onOverlayUpdated","onMarkerClicked","isLoaded","loadError","useJsApiLoader","googleMapsApiKey","mapMoveEndTimer","setMap","polygon","setPolygon","setDrawingMode","prevMarkers","usePrevious","prevActiveOverlay","apiIsLoaded","MAP_MINIMUM_SCALE_RADIUS","fitMapBoundsForMarkers","useFitMapBounds","allOverlayOptions","DEFAULT_OVERLAY_OPTIONS","googleMapOptions","DEFAULT_GOOGLE_MAP_OPTIONS","handleChangeIsSearchOnMapMove","clearTimeout","handleMapMoveStart","handleMapMoveEnd","handleMapIdle","setTimeout","handleOverlayChange","propOverlay","stateOverlay","isEmpty","typeActions","getPath","getArray","latlng","radius","getRadius","data","handleOverlayComplete","handleClearOverlay","renderMarkers","clusterer","filter","mapTypeId","MapTypeId","ROADMAP","onLoad","zoom","onZoomChanged","onDragStart","onIdle","ControlPosition","TOP_RIGHT","TOP_CENTER","editable","onMouseUp","onDragEnd","onPolygonComplete","onCircleComplete","drawingControl","circleOptions","polygonOptions","VerticalDivider","borderLeft","flexShrink","defaultHistoryDiff","appearance","roles","tags","fixRefEntity","evolve","refEntity","wrapInArrayIfNeeded","refRelation","prepareHistorySlice","historySlice","useHistoryDiff","useDispatch","useSelector","historyDiff","historyMode","aEntity","bEntity","History","computeEntityHistoryDiff","HistoryMode","card","borderBottom","withBackground","lineWrapper","left","line","info","wordWrap","commentsInfo","marginTop","commentsIcon","infoValue","infoBlock","header","caption","flag","date","mainInfo","controlsBox","controlsInRow","priority","comments","dueDate","dueDateInput","inputLabel","taskId","isTaskOpen","updateDueDate","updateRequestIsInProgress","readOnly","updateTaskState","WorkflowTasksContext","workflowPath","environment","tenant","safePromise","useSafePromise","setUpdateRequestIsInProgress","canUpdateTask","useWorkflowCheckPermission","checkWorkflowPermission","isOpenTask","newValue","updateDueDateForTask","then","catch","showWorkflowError","finally","useWorkflowDueDate","DateEditor","getTime","InputProps","InputLabelProps","priorities","updatePriority","newPriority","updatePriorityForTask","WorkflowPriority","useWorkflowPriority","DropDownSelector","isDisabled","hideSelectedOptions","TextFieldProps","decorator","lineBlock","withLinePadding","noLine","plain","last","rowDivider","first","transparent","divider","light","taskToColor","COLORS","colorIndex","task","actions","assignee","createdBy","createTime","displayName","step","processDefinitionDisplayName","objectURIs","processInstanceComments","possibleActions","dcrId","getDCRId","hash","useWorkflowColor","isExpanded","setExpanded","canViewComments","Flag","CollapseButton","CollaborationIcon","TaskActions","AssigneeSelector","WorkflowComments","cx","cy","r","OperationTypes","DCRTypes","getOperationType","oldValue","CREATE_RELATIONSHIP","INSERT_ATTRIBUTE","ADDED","UPDATE_TAGS","UPDATE_ROLES","UPDATE_ATTRIBUTE","EDITED","DELETE_ATTRIBUTE","DELETE_RELATIONSHIP","DELETED","PIN_ATTRIBUTE","pin","PIN_DELETED","PINNED","IGNORE_ATTRIBUTE","ignored","IGNORE_DELETED","IGNORED","getOperationLabel","operation","getDataTypeDefinition","attributeType","attributeValue","DataTypes","isUrl","getAttrDataTypeDefinition","getValues","attrType","newAttrValues","pathOr","name","oldAttrValues","times","index","values","getEntityChanges","entityInfo","changes","getFilteredAttrTypes","getAttributesList","getRelationChanges","relationInfo","changeType","getRelationType","flatten","level","propOr","addRelationOperationIfNeeded","dcrAttributesFactory","complement","getNestedAttributeChange","getReferenceAttributeChange","isSpecialAttribute","is","Object","getSimpleAttributeValue","getSimpleAttributeChange","attributeTypeList","getAttributeTypeSubAttributes","getLabel","getDiffParameters","SPECIAL_ATTRIBUTES_NAMES","EntityAttrTypes","prepareStartOrEndDate","parseValue","isNaN","parseInt","isExistedValue","isExistNewValue","isExistOldValue","prepareRolesOrTags","change","getRoleLabel","diffNewValue","difference","diffOldValue","join","prepareAttribute","changePath","attributePath","refObjectURI","refAttributeType","generateTempUri","typePath","split","pathArray","holder","indexOf","isNil","createEntityOrRelation","startDate","endDate","defaultProfilePicValue","newObject","mergeAttributesInChange","objectInfo","UPDATE_PROFILE_PIC_BY_URL","UPDATE_START_DATE","UPDATE_END_DATE","CREATE_ENTITY","linkLabel","suggestionsCount","Link","component","underline","field","wordBreak","fieldName","arrow","chip","borderColor","ArrowRightAlt","Chip","AttributesChangesContext","React","linkContainer","textDecoration","disabledLink","objectsInfo","getLinkDescription","isReference","anyPass","hasPath","ifElse","currentEntityUri","objectLabel","objectUri","startObjectUri","endObjectUri","endObjectLabel","startObjectLabel","objectURI","getAttributeDescription","renderLink","isNotExist","isExist","EntityUriLink","changeLabel","attrValue","getAttributeValue","DataTypeValue","dataTypeDefinition","has","getSuggestionsCount","showMoreLink","relationsInfo","mergedEntityChanges","mergedRelationsChanges","getAttributeChanges","attributeName","concatChanges","getters","attributesTree","reduce","acc","getter","changesTree","result","relationsTrees","updateRelation","mergeChanges","changesList","relationshipTitle","onToggle","itemsToShow","collapsedSuggestionsCount","limit","setIsExpanded","collapsedItems","slice","visibleSuggestionsCount","useCollapsibleList","Provider","getEntityUriForLink","getEntitiesObjects","isEntityUri","getRelationsObjects","isRelationUri","getRelations","objectsWithChanges","createEntityRelationsObjectByEntity","relations","createEntityRelationsObjectByRelation","concatEntityRelationsObjects","mergedRelations","dcrUri","getDCRUri","dcr","groupedObjects","setGroupedObjects","setDcr","requestEntities","entityUris","Promise","resolve","getEntitiesByUris","searchOptions","defaultMaxValues","getDataChangeRequest","keys","extractObjectsFromChangeRequest","entityObjectsWithRelations","relationsObjects","relationsObjectsWithEntity","relationsObjectsWithoutEntity","partition","entities","relationsObjectsWithRequestedEntities","relationsObject","useChangeRequest","DcrTaskIcon","pmCard","defaultOptions","showTransitiveMatches","showInactiveEntities","matches","useMatchesLoader","rowsPerPage","Number","MAX_SAFE_INTEGER","page","includes","PmTaskIcon","WorkflowTaskCardsFactory","build","processType","PredefinedWorkflowProcessType","DeleteRequestTaskIcon","DefaultTaskIcon","WorkflowTaskCard","popoverPaper","simpleDropDownSelector","inputRoot","select","footer","cancelButton","AddWorkflowDialog","onClose","comment","setComment","taskType","setTaskType","isOpenSnackbar","setIsOpenSnackbar","definitions","setDefinitions","processDefinitions","manualStart","objectTypes","_entityType","filterDefinitions","useWorkflowDefinitions","processInstance","loading","loadTasks","setLoading","startProcessInstance","useWorkflowProcessInstance","Popover","paper","SimpleDropDownSelector","definition","TextField","hiddenLabel","multiline","Portal","body","Snackbar","autoHideDuration","message","buttonLabel","AddWorkflowButton","setAnchorEl","canStartProcess","canViewProcessDefinitions","currentTarget","Add","useWorkflowTasks","processTypes","showClosedTasks","isWorkflowEnabled","isEditableMode","canViewTasks","tasks","setTasks","total","setTotal","parsedProcessTypes","Array","isArray","requests","getTasksForEntity","includeClosed","all","responses","reject","uniqBy","isRequestedTask","console","warn","payload","mergeLeft","fillColor","strokeWeight","strokeColor","clickable","mapTypeControl","streetViewControl","fullscreenControl","InterceptHandlersContext","ProfilePerspectiveViewContext","SandboxAPIContext","getCurrentPerspectiveId","setEntityUri","showPerspective","getHeaders","async","signHandler","accessToken","headers","Authorization","validateParams","permissions","permission","urlOrigin","permRegex","RegExp","decodedPerm","replace","startsWith","test","processRequest","paramObject","worker","apiPath","servicesPath","user","openSearch","workflowCheckPermission","handleRequest","request","postMessage","action","status","isNewUI","getAccessToken","RequestAction","sendRequestFromCustomSandbox","method","noRequestProcessor","sendApiRequest","isExternalUrl","sendWorkflowRequest","workflowRequest","processDefinitionId","searchString","startProcessFromQuery","processFromQuery","response","listener","perspective","searchState","alert","confirm","prompt","defaultText","location","reload","getWorkerURL","uiPath","processInnerHtml","parent","setTooltip","handlersToReset","uiActions","getAttribute","uiTooltip","uiAction","handler","postEventMessage","files","readFilePromises","file","reader","FileReader","onload","lastModified","onerror","readAsArrayBuffer","getFilesWithArrayBuffer","addEventListener","removeEventListener","removeAttribute","childNodes","child","nodeType","resetHtml","innerText","html","setListenersToReset","setHtml","docBlock","innerHTML","isURLtoProcess","processApi","regExp","setUpQooxdooRequestInterceptor","workerRef","setRequestListeners","processApiRequest","next","requestId","nanoid","setUpQooxdooResponseInterceptor","setResponseListeners","processApiResponse","responseId","setUpRequestInterceptor","reltioPath","fakeURL","origin","setUpResponseInterceptor","abort","json","img","link","iframe","a","useHtmlSanitizer","allowedAttributes","allowedTags","sanitizeHtml","sanitizeOptions","allowVulnerableTags","useAPI","listenersToReset","popupListenersToReset","setPopupListenersToReset","setVisible","popup","setPopup","tooltip","customStyles","setCustomStyles","requestListeners","responseListeners","workerUrl","showSnackbarMessage","SnackbarContext","qxApi","interceptHandlers","typeSearch","search","searchQuery","isOldUI","supportedInterceptHandlers","interceptors","ui","popupText","process","CustomAction","sanitizedHtml","getElementById","sanitizedPopup","prev","log","qooxdooRequestInterceptor","qooxdooResponseInterceptor","requestInterceptor","responseInterceptor","platform","CustomScriptPlatform","initializeWebWorker","addInternalRequestInterceptor","addInternalResponseInterceptor","removeInternalRequestInterceptor","removeInternalResponseInterceptor","useCommentsEntitiesMap","mdm","setEntitiesMap","getEntities","entitiesUris","requestFilters","FilterOptions","requestOptions","activeness","ActivityFilters","getFilteredEntities","getNotFoundEntity","getEntity","addNotFoundEntities","notFoundEntities","uniqEntitiesUris","objectType","relatedObjectUris","results","getNotFoundUris","prevEntitiesMap","emptyArray","useConfigPermissions","userRoles","canCreate","checkConfigPermission","ConfigPermissions","canRead","canUpdate","canDelete","buildSuggestedIds","n","useRelationsLoader","sorting","relationActivityFilter","searchByOv","isLoading","setIsLoading","dtssPath","activityFilter","globalFilter","processContent","getUri","isObject","filterRelation","isAvailableRelationTypeUri","filterFn","isAvailableEntityTypeUri","nextEntry","suggested","loadRelations","requestConfig","sortBy","order","returnDates","returnObjects","ActivityFilter","offset","addGlobalFilterToQuery","undefined","configs","cond","isDataTenantEntity","getRelationsForDataTenantEntity","customerTenant","dataTenant","getRelationsForEntity","connections","isRequestSentRef","prevMode","Mode"],"sourceRoot":""}
1
+ {"version":3,"file":"99.js","mappings":"uaAEA,MAQA,EAR4DA,GAEpD,2BAAKC,MAAO,GAAIC,OAAQ,GAAIC,QAAQ,YAAYC,MAAM,8BAAiCJ,GACnF,0BAAMK,EAAE,4BAA4BC,KAAK,eAAeC,SAAS,UAAUC,OAAO,OAAOC,YAAa,KCHrGC,GAAYC,E,SAAAA,IAAYC,IAAD,CAChC,sBAAuB,CACnBC,MAAOD,EAAME,QAAQC,QAAQC,MAEjCC,UAAW,CACPC,SAAU,WACVC,MAAO,MACPC,OAAQ,MACRC,UAAW,cAEfC,OAAQ,CACJC,QAAS,YCJXC,EAAe,IAAwB,IAAvB,QAACC,EAAD,QAAUC,GAAa,EACzC,MAAMC,EAASjB,IAEf,OACI,kBAAC,EAAAkB,QAAD,CAASC,MAAOJ,EAAUK,IAAAA,KAAU,qBAAuBA,IAAAA,KAAU,WACjE,kBAAC,EAAAC,WAAD,CAAYL,QAASA,EAASM,QAAS,CAACC,KAAMN,EAAOL,SAChDG,EACG,oCACI,kBAACS,EAAD,CAAYC,UAAWR,EAAO,yBAC9B,kBAACS,EAAA,QAAD,CAAWvB,MAAM,UAAUsB,UAAWR,EAAOV,aAGjD,kBAACiB,EAAD,SAOpBV,EAAaa,UAAY,CACrBZ,QAASa,IAAAA,KACTZ,QAASY,IAAAA,MAGb,W,4JC/BO,MAAM5B,GAAYC,E,SAAAA,GAAW,CAChC4B,aAAc,CACVC,WAAY,kBACZC,YAAa,OACblB,QAAS,OAEbm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11B,GAAIo6B,EACJ7nB,IAAKgoB,EACLvE,OAAQvrB,EAAQurB,OAChBzf,KAAAA,OAGP8F,OAAOre,IACJ08B,EAAM18B,WAGd87B,EAAKpD,O,uICjNjB,MAqUA,GACIn3B,WAAY,CACR,IAAK,CAtUT,gBACA,aACA,WACA,qBACA,eACA,aACA,YACA,cACA,SACA,gBACA,gBACA,cACA,UACA,gBACA,iBACA,cACA,OACA,QACA,OACA,KACA,WACA,aACA,QACA,OACA,gBACA,YACA,YACA,QACA,sBACA,8BACA,gBACA,kBACA,oBACA,mBACA,SACA,KACA,KACA,IACA,aACA,UACA,kBACA,YACA,UACA,UACA,oBACA,MACA,KACA,KACA,WACA,YACA,oBACA,MACA,WACA,4BACA,OACA,eACA,YACA,SACA,YACA,cACA,cACA,gBACA,cACA,YACA,mBACA,eACA,aACA,eACA,cACA,SACA,OACA,KACA,KACA,KACA,KACA,aACA,+BACA,6BACA,WACA,oBACA,gBACA,UACA,SACA,cACA,iBACA,KACA,cACA,kBACA,KACA,MACA,YACA,IACA,KACA,KACA,KACA,KACA,eACA,mBACA,UACA,YACA,aACA,WACA,OACA,eACA,iBACA,iBACA,oBACA,QACA,aACA,aACA,eACA,eACA,cACA,cACA,OACA,mBACA,YACA,eACA,MACA,QACA,SACA,MACA,OACA,OACA,aACA,SACA,UACA,WACA,QACA,SACA,cACA,SACA,WACA,oBACA,qBACA,WACA,cACA,OACA,aACA,sBACA,mBACA,eACA,iBACA,SACA,YACA,YACA,YACA,gBACA,sBACA,iBACA,IACA,SACA,OACA,OACA,mBACA,cACA,YACA,qBACA,mBACA,UACA,SACA,SACA,KACA,KACA,QACA,OACA,kBACA,QACA,UACA,mBACA,mBACA,QACA,eACA,cACA,eACA,QACA,QACA,cACA,aACA,eACA,yBACA,0BACA,SACA,SACA,mBACA,oBACA,iBACA,kBACA,oBACA,iBACA,eACA,QACA,eACA,iBACA,cACA,SACA,UACA,UACA,cACA,kBACA,iBACA,aACA,KACA,YACA,OACA,KACA,KACA,qBACA,sBACA,UACA,eACA,gBACA,eACA,eACA,YACA,gBACA,iBACA,SACA,UACA,aACA,gBACA,gBACA,UACA,aACA,aACA,QACA,SACA,eACA,eACA,IACA,WACA,KACA,KACA,mBACA,IACA,KACA,KACA,mBACA,IACA,aAuFgC,aAAc,cAC1Cq7B,IAAK,CAAC,MAAO,SAAU,MAAO,QAAS,WACvCC,KAAM,CAAC,OAAQ,OACfC,OAAQ,CAAC,OACTC,EAAG,CAAC,SAERziB,KAAM,CAzFN,UACA,eACA,gBACA,mBACA,QACA,MACA,SACA,UACA,OACA,UACA,WACA,OACA,OACA,QACA,IACA,SACA,OACA,gBACA,UACA,MACA,SACA,SACA,OACA,YACA,mBACA,iBACA,gBACA,gBACA,QACA,QACA,iBACA,iBACA,OACA,SACA,UACA,QACA,OACA,OACA,UACA,WACA,OACA,OACA,MACA,iBACA,eACA,cACA,SACA,UACA,OACA,OACA,UACA,WACA,OACA,OACA,IACA,MACA,SACA,MACA,WACA,cACA,eACA,QACA,WACA,WACA,OACA,OACA,QACA,WACA,WACA,OACA,QACA,WACA,gBACA,SACA,SACA,gBACA,SACA,QACA,OAWuB,IAAK,OAAQ,QAAS,SAAU,SAAU,Q,wcC1U9D,MAAM0iB,EAAmB,KAC5B,MAAM,kBAACC,EAAD,YAAoBC,GAAeC,IAAAA,UACnC,WAAC57B,EAAD,KAAa+Y,GAAQ8iB,EACrB3wB,EAAoB,CACtBywB,YAAaA,EAAYh7B,OAAOoY,GAChC2iB,kBAAmB,EAAF,GAAMA,EAAsB17B,GAC7C87B,qBAAqB,GAEzB,OAAQnC,GAAiBiC,GAAAA,CAAajC,EAAMzuB,I,mgBCqBzC,MAAM6wB,EAAS,WAAmC,YAAlCz9B,EAAkC,uDAAjB,GACpC,MAAOq7B,EAAME,IAAWvjC,EAAAA,EAAAA,aACjB0lC,EAAkBpC,IAAuBtjC,EAAAA,EAAAA,UAA4B,KACrE2lC,EAAuBC,IAA4B5lC,EAAAA,EAAAA,UAA4B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O2lC,WACnB1B,SAAAA,EACA91B,QAAAA,KAGZ,CAAClT,EAAAA,EAAI+E,IAAW4lC,EAAAA,EAAAA,KAAsB5lC,EAAOuF,IAAK+/B,EAASn3B,MAE/D61B,GAAa,GACb3kB,EAAY6Z,EAAQl5B,IACf8f,MAAK,IAA4B,KAA1B,YAAC+lB,EAAD,MAAclQ,IAAY,EAC9Br0B,EAAS4B,EAAAA,GAAAA,UAAAA,QAAAA,gBAA0C,CAACQ,GAAInC,EAAOmC,GAAImiC,YAAAA,EAAalQ,MAAAA,QAEnF1V,SAAQ,KACL+jB,GAAa,SAI1B,CACCE,EACAhkC,EACAqB,EACAD,EACA2iC,EACAjkC,MAAAA,OAND,EAMCA,EAAQuF,IACRvF,MAAAA,OAPD,EAOCA,EAAQ2lC,WACRrrB,EACA6pB,EACAzS,EACAmS,EACAtS,EACAlS,EACAukB,EACAxkB,EACAjR,IAEE23B,GAAmBviC,EAAAA,EAAAA,SAAgB,GACzCuiC,EAAiBniC,SAAU,GAC3BjK,EAAAA,EAAAA,YAAU,KACNosC,EAAiBniC,SAAU,EAC3BkhC,MACD,CAACA,IACJ,MAAMkB,GAAWxtB,EAAAA,EAAAA,GAAY/W,GAO7B,OANA9H,EAAAA,EAAAA,YAAU,KACF8H,IAASwkC,EAAAA,IAAAA,SAAiBF,EAAiBniC,SAAWoiC,IAAavkC,IACnEskC,EAAiBniC,SAAU,EAC3BkhC,OAEL,CAACA,EAAerjC,EAAMukC,IAClB,CAAChC,UAAAA,EAAWlJ,OAAQgK,K","sources":["webpack://@reltio/remotes/../components/src/icons/Filter.tsx","webpack://@reltio/remotes/../components/src/components/BasicTableView/BasicTableHeader/FilterButton/styles.js","webpack://@reltio/remotes/../components/src/components/BasicTableView/BasicTableHeader/FilterButton/FilterButton.js","webpack://@reltio/remotes/../components/src/components/ExpandableSearchInput/styles.ts","webpack://@reltio/remotes/../components/src/components/ExpandableSearchInput/ExpandableSearchInput.tsx","webpack://@reltio/remotes/../components/src/components/HideOnShrink/HideOnShrink.js","webpack://@reltio/remotes/../components/src/components/ModeSwitcherSelect/styles.ts","webpack://@reltio/remotes/../components/src/components/ModeSwitcherSelect/ModeSwitcherSelect.tsx","webpack://@reltio/remotes/../components/src/components/ProfileMatchCard/styles.ts","webpack://@reltio/remotes/../components/src/components/ProfileMatchCard/ProfileMatchCard.tsx","webpack://@reltio/remotes/../components/src/components/RelationEditor/styles.js","webpack://@reltio/remotes/../components/src/components/RelationEditor/RelationEditor.js","webpack://@reltio/remotes/../components/src/components/RelationEditor/index.js","webpack://@reltio/remotes/../components/src/components/ReltioGridLayout/helpers.js","webpack://@reltio/remotes/../components/src/components/ReltioGridLayout/icons/ResizeIcon.svg.ts","webpack://@reltio/remotes/../components/src/components/ReltioGridLayout/styles.js","webpack://@reltio/remotes/../components/src/components/ReltioGridLayout/ReltioGridLayout.js","webpack://@reltio/remotes/../components/src/components/ReltioMap/MapControls/MapControlContainer/MapControlContrainer.tsx","webpack://@reltio/remotes/../components/src/icons/Radius.tsx","webpack://@reltio/remotes/../components/src/icons/Draw.tsx","webpack://@reltio/remotes/../components/src/components/ReltioMap/MapControls/TopRightMapControls/styles.ts","webpack://@reltio/remotes/../components/src/components/ReltioMap/MapControls/TopRightMapControls/TopRightMapControls.tsx","webpack://@reltio/remotes/../components/src/components/ReltioMap/MapControls/TopCenterMapControls/styles.ts","webpack://@reltio/remotes/../components/src/components/ReltioMap/MapControls/TopCenterMapControls/TopCenterMapControls.tsx","webpack://@reltio/remotes/../components/src/components/ReltioMap/helpers/index.ts","webpack://@reltio/remotes/../components/src/components/ReltioMap/EntityMarker/icons/marker.inline.svg.ts","webpack://@reltio/remotes/../components/src/components/ReltioMap/EntityMarker/styles.ts","webpack://@reltio/remotes/../components/src/components/ReltioMap/EntityMarker/EntityMarker.tsx","webpack://@reltio/remotes/../components/src/components/ReltioMap/EntityMarker/icons/marker-hover.inline.svg.ts","webpack://@reltio/remotes/../components/src/components/ReltioMap/styles.ts","webpack://@reltio/remotes/../components/src/components/ReltioMap/index.tsx","webpack://@reltio/remotes/../components/src/components/VerticalDivider/VerticalDivider.js","webpack://@reltio/remotes/../components/src/components/history/hooks/useHistoryDiff.ts","webpack://@reltio/remotes/../components/src/components/workflow/cards/GenericWorkflowTaskCard/styles.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/DueDateField/styles.ts","webpack://@reltio/remotes/../components/src/components/workflow/hooks/useWorkflowDueDate.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/DueDateField/DueDateField.tsx","webpack://@reltio/remotes/../components/src/components/workflow/hooks/useWorkflowPriority.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/PrioritySelector/PrioritySelector.tsx","webpack://@reltio/remotes/../components/src/components/workflow/components/LineDecorator/styles.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/LineDecorator/LineDecorator.tsx","webpack://@reltio/remotes/../components/src/components/workflow/hooks/useWorkflowColor.ts","webpack://@reltio/remotes/../components/src/icons/CollaborationIcon.tsx","webpack://@reltio/remotes/../components/src/components/workflow/cards/GenericWorkflowTaskCard/GenericWorkflowTaskCard.tsx","webpack://@reltio/remotes/../components/src/icons/DcrTaskIcon.tsx","webpack://@reltio/remotes/../components/src/components/workflow/constants/operations.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/helpers/helpers.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/helpers/attributesHelpers.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/helpers/mergeHelpers.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/components/ShowMoreLink/styles.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/components/ShowMoreLink/ShowMoreLink.tsx","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/components/ChangeView/styles.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/components/ChangeView/ChangeView.tsx","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/contexts/AttributesChangesContext.tsx","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/components/DiffRenderer/styles.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/components/DiffRenderer/DiffRenderer.tsx","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/components/DCRChangesList/styles.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/components/DCRChangesList/DCRChangesList.tsx","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/helpers/contextHelpers.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/styles.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/AttributesChanges.tsx","webpack://@reltio/remotes/../components/src/components/workflow/components/AttributesChanges/hooks/useCollapsibleList.ts","webpack://@reltio/remotes/../components/src/components/workflow/helpers/dcrHelpers.ts","webpack://@reltio/remotes/../components/src/components/workflow/hooks/useChangeRequest.ts","webpack://@reltio/remotes/../components/src/components/workflow/cards/DataChangeRequestTaskCard/DataChangeRequestTaskCard.tsx","webpack://@reltio/remotes/../components/src/components/workflow/cards/PotentialMatchTaskCard/styles.ts","webpack://@reltio/remotes/../components/src/icons/PmTaskIcon.tsx","webpack://@reltio/remotes/../components/src/components/workflow/cards/PotentialMatchTaskCard/PotentialMatchTaskCard.tsx","webpack://@reltio/remotes/../components/src/icons/DefaultTaskIcon.tsx","webpack://@reltio/remotes/../components/src/icons/DeleteRequestTaskIcon.tsx","webpack://@reltio/remotes/../components/src/components/workflow/cards/WorkflowTaskCardsFactory.tsx","webpack://@reltio/remotes/../components/src/components/workflow/cards/WorkflowTaskCard.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AddWorkflowDialog/styles.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AddWorkflowDialog/AddWorkflowDialog.tsx","webpack://@reltio/remotes/../components/src/components/workflow/hooks/useWorkflowDefinitions.ts","webpack://@reltio/remotes/../components/src/components/workflow/hooks/useWorkflowProcessInstance.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AddWorkflowButton/styles.ts","webpack://@reltio/remotes/../components/src/components/workflow/components/AddWorkflowButton/AddWorkflowButton.tsx","webpack://@reltio/remotes/../components/src/components/workflow/hooks/useWorkflowTasks.ts","webpack://@reltio/remotes/../components/src/constants/map.ts","webpack://@reltio/remotes/../components/src/contexts/EntityMarkerContext/index.ts","webpack://@reltio/remotes/../components/src/contexts/InterceptHandlersContext/index.ts","webpack://@reltio/remotes/../components/src/contexts/ProfilePerspectiveViewContext/index.ts","webpack://@reltio/remotes/../components/src/contexts/SandboxAPIContext/index.ts","webpack://@reltio/remotes/../components/src/hooks/useAPI/API.ts","webpack://@reltio/remotes/../components/src/hooks/useAPI/helpers.ts","webpack://@reltio/remotes/../components/src/hooks/helpers/sanitizerOptions.ts","webpack://@reltio/remotes/../components/src/hooks/useHtmlSanitizer.ts","webpack://@reltio/remotes/../components/src/hooks/useAPI/useAPI.ts","webpack://@reltio/remotes/../components/src/hooks/useCommentsEntitiesMap.ts","webpack://@reltio/remotes/../components/src/hooks/useConfigPermissions.ts","webpack://@reltio/remotes/../components/src/hooks/useRelationsLoader.ts"],"sourcesContent":["import React from 'react';\n\nconst SvgFilter: React.FC<React.SVGProps<SVGSVGElement>> = (props) => {\n return (\n <svg width={18} height={18} viewBox=\"0 0 18 18\" xmlns=\"http://www.w3.org/2000/svg\" {...props}>\n <path d=\"M18 2V0H0v2l7 8v8l4-2v-6z\" fill=\"currentColor\" fillRule=\"nonzero\" stroke=\"none\" strokeWidth={1} />\n </svg>\n );\n};\n\nexport default SvgFilter;\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles((theme) => ({\n 'filterIcon--enabled': {\n color: theme.palette.primary.main\n },\n closeIcon: {\n position: 'absolute',\n right: '3px',\n bottom: '3px',\n transform: 'scale(0.5)'\n },\n button: {\n padding: '11px'\n }\n}));\n","import React from 'react';\nimport PropTypes from 'prop-types';\nimport i18n from 'ui-i18n';\nimport {IconButton as IconButton} from '@material-ui/core';\nimport CloseIcon from '@material-ui/icons/Close';\nimport {Tooltip as Tooltip} from '@material-ui/core';\nimport FilterIcon from '../../../../icons/Filter';\nimport {useStyles} from './styles';\n\nconst FilterButton = ({enabled, onClick}) => {\n const styles = useStyles();\n\n return (\n <Tooltip title={enabled ? i18n.text('Clear all filters') : i18n.text('Filter')}>\n <IconButton onClick={onClick} classes={{root: styles.button}}>\n {enabled ? (\n <>\n <FilterIcon className={styles['filterIcon--enabled']} />\n <CloseIcon color=\"primary\" className={styles.closeIcon} />\n </>\n ) : (\n <FilterIcon />\n )}\n </IconButton>\n </Tooltip>\n );\n};\n\nFilterButton.propTypes = {\n enabled: PropTypes.bool,\n onClick: PropTypes.func\n};\n\nexport default FilterButton;\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles({\n searchButton: {\n marginLeft: 'auto !important',\n marginRight: '-4px',\n padding: '8px'\n },\n input: {\n flex: '1 0 200px',\n marginLeft: '70px',\n fontSize: '14px',\n background: 'rgba(0,0,0,0.03) 2px',\n padding: '4px 0',\n marginRight: '4px'\n },\n startAdornment: {\n color: 'rgba(0,0,0,0.54)',\n paddingLeft: '8px'\n }\n});\n","import React, {useState, useEffect} from 'react';\nimport i18n from 'ui-i18n';\nimport {always, F, pipe, propEq, T, tap, trim, when} from 'ramda';\nimport CloseIcon from '@material-ui/icons/Close';\nimport {IconButton as IconButton} from '@material-ui/core';\nimport {Input as Input} from '@material-ui/core';\nimport {InputAdornment as InputAdornment} from '@material-ui/core';\nimport SearchIcon from '@material-ui/icons/Search';\nimport {SmallIconButton} from '../SmallIconButton';\nimport {getValue} from '../../core';\n\nimport {useStyles} from './styles';\n\ntype Props = {\n query: string;\n onChange: (value: string) => void;\n};\n\nexport const ExpandableSearchInput = ({query, onChange}: Props) => {\n const [value, setValue] = useState(query);\n const [isOpen, setIsOpen] = useState(!!query);\n useEffect(() => {\n setValue(query);\n }, [query]);\n const styles = useStyles();\n const hasValue = value && value.length;\n\n return isOpen ? (\n <Input\n className={styles.input}\n value={value}\n autoFocus={true}\n placeholder={i18n.text('Search')}\n disableUnderline={true}\n onChange={pipe(getValue, setValue)}\n startAdornment={\n <InputAdornment position=\"start\">\n <SearchIcon className={styles.startAdornment} />\n </InputAdornment>\n }\n endAdornment={\n <InputAdornment position=\"end\">\n {hasValue && (\n <SmallIconButton\n size=\"S\"\n icon={CloseIcon}\n onClick={pipe(F, setIsOpen, always(''), tap(onChange), setValue)}\n />\n )}\n </InputAdornment>\n }\n onKeyPress={when(propEq('key', 'Enter'), pipe(always(value), trim, onChange))}\n />\n ) : (\n <IconButton className={styles.searchButton} onClick={pipe(T, setIsOpen)}>\n <SearchIcon />\n </IconButton>\n );\n};\n","import PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactResizeDetector from 'react-resize-detector';\n\nconst EmptyStub = () => <div style={{display: 'none'}} />;\n\nconst HideOnShrink = ({widthToHide, children}) => (\n <ReactResizeDetector\n handleWidth={true}\n render={({width}) => (width > widthToHide ? <>{children}</> : <EmptyStub />)}\n />\n);\n\nHideOnShrink.propTypes = {\n children: PropTypes.node,\n widthToHide: PropTypes.number.isRequired\n};\n\nexport default HideOnShrink;\n","import {makeStyles} from '@material-ui/core/styles';\n\nconst MAX_WIDTH_SELECT = 200;\nconst SELECT_PADDING_RIGHT = 32;\nconst SELECT_PADDING_LEFT = 12;\nconst CALCULATED_MAX_WIDTH_SELECT = MAX_WIDTH_SELECT - SELECT_PADDING_LEFT - SELECT_PADDING_RIGHT;\n\nexport const useStyles = makeStyles((theme) => ({\n root: {\n maxWidth: CALCULATED_MAX_WIDTH_SELECT,\n paddingTop: '9px',\n paddingBottom: '9px'\n },\n outlined: {\n paddingRight: SELECT_PADDING_RIGHT,\n paddingLeft: SELECT_PADDING_LEFT\n },\n arrowIcon: {\n fontSize: '18px',\n top: 'calc(50% - 9px)',\n right: '12px',\n color: theme.palette.text.secondary\n },\n currentValue: {\n display: 'flex',\n alignItems: 'center'\n },\n currentValueIcon: {\n fontSize: '18px',\n marginRight: '8px',\n color: theme.palette.text.secondary\n },\n currentValueText: {\n fontSize: '14px',\n lineHeight: '16px',\n textTransform: 'uppercase',\n fontWeight: 500,\n color: theme.palette.text.primary,\n whiteSpace: 'nowrap',\n textOverflow: 'ellipsis',\n overflow: 'hidden'\n },\n menuItem: {\n padding: '9px 12px 7px'\n },\n firstMenuItemButton: {\n borderTop: '1px solid #e4e4e4'\n },\n menuItemInner: {\n display: 'flex',\n alignItems: 'flex-start'\n },\n menuItemIcon: {\n fontSize: '18px',\n color: theme.palette.text.secondary,\n marginRight: '9px'\n },\n menuItemLabel: {\n fontSize: '14px',\n lineHeight: '16px',\n fontWeight: 500,\n color: theme.palette.text.primary\n },\n menuItemDescription: {\n fontSize: '10px',\n lineHeight: '16px',\n color: theme.palette.text.secondary\n }\n}));\n","import React from 'react';\nimport {propEq} from 'ramda';\nimport classnames from 'classnames';\nimport {Select as Select} from '@material-ui/core';\nimport {MenuItem as MenuItem} from '@material-ui/core';\nimport {Box as Box} from '@material-ui/core';\nimport {Typography as Typography} from '@material-ui/core';\nimport {Tooltip as Tooltip} from '@material-ui/core';\nimport {useStyles} from './styles';\n\ntype Option = {\n label: string;\n value: string;\n description: string;\n icon: React.ElementType;\n};\n\ntype Button = Option & {\n onClick: (value: string) => void;\n};\n\ntype ModeSwitcherSelectProps = {\n optionsGroup: Option[];\n buttonsGroup: Button[];\n value: string;\n onChange?: (value: string) => void;\n disabled?: boolean;\n};\n\ntype MenuItemProps = React.ComponentPropsWithoutRef<typeof MenuItem>;\n\nconst isButton = (value: Option | Button): value is Button => 'onClick' in value;\n\nexport const ModeSwitcherSelect = ({\n optionsGroup,\n buttonsGroup,\n value,\n onChange,\n disabled = false\n}: ModeSwitcherSelectProps) => {\n const styles = useStyles();\n\n const handleChange = (e: React.ChangeEvent<{value: string}>) => {\n const {value} = e.target;\n const isOption = optionsGroup.some(propEq('value', value));\n if (isOption) onChange(value);\n };\n\n const renderMenuItems = (items: (Option | Button)[]) => {\n const firstButtonIdx = items.findIndex(isButton);\n\n return items.map((item, idx) => {\n const {value, description, icon: IconComponent} = item;\n\n const menuItemProps: MenuItemProps = {\n value: value,\n className: styles.menuItem\n };\n\n if (isButton(item)) {\n menuItemProps.onClick = () => item.onClick(value);\n menuItemProps.className = classnames(menuItemProps.className, {\n [styles.firstMenuItemButton]: idx === firstButtonIdx\n });\n }\n\n return (\n <MenuItem key={value} {...menuItemProps} data-reltio-id={`reltio-profile-select-mode-${value}`}>\n <Box className={styles.menuItemInner}>\n <IconComponent className={styles.menuItemIcon} />\n <Box>\n <Typography className={styles.menuItemLabel}>{value}</Typography>\n <Typography className={styles.menuItemDescription}>{description}</Typography>\n </Box>\n </Box>\n </MenuItem>\n );\n });\n };\n\n return (\n <Select\n classes={{\n root: styles.root,\n icon: styles.arrowIcon,\n outlined: styles.outlined\n }}\n value={value}\n onChange={handleChange}\n variant=\"outlined\"\n renderValue={(value) => {\n const {icon: IconComponent, label = value} = optionsGroup.find(propEq('value', value)) || {};\n return (\n <Box className={styles.currentValue}>\n {IconComponent && <IconComponent className={styles.currentValueIcon} />}\n <Tooltip title={label}>\n <Typography className={styles.currentValueText}>{label}</Typography>\n </Tooltip>\n </Box>\n );\n }}\n MenuProps={{\n anchorOrigin: {\n vertical: 'bottom',\n horizontal: 'right'\n },\n transformOrigin: {\n vertical: 'top',\n horizontal: 'right'\n },\n getContentAnchorEl: null\n }}\n disabled={disabled}\n data-reltio-id=\"reltio-profile-select-mode\"\n >\n {renderMenuItems([...optionsGroup, ...buttonsGroup])}\n </Select>\n );\n};\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles({\n root: {\n display: 'flex',\n flexDirection: 'column',\n paddingRight: '12px',\n paddingTop: '8px',\n paddingBottom: '8px',\n '& + &': {\n borderTop: '1px solid rgba(0,0,0, 0.12)'\n }\n },\n profileCardWrapper: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n gap: '4px'\n },\n profileCardContainer: {\n flexGrow: 1,\n paddingBottom: '8px',\n paddingTop: '8px'\n },\n rulesContainer: {\n paddingLeft: '52px',\n marginBottom: '8px'\n }\n});\n","import React from 'react';\nimport {Entity, Metadata, Match} from '@reltio/mdm-sdk';\nimport {useStyles} from './styles';\nimport ProfileCard from '../ProfileCard/ProfileCard';\nimport MatchRulesBlock from '../MatchRulesBlock/MatchRulesBlock';\nimport classnames from 'classnames';\n\ntype Props = {\n entitiesMap: {\n [key: string]: Pick<Entity, 'uri' | 'type' | 'label'>;\n };\n entity: Entity;\n match: Match;\n metadata: Metadata;\n children?: React.ReactNode;\n className?: string;\n};\n\nexport const ProfileMatchCard = ({children, entitiesMap, entity, match, metadata, className}: Props) => {\n const styles = useStyles();\n return (\n <div className={classnames(styles.root, className)}>\n <div className={styles.profileCardWrapper}>\n <ProfileCard entity={match.object} classes={{container: styles.profileCardContainer}} />\n {children}\n </div>\n <div className={styles.rulesContainer}>\n {match.matchRules && (\n <MatchRulesBlock match={match} metadata={metadata} entitiesMap={entitiesMap} entity={entity} />\n )}\n </div>\n </div>\n );\n};\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles({\n editor: {\n display: 'flex',\n flexDirection: 'column',\n padding: '0 24px 5px',\n overflowX: 'hidden'\n },\n title: {\n color: 'rgba(0, 0, 0, 0.6)',\n fontSize: '16px',\n letterSpacing: '0.15px',\n lineHeight: '24px',\n margin: '17px 0 24px'\n },\n item: {\n marginBottom: '20px'\n },\n dense: {\n marginBottom: 0\n },\n actionButtons: {\n display: 'flex',\n justifyContent: 'flex-end',\n margin: '0 8px 10px',\n\n '& > button': {\n fontSize: '14px',\n lineHeight: '16px',\n marginLeft: '8px',\n padding: '10px 8px',\n backgroundColor: 'rgba(98, 2, 238, 0)'\n }\n }\n});\n","import React, {useCallback, useEffect, useMemo, useRef} from 'react';\nimport i18n from 'ui-i18n';\nimport PropTypes from 'prop-types';\nimport classnames from 'classnames';\nimport {\n allPass,\n always,\n concat,\n differenceWith,\n equals,\n forEach,\n omit,\n path,\n pick,\n pipe,\n prop,\n when,\n uniq,\n propEq\n} from 'ramda';\nimport {Button as Button} from '@material-ui/core';\nimport {Divider as Divider} from '@material-ui/core';\nimport {Typography as Typography} from '@material-ui/core';\nimport {\n AttributeErrorType,\n ConnectionType,\n createTemporaryEntity,\n EntityType,\n findRelatedTemporaryEntities,\n getActivenessAttributes,\n getCreatableAttributeTypes,\n getEntityType,\n getErrorMessage,\n getErrorId,\n MetadataType,\n omitMarks,\n relationEditorAttributeTypesSelectionStrategy,\n RelationsConfigType,\n validateConnection,\n updateConnectionEntityLabel,\n isTempUri,\n isEmptyValue,\n getRelationAttributesList,\n getDefaultRelationTypeObject,\n getInOutRelations,\n isSuggestMode\n} from '@reltio/mdm-sdk';\nimport {profile} from '@reltio/mdm-module';\nimport ConnectionRelationTypeSelector from '../ConnectionRelationTypeSelector/ConnectionRelationTypeSelector';\nimport ErrorWrapper from '../ErrorWrapper/ErrorWrapper';\nimport EntitySelector from '../attributes/editMode/EntitySelector/EntitySelector';\nimport AttributesList from '../attributes/editMode/AttributesList';\nimport {withContext} from '../../HOCs';\nimport {ScrollToErrorContext} from '../../contexts';\nimport {useScrollToAttributeError} from '../../hooks';\n\nimport {useStyles} from './styles';\n\nconst areRelatedEntitiesChanged = (initial, actual) =>\n initial.length !== actual.length || initial.some((_, i) => initial[i] !== actual[i]);\n\nconst RelationEditor = ({\n connection,\n modifiedEntity,\n initialConnection,\n initialModifiedEntity,\n allModifiedEntities,\n dispatch,\n config,\n mode,\n metadata,\n globalSearchRequestOptions,\n error,\n highlightedError\n}) => {//NOSONAR\n const {relationUri, relationType, direction} = connection.relation;\n const isNew = connection.isNew;\n const styles = useStyles();\n const {ref, errorClassName} = useScrollToAttributeError({highlightedError, isSimple: true});\n const {inRelations: inRelationTypes = [], outRelations: outRelationTypes = []} = useMemo(\n () =>\n getInOutRelations({\n content: connection.parentEntityUri ? config.contentSecondLevel : config.content,\n direction,\n relationType,\n mode,\n metadata\n }),\n [config, direction, relationType, mode, metadata, connection.parentEntityUri]\n );\n const firstLevelRelationAttrTypes = useMemo(\n () => getRelationAttributesList(metadata, relationType),\n [relationType, metadata]\n );\n const attributeListEntity = useMemo(\n () => ({\n attributes: {\n ...profile.relations.selectors.getRelationAttributesFromConnection(connection)\n },\n ...getActivenessAttributes(connection.relation)\n }),\n [connection]\n );\n const relatedTempEntities = useMemo(\n () => findRelatedTemporaryEntities(allModifiedEntities, modifiedEntity),\n [allModifiedEntities, modifiedEntity]\n );\n const relatedTempEntitiesUrisHistory = useRef([]);\n\n const setInitialInfo = useCallback(\n (entity, connection) => {\n dispatch(profile.relations.actions.setInitialInfo(config.id, relationUri, entity, connection));\n },\n [dispatch]\n );\n\n useEffect(() => {\n if (!initialConnection) {\n setInitialInfo(modifiedEntity, connection);\n }\n }, []);\n\n useEffect(() => {\n relatedTempEntitiesUrisHistory.current = pipe(\n concat(relatedTempEntities.map(prop('uri'))),\n uniq\n )(relatedTempEntitiesUrisHistory.current);\n }, [relatedTempEntities]);\n const initialRelatedTempEntities = useRef(relatedTempEntities);\n const defaultRelationType = getDefaultRelationTypeObject(inRelationTypes, outRelationTypes);\n const hasChanges =\n !equals(pick(['entity', 'relation'], initialConnection || {}), pick(['entity', 'relation'], connection)) ||\n !equals(initialModifiedEntity, modifiedEntity) ||\n areRelatedEntitiesChanged(initialRelatedTempEntities.current, relatedTempEntities) ||\n (connection.isNew && !isEmptyValue(path(['relation', 'object', 'attributes'], connection)));\n const applyAction = isNew ? profile.relations.actions.addRelation : profile.relations.actions.editRelation;\n\n const onRelationTypeChange = useCallback(\n pipe(profile.relations.actions.setRelationType(config.id, relationUri), dispatch),\n [config, relationUri, dispatch]\n );\n\n const handleClose = useCallback(\n () => pipe(profile.relations.actions.closeRelationEditor, dispatch)(config.id, relationUri),\n [config, relationUri, dispatch]\n );\n\n const updateModifiedEntityLabel = useCallback(\n (connection) => {\n if (modifiedEntity) {\n const entityType = getEntityType(metadata, modifiedEntity.type);\n return updateConnectionEntityLabel(entityType, modifiedEntity, connection);\n }\n return connection;\n },\n [modifiedEntity, metadata]\n );\n\n const setModifiedEntity = useCallback(\n (entity) => dispatch(profile.modifiedEntities.actions.entityCreated(entity)),\n [dispatch]\n );\n\n const deleteModifiedEntity = useCallback(\n (entityUri) => dispatch(profile.modifiedEntities.actions.entityDeleted(entityUri)),\n [dispatch]\n );\n\n const onChangeEntity = useCallback(\n (entity) => {\n if (modifiedEntity) {\n deleteModifiedEntity(modifiedEntity.uri);\n }\n dispatch(profile.relations.actions.setRelationEntity(config.id, relationUri, entity));\n if (error) {\n dispatch(profile.errors.actions.errorDeactivated(getErrorId(error)));\n }\n },\n [config.id, relationUri, dispatch, modifiedEntity, deleteModifiedEntity, error]\n );\n\n const validate = useCallback(() => {\n const errors = validateConnection(metadata, allModifiedEntities, connection);\n dispatch(profile.errors.actions.errorsSet(errors));\n return errors.length === 0;\n }, [connection, metadata, allModifiedEntities, dispatch]);\n\n const resetErrors = useCallback(() => dispatch(profile.errors.actions.errorsSet([])), [dispatch]);\n\n const onApply = useCallback(\n pipe(\n always(connection),\n when(\n validate,\n pipe(\n omitMarks,\n updateModifiedEntityLabel,\n omit(['initial']),\n applyAction(config.id),\n dispatch,\n always(\n differenceWith(\n equals,\n relatedTempEntitiesUrisHistory.current,\n relatedTempEntities.map(prop('uri'))\n )\n ),\n forEach(deleteModifiedEntity),\n handleClose\n )\n )\n ),\n [connection, config, dispatch, updateModifiedEntityLabel, validate, relatedTempEntities]\n );\n\n const onCancel = useCallback(() => {\n if (modifiedEntity !== initialModifiedEntity) {\n if (initialModifiedEntity) {\n setModifiedEntity(initialModifiedEntity);\n if (modifiedEntity && modifiedEntity.uri !== initialModifiedEntity.uri) {\n deleteModifiedEntity(modifiedEntity.uri);\n }\n } else {\n deleteModifiedEntity(modifiedEntity.uri);\n }\n }\n const initialTempEntities = initialRelatedTempEntities.current;\n const entitiesUrisToDelete = differenceWith(\n equals,\n relatedTempEntitiesUrisHistory.current,\n initialTempEntities.map(prop('uri'))\n );\n entitiesUrisToDelete.forEach(deleteModifiedEntity);\n initialTempEntities.forEach(setModifiedEntity);\n resetErrors();\n handleClose();\n }, [handleClose, setModifiedEntity, deleteModifiedEntity, resetErrors, modifiedEntity, initialModifiedEntity]);\n\n const onAddAttributes = useCallback(\n (params) =>\n pipe(profile.actions.addAttributes, dispatch)(params.map((param) => ({...param, viewId: config.id}))),\n [config.id, dispatch]\n );\n\n const onChangeAttribute = useCallback(\n (params) => pipe(profile.actions.modifyAttribute, dispatch)({...params, viewId: config.id}),\n [config.id, dispatch]\n );\n\n const onDeleteAttribute = useCallback(\n (params) => pipe(profile.actions.removeAttribute, dispatch)({...params, viewId: config.id}),\n [config.id, dispatch]\n );\n\n const onCreateEntity = useCallback(\n (entityTypeUri, initValue) => {\n const entityType = getEntityType(metadata, entityTypeUri);\n const newEntityAttrTypes = pipe(\n relationEditorAttributeTypesSelectionStrategy,\n getCreatableAttributeTypes(mode)\n )(entityType);\n const newEntity = createTemporaryEntity({\n entityTypeUri,\n initValue,\n attributeTypes: newEntityAttrTypes,\n metadata,\n mode\n });\n onChangeEntity(newEntity);\n setModifiedEntity(newEntity);\n },\n [setModifiedEntity, onChangeEntity, mode, metadata]\n );\n const errorMessage = getErrorMessage(error);\n\n const getEntityTypesUris = useCallback(() => {\n const {content, contentSecondLevel} = config;\n\n if (contentSecondLevel && connection.parentEntityUri) {\n return contentSecondLevel.entityTypes;\n }\n\n return content.entityTypes;\n }, [config, connection.parentEntityUri]);\n\n return (\n <>\n <div className={styles.editor}>\n <Typography className={styles.title}>\n {isNew ? i18n.text('Add new item') : i18n.text('Edit item')}\n </Typography>\n {defaultRelationType === null && (\n <ConnectionRelationTypeSelector\n className={styles.item}\n relation={connection.relation}\n inRelationTypes={inRelationTypes}\n outRelationTypes={outRelationTypes}\n onChange={onRelationTypeChange}\n />\n )}\n {Boolean(relationType) && (\n <>\n <div ref={ref} className={errorClassName}>\n <ErrorWrapper errorMessage={errorMessage}>\n <EntitySelector\n className={classnames(styles.item, {\n [styles.dense]:\n errorMessage ||\n (connection.entity && isTempUri(connection.entity.entityUri))\n })}\n entity={connection.entity || {}}\n entityTypesUris={getEntityTypesUris() || []}\n max={config.max || 20}\n globalSearchRequestOptions={globalSearchRequestOptions}\n mode={mode}\n onChange={onChangeEntity}\n onCreate={isSuggestMode(mode) ? undefined : onCreateEntity}\n metadata={metadata}\n attributeTypesSelectionStrategy={relationEditorAttributeTypesSelectionStrategy}\n />\n </ErrorWrapper>\n </div>\n <AttributesList\n className={styles.item}\n attrTypes={firstLevelRelationAttrTypes}\n entity={attributeListEntity}\n showEmptyEditors={true}\n crosswalks={connection.crosswalks}\n mode={mode}\n parentUri={relationUri}\n onAddAttributes={onAddAttributes}\n onChangeAttribute={onChangeAttribute}\n onDeleteAttribute={onDeleteAttribute}\n />\n </>\n )}\n </div>\n <div className={styles.actionButtons}>\n <Button onClick={onCancel}>{i18n.text('Cancel')}</Button>\n <Button color=\"primary\" disabled={!hasChanges} onClick={onApply}>\n {i18n.text('Apply')}\n </Button>\n </div>\n <Divider />\n </>\n );\n};\n\nRelationEditor.propTypes = {\n connection: ConnectionType,\n modifiedEntity: EntityType,\n initialConnection: ConnectionType,\n initialModifiedEntity: EntityType,\n allModifiedEntities: PropTypes.object,\n dispatch: PropTypes.func,\n config: RelationsConfigType,\n mode: PropTypes.string,\n metadata: MetadataType,\n globalSearchRequestOptions: PropTypes.object,\n error: AttributeErrorType,\n parentEntityUri: PropTypes.string,\n highlightedError: PropTypes.object\n};\n\nexport default withContext(\n ScrollToErrorContext,\n (contextValue, {connection}) => {\n const {error = {}} = contextValue || {};\n const {relationUri, relationType} = connection.relation;\n const isHighlighted = allPass([\n pipe(prop('uri'), isEmptyValue),\n propEq('parentUri', relationUri),\n propEq('attributeTypeUri', relationType)\n ])(error);\n return {highlightedError: isHighlighted ? contextValue : null};\n },\n RelationEditor\n);\n","import RelationEditor from './RelationEditor';\nimport mdmModule, {profile} from '@reltio/mdm-module';\nimport {connect} from 'react-redux';\nimport {getRelationEditorActiveError, isTempUri} from '@reltio/mdm-sdk';\n\nconst getConnectionEntityUri = (props) => profile.relations.selectors.getEntityUriFromConnection(props.connection);\nconst getConnectionRelationUri = (props) => profile.relations.selectors.getRelationUriFromConnection(props.connection);\n\nconst mapStateToProps = (state, ownProps) => {\n const entityUri = getConnectionEntityUri(ownProps);\n const relationUri = getConnectionRelationUri(ownProps);\n const isTempEntity = isTempUri(entityUri);\n return {\n initialConnection: mdmModule.selectors.getInitialConnection(state, ownProps.config.id, relationUri),\n initialModifiedEntity: mdmModule.selectors.getInitialConnectionTempEntity(\n state,\n ownProps.config.id,\n relationUri\n ),\n modifiedEntity: isTempEntity ? mdmModule.selectors.getModifiedEntity(state, entityUri) : null,\n allModifiedEntities: isTempEntity ? mdmModule.selectors.getModifiedEntities(state) : null,\n globalSearchRequestOptions: mdmModule.selectors.getGlobalSearchRequestOptions(state, ['ovOnly']),\n error: getRelationEditorActiveError(ownProps.connection, mdmModule.selectors.getProfileErrors(state))\n };\n};\n\nexport {RelationEditor};\n\nexport default connect(mapStateToProps)(RelationEditor);\n","import {curry, defaultTo, mergeAll, pick, pipe, prop, propEq, __} from 'ramda';\n\nexport const getReltioViewId = (id) => id.split(/\\d+_/)[1];\n\nexport const reltioLayoutItemToReactGridLayoutItem = ({\n x,\n y,\n width,\n height,\n id,\n minWidth,\n minHeight,\n maxWidth,\n maxHeight,\n isStatic\n}) => ({\n x,\n y,\n w: width,\n h: height,\n minW: minWidth,\n minH: minHeight,\n maxW: maxWidth,\n maxH: maxHeight,\n i: id,\n static: isStatic\n});\n\nexport const reactGridLayoutItemToReltioLayoutItem = ({x, y, w, h, maxW, minW, minH, maxH, i, ...obj}) => ({\n x,\n y,\n width: w,\n height: h,\n minWidth: minW,\n minHeight: minH,\n maxWidth: maxW,\n maxHeight: maxH,\n id: i,\n isStatic: obj.static\n});\n\nexport const reltioLayoutToReactGridLayout = (layout) => (layout || []).map(reltioLayoutItemToReactGridLayoutItem);\n\nexport const reactGridLayoutToReltioLayout = (layout) => (layout || []).map(reactGridLayoutItemToReltioLayoutItem);\n\nexport const getReltioLayoutItemById = curry((layout, id) => (layout || []).find(propEq('id', id)));\n\nconst updateExtraPropsInLayoutItem = curry((props, from, to) => mergeAll([to, pick(props, from)]));\n\nexport const copyPropsFromPreviousLayout = curry((props, oldReltioLayout, reltioLayout) =>\n (reltioLayout || []).map((layoutItem) =>\n pipe(\n prop('id'),\n getReltioLayoutItemById(oldReltioLayout),\n defaultTo({}),\n updateExtraPropsInLayoutItem(props, __, layoutItem)\n )(layoutItem)\n )\n);\n\nexport const calcHeight = (height, options) => {\n const {margin, rowHeight} = options;\n\n return Math.ceil((height + margin[1]) / (rowHeight + margin[1]));\n};\n","export const RESIZE_ICON = `<svg width=\"10\" height=\"10\" viewBox=\"0 0 10 10\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path stroke=\"#505050\" stroke-opacity=\".54\" d=\"M9.5 0v10M0 9.5h9M7.5 4v4M4 7.5h3\"/>\n</svg>`;\n","import {makeStyles} from '@material-ui/core/styles';\nimport {svg2Url} from '@reltio/mdm-sdk';\nimport {RESIZE_ICON} from './icons/ResizeIcon.svg';\n\nexport const useStyles = makeStyles((_) => ({\n gridLayout: {\n position: 'relative',\n width: '100%',\n '& .react-grid-item': {\n '&.react-grid-placeholder': {\n background: 'rgba(0, 0, 0, 0.03)',\n border: '2px dashed rgba(0, 0, 0, 0.3)',\n borderRadius: '3px',\n transitionDuration: '100ms',\n zIndex: 7,\n userSelect: 'none',\n '& .react-resizable-handle': {\n display: 'none'\n }\n },\n '&.static .react-resizable-handle': {\n display: 'none'\n },\n '&.cssTransforms': {\n transitionProperty: 'transform'\n },\n '&.resizing': {\n zIndex: 9,\n willChange: 'width, height',\n pointerEvents: 'none'\n },\n '&.react-draggable-dragging': {\n transition: 'none',\n zIndex: 8,\n willChange: 'transform',\n '& .react-resizable-handle': {\n backgroundImage: 'none'\n }\n },\n '& .react-resizable-handle': {\n position: 'absolute',\n width: '17px',\n height: '17px',\n bottom: 0,\n right: 0,\n zIndex: 20,\n backgroundImage: `url('${svg2Url(RESIZE_ICON)}')`,\n backgroundRepeat: 'no-repeat',\n backgroundOrigin: 'content-box',\n boxSizing: 'border-box',\n cursor: 'se-resize'\n },\n '&.fullscreen': {\n visibility: 'visible',\n position: 'unset',\n width: '100% !important',\n height: '100% !important',\n transform: 'translate(0) !important'\n }\n }\n },\n\n gridFullscreen: {\n height: '100% !important',\n overflowY: 'hidden',\n '& .react-resizable-handle, & .react-grid-item': {\n visibility: 'hidden'\n }\n }\n}));\n","import PropTypes from 'prop-types';\nimport React, {useCallback, useMemo, useRef, useState, memo} from 'react';\nimport GridLayout from 'react-grid-layout';\nimport ReactResizeDetector from 'react-resize-detector';\nimport {identity, pipe} from 'ramda';\nimport classnames from 'classnames';\nimport {\n reltioLayoutToReactGridLayout,\n reactGridLayoutToReltioLayout,\n reactGridLayoutItemToReltioLayoutItem,\n copyPropsFromPreviousLayout,\n calcHeight,\n getReltioLayoutItemById\n} from './helpers';\n\nimport {useStyles} from './styles';\n\nconst ReltioGridLayout = ({\n views,\n layout,\n layoutOptions,\n onLayoutChanged,\n draggableHandle,\n LayoutItem,\n onRemove,\n onDrop,\n droppingItem,\n isDroppable,\n classes\n}) => {\n const ref = useRef();\n const styles = useStyles();\n const [fullscreenItemId, setFullscreenItemId] = useState(null);\n const [width, setWidth] = useState(0);\n const {cols, rowHeight, margin} = layoutOptions;\n const processedLayout = useMemo(() => reltioLayoutToReactGridLayout(layout), [layout]);\n const onReltioLayoutChanged = pipe(\n reactGridLayoutToReltioLayout,\n copyPropsFromPreviousLayout(['autosizing'], layout),\n onLayoutChanged\n );\n const handleDrop = (layout, layoutItem, e) => {\n if (onDrop) {\n onDrop(reactGridLayoutToReltioLayout(layout), reactGridLayoutItemToReltioLayoutItem(layoutItem), e);\n }\n };\n const onToggleFullscreen = useCallback((id) => setFullscreenItemId((prevId) => (prevId ? null : id)), []);\n const isFullscreenEnabled = fullscreenItemId !== null;\n\n const onItemHeightResize = useCallback(\n (height, layoutId) => {\n let isLayoutChanged = false;\n\n const newLayout = layout.map((layoutItem) => {\n if (layoutItem.id === layoutId && height) {\n const newHeight = calcHeight(height, layoutOptions);\n\n if (layoutItem.height !== newHeight) {\n isLayoutChanged = true;\n return {\n ...layoutItem,\n minHeight: newHeight,\n maxHeight: newHeight,\n height: newHeight\n };\n }\n }\n return layoutItem;\n });\n\n if (isLayoutChanged) {\n onLayoutChanged(newLayout);\n }\n },\n [layout, layoutOptions, onLayoutChanged]\n );\n\n const getAutosizeComponent = (layoutItemId) => {\n return (\n <ReactResizeDetector\n handleHeight\n onResize={(width, height) => {\n onItemHeightResize(height, layoutItemId);\n }}\n />\n );\n };\n\n return (\n <>\n <ReactResizeDetector\n refreshMode=\"debounce\"\n refreshRate={50}\n handleWidth={true}\n onResize={(width) => setWidth(width)}\n />\n <GridLayout\n innerRef={ref}\n layout={processedLayout}\n cols={cols}\n draggableHandle={draggableHandle}\n autoSize={true}\n rowHeight={rowHeight}\n width={width}\n margin={margin}\n onLayoutChange={onReltioLayoutChanged}\n isResizable={!isFullscreenEnabled}\n isDraggable={!isFullscreenEnabled}\n className={classnames(classes.root, styles.gridLayout, {[styles.gridFullscreen]: isFullscreenEnabled})}\n onDrop={handleDrop}\n droppingItem={droppingItem}\n isDroppable={isDroppable}\n >\n {processedLayout.map((layoutItem) => {\n const isItemFullscreen = fullscreenItemId === layoutItem.i;\n const isAutosize = (getReltioLayoutItemById(layout, layoutItem.i) || {}).autosizing;\n const autosizeComponent = isAutosize ? {AutosizeComponent: getAutosizeComponent(layoutItem.i)} : {};\n return (\n <LayoutItem\n key={layoutItem.i}\n layoutItemConfig={layoutItem}\n views={views}\n onToggleFullscreen={onToggleFullscreen}\n onRemove={onRemove}\n className={classnames({fullscreen: isItemFullscreen}, classes.item)}\n isFullscreen={isItemFullscreen}\n {...autosizeComponent}\n />\n );\n })}\n </GridLayout>\n </>\n );\n};\n\nReltioGridLayout.defaultProps = {\n layoutOptions: {\n cols: 4,\n rowHeight: 30,\n margin: [15, 15]\n },\n onConfigChanged: identity,\n onLayoutChanged: identity,\n classes: {}\n};\nReltioGridLayout.propTypes = {\n views: PropTypes.array,\n layout: PropTypes.array,\n layoutOptions: PropTypes.object,\n onConfigChanged: PropTypes.func,\n onLayoutChanged: PropTypes.func,\n onDrop: PropTypes.func,\n onRemove: PropTypes.func,\n LayoutItem: PropTypes.elementType,\n draggableHandle: PropTypes.string,\n isDroppable: PropTypes.bool,\n droppingItem: PropTypes.object,\n classes: PropTypes.shape({\n root: PropTypes.string,\n item: PropTypes.string\n })\n};\n\nexport default memo(ReltioGridLayout);\n","import React, {useEffect, useState} from 'react';\nimport {createPortal} from 'react-dom';\nimport {MapInstance} from '../../types';\n\ntype Props = {\n children: React.ReactNode;\n className?: string;\n position: number;\n map: MapInstance;\n};\n\nexport const MapControlContainer = ({children, className, position, map}: Props) => {\n const [controlElement, setControlElement] = useState(null);\n\n useEffect(() => {\n const controlDiv = document.createElement('div');\n const divIndex = map.controls[position].length;\n map.controls[position].push(controlDiv);\n setControlElement(controlDiv);\n\n return () => {\n map.controls[position].removeAt(divIndex);\n };\n }, [map, position]);\n\n useEffect(() => {\n if (controlElement && className) {\n controlElement.classList.add(className);\n }\n }, [className, controlElement]);\n\n if (controlElement) {\n return createPortal(children, controlElement);\n }\n\n return null;\n};\n","import React from 'react';\n\nconst SvgRadius: React.FC<React.SVGProps<SVGSVGElement>> = (props) => {\n return (\n <svg width={18} height={18} viewBox=\"0 0 18 18\" xmlns=\"http://www.w3.org/2000/svg\" {...props}>\n <path\n d=\"M10.61 8.568A1.666 1.666 0 119.432 7.39l3.656-3.657a6.668 6.668 0 101.179 1.179L10.61 8.568zm-7.503 6.325A8.333 8.333 0 1114.893 3.107 8.333 8.333 0 013.107 14.893z\"\n fill=\"#000\"\n stroke=\"none\"\n strokeWidth={1}\n fillRule=\"evenodd\"\n opacity={0.54}\n />\n </svg>\n );\n};\n\nexport default SvgRadius;\n","import React from 'react';\n\nconst SvgDraw: React.FC<React.SVGProps<SVGSVGElement>> = (props) => {\n return (\n <svg\n width={24}\n height={24}\n viewBox=\"0 0 24 24\"\n xmlns=\"http://www.w3.org/2000/svg\"\n xmlnsXlink=\"http://www.w3.org/1999/xlink\"\n {...props}\n >\n <defs>\n <path\n d=\"M18.29 11.44a1.49 1.49 0 012.12 0l1.15 1.15c.59.58.59 1.53 0 2.12L16.27 20H13v-3.27zM18.174 4c0 1.71-.26 3.285-.932 4.563-.946 1.798-2.609 2.724-4.906 2.46l-.855-.116c-4.382-.544-6.626.53-6.626 3.609 0 1.968 1.105 2.924 3.267 3.304.692.121 1.306.165 2.234.176L11 18v2l-.698-.003c-1.016-.013-1.71-.063-2.526-.206-3.018-.53-4.921-2.176-4.921-5.274 0-4.819 3.71-6.378 9.52-5.505 1.575.237 2.506-.255 3.098-1.38.451-.858.666-2.02.697-3.307L16.174 4h2zM18 13.97l-3.45 3.45v1.03h1.03L19.03 15 18 13.97z\"\n id=\"Draw_svg__a\"\n />\n </defs>\n <g stroke=\"none\" strokeWidth={1} fill=\"none\" fillRule=\"evenodd\">\n <mask id=\"Draw_svg__b\" fill=\"#fff\">\n <use xlinkHref=\"#Draw_svg__a\" />\n </mask>\n <g mask=\"url(#Draw_svg__b)\" fill=\"#000\" fillOpacity={0.54}>\n <path d=\"M0 0h24v24H0z\" />\n </g>\n </g>\n </svg>\n );\n};\n\nexport default SvgDraw;\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles({\n container: {\n margin: '2px',\n display: 'flex',\n alignItems: 'center'\n },\n button: {\n color: 'rgba(0,0,0,0.54)',\n padding: 0,\n height: '24px',\n width: '24px',\n minWidth: 0\n },\n icon: {\n width: '20px',\n height: '20px'\n }\n});\n","import React from 'react';\nimport i18n from 'ui-i18n';\nimport {Button as Button} from '@material-ui/core';\nimport {withTooltip} from '../../../../HOCs';\nimport HighlightOffIcon from '@material-ui/icons/HighlightOff';\nimport {MAP_DRAWING_MODES} from '../../../../constants';\nimport RadiusIcon from '../../../../icons/Radius';\nimport DrawIcon from '../../../../icons/Draw';\nimport {DrawingMode, DrawingModes} from '../../types';\nimport {useStyles} from './styles';\n\nexport const ButtonWithTooltip = withTooltip(Button);\n\nconst getIcon = (mode: DrawingMode) => {\n switch (mode) {\n case MAP_DRAWING_MODES.CIRCLE:\n return RadiusIcon;\n case MAP_DRAWING_MODES.POLYGON:\n return DrawIcon;\n default:\n return null;\n }\n};\n\ntype Props = {\n onDrawingModeChanged: (value: DrawingMode | null) => void;\n drawingMode: DrawingMode | null;\n drawingModes: DrawingModes;\n hasActiveOverlay: boolean;\n onClearOverlay: () => void;\n};\n\nexport const TopRightMapControls = ({\n drawingMode,\n drawingModes = [],\n hasActiveOverlay,\n onDrawingModeChanged,\n onClearOverlay\n}: Props) => {\n const styles = useStyles();\n\n const changeDrawingModeTo = (drawingMode) => () => {\n onDrawingModeChanged(drawingMode);\n };\n\n return (\n <div className={styles.container}>\n {drawingMode || hasActiveOverlay ? (\n <ButtonWithTooltip\n tooltipTitle={i18n.text('Clear area')}\n className={styles.button}\n onClick={hasActiveOverlay ? onClearOverlay : changeDrawingModeTo(null)}\n >\n <HighlightOffIcon className={styles.icon} />\n </ButtonWithTooltip>\n ) : (\n drawingModes.map((mode) => {\n const Icon = getIcon(mode);\n return (\n <ButtonWithTooltip\n tooltipTitle={i18n.text('Draw area')}\n key={mode}\n className={styles.button}\n onClick={changeDrawingModeTo(mode)}\n >\n <Icon className={styles.icon} />\n </ButtonWithTooltip>\n );\n })\n )}\n </div>\n );\n};\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles({\n container: {\n height: '28px',\n marginRight: '7px',\n marginLeft: 0\n },\n label: {\n fontSize: '11px',\n alignSelf: 'center',\n lineHeight: '13px',\n marginLeft: '2px',\n letterSpacing: 0\n },\n checkbox: {\n width: '20px',\n height: '20px',\n padding: '5px',\n '& svg': {\n width: '16px',\n height: '16px'\n }\n }\n});\n","import React from 'react';\nimport i18n from 'ui-i18n';\nimport {FormControlLabel as FormControlLabel} from '@material-ui/core';\nimport {Checkbox as Checkbox} from '@material-ui/core';\nimport {useStyles} from './styles';\n\ntype Props = {\n isSearchOnMapMove: boolean;\n onChangeIsSearchOnMapMove: (value: boolean) => void;\n};\n\nexport const TopCenterMapControls = ({isSearchOnMapMove, onChangeIsSearchOnMapMove}: Props) => {\n const styles = useStyles();\n const onChange = (event) => {\n onChangeIsSearchOnMapMove(event.target.checked);\n };\n return (\n <FormControlLabel\n classes={{\n root: styles.container,\n label: styles.label\n }}\n control={\n <Checkbox checked={isSearchOnMapMove} onChange={onChange} color=\"primary\" className={styles.checkbox} />\n }\n label={i18n.text('Search as I move the map')}\n />\n );\n};\n","import {MAP_DRAWING_MODES, MAP_MINIMUM_SCALE_RADIUS} from '../../../constants';\nimport {DrawingMode, EntityMarker, Overlay, MapInstance} from '../types';\n\nexport const getMapBoundsPolygon = (map: MapInstance) => {\n const bounds = map.getBounds();\n const ne = bounds.getNorthEast();\n const sw = bounds.getSouthWest();\n const neLat = ne.lat(),\n neLng = ne.lng(),\n swLat = sw.lat(),\n swLng = sw.lng();\n const additionalPoint1 = [];\n const additionalPoint2 = [];\n if (!((neLng === 180 && swLng === -180) || (neLng === -180 && swLng === 180))) {\n // excluding corner case when we see more than one \"map unfolding\" (in this case google maps automatically set 180 and -180),\n // we can't describe map bounds as just rectangle, because lng distance can be more than 180\",\n // so we need to add additional points to have correct polygon\n const center = bounds.getCenter();\n additionalPoint1.push([neLat, center.lng()]);\n additionalPoint2.push([swLat, center.lng()]);\n }\n return [[neLat, neLng], ...additionalPoint1, [neLat, swLng], [swLat, swLng], ...additionalPoint2, [swLat, neLng]];\n};\n\nexport const getDrawingMode = (drawingMode: DrawingMode) => {\n switch (drawingMode) {\n case MAP_DRAWING_MODES.CIRCLE:\n return window.google.maps.drawing.OverlayType.CIRCLE;\n case MAP_DRAWING_MODES.POLYGON:\n return window.google.maps.drawing.OverlayType.POLYGON;\n default:\n return null;\n }\n};\n\nexport const fitMapBoundsForMarkers = (markers: EntityMarker[], map: MapInstance, overlay: Overlay) => {\n const bounds = new window.google.maps.LatLngBounds();\n\n markers.forEach((marker) => bounds.extend(marker.point));\n\n if (markers.length === 1) {\n const center = bounds.getCenter();\n\n bounds.extend(\n new window.google.maps.LatLng(\n center.lat() + MAP_MINIMUM_SCALE_RADIUS,\n center.lng() + MAP_MINIMUM_SCALE_RADIUS\n )\n );\n bounds.extend(\n new window.google.maps.LatLng(\n center.lat() - MAP_MINIMUM_SCALE_RADIUS,\n center.lng() - MAP_MINIMUM_SCALE_RADIUS\n )\n );\n }\n\n map.fitBounds(bounds);\n\n if (overlay) {\n fitMapBoundsForOverlay(map, overlay, bounds);\n }\n};\n\nexport const fitMapBoundsForOverlay = (map: MapInstance, overlay: Overlay, existingBounds?) => {\n if (overlay.path) {\n const bounds = existingBounds || new window.google.maps.LatLngBounds();\n overlay.path.forEach(({lat, lng}) => bounds.extend(new window.google.maps.LatLng(lat, lng)));\n map.fitBounds(bounds);\n }\n};\n","export const MARKER = `<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<svg width=\"22px\" height=\"32px\" viewBox=\"0 0 22 32\" version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n <title>View / Map / Marker / Large</title>\n <defs>\n <radialGradient cx=\"50%\" cy=\"50.2950175%\" fx=\"50%\" fy=\"50.2950175%\" r=\"49.7049825%\" gradientTransform=\"translate(0.500000,0.502950),scale(0.777778,1.000000),rotate(90.000000),scale(1.000000,1.293560),translate(-0.500000,-0.502950)\" id=\"radialGradient-1\">\n <stop stop-color=\"#000000\" offset=\"0%\"></stop>\n <stop stop-color=\"#000000\" stop-opacity=\"0\" offset=\"100%\"></stop>\n </radialGradient>\n <path d=\"M20,1 C20.5522847,1 21,1.44771525 21,2 L21,20 C21,20.5522847 20.5522847,21 20,21 L15.2374606,21.0021908 C14.9306693,21.3935449 14.6510143,21.7632851 14.3885453,22.1256523 C12.8309725,24.2760522 12,26.0137017 12,27.5 C12,28.0522847 11.5522847,28.5 11,28.5 C10.4477153,28.5 10,28.0522847 10,27.5 C10,25.7886708 8.84033182,23.6810997 6.73798027,21.0014567 L2,21 C1.44771525,21 1,20.5522847 1,20 L1,2 C1,1.44771525 1.44771525,1 2,1 L20,1 Z\" id=\"path-2\"></path>\n </defs>\n <g id=\"View-/-Map-/-Marker-/-Large\" stroke=\"none\" stroke-width=\"1\" fill=\"none\" fill-rule=\"evenodd\">\n <ellipse id=\"Oval\" fill=\"url(#radialGradient-1)\" opacity=\"0.12\" cx=\"11\" cy=\"28.5\" rx=\"4.5\" ry=\"3.5\"></ellipse>\n <path d=\"M21,0 C21.5522847,-1.01453063e-16 22,0.44771525 22,1 L22,21 C22,21.5522847 21.5522847,22 21,22 L15.7283832,22.0012846 C15.5422129,22.2445529 15.3664776,22.4802332 15.1984183,22.7122576 C13.7560833,24.7035592 13,26.2846074 13,27.5 L13,27.5 L12.9945143,27.6492623 C12.9181651,28.6841222 12.0543618,29.5 11,29.5 C9.8954305,29.5 9,28.6045695 9,27.5 L9,27.5 L8.99485006,27.3298651 C8.91582184,26.0024976 7.93016704,24.2171459 6.23940611,22.000704 L1,22 C0.44771525,22 6.76353751e-17,21.5522847 0,21 L0,1 C-6.76353751e-17,0.44771525 0.44771525,1.01453063e-16 1,0 L21,0 Z\" id=\"Path-3\" fill=\"#FFFFFF\"></path>\n <mask id=\"mask-3\" fill=\"white\">\n <use xlink:href=\"#path-2\"></use>\n </mask>\n <use id=\"Path-2\" fill=\"#FFFFFF\" fill-rule=\"nonzero\" xlink:href=\"#path-2\"></use>\n <rect id=\"Entity-type\" fill=\"#24A8E8\" mask=\"url(#mask-3)\" x=\"0\" y=\"0\" width=\"22\" height=\"32\"></rect>\n </g>\n</svg>`;\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles({\n popper: {\n maxWidth: '263px',\n minWidth: '150px',\n boxShadow: '0 1px 1px 0 rgba(0,0,0,0.14), 0 2px 1px -1px rgba(0,0,0,0.12), 0 1px 3px 0 rgba(0,0,0,0.2)',\n backgroundColor: 'white',\n borderRadius: '2px'\n }\n});\n","import React, {memo, useCallback, useContext, useRef, useState} from 'react';\nimport {pathEq} from 'ramda';\nimport {Marker, InfoBox, MarkerProps} from '@react-google-maps/api';\nimport ProfileCard from '../../ProfileCard/ProfileCard';\nimport Popper from '../../Popper/Popper';\nimport {debounce, svg2Url} from '@reltio/mdm-sdk';\nimport {EntityMarkerContext} from '../../../contexts';\nimport {MARKER} from './icons/marker.inline.svg';\nimport {HOVERED_MARKER} from './icons/marker-hover.inline.svg';\nimport {EntityMarker as EntityMarkerType} from '../types';\nimport {useStyles} from './styles';\n\nconst HIDE_DEBOUNCE_INTERVAL = 50;\nconst MARKER_WIDTH = 22;\nconst MARKER_HEIGHT = 32;\nconst MARKER_CARD_MARGIN = 8;\n\nconst hoveredMarkerIcon = svg2Url(HOVERED_MARKER);\nconst markerIcon = svg2Url(MARKER);\n\ntype Props = {\n marker: EntityMarkerType;\n onClick: (marker: EntityMarkerType) => void;\n} & Omit<MarkerProps, 'onClick' | 'icon' | 'position' | 'visible' | 'onMouseOver' | 'onMouseOut'>;\n\nconst EntityMarker = ({marker, onClick, ...otherProps}: Props) => {\n const styles = useStyles();\n const popperAnchor = useRef();\n const [hovered, setHovered] = useState(false);\n const {activeEntityUri} = useContext(EntityMarkerContext);\n const isActive = pathEq(['entity', 'uri'], activeEntityUri, marker);\n const position = {lat: marker.point.lat, lng: marker.point.lng};\n const setHoveredDebounced = useCallback(debounce(setHovered, HIDE_DEBOUNCE_INTERVAL), []);\n const onMouseOver = useCallback(() => setHoveredDebounced(true), [setHoveredDebounced]);\n const onMouseOut = useCallback(() => setHoveredDebounced(false), [setHoveredDebounced]);\n const handleClick = useCallback(() => onClick(marker), [onClick, marker]);\n\n return (\n <>\n <Popper\n anchorEl={popperAnchor.current}\n open={hovered}\n className={styles.popper}\n modal={false}\n placement=\"top\"\n >\n <ProfileCard entity={marker.entity} onMouseOver={onMouseOver} onMouseOut={onMouseOut} />\n </Popper>\n <Marker\n icon={{\n url: hovered || isActive ? hoveredMarkerIcon : markerIcon,\n // needed for IE:\n scaledSize: new google.maps.Size(MARKER_WIDTH, MARKER_HEIGHT) //eslint-disable-line\n }}\n position={position}\n onClick={handleClick}\n visible={marker.visible !== false}\n onMouseOver={onMouseOver}\n onMouseOut={onMouseOut}\n {...otherProps}\n />\n <InfoBox\n options={{\n alignBottom: true,\n pane: 'mapPane',\n pixelOffset: new google.maps.Size(0, -(MARKER_HEIGHT + MARKER_CARD_MARGIN)), //eslint-disable-line\n closeBoxURL: '',\n enableEventPropagation: true,\n disableAutoPan: true\n }}\n position={position}\n >\n <span ref={popperAnchor} />\n </InfoBox>\n </>\n );\n};\n\nexport default memo(EntityMarker);\n","export const HOVERED_MARKER = `<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<svg width=\"22px\" height=\"32px\" viewBox=\"0 0 22 32\" version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n <title>View / Map / Marker / Large (hover)</title>\n <defs>\n <radialGradient cx=\"50%\" cy=\"50.2950175%\" fx=\"50%\" fy=\"50.2950175%\" r=\"49.7049825%\" gradientTransform=\"translate(0.500000,0.502950),scale(0.777778,1.000000),rotate(90.000000),scale(1.000000,1.293560),translate(-0.500000,-0.502950)\" id=\"radialGradient-1\">\n <stop stop-color=\"#000000\" offset=\"0%\"></stop>\n <stop stop-color=\"#000000\" stop-opacity=\"0\" offset=\"100%\"></stop>\n </radialGradient>\n <path d=\"M21,0 C21.5522847,-1.01453063e-16 22,0.44771525 22,1 L22,21 C22,21.5522847 21.5522847,22 21,22 L15.7283832,22.0012846 C15.5422129,22.2445529 15.3664776,22.4802332 15.1984183,22.7122576 C13.7560833,24.7035592 13,26.2846074 13,27.5 L13,27.5 L12.9945143,27.6492623 C12.9181651,28.6841222 12.0543618,29.5 11,29.5 C9.8954305,29.5 9,28.6045695 9,27.5 L9,27.5 L8.99485006,27.3298651 C8.91582184,26.0024976 7.93016704,24.2171459 6.23940611,22.000704 L1,22 C0.44771525,22 6.76353751e-17,21.5522847 0,21 L0,1 C-6.76353751e-17,0.44771525 0.44771525,1.01453063e-16 1,0 L21,0 Z\" id=\"path-2\"></path>\n </defs>\n <g id=\"View-/-Map-/-Marker-/-Large-(hover)\" stroke=\"none\" stroke-width=\"1\" fill=\"none\" fill-rule=\"evenodd\">\n <ellipse id=\"Oval\" fill=\"url(#radialGradient-1)\" opacity=\"0.32\" cx=\"11\" cy=\"28.5\" rx=\"6\" ry=\"4.66666667\"></ellipse>\n <mask id=\"mask-3\" fill=\"white\">\n <use xlink:href=\"#path-2\"></use>\n </mask>\n <use id=\"Path-2\" fill=\"#FFFFFF\" xlink:href=\"#path-2\"></use>\n <rect id=\"Entity-type\" fill=\"#24A8E8\" mask=\"url(#mask-3)\" x=\"0\" y=\"0\" width=\"22\" height=\"32\"></rect>\n <path d=\"M20,2 L20,20 L14.755,20 L14.6905172,20.0815309 C14.3562717,20.5012516 14.0578656,20.8886742 13.7817711,21.2616986 L13.5786724,21.5390469 C11.92787,23.8181606 11.079024,25.6311217 11.0052669,27.2674145 L11.0052669,27.2674145 L11,27.5 L10.9968324,27.3203844 C10.9285422,25.3781621 9.75347502,23.1598866 7.22124201,20.0010865 L2,20 L2,2 L20,2 Z\" id=\"Path\" fill=\"#FFFFFF\" fill-rule=\"nonzero\" mask=\"url(#mask-3)\"></path>\n </g>\n</svg>`;\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles({\n mapControlContainer: {\n borderRadius: '2px',\n backgroundColor: '#FFFFFF',\n boxShadow: '0 1px 3px 0 rgba(0,0,0,0.15)',\n margin: '10px'\n }\n});\n","import React, {useCallback, useEffect, useMemo, useRef, useState} from 'react';\nimport {propEq, isEmpty, prop} from 'ramda';\nimport {\n GoogleMap,\n useJsApiLoader,\n GoogleMapProps,\n Polygon,\n DrawingManager,\n MarkerClusterer,\n LoadScriptProps,\n MarkerClustererProps\n} from '@react-google-maps/api';\nimport {MapControlContainer} from './MapControls/MapControlContainer/MapControlContrainer';\nimport {TopRightMapControls} from './MapControls/TopRightMapControls/TopRightMapControls';\nimport {TopCenterMapControls} from './MapControls/TopCenterMapControls/TopCenterMapControls';\nimport {getMapBoundsPolygon, getDrawingMode, fitMapBoundsForMarkers, fitMapBoundsForOverlay} from './helpers';\nimport EntityMarker from './EntityMarker/EntityMarker';\nimport {DEFAULT_GOOGLE_MAP_OPTIONS, DEFAULT_OVERLAY_OPTIONS, MAP_DRAWING_MODES} from '../../constants';\nimport {DrawingModes, EntityMarker as Marker, MapBounds, Overlay, OverlayPath} from './types';\nimport {useStyles} from './styles';\nimport {usePrevious} from '../../hooks';\n\nconst ON_MAP_MOVE_DEBOUNCE_INTERVAL = 1000;\n\ntype Props = {\n markers: Marker[];\n mapKey: string;\n defaultZoom: GoogleMapProps['zoom'];\n defaultCenter: GoogleMapProps['center'];\n loadingElement: JSX.Element;\n isSearchOnMapMove?: boolean;\n isSearchEnabled?: boolean;\n activeOverlay?: Overlay;\n overlayOptions?: google.maps.PolygonOptions | google.maps.CircleOptions;\n drawingModes?: DrawingModes;\n markerClusterer?: boolean;\n markerClustererOptions?: MarkerClustererProps['options'];\n mapOptions?: google.maps.MapOptions;\n mapContainerClassName: string;\n onMapBoundsChanged?: (value: MapBounds | null) => void;\n onOverlayUpdated?: (value: {data: OverlayPath; type: string}) => void;\n onMarkerClicked?: (value: Marker) => void;\n};\n\nconst libraries = ['drawing'] as LoadScriptProps['libraries'];\n\nconst useFitMapBounds = ({markers, activeOverlay, isSearchOnMapMove, map}) => {\n const prevMarkers = usePrevious(markers);\n const prevActiveOverlay = usePrevious(activeOverlay);\n const apiIsLoaded = map && window.google;\n\n useEffect(() => {\n if (apiIsLoaded && !isSearchOnMapMove && markers.length && markers !== prevMarkers) {\n fitMapBoundsForMarkers(markers, map, activeOverlay);\n } else if (apiIsLoaded && activeOverlay && activeOverlay !== prevActiveOverlay) {\n fitMapBoundsForOverlay(map, activeOverlay);\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [map, markers, activeOverlay]);\n};\n\nexport const ReltioMap = ({\n markers = [],\n mapKey,\n defaultZoom,\n defaultCenter,\n loadingElement,\n isSearchOnMapMove,\n isSearchEnabled,\n activeOverlay,\n overlayOptions,\n drawingModes = [],\n markerClusterer,\n markerClustererOptions,\n mapOptions,\n mapContainerClassName,\n onMapBoundsChanged,\n onOverlayUpdated,\n onMarkerClicked\n}: Props) => {\n const styles = useStyles();\n const {isLoaded, loadError} = useJsApiLoader({\n googleMapsApiKey: mapKey,\n libraries\n });\n\n const mapMoveEndTimer = useRef(null);\n const [map, setMap] = useState(null);\n const [polygon, setPolygon] = useState(null);\n const [drawingMode, setDrawingMode] = useState(null);\n\n useFitMapBounds({markers, activeOverlay, map, isSearchOnMapMove});\n\n const allOverlayOptions = useMemo(\n () => ({\n ...DEFAULT_OVERLAY_OPTIONS,\n ...(overlayOptions || {})\n }),\n [overlayOptions]\n );\n\n const googleMapOptions = useMemo(\n () => ({\n ...DEFAULT_GOOGLE_MAP_OPTIONS,\n ...(mapOptions || {})\n }),\n [mapOptions]\n );\n\n const handleChangeIsSearchOnMapMove = useCallback(\n (isSearchOnMapMove: boolean) => {\n onMapBoundsChanged(isSearchOnMapMove ? getMapBoundsPolygon(map) : null);\n setDrawingMode(null);\n clearTimeout(mapMoveEndTimer.current);\n },\n [map, onMapBoundsChanged]\n );\n\n const handleMapMoveStart = useCallback(() => {\n clearTimeout(mapMoveEndTimer.current);\n }, []);\n\n const handleMapMoveEnd = useCallback(() => {\n if (isSearchOnMapMove) {\n onMapBoundsChanged(getMapBoundsPolygon(map));\n }\n }, [isSearchOnMapMove, map, onMapBoundsChanged]);\n\n const handleMapIdle = useCallback(() => {\n if (isSearchOnMapMove) {\n clearTimeout(mapMoveEndTimer.current);\n mapMoveEndTimer.current = setTimeout(handleMapMoveEnd, ON_MAP_MOVE_DEBOUNCE_INTERVAL);\n }\n }, [handleMapMoveEnd, isSearchOnMapMove]);\n\n const handleOverlayChange = useCallback(\n (e, propOverlay?) => {\n const stateOverlay =\n propOverlay ||\n (polygon && {\n type: MAP_DRAWING_MODES.POLYGON,\n overlay: polygon\n });\n\n if (!isEmpty(stateOverlay) && typeof onOverlayUpdated === 'function') {\n const {overlay, type} = stateOverlay;\n\n const typeActions = {\n [MAP_DRAWING_MODES.POLYGON]: () => {\n return overlay\n .getPath()\n .getArray()\n .map((latlng) => [latlng.lat(), latlng.lng()]);\n },\n [MAP_DRAWING_MODES.CIRCLE]: () => {\n return {radius: overlay.getRadius() / 1000, center: overlay.getCenter()};\n }\n };\n\n const data = typeActions[type] && typeActions[type]();\n data && onOverlayUpdated({data, type});\n }\n },\n [onOverlayUpdated, polygon]\n );\n\n const handleOverlayComplete = useCallback(\n (type) => (overlay) => {\n handleOverlayChange(null, {type, overlay});\n overlay.setMap(null);\n setDrawingMode(null);\n },\n [handleOverlayChange]\n );\n\n const handleClearOverlay = useCallback(() => {\n onOverlayUpdated(null);\n }, [onOverlayUpdated]);\n\n const renderMarkers = (clusterer?) => {\n return markers\n .filter(prop('point'))\n .map((marker) => (\n <EntityMarker key={marker.id} marker={marker} clusterer={clusterer} onClick={onMarkerClicked} />\n ));\n };\n\n const renderMarkerClusterer = (options) => {\n return <MarkerClusterer options={options}>{renderMarkers}</MarkerClusterer>;\n };\n\n if (loadError) {\n return null;\n }\n\n if (!isLoaded) {\n return loadingElement;\n }\n\n return (\n <GoogleMap\n mapTypeId={window.google.maps.MapTypeId.ROADMAP}\n options={googleMapOptions}\n onLoad={setMap}\n zoom={defaultZoom}\n center={defaultCenter}\n onZoomChanged={handleMapMoveStart}\n onDragStart={handleMapMoveStart}\n onIdle={handleMapIdle}\n mapContainerClassName={mapContainerClassName}\n >\n {map && isSearchEnabled && Boolean(drawingModes.length) && (\n <MapControlContainer\n className={styles.mapControlContainer}\n position={window.google.maps.ControlPosition.TOP_RIGHT}\n map={map}\n >\n <TopRightMapControls\n hasActiveOverlay={!!activeOverlay}\n drawingModes={drawingModes}\n drawingMode={drawingMode}\n onDrawingModeChanged={setDrawingMode}\n onClearOverlay={handleClearOverlay}\n />\n </MapControlContainer>\n )}\n\n {map && isSearchEnabled && (\n <MapControlContainer\n className={styles.mapControlContainer}\n position={window.google.maps.ControlPosition.TOP_CENTER}\n map={map}\n >\n <TopCenterMapControls\n onChangeIsSearchOnMapMove={handleChangeIsSearchOnMapMove}\n isSearchOnMapMove={isSearchOnMapMove}\n />\n </MapControlContainer>\n )}\n\n {markerClusterer ? renderMarkerClusterer(markerClustererOptions) : renderMarkers()}\n\n {!getDrawingMode(drawingMode) &&\n activeOverlay &&\n propEq('type', MAP_DRAWING_MODES.POLYGON, activeOverlay) && (\n <Polygon\n onLoad={setPolygon}\n path={activeOverlay.path}\n editable={true}\n options={allOverlayOptions}\n onMouseUp={handleOverlayChange}\n onDragEnd={handleOverlayChange}\n />\n )}\n\n {isSearchEnabled && Boolean(drawingModes.length) && (\n <DrawingManager\n onPolygonComplete={handleOverlayComplete(MAP_DRAWING_MODES.POLYGON)}\n onCircleComplete={handleOverlayComplete(MAP_DRAWING_MODES.CIRCLE)}\n drawingMode={getDrawingMode(drawingMode)}\n options={{\n drawingControl: false,\n circleOptions: allOverlayOptions,\n polygonOptions: allOverlayOptions\n }}\n />\n )}\n </GoogleMap>\n );\n};\n","import PropTypes from 'prop-types';\nimport React from 'react';\n\nconst VerticalDivider = ({height, margin}) => (\n <div\n style={{\n width: '1px',\n height: `${height}px`,\n borderLeft: '1px solid rgba(0,0,0,0.38)',\n margin: `0 ${margin}px`,\n flexShrink: '0'\n }}\n />\n);\n\nVerticalDivider.propTypes = {\n height: PropTypes.number,\n margin: PropTypes.number\n};\n\nexport default VerticalDivider;\n","import {useEffect} from 'react';\nimport {useDispatch, useSelector} from 'react-redux';\nimport {evolve, map} from 'ramda';\nimport {entity as History, HistoryDiff, wrapInArrayIfNeeded} from '@reltio/mdm-sdk';\nimport mdmModule, {HistoryMode, profile} from '@reltio/mdm-module';\n\nexport const defaultHistoryDiff: HistoryDiff = {\n appearance: {},\n attributes: {},\n roles: [],\n tags: []\n};\n\nconst fixRefEntity = evolve({\n refEntity: wrapInArrayIfNeeded,\n refRelation: wrapInArrayIfNeeded\n});\n\nconst prepareHistorySlice = (historySlice) => {\n if (historySlice) {\n return evolve({\n attributes: map(map(fixRefEntity))\n })(historySlice);\n }\n return historySlice;\n};\n\nexport const useHistoryDiff = () => {\n const dispatch = useDispatch();\n const historySlice = useSelector(mdmModule.selectors.getHistorySlice);\n const historyDiff = useSelector(mdmModule.selectors.getHistoryDiff);\n const historyMode = useSelector(mdmModule.selectors.getHistoryMode);\n const entity = useSelector(mdmModule.selectors.getEntity);\n\n useEffect(() => {\n if (historySlice) {\n const {aEntity, bEntity} = historySlice;\n const historyManager = History.HistoryManager.createHistoryManager(History.AttributesDiff);\n const historyDiff: HistoryDiff = historyManager.computeEntityHistoryDiff(\n prepareHistorySlice(historyMode === HistoryMode.Current ? entity : bEntity),\n prepareHistorySlice(aEntity)\n );\n dispatch(profile.history.actions.setHistoryDiff(historyDiff));\n }\n }, [historySlice, historyMode, dispatch, entity]);\n\n return historyDiff || defaultHistoryDiff;\n};\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles((theme) => ({\n card: {\n borderBottom: '1px solid rgba(0,0,0,0.06)'\n },\n withBackground: {\n backgroundColor: 'rgba(0, 0, 0, 0.03)'\n },\n lineWrapper: {\n position: 'relative'\n },\n icon: {\n position: 'absolute',\n top: '8px',\n left: '16px',\n width: '32px',\n height: '32px',\n zIndex: 1\n },\n line: ({color}: {color: string}) => ({\n borderLeft: `3px solid ${color}`,\n position: 'absolute',\n left: 0,\n top: 0,\n bottom: 0\n }),\n info: {\n fontSize: '13px',\n color: theme.palette.text.secondary,\n wordWrap: 'break-word',\n lineHeight: '15px'\n },\n commentsInfo: {\n display: 'flex',\n alignItems: 'center',\n marginBottom: '-4px',\n marginTop: '7px'\n },\n commentsIcon: {\n width: '11px',\n height: '11px',\n marginLeft: '2px',\n marginRight: '6px',\n marginTop: '-2px'\n },\n infoValue: {\n color: theme.palette.text.primary\n },\n infoBlock: {\n display: 'flex',\n flexDirection: 'row',\n marginBottom: '5px'\n },\n header: {\n display: 'flex',\n flexDirection: 'row',\n paddingBottom: '12px'\n },\n flex: {\n flex: 1\n },\n caption: {\n fontSize: '16px',\n color: theme.palette.text.primary\n },\n title: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n marginBottom: '-4px'\n },\n flag: {\n height: '13px',\n width: '13px',\n marginTop: '-2px',\n stroke: '#000000',\n fill: 'none',\n margin: '2px 5px 0 5px'\n },\n date: {\n fontSize: '13px',\n color: theme.palette.text.primary\n },\n mainInfo: {\n display: 'flex',\n flexDirection: 'column',\n flex: 1\n },\n controlsBox: {\n marginRight: '16px',\n marginBottom: '12px',\n marginTop: '13px'\n },\n controlsInRow: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'space-between',\n marginBottom: '20px'\n },\n priority: {\n width: '162px'\n },\n comments: {\n marginLeft: '11px'\n }\n}));\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles({\n dueDate: {\n marginTop: 0,\n marginBottom: 0\n },\n dueDateInput: {\n height: '40px'\n },\n inputLabel: {\n fontSize: '14px'\n }\n});\n","import {useState, useCallback, useContext} from 'react';\nimport {useSelector} from 'react-redux';\nimport {updateDueDateForTask, WorkflowTaskData} from '@reltio/mdm-sdk';\nimport mdmModule from '@reltio/mdm-module';\nimport {useSafePromise} from '../../../hooks';\nimport {WorkflowTasksContext} from '../../../contexts/WorkflowTasksContext';\nimport {showWorkflowError} from '../helpers/errors';\nimport {useWorkflowCheckPermission} from './useWorkflowCheckPermission';\nimport {isOpenTask} from '../helpers';\n\nexport const useWorkflowDueDate = ({\n dueDate,\n taskId,\n isOpen\n}: Pick<WorkflowTaskData, 'dueDate' | 'taskId' | 'isOpen'>) => {\n const {updateTaskState} = useContext(WorkflowTasksContext) || {};\n const workflowPath: string = useSelector(mdmModule.selectors.getWorkflowPath);\n const environment: string = useSelector(mdmModule.selectors.getWorkflowEnvironmentUrl);\n const tenant: string = useSelector(mdmModule.selectors.getTenant);\n const safePromise = useSafePromise();\n const [updateRequestIsInProgress, setUpdateRequestIsInProgress] = useState(false);\n const checkWorkflowPermission = useWorkflowCheckPermission();\n const canUpdateTask = checkWorkflowPermission('UPDATE_TASK') && isOpenTask(isOpen);\n\n const updateDueDate = useCallback(\n (newValue: number) => {\n if (workflowPath && canUpdateTask && taskId && newValue && dueDate !== newValue) {\n setUpdateRequestIsInProgress(true);\n safePromise(\n updateDueDateForTask({\n taskId,\n workflowPath,\n environment,\n tenant,\n dueDate: newValue\n })\n )\n .then(() => {\n updateTaskState?.(taskId, {dueDate: newValue});\n })\n .catch(showWorkflowError)\n .finally(() => {\n setUpdateRequestIsInProgress(false);\n });\n }\n },\n [workflowPath, taskId, environment, tenant, updateTaskState, safePromise, dueDate, canUpdateTask]\n );\n return {updateDueDate, updateRequestIsInProgress, readOnly: !canUpdateTask};\n};\n","import React from 'react';\nimport i18n from 'ui-i18n';\nimport classnames from 'classnames';\nimport {pipe} from 'ramda';\nimport {WorkflowTaskData} from '@reltio/mdm-sdk';\n\nimport {useStyles} from './styles';\nimport {DateEditor} from '../../../editors';\nimport {useWorkflowDueDate} from '../../hooks/useWorkflowDueDate';\n\ntype Props = Pick<WorkflowTaskData, 'taskId' | 'dueDate'> & {\n isTaskOpen?: WorkflowTaskData['isOpen'];\n className?: string;\n};\nconst DueDateField = ({taskId, dueDate, isTaskOpen, className}: Props) => {\n const styles = useStyles();\n const {updateDueDate, updateRequestIsInProgress, readOnly} = useWorkflowDueDate({\n dueDate,\n taskId,\n isOpen: isTaskOpen\n });\n\n return (\n <DateEditor\n className={classnames(styles.dueDate, className)}\n disabled={updateRequestIsInProgress || readOnly}\n value={dueDate}\n label={i18n.text('Due date')}\n onChange={pipe((date) => date && date.getTime(), updateDueDate)}\n margin=\"dense\"\n InputProps={{className: styles.dueDateInput}}\n InputLabelProps={{classes: {root: styles.inputLabel}}}\n />\n );\n};\n\nexport default DueDateField;\n","import {useState, useCallback, useContext, useMemo} from 'react';\nimport {useSelector} from 'react-redux';\nimport i18n from 'ui-i18n';\nimport {updatePriorityForTask, WorkflowPriority, WorkflowTaskData} from '@reltio/mdm-sdk';\nimport mdmModule from '@reltio/mdm-module';\nimport {useSafePromise} from '../../../hooks';\nimport {WorkflowTasksContext} from '../../../contexts/WorkflowTasksContext';\nimport {showWorkflowError} from '../helpers/errors';\nimport {useWorkflowCheckPermission} from './useWorkflowCheckPermission';\nimport {isOpenTask} from '../helpers';\n\ntype PriorityOption = {label: string; value: number};\n\nexport const useWorkflowPriority = ({\n priority,\n taskId,\n isOpen\n}: Pick<WorkflowTaskData, 'taskId' | 'priority' | 'isOpen'>) => {\n const {updateTaskState} = useContext(WorkflowTasksContext) || {};\n const workflowPath: string = useSelector(mdmModule.selectors.getWorkflowPath);\n const environment: string = useSelector(mdmModule.selectors.getWorkflowEnvironmentUrl);\n const tenant: string = useSelector(mdmModule.selectors.getTenant);\n const safePromise = useSafePromise();\n const [updateRequestIsInProgress, setUpdateRequestIsInProgress] = useState(false);\n const checkWorkflowPermission = useWorkflowCheckPermission();\n const canUpdateTask = checkWorkflowPermission('UPDATE_TASK') && isOpenTask(isOpen);\n\n const updatePriority = useCallback(\n (newValue: PriorityOption) => {\n const {value: newPriority} = newValue;\n if (workflowPath && canUpdateTask && taskId && priority !== newPriority) {\n setUpdateRequestIsInProgress(true);\n safePromise(\n updatePriorityForTask({\n taskId,\n workflowPath,\n environment,\n tenant,\n priority: newPriority\n })\n )\n .then(() => {\n updateTaskState?.(taskId, {priority: newPriority});\n })\n .catch(showWorkflowError)\n .finally(() => {\n setUpdateRequestIsInProgress(false);\n });\n }\n },\n [workflowPath, taskId, environment, tenant, updateTaskState, safePromise, priority, canUpdateTask]\n );\n\n const priorities: PriorityOption[] = useMemo(\n () => [\n {\n label: i18n.text('Low'),\n value: WorkflowPriority.low\n },\n {\n label: i18n.text('Medium'),\n value: WorkflowPriority.medium\n },\n {\n label: i18n.text('High'),\n value: WorkflowPriority.high\n },\n {\n label: i18n.text('Urgent'),\n value: WorkflowPriority.urgent\n }\n ],\n []\n );\n return {priorities, updatePriority, updateRequestIsInProgress, readOnly: !canUpdateTask};\n};\n","import React from 'react';\nimport i18n from 'ui-i18n';\nimport {propEq} from 'ramda';\nimport {WorkflowTaskData} from '@reltio/mdm-sdk';\n\nimport DropDownSelector from '../../../DropDownSelector/DropDownSelector';\nimport {useWorkflowPriority} from '../../hooks/useWorkflowPriority';\n\ntype Props = Pick<WorkflowTaskData, 'taskId' | 'priority'> & {\n isTaskOpen?: WorkflowTaskData['isOpen'];\n className?: string;\n};\n\nconst PrioritySelector = ({taskId, priority, isTaskOpen, className}: Props) => {\n const {priorities, updatePriority, updateRequestIsInProgress, readOnly} = useWorkflowPriority({\n taskId,\n priority,\n isOpen: isTaskOpen\n });\n const disabled = updateRequestIsInProgress || readOnly;\n\n return (\n <DropDownSelector\n className={className}\n isDisabled={disabled}\n options={priorities}\n onChange={updatePriority}\n hideSelectedOptions={false}\n label={i18n.text('Priority')}\n value={priorities.find(propEq('value', priority))}\n TextFieldProps={{disabled}}\n height={40}\n />\n );\n};\n\nexport default PrioritySelector;\n","import {makeStyles} from '@material-ui/core/styles';\n\nconst pointColor = '#d8d8d8';\nconst lineStyle = '2px solid rgba(0,0,0,0.06)';\nconst pointSize = 6;\nconst blockWidth = 56;\nconst linePadding = 10;\nconst pointPadding = 15;\n\nexport const useStyles = makeStyles({\n decorator: {\n display: 'flex',\n alignItems: 'stretch'\n },\n lineBlock: {\n width: `${blockWidth}px`,\n flexShrink: 0\n },\n withLinePadding: {\n '& $noLine': {\n height: `${linePadding}px`\n },\n '& $line': {\n height: `calc(100% - ${linePadding}px)`\n }\n },\n noLine: {\n height: '0'\n },\n line: {\n height: '100%',\n position: 'relative',\n marginLeft: '31px',\n borderLeft: lineStyle,\n '&:before': {\n position: 'absolute',\n height: pointSize,\n width: pointSize,\n borderRadius: '50%',\n left: -pointSize + 1,\n top: `${pointPadding}px`,\n background: pointColor,\n content: '\"\"',\n display: 'block',\n border: '1px solid white'\n },\n '&$plain': {\n '&:before': {\n width: 0,\n border: 'none'\n }\n },\n '&$last': {\n height: `${pointPadding}px`\n }\n },\n content: {\n flex: 1,\n minWidth: 0\n },\n plain: {},\n last: {},\n rowDivider: {\n marginLeft: 0\n }\n});\n","import React from 'react';\nimport classnames from 'classnames';\nimport {useStyles} from './styles';\nimport {Divider as Divider} from '@material-ui/core';\n\ntype Props = {\n className?: string;\n children: React.ReactNode;\n plain?: boolean;\n first?: boolean;\n last?: boolean;\n transparent?: boolean;\n divider?: boolean;\n};\n\nconst LineDecorator = ({className, children, plain, first, last, transparent, divider}: Props) => {\n const styles = useStyles();\n return (\n <div className={classnames(className, styles.decorator)}>\n <div className={classnames(styles.lineBlock, {[styles.withLinePadding]: first})}>\n {!transparent && (\n <>\n <div className={styles.noLine} />\n <div className={classnames(styles.line, {[styles.plain]: plain}, {[styles.last]: last})} />\n </>\n )}\n </div>\n <div className={styles.content}>\n {children}\n {divider && <Divider className={styles.rowDivider} light variant=\"inset\" />}\n </div>\n </div>\n );\n};\n\nexport default LineDecorator;\n","import {WorkflowTaskData} from '@reltio/mdm-sdk';\n\nlet taskToColor = {};\nconst COLORS = [\n '#DC057B',\n '#5DC003',\n '#FEC92F',\n '#F57F27',\n '#B71137',\n '#056B97',\n '#4499AE',\n '#BD81BE',\n '#5F3577',\n '#A68560',\n '#555962'\n];\nlet colorIndex = 0;\n\nexport const resetTaskToColor = () => {\n taskToColor = {};\n colorIndex = 0;\n};\n\nexport const useWorkflowColor = ({\n processDefinitionDisplayName\n}: Pick<WorkflowTaskData, 'processDefinitionDisplayName'>) => {\n const hash = processDefinitionDisplayName;\n if (!taskToColor[hash]) {\n taskToColor[hash] = COLORS[colorIndex];\n colorIndex++;\n if (colorIndex > COLORS.length - 1) {\n colorIndex = 0;\n }\n }\n return taskToColor[hash];\n};\n","import React from 'react';\n\nconst SvgCollaborationIcon: React.FC<React.SVGProps<SVGSVGElement>> = (props) => {\n return (\n <svg\n width={20}\n height={20}\n viewBox=\"0 0 20 20\"\n xmlns=\"http://www.w3.org/2000/svg\"\n xmlnsXlink=\"http://www.w3.org/1999/xlink\"\n {...props}\n >\n <defs>\n <path\n d=\"M4 17.17L5.17 16H20V4H4v13.17zM20 2c1.1 0 2 .9 2 2v12c0 1.1-.9 2-2 2H6l-4 4V4c0-1.1.9-2 2-2h16zm-3 9H7v2h10v-2zm0-4H7v2h10V7z\"\n id=\"CollaborationIcon_svg__a\"\n />\n </defs>\n <g transform=\"translate(-2 -2)\" stroke=\"none\" strokeWidth={1} fill=\"none\" fillRule=\"evenodd\">\n <mask id=\"CollaborationIcon_svg__b\" fill=\"#fff\">\n <use xlinkHref=\"#CollaborationIcon_svg__a\" />\n </mask>\n <path fillOpacity={0.54} fill=\"#000\" mask=\"url(#CollaborationIcon_svg__b)\" d=\"M0 0h24v24H0z\" />\n </g>\n </svg>\n );\n};\n\nexport default SvgCollaborationIcon;\n","import React, {useState} from 'react';\nimport classnames from 'classnames';\nimport FlagIcon from '@material-ui/icons/Flag';\nimport i18n from 'ui-i18n';\nimport {WorkflowTaskData} from '@reltio/mdm-sdk';\nimport {Tooltip as Tooltip} from '@material-ui/core';\n\nimport {useStyles} from './styles';\n\nimport CollapseButton from '../../../CollapseButton/CollapseButton';\nimport AssigneeSelector from '../../components/AssigneeSelector/AssigneeSelector';\nimport DueDateField from '../../components/DueDateField/DueDateField';\nimport PrioritySelector from '../../components/PrioritySelector/PrioritySelector';\nimport WorkflowComments from '../../components/WorkflowComments';\nimport {getDCRId} from '../../helpers';\nimport TaskActions from '../../components/TaskActions/TaskActions';\nimport LineDecorator from '../../components/LineDecorator/LineDecorator';\nimport {useWorkflowColor} from '../../hooks/useWorkflowColor';\nimport {useWorkflowCheckPermission} from '../../hooks/useWorkflowCheckPermission';\nimport CollaborationIcon from '../../../../icons/CollaborationIcon';\n\ntype Props = {\n task: WorkflowTaskData;\n children?: React.ReactNode;\n actions?: React.ReactNode;\n Icon?: React.ElementType;\n};\n\nconst GenericWorkflowTaskCard = ({task, children, actions, Icon}: Props) => {\n const {\n taskId,\n dueDate,\n priority,\n assignee,\n createdBy,\n createTime,\n displayName: step,\n processDefinitionDisplayName,\n objectURIs,\n processInstanceComments,\n possibleActions,\n isOpen: isTaskOpen\n } = task;\n const dcrId = getDCRId(objectURIs);\n const color = useWorkflowColor({processDefinitionDisplayName});\n const styles = useStyles({color});\n const [isExpanded, setExpanded] = useState(false);\n const checkWorkflowPermission = useWorkflowCheckPermission();\n const canViewComments = checkWorkflowPermission('VIEW_PROCESS_INSTANCE_COMMENTS');\n return (\n <div className={styles.card}>\n <div className={classnames({[styles.withBackground]: isExpanded})}>\n <div className={styles.lineWrapper}>\n <div className={styles.line} />\n {Icon && <Icon className={styles.icon} />}\n <LineDecorator plain first transparent={!isExpanded}>\n <div className={styles.mainInfo}>\n <div className={styles.title}>\n <div className={classnames(styles.caption, styles.flex)}>\n {processDefinitionDisplayName}\n </div>\n <FlagIcon className={styles.flag} />\n <Tooltip title={i18n.text('Due date')}>\n <span className={styles.date}>{i18n.date(dueDate, 'L')}</span>\n </Tooltip>\n <CollapseButton\n isOpen={isExpanded}\n size=\"L\"\n onClick={() => {\n setExpanded(!isExpanded);\n }}\n />\n </div>\n <div className={styles.infoBlock}>\n <div className={styles.flex}>\n {dcrId && (\n <div className={styles.info}>\n {i18n.text('DCR ID')}\n {': '}\n <span className={styles.infoValue}>{dcrId}</span>\n </div>\n )}\n <div className={styles.info}>\n {i18n.text('Created by')}\n {': '}\n <span className={styles.infoValue}>{createdBy}</span> {i18n.text('on')}{' '}\n <span className={styles.infoValue}>{i18n.date(createTime, 'L')}</span>\n </div>\n <div className={styles.info}>\n {i18n.text('Step')}\n {': '}\n <span className={styles.infoValue}>{step}</span>\n </div>\n {canViewComments && processInstanceComments?.length > 0 && (\n <div className={styles.commentsInfo}>\n <CollaborationIcon className={styles.commentsIcon} />\n <div className={styles.infoValue}>{processInstanceComments.length}</div>\n </div>\n )}\n </div>\n {actions || (\n <TaskActions\n taskId={taskId}\n possibleActions={possibleActions}\n assignee={assignee}\n isTaskOpen={isTaskOpen}\n />\n )}\n </div>\n </div>\n </LineDecorator>\n </div>\n {isExpanded && (\n <LineDecorator plain>\n <div className={styles.controlsBox}>\n <div className={styles.controlsInRow}>\n <DueDateField taskId={taskId} dueDate={dueDate} isTaskOpen={isTaskOpen} />\n <PrioritySelector\n taskId={taskId}\n priority={priority}\n className={styles.priority}\n isTaskOpen={isTaskOpen}\n />\n </div>\n <AssigneeSelector taskId={taskId} assignee={assignee} isTaskOpen={isTaskOpen} />\n </div>\n </LineDecorator>\n )}\n </div>\n {isExpanded && (\n <>\n {children}\n {canViewComments && (\n <div className={styles.comments}>\n <WorkflowComments\n taskId={taskId}\n processInstanceComments={processInstanceComments}\n isTaskOpen={isTaskOpen}\n />\n </div>\n )}\n </>\n )}\n </div>\n );\n};\n\nexport default GenericWorkflowTaskCard;\n","import React from 'react';\n\nconst SvgDcrTaskIcon: React.FC<React.SVGProps<SVGSVGElement>> = (props) => {\n return (\n <svg width={28} height={28} viewBox=\"0 0 28 28\" xmlns=\"http://www.w3.org/2000/svg\" {...props}>\n <g stroke=\"none\" strokeWidth={1} fill=\"none\" fillRule=\"evenodd\">\n <circle fill=\"#42A5F5\" cx={14} cy={14} r={14} />\n <path\n d=\"M16.43 9.87c0 1.59 1.25 2.87 2.79 2.87 1.53 0 2.78-1.28 2.78-2.87C22 8.29 20.75 7 19.22 7c-1.54 0-2.79 1.29-2.79 2.87zm1.4 0c0-.79.62-1.43 1.39-1.43.77 0 1.39.64 1.39 1.43 0 .79-.62 1.44-1.39 1.44-.77 0-1.39-.65-1.39-1.44zm-6.26 8.26c0-1.59-1.25-2.87-2.79-2.87-1.53 0-2.78 1.28-2.78 2.87C6 19.71 7.25 21 8.78 21c1.54 0 2.79-1.29 2.79-2.87zM8.09 9.15v4.31h1.39v-2.87h2.78v2.15l2.78-2.87L12.26 7v2.15H8.09zm11.82 9.7v-4.31h-1.39v2.87h-2.78v-2.15l-2.78 2.87L15.74 21v-2.15h4.17z\"\n fill=\"#FFF\"\n opacity={0.87}\n />\n </g>\n </svg>\n );\n};\n\nexport default SvgDcrTaskIcon;\n","export enum OperationTypes {\n ADDED = 'added',\n EDITED = 'edited',\n DELETED = 'deleted',\n PINNED = 'pinned',\n IGNORED = 'ignored',\n PIN_DELETED = 'pin_deleted',\n IGNORE_DELETED = 'ignore_deleted'\n}\n\nexport enum DCRTypes {\n INSERT_ATTRIBUTE = 'INSERT_ATTRIBUTE',\n UPDATE_ATTRIBUTE = 'UPDATE_ATTRIBUTE',\n DELETE_ATTRIBUTE = 'DELETE_ATTRIBUTE',\n PIN_ATTRIBUTE = 'PIN_ATTRIBUTE',\n IGNORE_ATTRIBUTE = 'IGNORE_ATTRIBUTE',\n CREATE_ENTITY = 'CREATE_ENTITY',\n CREATE_RELATIONSHIP = 'CREATE_RELATIONSHIP',\n UPDATE_TAGS = 'UPDATE_TAGS',\n UPDATE_ROLES = 'UPDATE_ROLES',\n UPDATE_START_DATE = 'UPDATE_START_DATE',\n UPDATE_END_DATE = 'UPDATE_END_DATE',\n UPDATE_PROFILE_PIC_BY_URL = 'UPDATE_PROFILE_PIC_BY_URL',\n UPDATE_PROFILE_PIC_BY_URI = 'UPDATE_PROFILE_PIC_BY_URI',\n DELETE_RELATIONSHIP = 'DELETE_RELATIONSHIP'\n}\n","import i18n from 'ui-i18n';\nimport {allPass, always, equals, evolve, pipe, prop, when} from 'ramda';\nimport {AttributeType, DataTypes, getAttrDataTypeDefinition, isUrl} from '@reltio/mdm-sdk';\nimport {DCRTypes, OperationTypes} from '../../../constants/operations';\nimport {DCRAttributeValue, DCRObjectsInfo, EntityInfo, RelationInfo, Value} from '../../../types/dcrTypes';\n\nexport const getOperationType = (type: string, oldValue?: DCRAttributeValue) => {\n switch (type) {\n case DCRTypes.CREATE_RELATIONSHIP:\n case DCRTypes.INSERT_ATTRIBUTE:\n return OperationTypes.ADDED;\n case DCRTypes.UPDATE_TAGS:\n case DCRTypes.UPDATE_ROLES:\n case DCRTypes.UPDATE_ATTRIBUTE:\n return OperationTypes.EDITED;\n case DCRTypes.DELETE_ATTRIBUTE:\n case DCRTypes.DELETE_RELATIONSHIP:\n return OperationTypes.DELETED;\n case DCRTypes.PIN_ATTRIBUTE:\n return oldValue?.pin ? OperationTypes.PIN_DELETED : OperationTypes.PINNED;\n case DCRTypes.IGNORE_ATTRIBUTE:\n return oldValue?.ignored ? OperationTypes.IGNORE_DELETED : OperationTypes.IGNORED;\n }\n};\n\nexport const getOperationLabel = (operation: OperationTypes) => {\n const labels = {\n [OperationTypes.ADDED]: i18n.text('added'),\n [OperationTypes.EDITED]: i18n.text('edited'),\n [OperationTypes.DELETED]: i18n.text('deleted'),\n [OperationTypes.PINNED]: i18n.text('pinned'),\n [OperationTypes.PIN_DELETED]: i18n.text('pin deleted'),\n [OperationTypes.IGNORED]: i18n.text('ignored'),\n [OperationTypes.IGNORE_DELETED]: i18n.text('ignore deleted')\n };\n\n return labels[operation] || '';\n};\n\nexport const getAttributeDescription = (\n attrType: AttributeType,\n value: DCRAttributeValue,\n currentEntityUri: string,\n objectsInfo: DCRObjectsInfo = {}\n) => {\n let objectLabel: string, objectUri: string;\n\n const relation = objectsInfo[value.refObjectURI] as RelationInfo;\n if (relation) {\n objectUri = currentEntityUri === relation.startObjectUri ? relation.endObjectUri : relation.startObjectUri;\n objectLabel =\n currentEntityUri === relation.startObjectUri ? relation.endObjectLabel : relation.startObjectLabel;\n } else if (value.refEntity) {\n objectUri = value.refEntity.objectURI;\n objectLabel = (objectsInfo[objectUri] as EntityInfo).label;\n }\n\n return {\n objectUri,\n objectLabel\n };\n};\n\nexport const getDataTypeDefinition = (attributeType: AttributeType, attributeValue: Value) => {\n return when(\n allPass([pipe(prop('type'), equals(DataTypes.TYPE_STRING)), () => isUrl(attributeValue)]),\n evolve({type: always(DataTypes.TYPE_URL)})\n )(getAttrDataTypeDefinition(attributeType));\n};\n","import {complement, curry, flatten, is, isEmpty, pathOr, propOr, times} from 'ramda';\nimport {\n AttributeType,\n DataTypes,\n getAttributeTypeSubAttributes,\n getLabel,\n getRelationAttributesList,\n getRelationType,\n isEmptyValue,\n isSpecialAttribute,\n Metadata\n} from '@reltio/mdm-sdk';\nimport {DCRAttributes, DCRAttributeValue, DCRChange, EntityInfo, RelationInfo} from '../../../types/dcrTypes';\nimport {Diff} from '../types/diffTypes';\nimport {getFilteredAttrTypes} from '../../../../attributes/helpers/attributesView';\nimport {getOperationType} from './helpers';\nimport {DCRTypes} from '../../../constants/operations';\n\nconst getValues = (attributes: DCRAttributes | DCRChange, attrType: AttributeType) => {\n if ('newValue' in attributes || 'oldValue' in attributes) {\n const {newValue, oldValue, type} = attributes;\n const newAttrValues = pathOr([], ['value', attrType.name])(newValue);\n const oldAttrValues = pathOr([], ['value', attrType.name])(oldValue);\n\n const length = Math.max(newAttrValues.length, oldAttrValues.length);\n return times((index) => {\n const attributeValue = {\n newValue: newAttrValues[index],\n oldValue: oldAttrValues[index],\n type\n };\n\n return [{value: attributeValue}];\n }, length);\n }\n const values = attributes[attrType.name];\n return values ? [values] : [];\n};\n\nconst getEntityChanges = curry((metadata: Metadata, entityInfo: EntityInfo, changes: DCRAttributes) => {\n const attrTypes: AttributeType[] = getFilteredAttrTypes(metadata, entityInfo.type, [], []);\n return getAttributesList(metadata, attrTypes, changes);\n});\n\nconst getRelationChanges = curry(\n (metadata: Metadata, relationInfo: RelationInfo, changes: DCRAttributes, changeType: DCRTypes): Diff[] => {\n const addRelationOperationIfNeeded = (changes: DCRAttributes, changeType: DCRTypes) => {\n if (changeType === DCRTypes.CREATE_RELATIONSHIP || isEmptyValue(changes)) {\n const operation = getOperationType(changeType);\n return operation ? {operation} : {};\n }\n return {};\n };\n\n const relationType = getRelationType(metadata, relationInfo.type);\n const attrTypes = getRelationAttributesList(metadata, relationInfo.type);\n return flatten([\n {\n level: 1,\n label: propOr('', 'label', relationType),\n attributeType: relationType,\n attributeValue: {...relationInfo, ...changes},\n ...addRelationOperationIfNeeded(changes, changeType)\n },\n getAttributesList(metadata, attrTypes, changes, 2)\n ]);\n }\n);\n\nconst getAttributesList = (\n metadata: Metadata,\n attrTypes: AttributeType[],\n attributes: DCRAttributes | DCRChange,\n level = 0\n): Diff[] => {\n return flatten(\n attrTypes\n .map((attrType) => {\n return getValues(attributes, attrType).map((value) => {\n return value.map((attributeValue) => {\n return dcrAttributesFactory(metadata, attrType, attributeValue, level);\n });\n });\n })\n .filter(complement(isEmpty))\n );\n};\n\nconst getSimpleAttributeValue = (attributeType: AttributeType, attributeValue: DCRAttributeValue) => {\n const value = isSpecialAttribute(attributeType) ? attributeValue : attributeValue.value;\n return is(Object, value) ? value : {newValue: attributeValue, type: DCRTypes.INSERT_ATTRIBUTE};\n};\n\nconst dcrAttributesFactory = (\n metadata: Metadata,\n attributeType: AttributeType,\n attributeValue: DCRAttributeValue,\n level: number\n) => {\n switch (attributeType.type) {\n case DataTypes.TYPE_NESTED:\n case DataTypes.TYPE_IMAGE:\n return getNestedAttributeChange(metadata, attributeType, attributeValue, level);\n case DataTypes.TYPE_REFERENCE:\n return getReferenceAttributeChange(metadata, attributeType, attributeValue, level);\n default: {\n const value = getSimpleAttributeValue(attributeType, attributeValue);\n return getSimpleAttributeChange(attributeType, value as DCRChange, level);\n }\n }\n};\n\nconst getNestedAttributeChange = (\n metadata: Metadata,\n attributeType: AttributeType,\n attributeValue: DCRAttributeValue,\n level: number\n) => {\n const attributeTypeList = getAttributeTypeSubAttributes({} as Metadata, attributeType);\n const label = getLabel(attributeType?.label || attributeType?.name);\n return [\n {level, label, attributeType, attributeValue},\n getAttributesList(metadata, attributeTypeList, attributeValue.value as DCRAttributes, level + 1)\n ];\n};\n\nconst getReferenceAttributeChange = (\n metadata: Metadata,\n attributeType: AttributeType,\n attributeValue: DCRAttributeValue,\n level: number\n) => {\n const attributeTypeList = getAttributeTypeSubAttributes(metadata, attributeType);\n const label = attributeType?.label || attributeType?.name;\n\n return [\n {level, label, attributeType, attributeValue},\n getAttributesList(metadata, attributeTypeList, attributeValue.value as DCRAttributes, level + 1)\n ];\n};\n\nconst getDiffParameters = ({newValue, oldValue, type}: DCRChange) => {\n return type === DCRTypes.UPDATE_ATTRIBUTE ? {type, newValue, oldValue} : {type, newValue: oldValue || newValue};\n};\n\nconst getSimpleAttributeChange = (attributeType: AttributeType, attributeValue: DCRChange, level: number) => {\n const {newValue, oldValue, type} = getDiffParameters(attributeValue);\n const operation = getOperationType(type, oldValue as DCRAttributeValue);\n\n const label = attributeType?.label || attributeType?.name;\n\n return {\n attributeType,\n newValue,\n oldValue,\n operation,\n label,\n level\n };\n};\n\nexport {getEntityChanges, getRelationChanges};\n","import {\n concat,\n curry,\n difference,\n flatten,\n identity,\n isNil,\n omit,\n path,\n pick,\n pipe,\n propEq,\n propOr,\n reduce\n} from 'ramda';\nimport {\n Entity,\n EntityAttrTypes,\n generateTempUri,\n getRoleLabel,\n isEmptyValue,\n Metadata,\n Relation\n} from '@reltio/mdm-sdk';\nimport {DCRTypes} from '../../../constants/operations';\nimport {Diff} from '../types/diffTypes';\nimport {getEntityChanges, getRelationChanges} from './attributesHelpers';\n\nimport {\n DCRAttributes,\n DCRAttributeValue,\n DCRChange,\n DCRChanges,\n DCRObjectInfo,\n EntityInfo,\n RelationInfo\n} from '../../../types/dcrTypes';\n\nconst ATTRIBUTE_DELIMITER = '/';\nconst SPECIAL_ATTRIBUTES_NAMES = [\n 'defaultProfilePicValue',\n EntityAttrTypes.tags.name,\n EntityAttrTypes.roles.name,\n EntityAttrTypes.startDate.name,\n EntityAttrTypes.endDate.name\n];\n\nconst prepareStartOrEndDate = ({newValue, oldValue}: DCRChange): DCRChange[] => {\n const parseValue = (value) => (isNaN(value) || isEmptyValue(value) ? value : parseInt(value));\n\n const isExistedValue = (value) => value?.length && !isEmptyValue(value) && !isEmptyValue(value[0]);\n\n const isExistNewValue = isExistedValue(newValue);\n const isExistOldValue = isExistedValue(oldValue);\n if (isExistNewValue && isExistOldValue) {\n return [\n {\n type: DCRTypes.UPDATE_ATTRIBUTE,\n oldValue: {value: parseValue(oldValue[0])},\n newValue: {value: parseValue(newValue[0])}\n }\n ];\n } else if (isExistNewValue) {\n return [\n {\n type: DCRTypes.INSERT_ATTRIBUTE,\n newValue: {value: parseValue(newValue[0])}\n }\n ];\n } else if (isExistOldValue) {\n return [\n {\n type: DCRTypes.DELETE_ATTRIBUTE,\n oldValue: {value: parseValue(oldValue[0])}\n }\n ];\n }\n};\n\nconst prepareRolesOrTags = (metadata: Metadata, change: DCRChange): DCRChange[] => {\n const {newValue = [], oldValue = [], type} = change;\n const getLabel = type === DCRTypes.UPDATE_ROLES ? getRoleLabel(metadata) : identity;\n\n const diffNewValue = difference(newValue, oldValue);\n const diffOldValue = difference(oldValue, newValue);\n\n const items = [];\n\n if (diffNewValue.length) {\n items.push({\n type: DCRTypes.INSERT_ATTRIBUTE,\n newValue: {value: diffNewValue.map(getLabel).join(', ')}\n });\n }\n\n if (diffOldValue.length) {\n items.push({\n type: DCRTypes.DELETE_ATTRIBUTE,\n oldValue: {value: diffOldValue.map(getLabel).join(', ')}\n });\n }\n\n return items;\n};\n\nconst getPath = (change: DCRChange): string => {\n const {type, attributePath, refObjectURI, refAttributeType} = change;\n\n const path = type === DCRTypes.INSERT_ATTRIBUTE ? generateTempUri(attributePath) : attributePath;\n\n if (refObjectURI) {\n const typePath = refAttributeType.split('/attributes/');\n const id = refObjectURI.split(ATTRIBUTE_DELIMITER)[1];\n return [typePath[1], id, path].join(ATTRIBUTE_DELIMITER);\n }\n return path;\n};\n\nconst prepareAttribute = (container: DCRAttributes, change: DCRChange) => {\n const changePath = getPath(change);\n\n const pathArray = changePath.split(ATTRIBUTE_DELIMITER);\n\n let holder: DCRAttributes | DCRAttributeValue = container;\n\n for (let i = 0; i < pathArray.length - 1; i = i + 2) {\n const key = pathArray[i];\n const id = pathArray[i + 1];\n\n const currentValue = (holder[key] || []).find(propEq('id', id));\n\n const newValue = pathArray.length === i + 2 ? change : {};\n const value = currentValue ? currentValue : ({id, value: newValue} as DCRAttributeValue);\n\n const refObjectURI = change.refObjectURI?.indexOf(id) >= 0 && change.refObjectURI;\n if (refObjectURI) {\n value.refObjectURI = refObjectURI;\n }\n\n if (isNil(currentValue)) {\n holder[key] = (holder[key] || []).concat(value);\n }\n\n holder = value.value;\n }\n return container;\n};\n\nconst createEntityOrRelation = (metadata: Metadata, value: Entity | Relation) => {\n const {attributes = {}, startDate, endDate} = value;\n const {roles, tags, defaultProfilePicValue} = value as Entity;\n const newObject = {...attributes} as DCRAttributes;\n\n if (defaultProfilePicValue) {\n newObject['defaultProfilePicValue'] = [defaultProfilePicValue];\n }\n if (roles) {\n newObject[EntityAttrTypes.roles.name] = [\n {\n type: DCRTypes.INSERT_ATTRIBUTE,\n newValue: {value: roles.map(getRoleLabel(metadata)).join(', ')}\n }\n ];\n }\n if (tags) {\n newObject[EntityAttrTypes.tags.name] = [\n {\n type: DCRTypes.INSERT_ATTRIBUTE,\n newValue: {value: tags.join(', ')}\n }\n ];\n }\n if (startDate) {\n newObject[EntityAttrTypes.startDate.name] = [\n {\n type: DCRTypes.INSERT_ATTRIBUTE,\n newValue: {value: startDate}\n }\n ];\n }\n if (endDate) {\n newObject[EntityAttrTypes.endDate.name] = [\n {\n type: DCRTypes.INSERT_ATTRIBUTE,\n newValue: {value: endDate}\n }\n ];\n }\n return newObject;\n};\n\nconst mergeAttributesInChange = (\n metadata: Metadata,\n objectInfo: DCRObjectInfo,\n change: DCRChange,\n container: DCRAttributes = {}\n) => {\n const {type} = change;\n\n switch (type) {\n case DCRTypes.UPDATE_PROFILE_PIC_BY_URL:\n container['defaultProfilePicValue'] = [change.newValue];\n break;\n case DCRTypes.UPDATE_TAGS:\n container[EntityAttrTypes.tags.name] = prepareRolesOrTags(metadata, change);\n break;\n case DCRTypes.UPDATE_ROLES: {\n container[EntityAttrTypes.roles.name] = prepareRolesOrTags(metadata, change);\n break;\n }\n case DCRTypes.UPDATE_START_DATE:\n container[EntityAttrTypes.startDate.name] = prepareStartOrEndDate(change);\n break;\n case DCRTypes.UPDATE_END_DATE:\n container[EntityAttrTypes.endDate.name] = prepareStartOrEndDate(change);\n break;\n case DCRTypes.CREATE_RELATIONSHIP:\n case DCRTypes.CREATE_ENTITY: {\n return {\n ...container,\n ...createEntityOrRelation(metadata, change.newValue as Entity | Relation)\n };\n }\n case DCRTypes.INSERT_ATTRIBUTE:\n case DCRTypes.UPDATE_ATTRIBUTE:\n case DCRTypes.DELETE_ATTRIBUTE:\n case DCRTypes.PIN_ATTRIBUTE:\n case DCRTypes.IGNORE_ATTRIBUTE:\n prepareAttribute(container, change);\n break;\n default:\n break;\n }\n\n return container;\n};\n\nconst updateRelation = (metadata: Metadata, changes: DCRChanges, relationInfo: RelationInfo) => {\n const relationChanges: DCRChange[] = propOr([], relationInfo.uri)(changes);\n return relationChanges.reduce((result: DCRAttributes, change) => {\n return mergeAttributesInChange(metadata, relationInfo, change, result);\n }, {});\n};\n\nconst mergeChanges = (\n metadata: Metadata,\n changes: DCRChanges,\n entityInfo: EntityInfo,\n relationsInfo: RelationInfo[]\n): [Diff[], Diff[]] => {\n const getAttributeChanges = (attributeName: string) =>\n pipe(pick([attributeName]), getEntityChanges(metadata, entityInfo));\n const concatChanges = curry((getters, attributesTree) =>\n reduce((acc, getter) => concat(acc, getter(attributesTree)), [], getters)\n );\n\n const entityInfoChanges: DCRChange[] = propOr([], entityInfo.uri)(changes);\n\n const changesTree = entityInfoChanges.reduce((result: DCRAttributes, change: DCRChange) => {\n return mergeAttributesInChange(metadata, entityInfo, change, result);\n }, {});\n\n const relationsTrees = relationsInfo.map((relationInfo) => updateRelation(metadata, changes, relationInfo));\n\n const entityChanges: Diff[] = concatChanges(\n [\n pipe(omit(SPECIAL_ATTRIBUTES_NAMES), getEntityChanges(metadata, entityInfo)),\n getAttributeChanges(EntityAttrTypes.roles.name),\n getAttributeChanges(EntityAttrTypes.tags.name),\n getAttributeChanges(EntityAttrTypes.startDate.name),\n getAttributeChanges(EntityAttrTypes.endDate.name)\n ],\n changesTree\n );\n\n const relationsChanges: Diff[] = flatten(\n relationsInfo.map((relationInfo, index) => {\n const changeType: DCRTypes = path([relationInfo.uri, 0, 'type'], changes);\n return getRelationChanges(metadata, relationInfo, relationsTrees[index], changeType);\n })\n );\n\n return [entityChanges, relationsChanges];\n};\n\nexport {mergeChanges};\n","import {makeStyles} from '@material-ui/core/styles';\nimport {Theme} from '@material-ui/core';\n\nexport const useStyles = makeStyles((theme: Theme) => ({\n linkLabel: {\n color: theme.palette.primary.main,\n fontSize: '12px',\n letterSpacing: 0,\n lineHeight: '16px'\n }\n}));\n","import React from 'react';\nimport i18n from 'ui-i18n';\nimport {Link as Link} from '@material-ui/core';\n\nimport {useStyles} from './styles';\n\ntype Props = {\n onClick: () => void;\n suggestionsCount: number;\n isExpanded: boolean;\n className?: string;\n};\n\nconst ShowMoreLink = ({suggestionsCount, isExpanded, onClick, className}: Props) => {\n const styles = useStyles();\n return (\n <Link component=\"button\" variant=\"caption\" underline=\"none\" onClick={onClick} className={className}>\n <span className={styles.linkLabel}>\n {isExpanded\n ? i18n.text('View less suggestions')\n : i18n.text('View ${suggestionsCount} more suggestions', {suggestionsCount})}\n </span>\n </Link>\n );\n};\n\nexport default ShowMoreLink;\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles((theme) => ({\n field: {\n fontSize: '12px',\n lineHeight: '20px',\n color: theme.palette.text.primary,\n marginTop: '6px',\n overflow: 'hidden',\n wordBreak: 'break-word'\n },\n fieldName: {\n color: theme.palette.text.secondary,\n marginRight: '8px'\n },\n difference: {\n marginRight: '8px'\n },\n arrow: {\n margin: '0 4px',\n fontSize: '12px',\n color: theme.palette.text.primary\n },\n chip: {\n height: '20px',\n fontSize: '10px',\n fontWeight: 500,\n lineHeight: '16px',\n letterSpacing: 0,\n flexShrink: 0,\n textTransform: 'capitalize',\n color: theme.palette.primary.main,\n borderColor: theme.palette.primary.main,\n '&.edited': {\n color: '#CC7500',\n borderColor: '#CC7500'\n },\n '&.added': {\n color: '#599E0E',\n borderColor: '#599E0E'\n },\n '&.deleted': {\n color: '#CF0E26',\n borderColor: '#CF0E26'\n }\n }\n}));\n","import React from 'react';\nimport classnames from 'classnames';\nimport {isNil} from 'ramda';\nimport ArrowRightAltIcon from '@material-ui/icons/ArrowRightAlt';\nimport {Chip as Chip} from '@material-ui/core';\nimport {OperationTypes} from '../../../../constants/operations';\nimport {getOperationLabel} from '../../helpers/helpers';\n\nimport {useStyles} from './styles';\n\ntype Props = {\n label: React.ReactNode;\n oldValue?: React.ReactNode;\n newValue?: React.ReactNode;\n operation?: OperationTypes;\n className?: string;\n};\n\nconst ChangeView = ({label, oldValue, newValue, operation, className}: Props) => {\n const styles = useStyles();\n const value = oldValue || newValue;\n\n return (\n <div className={classnames(styles.field, className)}>\n <span className={styles.fieldName}>{label}:</span>\n {!isNil(value) && (\n <span className={styles.difference}>\n {value}\n {newValue && oldValue && (\n <>\n <ArrowRightAltIcon className={styles.arrow} />\n {newValue}\n </>\n )}\n </span>\n )}\n {operation && (\n <Chip\n variant=\"outlined\"\n label={getOperationLabel(operation)}\n className={classnames(styles.chip, operation)}\n />\n )}\n </div>\n );\n};\n\nexport default ChangeView;\n","import React from 'react';\nimport {DCRObjectsInfo} from '../../../types/dcrTypes';\n\nexport const AttributesChangesContext = React.createContext<DCRObjectsInfo>(null);\n\nAttributesChangesContext.displayName = 'AttributesChangesContext';\n","import {makeStyles} from '@material-ui/core/styles';\n\ntype StylesProps = {\n level: number;\n};\n\nexport const useStyles = makeStyles((theme) => ({\n linkContainer: {\n textDecoration: 'none',\n cursor: 'pointer',\n marginLeft: '4px'\n },\n linkLabel: {\n color: theme.palette.primary.main,\n fontSize: '12px',\n letterSpacing: 0,\n lineHeight: '16px'\n },\n disabledLink: {\n pointerEvents: 'none',\n cursor: 'default'\n },\n label: {\n color: theme.palette.text.primary\n },\n change: ({level = 0}: StylesProps) => ({\n marginLeft: `${level * 16}px`\n })\n}));\n","import React, {useCallback, useContext, useMemo} from 'react';\nimport {useSelector} from 'react-redux';\nimport {anyPass, ifElse, isNil, hasPath, path, when} from 'ramda';\nimport classnames from 'classnames';\nimport {getAttributeValue, getLabel, isReference} from '@reltio/mdm-sdk';\nimport mdmModule from '@reltio/mdm-module';\nimport ChangeView from '../ChangeView/ChangeView';\nimport {AttributesChangesContext} from '../../contexts/AttributesChangesContext';\nimport {getAttributeDescription, getDataTypeDefinition} from '../../helpers/helpers';\nimport {Diff, RelationAttributeValue} from '../../types/diffTypes';\nimport {ChangeValue, DCRAttributeValue, Value} from '../../../../types/dcrTypes';\nimport DataTypeValue from '../../../../../DataTypeValue/DataTypeValue';\nimport EntityUriLink from '../../../../../EntityUriLink/EntityUriLink';\n\nimport {useStyles} from './styles';\n\nconst DiffRenderer = ({label, level, attributeType, attributeValue, oldValue, newValue, operation}: Diff) => {\n const styles = useStyles({level});\n const entityUri = useSelector(mdmModule.selectors.getEntityUri);\n const objectsInfo = useContext(AttributesChangesContext);\n\n const getLinkDescription = useCallback(() => {\n if (isReference(attributeType)) {\n const value: DCRAttributeValue = when(\n anyPass([hasPath(['value', 'newValue']), hasPath(['value', 'oldValue'])]),\n ifElse(hasPath(['value', 'newValue']), path(['value', 'newValue']), path(['value', 'oldValue']))\n )(attributeValue);\n return getAttributeDescription(attributeType, value, entityUri, objectsInfo);\n } else if ('endObject' in attributeType) {\n const {endObjectUri, endObjectLabel} = attributeValue as RelationAttributeValue;\n return {\n objectUri: endObjectUri,\n objectLabel: endObjectLabel\n };\n }\n }, [attributeType, attributeValue, entityUri, objectsInfo]);\n\n const renderLink = useCallback(() => {\n const {objectUri, objectLabel} = getLinkDescription() || {};\n\n if (!isNil(objectUri) && !isNil(objectLabel)) {\n const isNotExist = objectsInfo[objectUri]?.isExist === false;\n return (\n <EntityUriLink\n value={objectUri}\n className={classnames(styles.linkContainer, {[styles.disabledLink]: isNotExist})}\n >\n <span className={classnames(styles.linkLabel, {[styles.label]: isNotExist})}>\n {getLabel(objectLabel)}\n </span>\n </EntityUriLink>\n );\n }\n return null;\n }, [getLinkDescription, objectsInfo, styles]);\n\n const changeLabel = useMemo(() => {\n return (\n <span>\n {label}\n {renderLink()}\n </span>\n );\n }, [label, renderLink]);\n\n const renderValue = useCallback(\n (value: ChangeValue) => {\n const attrValue: Value = getAttributeValue(value);\n return (\n <DataTypeValue value={attrValue} dataTypeDefinition={getDataTypeDefinition(attributeType, attrValue)} />\n );\n },\n [attributeType]\n );\n\n return (\n <ChangeView\n className={styles.change}\n label={changeLabel}\n oldValue={oldValue && renderValue(oldValue)}\n newValue={newValue && renderValue(newValue)}\n operation={operation}\n />\n );\n};\n\nexport default DiffRenderer;\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles({\n title: {\n fontSize: '12px',\n letterSpacing: 0,\n lineHeight: '16px',\n fontWeight: 500,\n marginTop: '8px'\n }\n});\n","import React from 'react';\nimport {has} from 'ramda';\nimport DiffRenderer from '../DiffRenderer/DiffRenderer';\nimport {Diff, Title} from '../../types/diffTypes';\n\nimport {useStyles} from './styles';\n\ntype Props = {\n changes: (Diff | Title)[];\n};\n\nconst DCRChangesList = ({changes}: Props) => {\n const styles = useStyles();\n return (\n <>\n {changes.map((change, index) => {\n return has('level', change) ? (\n <DiffRenderer {...(change as Diff)} key={index} />\n ) : (\n <div className={styles.title} key={index}>\n {change.label}\n </div>\n );\n })}\n </>\n );\n};\n\nexport default DCRChangesList;\n","import {has, filter, length, pipe} from 'ramda';\n\nexport const getSuggestionsCount = pipe(filter(has('operation')), length);\n","import {makeStyles} from '@material-ui/core/styles';\nimport {Theme} from '@material-ui/core';\n\nexport const useStyles = makeStyles((theme: Theme) => ({\n container: {\n boxSizing: 'border-box',\n border: '1px solid rgba(0,0,0,0.03)',\n borderRadius: '3px',\n backgroundColor: 'rgba(0,0,0,0.03)',\n padding: '10px',\n margin: '12px 16px 12px 0'\n },\n uri: {\n color: theme.palette.primary.main,\n textDecoration: 'none',\n cursor: 'pointer'\n },\n label: {\n fontSize: '12px',\n letterSpacing: 0,\n lineHeight: '16px'\n },\n showMoreLink: {\n marginTop: '8px'\n }\n}));\n","import React, {useMemo} from 'react';\nimport {useSelector} from 'react-redux';\nimport i18n from 'ui-i18n';\nimport {flatten} from 'ramda';\nimport mdmModule from '@reltio/mdm-module';\nimport {getEntityUriForLink, getLabel, Metadata} from '@reltio/mdm-sdk';\nimport {DCRChanges, DCRObjectsInfo, EntityInfo, RelationInfo} from '../../types/dcrTypes';\nimport {Diff, Title} from './types/diffTypes';\nimport {mergeChanges} from './helpers/mergeHelpers';\nimport ShowMoreLink from './components/ShowMoreLink/ShowMoreLink';\nimport DCRChangesList from './components/DCRChangesList/DCRChangesList';\nimport {AttributesChangesContext} from './contexts/AttributesChangesContext';\nimport {useCollapsibleList} from './hooks/useCollapsibleList';\nimport EntityUriLink from '../../../EntityUriLink/EntityUriLink';\n\nimport {useStyles} from './styles';\n\ntype Props = {\n changes: DCRChanges;\n objectsInfo: DCRObjectsInfo;\n entityInfo: EntityInfo;\n relationsInfo?: RelationInfo[];\n max?: number;\n};\n\nconst AttributesChanges = ({changes, objectsInfo, entityInfo, relationsInfo, max}: Props) => {\n const styles = useStyles();\n const metadata: Metadata = useSelector(mdmModule.selectors.getMetadata);\n\n const [mergedEntityChanges, mergedRelationsChanges] = useMemo(\n () => mergeChanges(metadata, changes, entityInfo, relationsInfo),\n [metadata, changes, entityInfo, relationsInfo]\n );\n\n const changesList: (Diff | Title)[] = useMemo(() => {\n const relationshipTitle: Title = {label: i18n.text('Relationships')};\n return mergedRelationsChanges.length > 0\n ? flatten([mergedEntityChanges, relationshipTitle, mergedRelationsChanges])\n : mergedEntityChanges;\n }, [mergedEntityChanges, mergedRelationsChanges]);\n\n const {isExpanded, onToggle, itemsToShow, collapsedSuggestionsCount} = useCollapsibleList(changesList, max);\n\n return (\n <AttributesChangesContext.Provider value={objectsInfo}>\n <div className={styles.container}>\n <EntityUriLink className={styles.uri} value={getEntityUriForLink(entityInfo)}>\n <div className={styles.label}>{getLabel(entityInfo.label)}</div>\n </EntityUriLink>\n <DCRChangesList changes={itemsToShow} />\n {collapsedSuggestionsCount > 0 && (\n <ShowMoreLink\n onClick={onToggle}\n suggestionsCount={collapsedSuggestionsCount}\n isExpanded={isExpanded}\n className={styles.showMoreLink}\n />\n )}\n </div>\n </AttributesChangesContext.Provider>\n );\n};\n\nexport default AttributesChanges;\n","import {useCallback, useMemo, useState} from 'react';\nimport {getSuggestionsCount} from '../helpers/contextHelpers';\nimport {Diff, Title} from '../types/diffTypes';\n\nconst DEFAULT_VISIBLE_ITEMS_COUNT = 3;\n\nexport const useCollapsibleList = (items: (Diff | Title)[], limit = DEFAULT_VISIBLE_ITEMS_COUNT) => {\n const [isExpanded, setIsExpanded] = useState(false);\n const onToggle = useCallback(() => setIsExpanded((value) => !value), []);\n\n const collapsedItems = useMemo(() => items.slice(0, limit), [items, limit]);\n const suggestionsCount = useMemo(() => getSuggestionsCount(items), [items]);\n const visibleSuggestionsCount = useMemo(() => getSuggestionsCount(collapsedItems), [collapsedItems]);\n\n const itemsToShow = isExpanded ? items : collapsedItems;\n const collapsedSuggestionsCount = suggestionsCount - visibleSuggestionsCount;\n\n return {isExpanded, onToggle, itemsToShow, collapsedSuggestionsCount};\n};\n","import {isEntityUri, isRelationUri} from '@reltio/mdm-sdk';\nimport {allPass, concat, curry, equals, filter, keys, map, pathOr, pipe, prop, uniq} from 'ramda';\nimport {\n GroupedObjectsInfo,\n DCRChanges,\n DCRObjectInfo,\n DCRObjectsInfo,\n EntityInfo,\n RelationInfo\n} from '../types/dcrTypes';\n\nexport const getEntitiesObjects = filter(pipe(prop('uri'), isEntityUri));\nexport const getRelationsObjects = filter(pipe(prop('uri'), isRelationUri));\n\nconst getRelations = (objectsWithChanges: DCRObjectInfo, entityUri: string) => {\n return filter(allPass([pipe(prop('uri'), isRelationUri), pipe(prop('startObjectUri'), equals(entityUri))]))(\n objectsWithChanges\n );\n};\n\nexport const extractObjectsFromChangeRequest = (changes: DCRChanges, objectsInfo: DCRObjectsInfo): DCRObjectInfo[] => {\n const getChange = (key) => prop([key], changes);\n return pipe(\n keys,\n filter(getChange),\n map((key) => ({...objectsInfo[key], uri: key}))\n )(objectsInfo);\n};\n\nexport const createEntityRelationsObjectByEntity = curry((objectsWithChanges: DCRObjectInfo, entity: EntityInfo) => {\n return {\n entity,\n relations: getRelations(objectsWithChanges, entity.uri)\n };\n});\n\nexport const createEntityRelationsObjectByRelation = curry((objectsInfo: DCRObjectInfo, relation: RelationInfo) => {\n const entity = objectsInfo[relation.startObjectUri];\n const relations = [relation];\n\n return entity ? {entity: {...entity, uri: relation.startObjectUri}, relations} : {relations};\n});\n\nexport const concatEntityRelationsObjects = (acc: Record<string, GroupedObjectsInfo>, object: GroupedObjectsInfo) => {\n const {entity, relations} = object;\n const {uri: entityUri} = entity;\n\n const mergedRelations = pipe(pathOr([], [entityUri, 'relations']), concat(relations), uniq)(acc);\n\n acc[entityUri] = {\n entity,\n relations: mergedRelations\n };\n\n return acc;\n};\n","import {useCallback, useEffect, useState} from 'react';\nimport {flatten, has, isEmpty, map, partition, path, pipe, reduce, values} from 'ramda';\nimport {getDataChangeRequest, getEntitiesByUris} from '@reltio/mdm-sdk';\nimport {useSafePromise} from '../../../hooks';\nimport {\n concatEntityRelationsObjects,\n createEntityRelationsObjectByEntity,\n createEntityRelationsObjectByRelation,\n extractObjectsFromChangeRequest,\n getEntitiesObjects,\n getRelationsObjects\n} from '../helpers/dcrHelpers';\nimport {GroupedObjectsInfo, ChangeRequest} from '../types/dcrTypes';\nimport {showWorkflowError} from '../helpers/errors';\n\nexport const useChangeRequest = (dcrUri: string) => {\n const [groupedObjects, setGroupedObjects] = useState<GroupedObjectsInfo[]>([]);\n const [dcr, setDcr] = useState<ChangeRequest>(null);\n const safePromise = useSafePromise();\n\n const requestEntities = useCallback((entityUris: string[]) => {\n if (isEmpty(entityUris)) {\n return Promise.resolve([]);\n }\n\n return safePromise(getEntitiesByUris(entityUris, {searchOptions: 'ovOnly', defaultMaxValues: 1}));\n }, []); // eslint-disable-line\n\n useEffect(() => {\n getDataChangeRequest(dcrUri)\n .then((dcr: ChangeRequest) => {\n const {changes, objectsInfo} = dcr;\n\n const objectsWithChanges = extractObjectsFromChangeRequest(changes, objectsInfo);\n\n const entityObjectsWithRelations: GroupedObjectsInfo[] = pipe(\n getEntitiesObjects,\n map(createEntityRelationsObjectByEntity(objectsWithChanges))\n )(objectsWithChanges);\n\n const relationsObjects: GroupedObjectsInfo[] = pipe(\n getRelationsObjects,\n map(createEntityRelationsObjectByRelation(objectsInfo))\n )(objectsWithChanges);\n\n const [relationsObjectsWithEntity, relationsObjectsWithoutEntity] = partition(\n has('entity'),\n relationsObjects\n );\n\n const entityUris: string[] = relationsObjectsWithoutEntity.map(\n path(['relations', 0, 'startObjectUri'])\n );\n\n requestEntities(entityUris)\n .then((entities) => {\n const relationsObjectsWithRequestedEntities = relationsObjectsWithoutEntity.map(\n (relationsObject, index) => {\n return {\n ...relationsObject,\n entity: entities[index]\n };\n }\n );\n\n pipe(\n flatten,\n reduce(concatEntityRelationsObjects, {}),\n values,\n setGroupedObjects\n )([\n entityObjectsWithRelations,\n relationsObjectsWithEntity,\n relationsObjectsWithRequestedEntities\n ]);\n })\n .catch(showWorkflowError);\n\n setDcr(dcr);\n })\n .catch(showWorkflowError);\n }, [dcrUri, requestEntities]);\n\n return {dcr, groupedObjects};\n};\n","import React from 'react';\nimport {WorkflowTaskData} from '@reltio/mdm-sdk';\nimport GenericWorkflowTaskCard from '../GenericWorkflowTaskCard/GenericWorkflowTaskCard';\nimport LineDecorator from '../../components/LineDecorator/LineDecorator';\nimport {getDCRUri} from '../../helpers';\nimport DcrTaskIcon from '../../../../icons/DcrTaskIcon';\nimport AttributesChanges from '../../components/AttributesChanges/AttributesChanges';\nimport {useChangeRequest} from '../../hooks/useChangeRequest';\n\ntype Props = {\n task: WorkflowTaskData;\n};\n\nconst DataChangeRequestTaskCard = ({task}: Props) => {\n const {objectURIs} = task;\n const dcrUri = getDCRUri(objectURIs);\n\n const {dcr, groupedObjects} = useChangeRequest(dcrUri);\n\n return (\n <GenericWorkflowTaskCard task={task} Icon={DcrTaskIcon}>\n {dcr &&\n groupedObjects.map((object, index: number) => (\n <LineDecorator key={index} last={index === groupedObjects.length - 1} divider={true}>\n <AttributesChanges\n entityInfo={object.entity}\n relationsInfo={object.relations}\n changes={dcr.changes}\n objectsInfo={dcr.objectsInfo}\n />\n </LineDecorator>\n ))}\n </GenericWorkflowTaskCard>\n );\n};\n\nexport default DataChangeRequestTaskCard;\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles({\n pmCard: {\n marginLeft: '-15px'\n }\n});\n","import React from 'react';\n\nconst SvgPmTaskIcon: React.FC<React.SVGProps<SVGSVGElement>> = (props) => {\n return (\n <svg width={28} height={28} viewBox=\"0 0 28 28\" xmlns=\"http://www.w3.org/2000/svg\" {...props}>\n <g stroke=\"none\" strokeWidth={1} fill=\"none\" fillRule=\"evenodd\">\n <circle fill=\"#1976D2\" cx={14} cy={14} r={14} />\n <path\n d=\"M22.5 14L18 9.5V13h-3.5L9 7.5 7.5 9l6.04 6H18v3.5l4.5-4.5zm-11.46 1.46L7.5 19 9 20.5l3.54-3.54-1.5-1.5z\"\n fill=\"#FFF\"\n opacity={0.87}\n />\n </g>\n </svg>\n );\n};\n\nexport default SvgPmTaskIcon;\n","import React from 'react';\nimport {useSelector} from 'react-redux';\nimport {WorkflowTaskData} from '@reltio/mdm-sdk';\nimport mdmModule from '@reltio/mdm-module';\n\nimport {useStyles} from './styles';\n\nimport GenericWorkflowTaskCard from '../GenericWorkflowTaskCard/GenericWorkflowTaskCard';\nimport LineDecorator from '../../components/LineDecorator/LineDecorator';\nimport PmTaskIcon from '../../../../icons/PmTaskIcon';\nimport {useMatchesLoader} from '../../../../hooks/useMatchesLoader';\nimport {ProfileMatchCard} from '../../../ProfileMatchCard/ProfileMatchCard';\n\ntype Props = {\n task: WorkflowTaskData;\n};\n\nconst defaultOptions = {\n showTransitiveMatches: true,\n showInactiveEntities: false\n};\n\nconst PotentialMatchTaskCard = ({task}: Props) => {\n const styles = useStyles();\n const {objectURIs} = task;\n const entity = useSelector(mdmModule.selectors.getEntity);\n const metadata = useSelector(mdmModule.selectors.getMetadata);\n const {matches, entitiesMap} = useMatchesLoader({\n enabled: !!entity.uri,\n entity,\n filter: '',\n rowsPerPage: Number.MAX_SAFE_INTEGER,\n page: 0,\n options: defaultOptions\n });\n const match = matches?.find(({object}) => objectURIs.includes(object.uri));\n\n return (\n <GenericWorkflowTaskCard task={task} Icon={PmTaskIcon}>\n {match && (\n <LineDecorator last>\n <div className={styles.pmCard}>\n <ProfileMatchCard metadata={metadata} entity={entity} match={match} entitiesMap={entitiesMap} />\n </div>\n </LineDecorator>\n )}\n </GenericWorkflowTaskCard>\n );\n};\n\nexport default PotentialMatchTaskCard;\n","import React from 'react';\n\nconst SvgDefaultTaskIcon: React.FC<React.SVGProps<SVGSVGElement>> = (props) => {\n return (\n <svg width={28} height={28} viewBox=\"0 0 28 28\" xmlns=\"http://www.w3.org/2000/svg\" {...props}>\n <g stroke=\"none\" strokeWidth={1} fill=\"none\" fillRule=\"evenodd\">\n <circle fill=\"#205191\" cx={14} cy={14} r={14} />\n <path\n d=\"M9.667 20.622c-.92 0-1.667-.744-1.667-1.662V8.99c0-.916.747-1.66 1.667-1.66h2.446A1.993 1.993 0 0114 6l.162.006a1.992 1.992 0 011.725 1.323h2.446c.92 0 1.667.745 1.667 1.662v9.97c0 .917-.747 1.661-1.667 1.661zm9-1.33V8.66h-1.334v1.993h-6.666V8.66H9.333v10.634h9.334zM15.86 14.46v1.302h-5.206V14.46h5.206zm1.494-2v1.302h-6.7V12.46h6.7zM14 7.33c.367 0 .667.298.667.664a.668.668 0 01-1.334 0c0-.366.3-.665.667-.665z\"\n fill=\"#FFF\"\n opacity={0.87}\n />\n </g>\n </svg>\n );\n};\n\nexport default SvgDefaultTaskIcon;\n","import React from 'react';\n\nconst SvgDeleteRequestTaskIcon: React.FC<React.SVGProps<SVGSVGElement>> = (props) => {\n return (\n <svg width={28} height={28} viewBox=\"0 0 28 28\" xmlns=\"http://www.w3.org/2000/svg\" {...props}>\n <g stroke=\"none\" strokeWidth={1} fill=\"none\" fillRule=\"evenodd\" opacity={0.87}>\n <circle fill=\"#0D47A1\" cx={14} cy={14} r={14} />\n <path\n d=\"M8.17 9.824v8.995c0 .886.72 1.606 1.607 1.606h8.352c.192 0 .375-.035.546-.097l1.38 1.382.804-.804-1.32-1.32-1.09-1.089-8.993-8.994-1.092-1.092-1.317-1.317-.803.803L8.17 9.824zm9.316 9.316h-8.03v-8.03l8.03 8.03zM9.777 7.575c-.192 0-.376.033-.55.094L10.42 8.86h.32v.322l1.607 1.606h4.819V8.86h1.284v8.03l1.285 1.286V9.182c0-.887-.72-1.607-1.606-1.607h-2.358a1.931 1.931 0 00-1.818-1.285 1.93 1.93 0 00-1.818 1.285H9.777zm3.533.643c0-.353.29-.643.643-.643.353 0 .642.29.642.643a.644.644 0 01-.642.642.644.644 0 01-.643-.642z\"\n fill=\"#FFF\"\n />\n </g>\n </svg>\n );\n};\n\nexport default SvgDeleteRequestTaskIcon;\n","import React from 'react';\nimport {PredefinedWorkflowProcessType, WorkflowTaskData} from '@reltio/mdm-sdk';\nimport GenericWorkflowTaskCard from './GenericWorkflowTaskCard/GenericWorkflowTaskCard';\nimport DataChangeRequestTaskCard from './DataChangeRequestTaskCard/DataChangeRequestTaskCard';\nimport PotentialMatchTaskCard from './PotentialMatchTaskCard/PotentialMatchTaskCard';\n\nimport DefaultTaskIcon from '../../../icons/DefaultTaskIcon';\nimport DeleteRequestTaskIcon from '../../../icons/DeleteRequestTaskIcon';\n\nexport type FactoryProps = {\n task: WorkflowTaskData;\n};\n\nclass WorkflowTaskCardsFactory {\n static build = ({task}: FactoryProps) => {\n const {processType} = task;\n switch (processType) {\n case PredefinedWorkflowProcessType.dataChangeRequestReview:\n return <DataChangeRequestTaskCard task={task} />;\n case PredefinedWorkflowProcessType.potentialMatchReview:\n return <PotentialMatchTaskCard task={task} />;\n case PredefinedWorkflowProcessType.recommendForDelete:\n return <GenericWorkflowTaskCard task={task} Icon={DeleteRequestTaskIcon} />;\n default:\n return <GenericWorkflowTaskCard task={task} Icon={DefaultTaskIcon} />;\n }\n };\n}\n\nexport default WorkflowTaskCardsFactory;\n","import WorkflowTaskCardsFactory, {FactoryProps} from './WorkflowTaskCardsFactory';\n\nexport const WorkflowTaskCard = ({task}: FactoryProps) => WorkflowTaskCardsFactory.build({task});\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles((theme) => ({\n popoverPaper: {\n width: '464px'\n },\n title: {\n fontSize: '20px',\n fontWeight: 500,\n letterSpacing: '0.25px',\n lineHeight: '24px',\n color: theme.palette.text.primary,\n marginBottom: '17px'\n },\n content: {\n display: 'flex',\n flexDirection: 'column',\n padding: '23px 24px 14px 24px'\n },\n simpleDropDownSelector: {\n marginBottom: '20px'\n },\n inputRoot: {\n paddingTop: '0 !important',\n paddingBottom: '0 !important'\n },\n select: {\n fontSize: '14px'\n },\n footer: {\n display: 'flex',\n justifyContent: 'flex-end',\n padding: '5px 8px 8px',\n borderTop: '1px solid rgba(0,0,0,0.12)'\n },\n cancelButton: {\n marginRight: '8px'\n },\n input: {\n fontSize: '14px'\n }\n}));\n","import React, {useState} from 'react';\nimport i18n from 'ui-i18n';\nimport {TextField as TextField} from '@material-ui/core';\nimport {Portal as Portal} from '@material-ui/core';\nimport {Snackbar as Snackbar} from '@material-ui/core';\nimport {Popover as Popover} from '@material-ui/core';\nimport {Typography as Typography} from '@material-ui/core';\nimport {Button as Button} from '@material-ui/core';\nimport SimpleDropDownSelector from '../../../SimpleDropDownSelector/SimpleDropDownSelector';\nimport {useWorkflowDefinitions} from '../../hooks/useWorkflowDefinitions';\nimport {useWorkflowProcessInstance} from '../../hooks/useWorkflowProcessInstance';\nimport {useStyles} from './styles';\n\ntype Props = {\n anchorEl: Element;\n onClose: () => void;\n};\n\nexport const AddWorkflowDialog = ({anchorEl, onClose}: Props) => {\n const styles = useStyles();\n\n const [comment, setComment] = useState('');\n const [taskType, setTaskType] = useState(null);\n const [isOpenSnackbar, setIsOpenSnackbar] = useState(false);\n\n const {definitions} = useWorkflowDefinitions();\n const {processInstance, loading} = useWorkflowProcessInstance();\n\n const handleChangeComment = (e) => {\n setComment(e.target.value);\n };\n\n const handleChangeTaskType = (value) => {\n setTaskType(value);\n };\n\n const handleStart = () => {\n processInstance(comment, taskType?.value)\n .then(() => {\n setIsOpenSnackbar(true);\n setComment('');\n setTaskType(null);\n onClose();\n })\n .catch(() => {});\n };\n\n const handleCloseSnackbar = () => {\n setIsOpenSnackbar(false);\n };\n\n const open = Boolean(anchorEl);\n\n return (\n <>\n <Popover\n open={open}\n anchorEl={anchorEl}\n onClose={onClose}\n anchorOrigin={{\n vertical: 'bottom',\n horizontal: 'right'\n }}\n transformOrigin={{\n vertical: 'top',\n horizontal: 'right'\n }}\n classes={{\n paper: styles.popoverPaper\n }}\n >\n <div className={styles.content}>\n <Typography className={styles.title}>{i18n.text('Add new workflow')}</Typography>\n <SimpleDropDownSelector\n className={styles.simpleDropDownSelector}\n variant=\"filled\"\n height={40}\n TextFieldProps={{\n InputProps: {\n disableUnderline: true\n }\n }}\n placeholder={i18n.text('Select task type')}\n value={taskType}\n onChange={handleChangeTaskType}\n label={''}\n options={definitions.map((definition) => {\n return {\n value: definition.type,\n label: definition.displayName\n };\n })}\n />\n <TextField\n variant=\"filled\"\n hiddenLabel\n size=\"small\"\n placeholder=\"Type a comment\"\n InputProps={{\n disableUnderline: true,\n classes: {\n input: styles.input,\n root: styles.inputRoot\n }\n }}\n value={comment}\n onChange={handleChangeComment}\n multiline={true}\n />\n </div>\n <div className={styles.footer}>\n <Button disabled={loading} className={styles.cancelButton} onClick={onClose}>\n {i18n.text('Cancel')}\n </Button>\n <Button disabled={loading} color=\"primary\" onClick={handleStart}>\n {i18n.text('Start')}\n </Button>\n </div>\n </Popover>\n <Portal container={document.body}>\n <Snackbar\n open={isOpenSnackbar}\n autoHideDuration={5000}\n onClose={handleCloseSnackbar}\n message={i18n.text('A new workflow has started')}\n />\n </Portal>\n </>\n );\n};\n","import {useEffect, useState} from 'react';\nimport mdmModule from '@reltio/mdm-module';\nimport {Entity, processDefinitions} from '@reltio/mdm-sdk';\nimport {useSelector} from 'react-redux';\n\nconst filterDefinitions = (definitions, entityType) => {\n return definitions.filter(({manualStart, objectTypes}) => {\n return manualStart && (!objectTypes || objectTypes?.some((_entityType) => _entityType === entityType));\n });\n};\n\nexport const useWorkflowDefinitions = () => {\n const [definitions, setDefinitions] = useState([]);\n\n const workflowPath: string = useSelector(mdmModule.selectors.getWorkflowPath);\n const environment: string = useSelector(mdmModule.selectors.getWorkflowEnvironmentUrl);\n const tenant: string = useSelector(mdmModule.selectors.getTenant);\n const entity: Entity = useSelector(mdmModule.selectors.getEntity);\n const entityType = entity.type;\n\n useEffect(() => {\n processDefinitions({workflowPath, environment, tenant}).then(({data}) =>\n setDefinitions(filterDefinitions(data, entityType))\n );\n }, [entityType, workflowPath, environment, tenant]);\n\n return {definitions};\n};\n","import {useCallback, useContext, useState} from 'react';\nimport {useSelector} from 'react-redux';\nimport mdmModule from '@reltio/mdm-module';\nimport {Entity, startProcessInstance} from '@reltio/mdm-sdk';\nimport {WorkflowTasksContext} from '../../../contexts/WorkflowTasksContext';\nimport {showWorkflowError} from '../helpers/errors';\n\nexport const useWorkflowProcessInstance = () => {\n const {loadTasks} = useContext(WorkflowTasksContext);\n const workflowPath: string = useSelector(mdmModule.selectors.getWorkflowPath);\n const environment: string = useSelector(mdmModule.selectors.getWorkflowEnvironmentUrl);\n const tenant: string = useSelector(mdmModule.selectors.getTenant);\n const entity: Entity = useSelector(mdmModule.selectors.getEntity);\n const entityUri = entity.uri;\n const [loading, setLoading] = useState(false);\n\n const processInstance = useCallback(\n (comment, taskType) => {\n setLoading(true);\n\n return startProcessInstance({\n workflowPath,\n tenant,\n environment,\n processType: taskType,\n comment,\n objectURIs: [entityUri]\n })\n .then(() => {\n loadTasks();\n })\n .catch((error) => {\n showWorkflowError(error);\n throw error;\n })\n .finally(() => {\n setLoading(false);\n });\n },\n [entityUri, environment, loadTasks, tenant, workflowPath]\n );\n\n return {processInstance, loading};\n};\n","import {makeStyles} from '@material-ui/core/styles';\n\nexport const useStyles = makeStyles({\n button: {\n padding: '9px 16px 9px 12px',\n marginLeft: 'auto',\n marginRight: '8px'\n },\n buttonLabel: {\n fontSize: '14px',\n fontWeight: 500,\n lineHeight: '16px'\n },\n icon: {\n fontSize: '18px',\n marginRight: '8px'\n }\n});\n","import React, {useState} from 'react';\nimport i18n from 'ui-i18n';\nimport {Button as Button} from '@material-ui/core';\nimport AddIcon from '@material-ui/icons/Add';\nimport {useWorkflowCheckPermission} from '../../hooks/useWorkflowCheckPermission';\nimport {AddWorkflowDialog} from '../AddWorkflowDialog/AddWorkflowDialog';\nimport {useStyles} from './styles';\n\nexport const AddWorkflowButton = () => {\n const styles = useStyles();\n const [anchorEl, setAnchorEl] = useState(null);\n\n const checkWorkflowPermission = useWorkflowCheckPermission();\n const canStartProcess = checkWorkflowPermission('START_PROCESS_INSTANCE');\n const canViewProcessDefinitions = checkWorkflowPermission('VIEW_PROCESS_DEFINITIONS');\n\n const handleOpen = (e) => setAnchorEl(e.currentTarget);\n const handleClose = () => setAnchorEl(null);\n\n return canStartProcess && canViewProcessDefinitions ? (\n <>\n <Button color=\"primary\" className={styles.button} onClick={handleOpen}>\n <AddIcon className={styles.icon} />\n <div className={styles.buttonLabel}>{i18n.text('Add')}</div>\n </Button>\n <AddWorkflowDialog anchorEl={anchorEl} onClose={handleClose} />\n </>\n ) : null;\n};\n","import {useCallback, useEffect, useState} from 'react';\nimport {useSelector} from 'react-redux';\nimport {filter, flatten, isNil, map, mergeLeft, pipe, prop, propEq, reject, uniqBy, when} from 'ramda';\nimport mdmModule from '@reltio/mdm-module';\nimport {getTasksForEntity, isTempUri, WorkflowTaskData} from '@reltio/mdm-sdk';\nimport {useSafePromise} from '../../../hooks/useSafePromise';\nimport {useWorkflowCheckPermission} from './useWorkflowCheckPermission';\n\ntype Config = {\n processTypes?: string[];\n assignee?: string;\n showClosedTasks?: boolean;\n};\n\nexport const useWorkflowTasks = (config?: Config) => {\n const {processTypes, assignee, showClosedTasks} = config || {};\n const safePromise = useSafePromise();\n const workflowPath: string = useSelector(mdmModule.selectors.getWorkflowPath);\n const environment: string = useSelector(mdmModule.selectors.getWorkflowEnvironmentUrl);\n const isWorkflowEnabled = useSelector(mdmModule.selectors.isWorkflowEnabled);\n const tenant: string = useSelector(mdmModule.selectors.getTenant);\n const entityUri = useSelector(mdmModule.selectors.getEntityUri);\n const isEditableMode = useSelector(mdmModule.selectors.getIsEditableMode);\n const checkWorkflowPermission = useWorkflowCheckPermission();\n const canViewTasks = checkWorkflowPermission('VIEW_TASKS');\n const enabled = !!(workflowPath && environment) && isWorkflowEnabled && canViewTasks;\n const [tasks, setTasks] = useState<WorkflowTaskData[]>(null);\n const [total, setTotal] = useState<number>(0);\n const [loading, setLoading] = useState<boolean>(false);\n\n const loadTasks = useCallback(() => {\n setLoading(true);\n const parsedProcessTypes = !Array.isArray(processTypes) || processTypes.includes('*') ? null : processTypes;\n const requests = (parsedProcessTypes || [null]).map((processType) =>\n getTasksForEntity({\n entityUri,\n workflowPath,\n environment,\n tenant,\n filter: {assignee, processType},\n includeClosed: !!showClosedTasks\n })\n );\n safePromise(Promise.all(requests))\n .then((responses) => {\n const tasks: WorkflowTaskData[] = pipe(\n map(prop('data')),\n reject(isNil),\n flatten,\n uniqBy(prop('taskId')),\n filter(isRequestedTask(parsedProcessTypes, assignee))\n )(responses);\n setTasks(tasks);\n setTotal(tasks.length);\n })\n .catch((error) => {\n console.warn('Workflow error', error);\n })\n .finally(() => {\n setLoading(false);\n });\n }, [entityUri, environment, safePromise, tenant, workflowPath, assignee, showClosedTasks, processTypes]);\n\n useEffect(() => {\n if (entityUri && enabled && !isTempUri(entityUri)) {\n loadTasks();\n } else {\n setTasks(null);\n setTotal(0);\n }\n }, [enabled, entityUri, loadTasks, isEditableMode]);\n\n const updateTaskState = useCallback((taskId: WorkflowTaskData['taskId'], payload: Partial<WorkflowTaskData>) => {\n setTasks(map(when(propEq('taskId', taskId), mergeLeft(payload))));\n }, []);\n\n return {tasks, total, loading, updateTaskState, loadTasks};\n};\n\nconst isRequestedTask = (processTypes: string[], assignee: string) => (task: WorkflowTaskData) =>\n (!processTypes || processTypes.includes(task.processType)) && (!assignee || assignee === task.assignee);\n","export const MAP_DRAWING_MODES = {\n CIRCLE: 'circle',\n POLYGON: 'polygon'\n};\n\nexport const DEFAULT_OVERLAY_OPTIONS = {\n fillColor: 'rgb(242,82,82)',\n fillOpacity: 0.1,\n strokeWeight: 2,\n strokeColor: '#F25252',\n clickable: false,\n editable: true,\n zIndex: 1\n};\n\nexport const DEFAULT_GOOGLE_MAP_OPTIONS = {\n mapTypeControl: false,\n streetViewControl: false,\n fullscreenControl: false\n};\n\nexport const MAP_MINIMUM_SCALE_RADIUS = 0.001;\n","import React from 'react';\n\ntype Value = {\n activeEntityUri?: string;\n};\n\nexport const EntityMarkerContext = React.createContext<Value>({});\nEntityMarkerContext.displayName = 'EntityMarkerContext';\n","import React from 'react';\nimport {InterceptHandlers} from '@reltio/mdm-sdk';\n\nexport const InterceptHandlersContext = React.createContext<InterceptHandlers>({});\n\nInterceptHandlersContext.displayName = 'InterceptHandlersContext';\n","import React from 'react';\n\nexport const ProfilePerspectiveViewContext = React.createContext(false);\n\nProfilePerspectiveViewContext.displayName = 'ProfilePerspectiveViewContext';\n","import React from 'react';\nimport {QxSandboxApi} from '@reltio/mdm-sdk';\n\nexport const SandboxAPIContext = React.createContext<QxSandboxApi>({\n getCurrentPerspectiveId: () => '',\n setEntityUri: () => {},\n showPerspective: () => {}\n});\n","import {\n AccessToken,\n CustomActionTaskParams,\n CustomActionExtension,\n CustomActionViewConfig,\n CustomScriptExtension,\n getAccessToken,\n RequestAction,\n sendRequestFromCustomSandbox,\n sendWorkflowRequest,\n startProcessFromQuery,\n Entity\n} from '@reltio/mdm-sdk';\nimport {isNewUI} from './helpers';\nimport {ProcessRequestParams} from './types';\n\ntype Config = CustomActionExtension | CustomActionViewConfig | CustomScriptExtension;\n\nconst processFromQuery = (\n params: CustomActionTaskParams,\n permissions?: string[] | undefined,\n workflowPath?: string,\n tenant?: string,\n environment?: string\n) => {\n if (!params.processDefinitionId) {\n return new Promise((resolve) => resolve({errorMessage: 'processDefinitionId is empty'}));\n }\n if (!params.searchString) {\n return new Promise((resolve) => resolve({errorMessage: 'searchString is empty'}));\n }\n if (!workflowPath) {\n return new Promise((resolve) => resolve({errorMessage: 'Workflow path is not defined'}));\n }\n const errors = validateParams({url: '/processInstances/_generateFromQuery', ...params}, permissions);\n if (errors) {\n return new Promise((resolve) => resolve(errors));\n }\n\n return startProcessFromQuery({\n workflowPath,\n processType: params.processDefinitionId,\n searchString: params.searchString,\n tenant,\n environment\n });\n};\n\nconst getHeaders = async (params: CustomActionTaskParams, signHandler?: () => Promise<AccessToken>) => {\n const {accessToken} = await signHandler?.();\n return accessToken\n ? {\n ...params.headers,\n Authorization: `Bearer ${accessToken}`\n }\n : params.headers;\n};\n\nconst workflowRequest = async (\n params: CustomActionTaskParams,\n permissions?: string[],\n workflowPath?: string,\n tenant?: string,\n signHandler?: () => Promise<AccessToken>\n) => {\n const {url} = params;\n const errors = validateParams(params, permissions);\n if (errors) {\n return errors;\n }\n const isExternalUrl = url.includes('http:') || url.includes('https:');\n if (!workflowPath && !isExternalUrl) {\n return {errorMessage: 'Workflow path is not defined'};\n }\n const headers = await getHeaders(params, signHandler);\n return await sendWorkflowRequest({\n url,\n method: params.method || 'GET',\n data: params.data,\n tenant,\n headers,\n workflowPath\n });\n};\n\nconst sendApiRequest = async (\n params: CustomActionTaskParams,\n permissions?: string[],\n signHandler?: () => Promise<AccessToken>\n) => {\n const errors = validateParams(params, permissions);\n if (errors) {\n return errors;\n }\n const headers = await getHeaders(params, signHandler);\n return await sendRequestFromCustomSandbox({\n url: params.url,\n method: params.method,\n data: params.data,\n headers,\n noRequestProcessor: true\n });\n};\n\nconst validateParams = (params: CustomActionTaskParams, permissions?: string[]) => {\n const {url} = params;\n if (!url) return {errorMessage: 'URL is empty'};\n const allowed = permissions?.some((permission) => {\n const urlOrigin = url.match(/^(https?:\\/\\/[^:/?#]*).*$/)?.[1];\n const permRegex = new RegExp('^' + permission + '$');\n const decodedPerm = permission.replace(/\\/*$/, '');\n return (\n decodedPerm === url ||\n (urlOrigin && urlOrigin === decodedPerm) ||\n (decodedPerm?.startsWith('/') && url?.startsWith(decodedPerm)) ||\n (permission && permRegex.test(url))\n );\n });\n\n if (!allowed || (permissions?.length || 0) === 0) {\n return {errorMessage: 'Not enough permissions'};\n }\n return false;\n};\n\nexport const processRequest = ({\n name,\n paramObject,\n permissions,\n worker,\n metadata,\n config,\n apiPath,\n servicesPath,\n user,\n workflowPath,\n entity,\n tenant,\n entityUri,\n query,\n openSearch,\n environment,\n getCurrentPerspectiveId,\n showPerspective,\n workflowCheckPermission,\n setEntityUri\n}: ProcessRequestParams) => {\n const handleRequest = (request: Promise<any>) => {\n request\n .then((data) => {\n worker.postMessage({\n action: 'response',\n result: {data, headers: paramObject.params.headers, status: 200},\n ...paramObject.params\n });\n })\n .catch((error) => {\n worker.postMessage({\n action: 'response',\n result: {data: error, headers: paramObject.params.headers, status: 0},\n ...paramObject.params\n });\n });\n };\n const shouldSignRequest = isNewUI(servicesPath);\n const signHandler = shouldSignRequest\n ? () => getAccessToken({servicesPath})\n : () => Promise.resolve({accessToken: ''});\n\n switch (name) {\n case RequestAction.API: {\n const request = sendApiRequest(paramObject.params, permissions, signHandler);\n handleRequest(request);\n break;\n }\n case RequestAction.WORKFLOW: {\n const request = workflowRequest(paramObject.params, permissions, workflowPath, tenant, signHandler);\n handleRequest(request);\n break;\n }\n case RequestAction.WORKFLOW_START_PROCESS_FROM_QUERY: {\n const request = processFromQuery(paramObject.params, permissions, workflowPath, tenant, environment);\n handleRequest(request);\n break;\n }\n case RequestAction.GET_CONFIGURATION: {\n worker.postMessage({action: 'response', result: metadata, ...paramObject.params});\n break;\n }\n case RequestAction.GET_UI_CONFIGURATION: {\n const response = {...config, action: {...config.action}};\n if (response.action.permissions) {\n delete response.action.permissions;\n }\n worker.postMessage({action: 'response', result: response, ...paramObject.params});\n break;\n }\n case RequestAction.SET_ENTITY_URI: {\n const listener = (newEntity: Entity) =>\n worker.postMessage({action: 'response', result: newEntity, ...paramObject.params});\n setEntityUri(paramObject.params.entityUri, listener);\n break;\n }\n case RequestAction.SET_PERSPECTIVE: {\n showPerspective(paramObject.params.perspective);\n worker.postMessage({\n action: 'response',\n result: getCurrentPerspectiveId(),\n ...paramObject.params\n });\n break;\n }\n case RequestAction.GET_PERSPECTIVE: {\n if (getCurrentPerspectiveId) {\n worker.postMessage({\n action: 'response',\n result: getCurrentPerspectiveId(),\n ...paramObject.params\n });\n }\n break;\n }\n case RequestAction.WORKFLOW_CHECK_PERMISSION: {\n worker.postMessage({\n action: 'response',\n result: workflowCheckPermission(paramObject.params.permission),\n ...paramObject.params\n });\n break;\n }\n case RequestAction.GET_SEARCH_QUERY: {\n worker.postMessage({action: 'response', result: query, ...paramObject.params});\n break;\n }\n case RequestAction.OPEN_SEARCH: {\n openSearch({viewId: (config as Config).id, searchState: paramObject.params.searchState || {}});\n break;\n }\n case RequestAction.GET_ENTITY_URI: {\n worker.postMessage({action: 'response', result: entityUri, ...paramObject.params});\n break;\n }\n case RequestAction.GET_ENTITY: {\n worker.postMessage({action: 'response', result: entity, ...paramObject.params});\n break;\n }\n case RequestAction.GET_API_PATH: {\n worker.postMessage({action: 'response', result: apiPath, ...paramObject.params});\n break;\n }\n case RequestAction.WORKFLOW_GET_WORKFLOW_PATH: {\n worker.postMessage({action: 'response', result: workflowPath, ...paramObject.params});\n break;\n }\n case RequestAction.GET_TENANT: {\n worker.postMessage({action: 'response', result: tenant, ...paramObject.params});\n break;\n }\n case RequestAction.GET_USER: {\n worker.postMessage({action: 'response', result: user, ...paramObject.params});\n break;\n }\n case RequestAction.ALERT: {\n worker.postMessage({\n action: 'response',\n result: window.alert(paramObject.params.text),\n ...paramObject.params\n });\n break;\n }\n case RequestAction.CONFIRM: {\n worker.postMessage({\n action: 'response',\n result: window.confirm(paramObject.params.text),\n ...paramObject.params\n });\n break;\n }\n case RequestAction.PROMPT: {\n worker.postMessage({\n action: 'response',\n result: window.prompt(paramObject.params.text, paramObject.params.defaultText || ''),\n ...paramObject.params\n });\n break;\n }\n case RequestAction.OPEN_WINDOW: {\n window.open(paramObject.params.url, '_blank');\n break;\n }\n case RequestAction.RELOAD_PAGE: {\n location.reload();\n break;\n }\n }\n};\n","import nanoid from 'nanoid';\n\nexport const isNewUI = (path?: string): boolean => {\n return path?.includes('/nui');\n};\n\nexport const getWorkerURL = (uiPath: string, tenant: string) => {\n if (isNewUI(uiPath)) {\n return `${uiPath.replace(`${tenant}/`, '')}worker_api.js`;\n } else {\n return `${uiPath}worker_api.js`;\n }\n};\n\nexport const getFilesWithArrayBuffer = (files: FileList) => {\n const readFilePromises = Array.from(files).map((file) => {\n return new Promise((resolve, reject) => {\n const reader = new FileReader();\n reader.onload = (event) => {\n const content = event.target.result;\n const {lastModified, name, size, type} = file;\n resolve({lastModified, name, size, type, content});\n };\n reader.onerror = (error) => {\n reject(error);\n };\n reader.readAsArrayBuffer(file);\n });\n });\n return Promise.all(readFilePromises);\n};\n\nconst processInnerHtml = (parent: HTMLElement, worker: Worker, setTooltip) => {\n let handlersToReset = [];\n const uiActions = parent.getAttribute('ui-actions');\n const uiTooltip = parent.getAttribute('ui-tooltip');\n const id = parent.getAttribute('id') || parent.getAttribute('name');\n if (uiActions) {\n uiActions.split(',').forEach((uiAction) => {\n const handler = (event: Event) => {\n const target = event.target as HTMLInputElement;\n const postEventMessage = (files?) => {\n worker.postMessage({\n action: 'event',\n type: 'uiAction',\n data: {type: uiAction, id, event: {...event, files}}\n });\n };\n if (target.files?.length) {\n getFilesWithArrayBuffer(target.files).then(postEventMessage);\n } else {\n postEventMessage();\n }\n };\n parent.addEventListener(uiAction, handler);\n handlersToReset.push(() => {\n parent.removeEventListener(uiAction, handler);\n });\n });\n parent.removeAttribute('ui-actions');\n }\n if (uiTooltip) {\n setTooltip(uiTooltip);\n }\n parent.childNodes.forEach((child) => {\n if (child.nodeType === 1) {\n //Node.ELEMENT_NODE\n handlersToReset = handlersToReset.concat(processInnerHtml(child as HTMLElement, worker, setTooltip));\n }\n });\n return handlersToReset;\n};\n\ntype ResetHTMLParams = {\n worker: Worker;\n setTooltip: any;\n html?: string;\n innerText?: string;\n setListenersToReset: any;\n setHtml: any;\n};\n\nexport const resetHtml = ({worker, setTooltip, innerText, html, setListenersToReset, setHtml}: ResetHTMLParams) => {\n const docBlock = document.createElement('div');\n docBlock.innerHTML = html || innerText;\n\n const handlersToReset = processInnerHtml(docBlock, worker, setTooltip);\n setListenersToReset(handlersToReset);\n setHtml(docBlock);\n};\n\nconst isURLtoProcess = (processApi: string[], url: string) =>\n (processApi || []).some((request) => {\n const regExp = new RegExp(`^${request}$`);\n return request.replace(/\\/*$/, '') === url || (request && regExp.test(url));\n });\n\nexport const setUpQooxdooRequestInterceptor = ({workerRef, setRequestListeners}) => ({\n processApiRequest: (url, method, headers, data, next) => {\n const requestId = nanoid();\n const options = {url, method, headers, noRequestProcessor: true};\n setRequestListeners(options, next, requestId);\n workerRef.current.postMessage({\n action: 'apiRequest',\n id: requestId,\n url,\n method,\n headers,\n data\n });\n }\n});\n\nexport const setUpQooxdooResponseInterceptor = ({workerRef, setResponseListeners}) => ({\n processApiResponse: (url, method, data, next) => {\n const responseId = nanoid();\n setResponseListeners(next, responseId);\n workerRef.current.postMessage({\n action: 'apiResponse',\n id: responseId,\n url,\n method,\n data\n });\n }\n});\n\nexport const setUpRequestInterceptor = ({\n apiPath,\n reltioPath,\n tenant,\n processApiRequest,\n workerRef,\n setRequestListeners\n}) => ({\n options = {},\n url,\n next\n}: {\n next: (url: string, options: RequestInit) => void;\n abort?: (error: Error) => void;\n url: string;\n options: RequestInit;\n}) => {\n const fakeURL =\n url.startsWith('/') && !url.startsWith(apiPath)\n ? `${reltioPath}/api/${tenant}${url}`\n : `${reltioPath}${url.replace(apiPath, '')}`;\n const isProcessableUrl = isURLtoProcess(processApiRequest, fakeURL);\n if (isProcessableUrl) {\n const requestId = nanoid();\n setRequestListeners(options, next, requestId);\n workerRef.current.postMessage({\n action: 'apiRequest',\n id: requestId,\n url: fakeURL,\n method: options.method,\n headers: {...options.headers, origin: 'ui', requestId},\n data: options.body\n });\n } else {\n next(url, options);\n }\n};\n\nexport const setUpResponseInterceptor = ({\n reltioPath,\n apiPath,\n processApiResponse,\n workerRef,\n setResponseListeners\n}) => ({url, response, next, options, abort}) => {\n if (options?.headers?.origin === 'ui') {\n response\n .json()\n .then((data) => {\n setResponseListeners(next, options.headers.requestId);\n workerRef.current.postMessage({\n action: 'response',\n result: {data, status: response.status},\n id: options?.id,\n name: options?.task?.params?.name\n });\n })\n .catch((error) => {\n abort(error);\n });\n } else {\n const fakeURL = `${reltioPath}${url.replace(apiPath, '')}`;\n const isProcessableUrl = isURLtoProcess(processApiResponse, fakeURL);\n\n if (isProcessableUrl) {\n const responseId = nanoid();\n response\n .json()\n .then((data) => {\n setResponseListeners(next, responseId);\n workerRef.current.postMessage({\n action: 'apiResponse',\n id: responseId,\n url: fakeURL,\n method: options.method,\n data\n });\n })\n .catch((error) => {\n abort(error);\n });\n } else {\n next(response);\n }\n }\n};\n","const defaultAttributes = [\n 'accent-height',\n 'accumulate',\n 'additive',\n 'alignment-baseline',\n 'allowReorder',\n 'alphabetic',\n 'amplitude',\n 'arabic-form',\n 'ascent',\n 'attributeName',\n 'attributeType',\n 'autoReverse',\n 'azimuth',\n 'baseFrequency',\n 'baseline-shift',\n 'baseProfile',\n 'bbox',\n 'begin',\n 'bias',\n 'by',\n 'calcMode',\n 'cap-height',\n 'class',\n 'clip',\n 'clipPathUnits',\n 'clip-path',\n 'clip-rule',\n 'color',\n 'color-interpolation',\n 'color-interpolation-filters',\n 'color-profile',\n 'color-rendering',\n 'contentScriptType',\n 'contentStyleType',\n 'cursor',\n 'cx',\n 'cy',\n 'd',\n 'decelerate',\n 'descent',\n 'diffuseConstant',\n 'direction',\n 'display',\n 'divisor',\n 'dominant-baseline',\n 'dur',\n 'dx',\n 'dy',\n 'edgeMode',\n 'elevation',\n 'enable-background',\n 'end',\n 'exponent',\n 'externalResourcesRequired',\n 'fill',\n 'fill-opacity',\n 'fill-rule',\n 'filter',\n 'filterRes',\n 'filterUnits',\n 'flood-color',\n 'flood-opacity',\n 'font-family',\n 'font-size',\n 'font-size-adjust',\n 'font-stretch',\n 'font-style',\n 'font-variant',\n 'font-weight',\n 'format',\n 'from',\n 'fx',\n 'fy',\n 'g1',\n 'g2',\n 'glyph-name',\n 'glyph-orientation-horizontal',\n 'glyph-orientation-vertical',\n 'glyphRef',\n 'gradientTransform',\n 'gradientUnits',\n 'hanging',\n 'height',\n 'horiz-adv-x',\n 'horiz-origin-x',\n 'id',\n 'ideographic',\n 'image-rendering',\n 'in',\n 'in2',\n 'intercept',\n 'k',\n 'k1',\n 'k2',\n 'k3',\n 'k4',\n 'kernelMatrix',\n 'kernelUnitLength',\n 'kerning',\n 'keyPoints',\n 'keySplines',\n 'keyTimes',\n 'lang',\n 'lengthAdjust',\n 'letter-spacing',\n 'lighting-color',\n 'limitingConeAngle',\n 'local',\n 'marker-end',\n 'marker-mid',\n 'marker-start',\n 'markerHeight',\n 'markerUnits',\n 'markerWidth',\n 'mask',\n 'maskContentUnits',\n 'maskUnits',\n 'mathematical',\n 'max',\n 'media',\n 'method',\n 'min',\n 'mode',\n 'name',\n 'numOctaves',\n 'offset',\n 'opacity',\n 'operator',\n 'order',\n 'orient',\n 'orientation',\n 'origin',\n 'overflow',\n 'overline-position',\n 'overline-thickness',\n 'panose-1',\n 'paint-order',\n 'path',\n 'pathLength',\n 'patternContentUnits',\n 'patternTransform',\n 'patternUnits',\n 'pointer-events',\n 'points',\n 'pointsAtX',\n 'pointsAtY',\n 'pointsAtZ',\n 'preserveAlpha',\n 'preserveAspectRatio',\n 'primitiveUnits',\n 'r',\n 'radius',\n 'refX',\n 'refY',\n 'rendering-intent',\n 'repeatCount',\n 'repeatDur',\n 'requiredExtensions',\n 'requiredFeatures',\n 'restart',\n 'result',\n 'rotate',\n 'rx',\n 'ry',\n 'scale',\n 'seed',\n 'shape-rendering',\n 'slope',\n 'spacing',\n 'specularConstant',\n 'specularExponent',\n 'speed',\n 'spreadMethod',\n 'startOffset',\n 'stdDeviation',\n 'stemh',\n 'stemv',\n 'stitchTiles',\n 'stop-color',\n 'stop-opacity',\n 'strikethrough-position',\n 'strikethrough-thickness',\n 'string',\n 'stroke',\n 'stroke-dasharray',\n 'stroke-dashoffset',\n 'stroke-linecap',\n 'stroke-linejoin',\n 'stroke-miterlimit',\n 'stroke-opacity',\n 'stroke-width',\n 'style',\n 'surfaceScale',\n 'systemLanguage',\n 'tableValues',\n 'target',\n 'targetX',\n 'targetY',\n 'text-anchor',\n 'text-decoration',\n 'text-rendering',\n 'textLength',\n 'to',\n 'transform',\n 'type',\n 'u1',\n 'u2',\n 'underline-position',\n 'underline-thickness',\n 'unicode',\n 'unicode-bidi',\n 'unicode-range',\n 'units-per-em',\n 'v-alphabetic',\n 'v-hanging',\n 'v-ideographic',\n 'v-mathematical',\n 'values',\n 'version',\n 'vert-adv-y',\n 'vert-origin-x',\n 'vert-origin-y',\n 'viewBox',\n 'viewTarget',\n 'visibility',\n 'width',\n 'widths',\n 'word-spacing',\n 'writing-mode',\n 'x',\n 'x-height',\n 'x1',\n 'x2',\n 'xChannelSelector',\n 'y',\n 'y1',\n 'y2',\n 'yChannelSelector',\n 'z',\n 'zoomAndPan'\n];\n\nconst defaultTags = [\n 'animate',\n 'animateColor',\n 'animateMotion',\n 'animateTransform',\n 'mpath',\n 'set',\n 'circle',\n 'ellipse',\n 'line',\n 'polygon',\n 'polyline',\n 'rect',\n 'defs',\n 'glyph',\n 'g',\n 'marker',\n 'mask',\n 'missing-glyph',\n 'pattern',\n 'svg',\n 'switch',\n 'symbol',\n 'font',\n 'font-face',\n 'font-face-format',\n 'font-face-name',\n 'font-face-src',\n 'font-face-uri',\n 'hkern',\n 'vkern',\n 'linearGradient',\n 'radialGradient',\n 'stop',\n 'circle',\n 'ellipse',\n 'image',\n 'line',\n 'path',\n 'polygon',\n 'polyline',\n 'rect',\n 'text',\n 'use',\n 'feDistantLight',\n 'fePointLight',\n 'feSpotLight',\n 'circle',\n 'ellipse',\n 'line',\n 'path',\n 'polygon',\n 'polyline',\n 'rect',\n 'defs',\n 'g',\n 'svg',\n 'symbol',\n 'use',\n 'altGlyph',\n 'altGlyphDef',\n 'altGlyphItem',\n 'glyph',\n 'glyphRef',\n 'textPath',\n 'text',\n 'tref',\n 'tspan',\n 'altGlyph',\n 'textPath',\n 'tref',\n 'tspan',\n 'clipPath',\n 'color-profile',\n 'cursor',\n 'filter',\n 'foreignObject',\n 'script',\n 'style',\n 'view'\n];\n\nexport default {\n attributes: {\n '*': [...defaultAttributes, 'ui-actions', 'ui-tooltip'],\n img: ['src', 'srcset', 'alt', 'title', 'loading'],\n link: ['href', 'rel'],\n iframe: ['src'],\n a: ['href']\n },\n tags: [...defaultTags, 'a', 'link', 'input', 'button', 'iframe', 'img']\n};\n","import sanitizeHtml, {IOptions} from 'sanitize-html';\nimport sanitizeOptions from './helpers/sanitizerOptions';\n\nexport const useHtmlSanitizer = () => {\n const {allowedAttributes, allowedTags} = sanitizeHtml.defaults;\n const {attributes, tags} = sanitizeOptions;\n const options: IOptions = {\n allowedTags: allowedTags.concat(tags),\n allowedAttributes: {...allowedAttributes, ...attributes},\n allowVulnerableTags: true\n };\n return (html: string) => sanitizeHtml(html, options);\n};\n","import {useCallback, useContext, useEffect, useRef, useState, CSSProperties} from 'react';\nimport {useDispatch, useSelector} from 'react-redux';\nimport mdmModule, {ui} from '@reltio/mdm-module';\nimport {\n CustomAction,\n CustomActionTaskParams,\n CustomScriptPlatform,\n CustomActionViewConfig,\n CustomActionExtension,\n Entity,\n initializeWebWorker,\n isEmptyValue,\n ProcessParams\n} from '@reltio/mdm-sdk';\nimport {omit} from 'ramda';\nimport {useWorkflowCheckPermission} from '../../components/workflow';\nimport {useHtmlSanitizer} from '../useHtmlSanitizer';\nimport {InterceptHandlersContext, SandboxAPIContext, SnackbarContext} from '../../contexts';\nimport {processRequest} from './API';\nimport {\n getWorkerURL,\n resetHtml,\n isNewUI,\n setUpResponseInterceptor,\n setUpRequestInterceptor,\n setUpQooxdooRequestInterceptor,\n setUpQooxdooResponseInterceptor\n} from './helpers';\nimport {Request} from './types';\n\ntype Config = CustomActionViewConfig | CustomActionExtension;\n\nexport const useAPI = (config: Config = {} as Config) => {\n const [html, setHtml] = useState<HTMLElement>();\n const [listenersToReset, setListenersToReset] = useState<Array<() => void>>([]);\n const [popupListenersToReset, setPopupListenersToReset] = useState<Array<() => void>>([]);\n const [visible, setVisible] = useState(true);\n const [popup, setPopup] = useState<HTMLElement>();\n const [tooltip, setTooltip] = useState<string>(null);\n const [customStyles, setCustomStyles] = useState<{\n height?: number | string;\n width?: number | string;\n pointerEvents?: CSSProperties['pointerEvents'];\n }>({});\n const workerRef = useRef<Worker>();\n const requestListeners = useRef({});\n const responseListeners = useRef({});\n\n const dispatch = useDispatch();\n const sanitizeHtml = useHtmlSanitizer();\n\n const uiPath = useSelector(mdmModule.selectors.getUIPath);\n const tenant: string = useSelector(mdmModule.selectors.getTenant);\n const workerUrl = getWorkerURL(uiPath, tenant);\n\n const showSnackbarMessage = useContext(SnackbarContext);\n const qxApi = useContext(SandboxAPIContext);\n const interceptHandlers = useContext(InterceptHandlersContext);\n\n const workflowCheckPermission = useWorkflowCheckPermission();\n\n const metadata = useSelector(mdmModule.selectors.getMetadata) || {};\n const entity = useSelector(mdmModule.selectors.getEntity) || ({} as Entity);\n const apiPath: string = useSelector(mdmModule.selectors.getApiPath);\n const servicesPath = useSelector(mdmModule.selectors.getServicesPath);\n const reltioPath = useSelector(mdmModule.selectors.getReltioPath);\n const workflowPath = useSelector(mdmModule.selectors.getWorkflowPath);\n const user = useSelector(mdmModule.selectors.getUser);\n const entityUri = useSelector(mdmModule.selectors.getEntityUri);\n const isEditableMode = useSelector(mdmModule.selectors.getIsEditableMode);\n const environment = useSelector(mdmModule.selectors.getWorkflowEnvironmentUrl);\n const {type: typeSearch, data: search} = useSelector(mdmModule.selectors.getSearchProviderData) || {};\n const searchQuery = typeSearch === 'search' ? search?.query : null;\n const isOldUI = !isNewUI(servicesPath);\n const supportedInterceptHandlers = isOldUI ? qxApi.interceptors : interceptHandlers;\n\n const openSearch = (search) => dispatch(ui.actions.openSearch(search));\n\n let innerText = '';\n let popupText = '';\n const process = ({task, worker}: ProcessParams) => {\n if (task) {\n switch (task.action) {\n case CustomAction.SET_HTML: {\n const sanitizedHtml = sanitizeHtml((task.params as CustomActionTaskParams).html);\n if ((task.params as CustomActionTaskParams).id) {\n const elem = document.getElementById((task.params as CustomActionTaskParams).id as string);\n elem.innerHTML = sanitizedHtml;\n } else if (innerText !== sanitizedHtml) {\n innerText = sanitizedHtml;\n resetHtml({\n worker,\n setTooltip,\n html: sanitizedHtml,\n innerText,\n setListenersToReset,\n setHtml\n });\n }\n break;\n }\n case CustomAction.SHOW_POPUP: {\n const sanitizedPopup = sanitizeHtml(task.params as string);\n popupText = sanitizedPopup;\n resetHtml({\n worker,\n setTooltip,\n html: sanitizedPopup,\n innerText: popupText,\n setListenersToReset: setPopupListenersToReset,\n setHtml: setPopup\n });\n break;\n }\n case CustomAction.HIDE_POPUP: {\n popupText = '';\n setPopup(null);\n break;\n }\n case CustomAction.SET_VISIBILITY: {\n if (task.params === 'visible') {\n setVisible(true);\n resetHtml({\n worker,\n setTooltip,\n innerText,\n setListenersToReset,\n setHtml\n });\n } else {\n setVisible(false);\n }\n break;\n }\n case CustomAction.SET_TOOLTIP: {\n setTooltip(task.params as string);\n break;\n }\n case CustomAction.SET_HEIGHT: {\n setCustomStyles((prev) => ({\n ...prev,\n height: task.params as string | number\n }));\n break;\n }\n case CustomAction.SET_WIDTH: {\n setCustomStyles((prev) => ({\n ...prev,\n width: task.params as string | number\n }));\n break;\n }\n case CustomAction.SET_ENABLED: {\n setCustomStyles((prev) =>\n task.params ? omit(['pointer-events'], prev) : {...prev, 'pointer-events': 'none'}\n );\n break;\n }\n case CustomAction.LOG: {\n console.log(task.params); //eslint-disable-line no-console\n break;\n }\n case CustomAction.MESSAGE: {\n showSnackbarMessage(task.params as string);\n break;\n }\n case CustomAction.REQUEST: {\n if ((task.params as CustomActionTaskParams)?.headers?.origin !== 'ui') {\n processRequest({\n name: (task.params as CustomActionTaskParams).name,\n paramObject: task as Request,\n permissions: config.action.permissions,\n worker,\n metadata,\n config: config as Config,\n user,\n servicesPath,\n apiPath: isOldUI ? apiPath : reltioPath,\n tenant,\n workflowPath,\n entity,\n entityUri,\n environment,\n query: searchQuery,\n openSearch,\n workflowCheckPermission,\n ...qxApi\n });\n } else {\n const {headers, id, url: fakeURL, method, data} = task.params as CustomActionTaskParams;\n const url = fakeURL.replace(reltioPath, apiPath);\n if (requestListeners.current[headers.requestId]) {\n requestListeners.current[headers.requestId].next(url, {\n body: data,\n id,\n task,\n headers,\n method\n });\n requestListeners.current = omit([headers.requestId], requestListeners.current);\n }\n }\n break;\n }\n case CustomAction.RETURN_PROCESSED_API_RESPONSE:\n case CustomAction.RETURN_PROCESSED_API_REQUEST: {\n const {id, data} = task.params as CustomActionTaskParams;\n if (responseListeners.current[id]) {\n responseListeners.current[id].next(data);\n responseListeners.current = omit([id], responseListeners.current);\n }\n break;\n }\n }\n }\n };\n\n const setRequestListeners = (options, next, requestId) => {\n requestListeners.current = {\n ...requestListeners.current,\n [requestId]: {options, next, id: requestId}\n };\n };\n\n const setResponseListeners = (next, responseId) => {\n responseListeners.current = {\n ...responseListeners.current,\n [responseId]: {next}\n };\n };\n\n const qooxdooRequestInterceptor = setUpQooxdooRequestInterceptor({workerRef, setRequestListeners});\n const qooxdooResponseInterceptor = setUpQooxdooResponseInterceptor({workerRef, setResponseListeners});\n const requestInterceptor = setUpRequestInterceptor({\n apiPath,\n reltioPath,\n tenant,\n processApiRequest: config?.action?.processApiRequest,\n workerRef,\n setRequestListeners\n });\n const responseInterceptor = setUpResponseInterceptor({\n reltioPath,\n apiPath,\n processApiResponse: config?.action?.processApiResponse,\n workerRef,\n setResponseListeners\n });\n\n const postEventMessage = (type: string, data: unknown) => {\n workerRef.current?.postMessage({action: 'event', type, data});\n };\n\n useEffect(() => {\n if (!isEmptyValue(config.action) && config.action.platform !== CustomScriptPlatform.CLASSIC) {\n workerRef.current = initializeWebWorker(workerUrl, process, config);\n postEventMessage('updateEntity', entity);\n }\n }, [entity, config]);\n\n useEffect(() => {\n postEventMessage('editMode', isEditableMode);\n }, [isEditableMode]);\n\n useEffect(() => {\n postEventMessage('changeSearchQuery', searchQuery);\n }, [searchQuery]);\n\n useEffect(() => {\n postEventMessage('changeVisibility', visible);\n }, [visible]);\n\n useEffect(\n () => () => {\n listenersToReset.forEach((listener) => listener());\n },\n [listenersToReset]\n );\n //we need to have separate handlers in opposite case main window listeners will be removed on the popup appear\n useEffect(\n () => () => {\n popupListenersToReset.forEach((listener) => listener());\n },\n [popupListenersToReset, listenersToReset]\n );\n\n const onClick = useCallback(() => {\n postEventMessage('execute', null);\n }, [config]);\n\n useEffect(() => {\n if (\n !isEmptyValue(supportedInterceptHandlers) &&\n (config?.action?.processApiRequest || config?.action?.processApiResponse)\n ) {\n const {\n addInternalRequestInterceptor,\n addInternalResponseInterceptor,\n removeInternalRequestInterceptor,\n removeInternalResponseInterceptor\n } = supportedInterceptHandlers;\n\n if (isOldUI) {\n addInternalRequestInterceptor(config?.action?.processApiRequest, qooxdooRequestInterceptor);\n addInternalResponseInterceptor(config?.action?.processApiResponse, qooxdooResponseInterceptor);\n return () => {\n removeInternalRequestInterceptor(qooxdooRequestInterceptor);\n removeInternalResponseInterceptor(qooxdooResponseInterceptor);\n };\n } else {\n addInternalRequestInterceptor(requestInterceptor);\n addInternalResponseInterceptor(responseInterceptor);\n return () => {\n removeInternalRequestInterceptor(requestInterceptor);\n removeInternalResponseInterceptor(responseInterceptor);\n };\n }\n }\n }, [config]);\n\n return {html, visible, tooltip, customStyles, onClick, popup};\n};\n","import {useCallback, useEffect, useState} from 'react';\nimport {concat, difference, isEmpty, map, pipe, prop, reduce, reject, uniq} from 'ramda';\nimport {useSelector} from 'react-redux';\nimport mdm from '@reltio/mdm-module';\nimport {\n ActivityFilters,\n Comment,\n Entity,\n FilterOptions,\n getFilteredEntities,\n isEntityUri,\n getEntity,\n EntitiesMap\n} from '@reltio/mdm-sdk';\nimport {useSafePromise} from './useSafePromise';\n\nconst SELECT_OPTION = 'uri,label,type';\n\nexport const useCommentsEntitiesMap = (comments: Comment[]) => {\n const safePromise = useSafePromise();\n const currentEntityUri = useSelector(mdm.selectors.getEntityUriWithDataTenant);\n\n const [entitiesMap, setEntitiesMap] = useState<EntitiesMap>({});\n\n const getEntities = useCallback(\n (entitiesUris: string[]) => {\n const requestFilters = [\n {\n filter: FilterOptions.EQUALS,\n fieldName: 'uri',\n values: entitiesUris\n }\n ];\n\n const requestOptions = {\n max: entitiesUris.length,\n activeness: ActivityFilters.ALL,\n select: 'uri,label,type'\n };\n return safePromise(getFilteredEntities(requestFilters, requestOptions));\n },\n [safePromise]\n );\n\n const getNotFoundEntity = (entityUri: string) => {\n return getEntity(entityUri, {options: SELECT_OPTION})\n .then((entity: Entity) => ({...entity, uri: entityUri} as Entity))\n .catch(() => ({}));\n };\n\n const addNotFoundEntities = useCallback(\n (entitiesUris: string[], entities: Entity[]) => {\n return safePromise(\n Promise.all((entitiesUris || []).map(getNotFoundEntity))\n ).then((notFoundEntities: Entity[]) => pipe(reject(isEmpty), concat(entities))(notFoundEntities));\n },\n [safePromise]\n );\n\n useEffect(() => {\n const uniqEntitiesUris = pipe(\n reduce((entitiesUris, comment) => {\n const {objectType: type, relatedObjectUris} = comment;\n\n if (type === 'relation' || type === 'potentialMatch') {\n (relatedObjectUris || []).forEach((uri) => {\n if (uri !== currentEntityUri && isEntityUri(uri) && !entitiesMap[uri]) {\n entitiesUris.push(uri);\n }\n });\n }\n return entitiesUris;\n }, []),\n uniq\n )(comments || []);\n\n if (uniqEntitiesUris.length) {\n getEntities(uniqEntitiesUris)\n .then((results: Entity[]) => {\n const getNotFoundUris = pipe(map(prop('uri')), difference(uniqEntitiesUris));\n\n const notFoundEntities = getNotFoundUris(results);\n return addNotFoundEntities(notFoundEntities, results);\n })\n .then((results) => {\n setEntitiesMap((prevEntitiesMap) =>\n results.reduce(\n (entities, entity) => {\n entities[entity.uri] = entity;\n return entities;\n },\n {...prevEntitiesMap}\n )\n );\n })\n .catch(() => {});\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [getEntities, addNotFoundEntities, comments, currentEntityUri]);\n\n return entitiesMap;\n};\n","import {useSelector} from 'react-redux';\nimport mdmModule from '@reltio/mdm-module';\nimport {checkConfigPermission, ConfigPermissions} from '@reltio/mdm-sdk';\nimport {useCallback} from 'react';\n\nconst emptyArray = [];\n\nexport const useConfigPermissions = () => {\n const userRoles = useSelector(mdmModule.selectors.getUserRoles) || emptyArray;\n\n return {\n canCreate: useCallback(checkConfigPermission(ConfigPermissions.CREATE, userRoles), [userRoles]),\n canRead: useCallback(checkConfigPermission(ConfigPermissions.READ, userRoles), [userRoles]),\n canUpdate: useCallback(checkConfigPermission(ConfigPermissions.UPDATE, userRoles), [userRoles]),\n canDelete: useCallback(checkConfigPermission(ConfigPermissions.DELETE, userRoles), [userRoles])\n };\n};\n","import {useCallback, useEffect, useMemo, useRef, useState} from 'react';\nimport {useDispatch, useSelector} from 'react-redux';\nimport {cond, pipe, prop, T, evolve, filter as filterFn, when, identity, times, length, ifElse, always} from 'ramda';\nimport mdm, {profile} from '@reltio/mdm-module';\nimport {\n ActivityFilter,\n addGlobalFilterToQuery,\n Connection,\n Entity,\n getRelationsForDataTenantEntity,\n getRelationsForEntity,\n GlobalSearchRequestOptions,\n isAvailableEntityTypeUri,\n isAvailableRelationTypeUri,\n isDataTenantEntity,\n isObject,\n isTempUri,\n Metadata,\n Mode,\n RelationsContent,\n RelationsViewConfig,\n wrapInArrayIfNeeded\n} from '@reltio/mdm-sdk';\nimport {useSafePromise} from './useSafePromise';\nimport {usePrevious} from './usePrevious';\n\ntype Props = {\n sorting?: {\n field: string;\n order: string;\n };\n filter?: string;\n page: number;\n rowsPerPage: number;\n config: Pick<RelationsViewConfig, 'suggested' | 'content' | 'id'>;\n entity: Entity;\n relationActivityFilter?: ActivityFilter;\n mode: Mode;\n searchByOv?: boolean;\n};\n\nconst buildSuggestedIds = when(\n identity,\n pipe(\n wrapInArrayIfNeeded,\n length,\n times((n) => n + 1)\n )\n);\ntype ConnectionResponse = Array<{connections?: Connection[]; total: number}>;\n\nexport const useRelationsLoader = ({\n sorting,\n filter,\n page,\n rowsPerPage,\n config,\n entity,\n relationActivityFilter,\n mode,\n searchByOv = false\n}: Props) => {\n const [isLoading, setIsLoading] = useState(false);\n const dispatch = useDispatch();\n const tenant = useSelector(mdm.selectors.getTenant) as string;\n const metadata = useSelector(mdm.selectors.getMetadata) as Metadata;\n const dtssPath = useSelector(mdm.selectors.getDtssPath) as string;\n const {activityFilter, globalFilter}: GlobalSearchRequestOptions =\n useSelector(mdm.selectors.getGlobalSearchRequestOptions) || {};\n const safePromise = useSafePromise();\n\n const processContent = (content: RelationsContent) => {\n const getUri = when(isObject, prop('uri'));\n const filterRelation = pipe(getUri, isAvailableRelationTypeUri(metadata));\n\n return evolve({\n entityTypes: filterFn(isAvailableEntityTypeUri(metadata)),\n inRelations: filterFn(filterRelation),\n outRelations: filterFn(filterRelation),\n nextEntry: processContent\n })(content);\n };\n\n const suggested = config.suggested;\n const options = useMemo(\n () => ({\n searchByOv\n }),\n [searchByOv]\n );\n const loadRelations = useCallback(() => {\n if (entity?.uri) {\n const processedConfig = processContent(config.content);\n const requestConfig = {\n ...processedConfig,\n sortBy: sorting?.field,\n order: sorting?.order,\n returnDates: true,\n returnObjects: true,\n activeness: {\n relation: relationActivityFilter || ActivityFilter.ALL,\n entity: activityFilter\n },\n max: rowsPerPage,\n offset: page * rowsPerPage,\n filter: addGlobalFilterToQuery(globalFilter, filter) || undefined,\n suggested: buildSuggestedIds(suggested)\n };\n const configs = [requestConfig].concat(\n ifElse(\n identity,\n pipe(wrapInArrayIfNeeded, (suggested) =>\n suggested.map((config, i) => ({...config, id: requestConfig.suggested[i]}))\n ),\n always([])\n )(suggested)\n );\n\n const request: (entity: Entity) => Promise<ConnectionResponse> = cond([\n [pipe(prop('uri'), isTempUri), () => Promise.resolve([{total: 0}])],\n [\n isDataTenantEntity,\n (entity) =>\n getRelationsForDataTenantEntity({\n entityUri: entity.uri,\n configs: configs,\n customerTenant: tenant,\n dataTenant: entity.dataTenant,\n dtssPath,\n options\n })\n ],\n [T, (entity) => getRelationsForEntity(entity.uri, configs, options)]\n ]);\n setIsLoading(true);\n safePromise(request(entity))\n .then(([{connections, total}]) => {\n dispatch(profile.relations.actions.relationsLoaded({id: config.id, connections, total}));\n })\n .finally(() => {\n setIsLoading(false);\n });\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [\n activityFilter,\n metadata,\n config,\n dispatch,\n dtssPath,\n entity?.uri,\n entity?.dataTenant,\n filter,\n globalFilter,\n page,\n relationActivityFilter,\n rowsPerPage,\n safePromise,\n sorting,\n tenant,\n options\n ]);\n const isRequestSentRef = useRef<boolean>(false);\n isRequestSentRef.current = false;\n useEffect(() => {\n isRequestSentRef.current = true;\n loadRelations();\n }, [loadRelations]);\n const prevMode = usePrevious(mode);\n useEffect(() => {\n if (mode === Mode.Viewing && !isRequestSentRef.current && prevMode !== mode) {\n isRequestSentRef.current = true;\n loadRelations();\n }\n }, [loadRelations, mode, prevMode]);\n return {isLoading, reload: loadRelations};\n};\n"],"names":["props","width","height","viewBox","xmlns","d","fill","fillRule","stroke","strokeWidth","useStyles","makeStyles","theme","color","palette","primary","main","closeIcon","position","right","bottom","transform","button","padding","FilterButton","enabled","onClick","styles","Tooltip","title","i18n","IconButton","classes","root","Filter","className","Close","propTypes","PropTypes","searchButton","marginLeft","marginRight","input","flex","fontSize","background","startAdornment","paddingLeft","ExpandableSearchInput","query","onChange","value","setValue","useState","isOpen","setIsOpen","useEffect","hasValue","length","Input","autoFocus","placeholder","disableUnderline","pipe","getValue","InputAdornment","Search","endAdornment","SmallIconButton","size","icon","CloseIcon","F","always","tap","onKeyPress","when","propEq","trim","T","EmptyStub","style","display","HideOnShrink","widthToHide","children","handleWidth","render","maxWidth","MAX_WIDTH_SELECT","paddingTop","paddingBottom","outlined","paddingRight","arrowIcon","top","text","secondary","currentValue","alignItems","currentValueIcon","currentValueText","lineHeight","textTransform","fontWeight","whiteSpace","textOverflow","overflow","menuItem","firstMenuItemButton","borderTop","menuItemInner","menuItemIcon","menuItemLabel","menuItemDescription","isButton","ModeSwitcherSelect","optionsGroup","buttonsGroup","disabled","Select","e","target","some","variant","renderValue","IconComponent","label","find","Box","Typography","MenuProps","anchorOrigin","vertical","horizontal","transformOrigin","getContentAnchorEl","items","firstButtonIdx","findIndex","map","item","idx","description","menuItemProps","classnames","MenuItem","key","renderMenuItems","flexDirection","profileCardWrapper","gap","profileCardContainer","flexGrow","rulesContainer","marginBottom","ProfileMatchCard","entitiesMap","entity","match","metadata","ProfileCard","object","container","matchRules","MatchRulesBlock","editor","overflowX","letterSpacing","margin","dense","actionButtons","justifyContent","backgroundColor","RelationEditor","connection","modifiedEntity","initialConnection","initialModifiedEntity","allModifiedEntities","dispatch","config","mode","globalSearchRequestOptions","error","highlightedError","relationUri","relationType","direction","relation","isNew","ref","errorClassName","useScrollToAttributeError","isSimple","inRelations","inRelationTypes","outRelations","outRelationTypes","useMemo","getInOutRelations","content","parentEntityUri","contentSecondLevel","firstLevelRelationAttrTypes","getRelationAttributesList","attributeListEntity","attributes","profile","getActivenessAttributes","relatedTempEntities","findRelatedTemporaryEntities","relatedTempEntitiesUrisHistory","useRef","setInitialInfo","useCallback","id","current","concat","prop","uniq","initialRelatedTempEntities","defaultRelationType","getDefaultRelationTypeObject","hasChanges","equals","pick","initial","actual","_","i","isEmptyValue","path","applyAction","onRelationTypeChange","handleClose","updateModifiedEntityLabel","entityType","getEntityType","type","updateConnectionEntityLabel","setModifiedEntity","deleteModifiedEntity","entityUri","onChangeEntity","uri","getErrorId","validate","errors","validateConnection","resetErrors","onApply","omitMarks","omit","differenceWith","forEach","onCancel","initialTempEntities","onAddAttributes","params","param","viewId","onChangeAttribute","onDeleteAttribute","onCreateEntity","entityTypeUri","initValue","newEntityAttrTypes","relationEditorAttributeTypesSelectionStrategy","getCreatableAttributeTypes","newEntity","createTemporaryEntity","attributeTypes","errorMessage","getErrorMessage","getEntityTypesUris","entityTypes","ConnectionRelationTypeSelector","Boolean","ErrorWrapper","EntitySelector","isTempUri","entityTypesUris","max","onCreate","isSuggestMode","undefined","attributeTypesSelectionStrategy","AttributesList","attrTypes","showEmptyEditors","crosswalks","parentUri","Button","Divider","ConnectionType","EntityType","RelationsConfigType","MetadataType","AttributeErrorType","withContext","ScrollToErrorContext","contextValue","allPass","connect","state","ownProps","getConnectionRelationUri","isTempEntity","mdmModule","getRelationEditorActiveError","reltioLayoutItemToReactGridLayoutItem","x","y","minWidth","minHeight","maxHeight","isStatic","w","h","minW","minH","maxW","maxH","static","reactGridLayoutItemToReltioLayoutItem","reactGridLayoutToReltioLayout","layout","getReltioLayoutItemById","curry","updateExtraPropsInLayoutItem","from","to","mergeAll","copyPropsFromPreviousLayout","oldReltioLayout","reltioLayout","layoutItem","defaultTo","__","gridLayout","border","borderRadius","transitionDuration","zIndex","userSelect","transitionProperty","willChange","pointerEvents","transition","backgroundImage","svg2Url","backgroundRepeat","backgroundOrigin","boxSizing","cursor","visibility","gridFullscreen","overflowY","ReltioGridLayout","views","layoutOptions","onLayoutChanged","draggableHandle","LayoutItem","onRemove","onDrop","droppingItem","isDroppable","fullscreenItemId","setFullscreenItemId","setWidth","cols","rowHeight","processedLayout","reltioLayoutToReactGridLayout","onReltioLayoutChanged","onToggleFullscreen","prevId","isFullscreenEnabled","onItemHeightResize","layoutId","isLayoutChanged","newLayout","newHeight","options","Math","ceil","calcHeight","refreshMode","refreshRate","onResize","innerRef","autoSize","onLayoutChange","isResizable","isDraggable","isItemFullscreen","autosizeComponent","autosizing","AutosizeComponent","layoutItemId","handleHeight","layoutItemConfig","fullscreen","isFullscreen","defaultProps","onConfigChanged","identity","memo","MapControlContainer","controlElement","setControlElement","controlDiv","document","createElement","divIndex","controls","push","removeAt","classList","add","createPortal","opacity","xmlnsXlink","xlinkHref","mask","fillOpacity","ButtonWithTooltip","withTooltip","TopRightMapControls","drawingMode","drawingModes","hasActiveOverlay","onDrawingModeChanged","onClearOverlay","changeDrawingModeTo","tooltipTitle","HighlightOff","Icon","MAP_DRAWING_MODES","RadiusIcon","DrawIcon","getIcon","alignSelf","checkbox","TopCenterMapControls","isSearchOnMapMove","onChangeIsSearchOnMapMove","FormControlLabel","control","Checkbox","checked","event","getMapBoundsPolygon","bounds","getBounds","ne","getNorthEast","sw","getSouthWest","neLat","lat","neLng","lng","swLat","swLng","additionalPoint1","additionalPoint2","center","getCenter","getDrawingMode","window","google","maps","drawing","OverlayType","CIRCLE","POLYGON","fitMapBoundsForOverlay","overlay","existingBounds","LatLngBounds","extend","LatLng","fitBounds","popper","boxShadow","hoveredMarkerIcon","markerIcon","marker","otherProps","popperAnchor","hovered","setHovered","activeEntityUri","useContext","EntityMarkerContext","isActive","pathEq","point","setHoveredDebounced","debounce","onMouseOver","onMouseOut","handleClick","Popper","anchorEl","open","modal","placement","url","scaledSize","Size","visible","alignBottom","pane","pixelOffset","closeBoxURL","enableEventPropagation","disableAutoPan","mapControlContainer","libraries","ReltioMap","markers","mapKey","defaultZoom","defaultCenter","loadingElement","isSearchEnabled","activeOverlay","overlayOptions","markerClusterer","markerClustererOptions","mapOptions","mapContainerClassName","onMapBoundsChanged","onOverlayUpdated","onMarkerClicked","isLoaded","loadError","useJsApiLoader","googleMapsApiKey","mapMoveEndTimer","setMap","polygon","setPolygon","setDrawingMode","prevMarkers","usePrevious","prevActiveOverlay","apiIsLoaded","MAP_MINIMUM_SCALE_RADIUS","fitMapBoundsForMarkers","useFitMapBounds","allOverlayOptions","DEFAULT_OVERLAY_OPTIONS","googleMapOptions","DEFAULT_GOOGLE_MAP_OPTIONS","handleChangeIsSearchOnMapMove","clearTimeout","handleMapMoveStart","handleMapMoveEnd","handleMapIdle","setTimeout","handleOverlayChange","propOverlay","stateOverlay","isEmpty","typeActions","getPath","getArray","latlng","radius","getRadius","data","handleOverlayComplete","handleClearOverlay","renderMarkers","clusterer","filter","mapTypeId","MapTypeId","ROADMAP","onLoad","zoom","onZoomChanged","onDragStart","onIdle","ControlPosition","TOP_RIGHT","TOP_CENTER","editable","onMouseUp","onDragEnd","onPolygonComplete","onCircleComplete","drawingControl","circleOptions","polygonOptions","VerticalDivider","borderLeft","flexShrink","defaultHistoryDiff","appearance","roles","tags","fixRefEntity","evolve","refEntity","wrapInArrayIfNeeded","refRelation","prepareHistorySlice","historySlice","useHistoryDiff","useDispatch","useSelector","historyDiff","historyMode","aEntity","bEntity","History","computeEntityHistoryDiff","HistoryMode","card","borderBottom","withBackground","lineWrapper","left","line","info","wordWrap","commentsInfo","marginTop","commentsIcon","infoValue","infoBlock","header","caption","flag","date","mainInfo","controlsBox","controlsInRow","priority","comments","dueDate","dueDateInput","inputLabel","taskId","isTaskOpen","updateDueDate","updateRequestIsInProgress","readOnly","updateTaskState","WorkflowTasksContext","workflowPath","environment","tenant","safePromise","useSafePromise","setUpdateRequestIsInProgress","canUpdateTask","useWorkflowCheckPermission","checkWorkflowPermission","isOpenTask","newValue","updateDueDateForTask","then","catch","showWorkflowError","finally","useWorkflowDueDate","DateEditor","getTime","InputProps","InputLabelProps","priorities","updatePriority","newPriority","updatePriorityForTask","WorkflowPriority","useWorkflowPriority","DropDownSelector","isDisabled","hideSelectedOptions","TextFieldProps","decorator","lineBlock","withLinePadding","noLine","plain","last","rowDivider","first","transparent","divider","light","taskToColor","COLORS","colorIndex","task","actions","assignee","createdBy","createTime","displayName","step","processDefinitionDisplayName","objectURIs","processInstanceComments","possibleActions","dcrId","getDCRId","hash","useWorkflowColor","isExpanded","setExpanded","canViewComments","Flag","CollapseButton","CollaborationIcon","TaskActions","AssigneeSelector","WorkflowComments","cx","cy","r","OperationTypes","DCRTypes","getOperationType","oldValue","CREATE_RELATIONSHIP","INSERT_ATTRIBUTE","ADDED","UPDATE_TAGS","UPDATE_ROLES","UPDATE_ATTRIBUTE","EDITED","DELETE_ATTRIBUTE","DELETE_RELATIONSHIP","DELETED","PIN_ATTRIBUTE","pin","PIN_DELETED","PINNED","IGNORE_ATTRIBUTE","ignored","IGNORE_DELETED","IGNORED","getOperationLabel","operation","getDataTypeDefinition","attributeType","attributeValue","DataTypes","isUrl","getAttrDataTypeDefinition","getValues","attrType","newAttrValues","pathOr","name","oldAttrValues","times","index","values","getEntityChanges","entityInfo","changes","getFilteredAttrTypes","getAttributesList","getRelationChanges","relationInfo","changeType","getRelationType","flatten","level","propOr","addRelationOperationIfNeeded","dcrAttributesFactory","complement","getNestedAttributeChange","getReferenceAttributeChange","isSpecialAttribute","is","Object","getSimpleAttributeValue","getSimpleAttributeChange","attributeTypeList","getAttributeTypeSubAttributes","getLabel","getDiffParameters","SPECIAL_ATTRIBUTES_NAMES","EntityAttrTypes","prepareStartOrEndDate","parseValue","isNaN","parseInt","isExistedValue","isExistNewValue","isExistOldValue","prepareRolesOrTags","change","getRoleLabel","diffNewValue","difference","diffOldValue","join","prepareAttribute","changePath","attributePath","refObjectURI","refAttributeType","generateTempUri","typePath","split","pathArray","holder","indexOf","isNil","createEntityOrRelation","startDate","endDate","defaultProfilePicValue","newObject","mergeAttributesInChange","objectInfo","UPDATE_PROFILE_PIC_BY_URL","UPDATE_START_DATE","UPDATE_END_DATE","CREATE_ENTITY","linkLabel","suggestionsCount","Link","component","underline","field","wordBreak","fieldName","arrow","chip","borderColor","ArrowRightAlt","Chip","AttributesChangesContext","React","linkContainer","textDecoration","disabledLink","objectsInfo","getLinkDescription","isReference","anyPass","hasPath","ifElse","currentEntityUri","objectLabel","objectUri","startObjectUri","endObjectUri","endObjectLabel","startObjectLabel","objectURI","getAttributeDescription","renderLink","isNotExist","isExist","EntityUriLink","changeLabel","attrValue","getAttributeValue","DataTypeValue","dataTypeDefinition","has","getSuggestionsCount","showMoreLink","relationsInfo","mergedEntityChanges","mergedRelationsChanges","getAttributeChanges","attributeName","concatChanges","getters","attributesTree","reduce","acc","getter","changesTree","result","relationsTrees","updateRelation","mergeChanges","changesList","relationshipTitle","onToggle","itemsToShow","collapsedSuggestionsCount","limit","setIsExpanded","collapsedItems","slice","visibleSuggestionsCount","useCollapsibleList","Provider","getEntityUriForLink","getEntitiesObjects","isEntityUri","getRelationsObjects","isRelationUri","getRelations","objectsWithChanges","createEntityRelationsObjectByEntity","relations","createEntityRelationsObjectByRelation","concatEntityRelationsObjects","mergedRelations","dcrUri","getDCRUri","dcr","groupedObjects","setGroupedObjects","setDcr","requestEntities","entityUris","Promise","resolve","getEntitiesByUris","searchOptions","defaultMaxValues","getDataChangeRequest","keys","extractObjectsFromChangeRequest","entityObjectsWithRelations","relationsObjects","relationsObjectsWithEntity","relationsObjectsWithoutEntity","partition","entities","relationsObjectsWithRequestedEntities","relationsObject","useChangeRequest","DcrTaskIcon","pmCard","defaultOptions","showTransitiveMatches","showInactiveEntities","matches","useMatchesLoader","rowsPerPage","Number","MAX_SAFE_INTEGER","page","includes","PmTaskIcon","WorkflowTaskCardsFactory","build","processType","PredefinedWorkflowProcessType","DeleteRequestTaskIcon","DefaultTaskIcon","WorkflowTaskCard","popoverPaper","simpleDropDownSelector","inputRoot","select","footer","cancelButton","AddWorkflowDialog","onClose","comment","setComment","taskType","setTaskType","isOpenSnackbar","setIsOpenSnackbar","definitions","setDefinitions","processDefinitions","manualStart","objectTypes","_entityType","filterDefinitions","useWorkflowDefinitions","processInstance","loading","loadTasks","setLoading","startProcessInstance","useWorkflowProcessInstance","Popover","paper","SimpleDropDownSelector","definition","TextField","hiddenLabel","multiline","Portal","body","Snackbar","autoHideDuration","message","buttonLabel","AddWorkflowButton","setAnchorEl","canStartProcess","canViewProcessDefinitions","currentTarget","Add","useWorkflowTasks","processTypes","showClosedTasks","isWorkflowEnabled","isEditableMode","canViewTasks","tasks","setTasks","total","setTotal","parsedProcessTypes","Array","isArray","requests","getTasksForEntity","includeClosed","all","responses","reject","uniqBy","isRequestedTask","console","warn","payload","mergeLeft","fillColor","strokeWeight","strokeColor","clickable","mapTypeControl","streetViewControl","fullscreenControl","InterceptHandlersContext","ProfilePerspectiveViewContext","SandboxAPIContext","getCurrentPerspectiveId","setEntityUri","showPerspective","getHeaders","async","signHandler","accessToken","headers","Authorization","validateParams","permissions","permission","urlOrigin","permRegex","RegExp","decodedPerm","replace","startsWith","test","processRequest","paramObject","worker","apiPath","servicesPath","user","openSearch","workflowCheckPermission","handleRequest","request","postMessage","action","status","isNewUI","getAccessToken","RequestAction","sendRequestFromCustomSandbox","method","noRequestProcessor","sendApiRequest","isExternalUrl","sendWorkflowRequest","workflowRequest","processDefinitionId","searchString","startProcessFromQuery","processFromQuery","response","listener","perspective","searchState","alert","confirm","prompt","defaultText","location","reload","getWorkerURL","uiPath","processInnerHtml","parent","setTooltip","handlersToReset","uiActions","getAttribute","uiTooltip","uiAction","handler","postEventMessage","files","readFilePromises","file","reader","FileReader","onload","lastModified","onerror","readAsArrayBuffer","getFilesWithArrayBuffer","addEventListener","removeEventListener","removeAttribute","childNodes","child","nodeType","resetHtml","innerText","html","setListenersToReset","setHtml","docBlock","innerHTML","isURLtoProcess","processApi","regExp","setUpQooxdooRequestInterceptor","workerRef","setRequestListeners","processApiRequest","next","requestId","nanoid","setUpQooxdooResponseInterceptor","setResponseListeners","processApiResponse","responseId","setUpRequestInterceptor","reltioPath","fakeURL","origin","setUpResponseInterceptor","abort","json","img","link","iframe","a","useHtmlSanitizer","allowedAttributes","allowedTags","sanitizeHtml","sanitizeOptions","allowVulnerableTags","useAPI","listenersToReset","popupListenersToReset","setPopupListenersToReset","setVisible","popup","setPopup","tooltip","customStyles","setCustomStyles","requestListeners","responseListeners","workerUrl","showSnackbarMessage","SnackbarContext","qxApi","interceptHandlers","typeSearch","search","searchQuery","isOldUI","supportedInterceptHandlers","interceptors","ui","popupText","process","CustomAction","sanitizedHtml","getElementById","sanitizedPopup","prev","log","qooxdooRequestInterceptor","qooxdooResponseInterceptor","requestInterceptor","responseInterceptor","platform","CustomScriptPlatform","initializeWebWorker","addInternalRequestInterceptor","addInternalResponseInterceptor","removeInternalRequestInterceptor","removeInternalResponseInterceptor","useCommentsEntitiesMap","mdm","setEntitiesMap","getEntities","entitiesUris","requestFilters","FilterOptions","requestOptions","activeness","ActivityFilters","getFilteredEntities","getNotFoundEntity","getEntity","addNotFoundEntities","notFoundEntities","uniqEntitiesUris","objectType","relatedObjectUris","results","getNotFoundUris","prevEntitiesMap","emptyArray","useConfigPermissions","userRoles","canCreate","checkConfigPermission","ConfigPermissions","canRead","canUpdate","canDelete","buildSuggestedIds","n","useRelationsLoader","sorting","relationActivityFilter","searchByOv","isLoading","setIsLoading","dtssPath","activityFilter","globalFilter","processContent","getUri","isObject","filterRelation","isAvailableRelationTypeUri","filterFn","isAvailableEntityTypeUri","nextEntry","suggested","loadRelations","requestConfig","sortBy","order","returnDates","returnObjects","ActivityFilter","offset","addGlobalFilterToQuery","configs","cond","isDataTenantEntity","getRelationsForDataTenantEntity","customerTenant","dataTenant","getRelationsForEntity","connections","isRequestSentRef","prevMode","Mode"],"sourceRoot":""}