@blaze-cms/react-page-builder 0.130.0-admin-updates.8 → 0.130.0-alpha.0

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 (83) hide show
  1. package/CHANGELOG.md +4 -60
  2. package/lib/components/Code/Code.js +3 -7
  3. package/lib/components/Code/Code.js.map +1 -1
  4. package/lib/components/DataSummary/helpers/build-loop-props-content.js +1 -3
  5. package/lib/components/DataSummary/helpers/build-loop-props-content.js.map +1 -1
  6. package/lib/components/DataSummary/helpers/build-props-to-display-with-content.js +2 -3
  7. package/lib/components/DataSummary/helpers/build-props-to-display-with-content.js.map +1 -1
  8. package/lib/components/Layout/Layout.js +10 -4
  9. package/lib/components/Layout/Layout.js.map +1 -1
  10. package/lib/components/SearchContent/SearchContent.js +6 -8
  11. package/lib/components/SearchContent/SearchContent.js.map +1 -1
  12. package/lib/components/SearchFilter/SearchFilterContainer.js +1 -2
  13. package/lib/components/SearchFilter/SearchFilterContainer.js.map +1 -1
  14. package/lib/components/SearchFilter/helpers/build-new-query.js +2 -3
  15. package/lib/components/SearchFilter/helpers/build-new-query.js.map +1 -1
  16. package/lib/components/SearchFilterSort/helpers/handle-sort-update.js +2 -5
  17. package/lib/components/SearchFilterSort/helpers/handle-sort-update.js.map +1 -1
  18. package/lib/components/SearchFilterSort/helpers/update-sort.js +1 -2
  19. package/lib/components/SearchFilterSort/helpers/update-sort.js.map +1 -1
  20. package/lib/helpers/build-props-query.js +2 -5
  21. package/lib/helpers/build-props-query.js.map +1 -1
  22. package/lib/helpers/get-wrapped-value-with-link.js +3 -2
  23. package/lib/helpers/get-wrapped-value-with-link.js.map +1 -1
  24. package/lib/helpers/index.js +0 -7
  25. package/lib/helpers/index.js.map +1 -1
  26. package/lib/helpers/parse-props-to-display.js +8 -13
  27. package/lib/helpers/parse-props-to-display.js.map +1 -1
  28. package/lib-es/components/Code/Code.js +4 -8
  29. package/lib-es/components/Code/Code.js.map +1 -1
  30. package/lib-es/components/DataSummary/helpers/build-loop-props-content.js +1 -3
  31. package/lib-es/components/DataSummary/helpers/build-loop-props-content.js.map +1 -1
  32. package/lib-es/components/DataSummary/helpers/build-props-to-display-with-content.js +3 -4
  33. package/lib-es/components/DataSummary/helpers/build-props-to-display-with-content.js.map +1 -1
  34. package/lib-es/components/Layout/Layout.js +11 -5
  35. package/lib-es/components/Layout/Layout.js.map +1 -1
  36. package/lib-es/components/SearchContent/SearchContent.js +6 -8
  37. package/lib-es/components/SearchContent/SearchContent.js.map +1 -1
  38. package/lib-es/components/SearchFilter/SearchFilterContainer.js +1 -2
  39. package/lib-es/components/SearchFilter/SearchFilterContainer.js.map +1 -1
  40. package/lib-es/components/SearchFilter/helpers/build-new-query.js +2 -3
  41. package/lib-es/components/SearchFilter/helpers/build-new-query.js.map +1 -1
  42. package/lib-es/components/SearchFilterSort/helpers/handle-sort-update.js +2 -7
  43. package/lib-es/components/SearchFilterSort/helpers/handle-sort-update.js.map +1 -1
  44. package/lib-es/components/SearchFilterSort/helpers/update-sort.js +2 -2
  45. package/lib-es/components/SearchFilterSort/helpers/update-sort.js.map +1 -1
  46. package/lib-es/helpers/build-props-query.js +2 -4
  47. package/lib-es/helpers/build-props-query.js.map +1 -1
  48. package/lib-es/helpers/get-wrapped-value-with-link.js +2 -2
  49. package/lib-es/helpers/get-wrapped-value-with-link.js.map +1 -1
  50. package/lib-es/helpers/index.js +0 -1
  51. package/lib-es/helpers/index.js.map +1 -1
  52. package/lib-es/helpers/parse-props-to-display.js +9 -12
  53. package/lib-es/helpers/parse-props-to-display.js.map +1 -1
  54. package/package.json +10 -10
  55. package/src/components/Code/Code.js +3 -7
  56. package/src/components/DataSummary/helpers/build-loop-props-content.js +1 -4
  57. package/src/components/DataSummary/helpers/build-props-to-display-with-content.js +3 -6
  58. package/src/components/Layout/Layout.js +9 -2
  59. package/src/components/SearchContent/SearchContent.js +6 -8
  60. package/src/components/SearchFilter/SearchFilterContainer.js +1 -2
  61. package/src/components/SearchFilter/helpers/build-new-query.js +2 -3
  62. package/src/components/SearchFilterSort/helpers/handle-sort-update.js +3 -7
  63. package/src/components/SearchFilterSort/helpers/update-sort.js +2 -2
  64. package/src/helpers/build-props-query.js +2 -4
  65. package/src/helpers/get-wrapped-value-with-link.js +3 -6
  66. package/src/helpers/index.js +0 -1
  67. package/src/helpers/parse-props-to-display.js +21 -25
  68. package/tests/unit/src/components/Code/Code.test.js +0 -5
  69. package/tests/unit/src/components/Code/__snapshots__/Code.test.js.snap +0 -8
  70. package/tests/unit/src/components/DataSummary/helpers/build-loop-props-content.test.js +0 -9
  71. package/tests/unit/src/components/SearchFilter/helpers/build-new-query.test.js +1 -15
  72. package/tests/unit/src/components/SearchFilterSort/helpers/handle-sort-update.test.js +3 -9
  73. package/tests/unit/src/components/SearchFilterSort/helpers/update-sort.test.js +1 -10
  74. package/tests/unit/src/helpers/build-props-query.test.js +0 -25
  75. package/tests/unit/src/helpers/get-wrapped-value-with-link.test.js +2 -2
  76. package/tests/unit/src/helpers/parse-props-to-display.test.js +0 -4
  77. package/lib/helpers/process-data-summary-value.js +0 -56
  78. package/lib/helpers/process-data-summary-value.js.map +0 -1
  79. package/lib-es/helpers/process-data-summary-value.js +0 -36
  80. package/lib-es/helpers/process-data-summary-value.js.map +0 -1
  81. package/src/helpers/process-data-summary-value.js +0 -22
  82. package/tests/unit/src/helpers/__snapshots__/get-wrapped-value-with-link.test.js.snap +0 -18
  83. package/tests/unit/src/helpers/prcoess-data-summary-value.test.js +0 -52
@@ -1 +1 @@
1
- {"version":3,"file":"handle-sort-update.js","names":["_queryString","require","_constants","_updateSort","_interopRequireDefault","handleSortUpdate","router","value","query","url","selectLabel","queryWithoutSort","routerOptions","shallow","scroll","asPath","hashBit","split","parsedHash","concat","Object","keys","forEach","key","indexOf","PAGINATION_QUERY","SORTBY","SORT","DEFAULT_SORT","stringifiedQuery","stringify","push","updatedSortUrl","updateSort","_default","exports"],"sources":["../../../../src/components/SearchFilterSort/helpers/handle-sort-update.js"],"sourcesContent":["import { stringify } from 'query-string';\nimport { DEFAULT_SORT, SORT, SORTBY, PAGINATION_QUERY } from '../constants';\nimport updateSort from './update-sort';\n\nconst handleSortUpdate = (router, value, query, url, selectLabel) => {\n const queryWithoutSort = {};\n const routerOptions = { shallow: true, scroll: false };\n\n const { asPath } = router;\n const hashBit = asPath.split('#')[1];\n const parsedHash = hashBit ? `#${hashBit}` : '';\n Object.keys(query).forEach(key => {\n if (key.indexOf(PAGINATION_QUERY) !== -1) return;\n if (key !== SORTBY && key !== SORT) queryWithoutSort[key] = query[key];\n });\n if (value === DEFAULT_SORT || value === selectLabel) {\n const stringifiedQuery = stringify(queryWithoutSort);\n\n return stringifiedQuery\n ? router.push(`/Resolver`, `${url}?${stringifiedQuery}${parsedHash}`, routerOptions)\n : router.push(`/Resolver`, `${url}${parsedHash}`, routerOptions);\n }\n const updatedSortUrl = updateSort(value, queryWithoutSort, url, parsedHash);\n return router.push('/Resolver', updatedSortUrl, routerOptions);\n};\n\nexport default handleSortUpdate;\n"],"mappings":";;;;;;;;;;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AACA,IAAAC,UAAA,GAAAD,OAAA;AACA,IAAAE,WAAA,GAAAC,sBAAA,CAAAH,OAAA;AAEA,IAAMI,gBAAgB,GAAG,SAAnBA,gBAAgBA,CAAIC,MAAM,EAAEC,KAAK,EAAEC,KAAK,EAAEC,GAAG,EAAEC,WAAW,EAAK;EACnE,IAAMC,gBAAgB,GAAG,CAAC,CAAC;EAC3B,IAAMC,aAAa,GAAG;IAAEC,OAAO,EAAE,IAAI;IAAEC,MAAM,EAAE;EAAM,CAAC;EAEtD,IAAQC,MAAM,GAAKT,MAAM,CAAjBS,MAAM;EACd,IAAMC,OAAO,GAAGD,MAAM,CAACE,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;EACpC,IAAMC,UAAU,GAAGF,OAAO,OAAAG,MAAA,CAAOH,OAAO,IAAK,EAAE;EAC/CI,MAAM,CAACC,IAAI,CAACb,KAAK,CAAC,CAACc,OAAO,CAAC,UAAAC,GAAG,EAAI;IAChC,IAAIA,GAAG,CAACC,OAAO,CAACC,2BAAgB,CAAC,KAAK,CAAC,CAAC,EAAE;IAC1C,IAAIF,GAAG,KAAKG,iBAAM,IAAIH,GAAG,KAAKI,eAAI,EAAEhB,gBAAgB,CAACY,GAAG,CAAC,GAAGf,KAAK,CAACe,GAAG,CAAC;EACxE,CAAC,CAAC;EACF,IAAIhB,KAAK,KAAKqB,uBAAY,IAAIrB,KAAK,KAAKG,WAAW,EAAE;IACnD,IAAMmB,gBAAgB,GAAG,IAAAC,sBAAS,EAACnB,gBAAgB,CAAC;IAEpD,OAAOkB,gBAAgB,GACnBvB,MAAM,CAACyB,IAAI,iBAAAZ,MAAA,CAAiBV,GAAG,OAAAU,MAAA,CAAIU,gBAAgB,EAAAV,MAAA,CAAGD,UAAU,GAAIN,aAAa,CAAC,GAClFN,MAAM,CAACyB,IAAI,iBAAAZ,MAAA,CAAiBV,GAAG,EAAAU,MAAA,CAAGD,UAAU,GAAIN,aAAa,CAAC;EACpE;EACA,IAAMoB,cAAc,GAAG,IAAAC,sBAAU,EAAC1B,KAAK,EAAEI,gBAAgB,EAAEF,GAAG,EAAES,UAAU,CAAC;EAC3E,OAAOZ,MAAM,CAACyB,IAAI,CAAC,WAAW,EAAEC,cAAc,EAAEpB,aAAa,CAAC;AAChE,CAAC;AAAC,IAAAsB,QAAA,GAEa7B,gBAAgB;AAAA8B,OAAA,cAAAD,QAAA"}
1
+ {"version":3,"file":"handle-sort-update.js","names":["_queryString","require","_constants","_updateSort","_interopRequireDefault","handleSortUpdate","router","value","query","url","selectLabel","queryWithoutSort","routerOptions","shallow","scroll","Object","keys","forEach","key","indexOf","PAGINATION_QUERY","SORTBY","SORT","DEFAULT_SORT","stringifiedQuery","stringify","push","concat","updatedSortUrl","updateSort","_default","exports"],"sources":["../../../../src/components/SearchFilterSort/helpers/handle-sort-update.js"],"sourcesContent":["import { stringify } from 'query-string';\nimport { DEFAULT_SORT, SORT, SORTBY, PAGINATION_QUERY } from '../constants';\nimport updateSort from './update-sort';\n\nconst handleSortUpdate = (router, value, query, url, selectLabel) => {\n const queryWithoutSort = {};\n const routerOptions = { shallow: true, scroll: false };\n Object.keys(query).forEach(key => {\n if (key.indexOf(PAGINATION_QUERY) !== -1) return;\n if (key !== SORTBY && key !== SORT) queryWithoutSort[key] = query[key];\n });\n if (value === DEFAULT_SORT || value === selectLabel) {\n const stringifiedQuery = stringify(queryWithoutSort);\n\n return stringifiedQuery\n ? router.push(`/Resolver`, `${url}?${stringifiedQuery}`, routerOptions)\n : router.push(`/Resolver`, url, routerOptions);\n }\n const updatedSortUrl = updateSort(value, queryWithoutSort, url);\n return router.push('/Resolver', updatedSortUrl, routerOptions);\n};\n\nexport default handleSortUpdate;\n"],"mappings":";;;;;;;;;;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AACA,IAAAC,UAAA,GAAAD,OAAA;AACA,IAAAE,WAAA,GAAAC,sBAAA,CAAAH,OAAA;AAEA,IAAMI,gBAAgB,GAAG,SAAnBA,gBAAgBA,CAAIC,MAAM,EAAEC,KAAK,EAAEC,KAAK,EAAEC,GAAG,EAAEC,WAAW,EAAK;EACnE,IAAMC,gBAAgB,GAAG,CAAC,CAAC;EAC3B,IAAMC,aAAa,GAAG;IAAEC,OAAO,EAAE,IAAI;IAAEC,MAAM,EAAE;EAAM,CAAC;EACtDC,MAAM,CAACC,IAAI,CAACR,KAAK,CAAC,CAACS,OAAO,CAAC,UAAAC,GAAG,EAAI;IAChC,IAAIA,GAAG,CAACC,OAAO,CAACC,2BAAgB,CAAC,KAAK,CAAC,CAAC,EAAE;IAC1C,IAAIF,GAAG,KAAKG,iBAAM,IAAIH,GAAG,KAAKI,eAAI,EAAEX,gBAAgB,CAACO,GAAG,CAAC,GAAGV,KAAK,CAACU,GAAG,CAAC;EACxE,CAAC,CAAC;EACF,IAAIX,KAAK,KAAKgB,uBAAY,IAAIhB,KAAK,KAAKG,WAAW,EAAE;IACnD,IAAMc,gBAAgB,GAAG,IAAAC,sBAAS,EAACd,gBAAgB,CAAC;IAEpD,OAAOa,gBAAgB,GACnBlB,MAAM,CAACoB,IAAI,iBAAAC,MAAA,CAAiBlB,GAAG,OAAAkB,MAAA,CAAIH,gBAAgB,GAAIZ,aAAa,CAAC,GACrEN,MAAM,CAACoB,IAAI,cAAcjB,GAAG,EAAEG,aAAa,CAAC;EAClD;EACA,IAAMgB,cAAc,GAAG,IAAAC,sBAAU,EAACtB,KAAK,EAAEI,gBAAgB,EAAEF,GAAG,CAAC;EAC/D,OAAOH,MAAM,CAACoB,IAAI,CAAC,WAAW,EAAEE,cAAc,EAAEhB,aAAa,CAAC;AAChE,CAAC;AAAC,IAAAkB,QAAA,GAEazB,gBAAgB;AAAA0B,OAAA,cAAAD,QAAA"}
@@ -22,7 +22,6 @@ var _queryString = require("query-string");
22
22
  function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
23
23
  function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2["default"])(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
24
24
  var updateSort = function updateSort(value, query, url) {
25
- var hashBit = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : '';
26
25
  var _value$split = value.split(':'),
27
26
  _value$split2 = (0, _slicedToArray2["default"])(_value$split, 2),
28
27
  newSortBy = _value$split2[0],
@@ -32,7 +31,7 @@ var updateSort = function updateSort(value, query, url) {
32
31
  sort: newSort
33
32
  });
34
33
  var parsedQuery = (0, _queryString.stringify)(updatedQuery);
35
- return "".concat(url, "?").concat(parsedQuery).concat(hashBit);
34
+ return "".concat(url, "?").concat(parsedQuery);
36
35
  };
37
36
  var _default = updateSort;
38
37
  exports["default"] = _default;
@@ -1 +1 @@
1
- {"version":3,"file":"update-sort.js","names":["_queryString","require","ownKeys","object","enumerableOnly","keys","Object","getOwnPropertySymbols","symbols","filter","sym","getOwnPropertyDescriptor","enumerable","push","apply","_objectSpread","target","i","arguments","length","source","forEach","key","_defineProperty2","getOwnPropertyDescriptors","defineProperties","defineProperty","updateSort","value","query","url","hashBit","undefined","_value$split","split","_value$split2","_slicedToArray2","newSortBy","newSort","updatedQuery","sortby","sort","parsedQuery","stringify","concat","_default","exports"],"sources":["../../../../src/components/SearchFilterSort/helpers/update-sort.js"],"sourcesContent":["import { stringify } from 'query-string';\n\nconst updateSort = (value, query, url, hashBit = '') => {\n const [newSortBy, newSort] = value.split(':');\n const updatedQuery = { ...query, sortby: newSortBy, sort: newSort };\n const parsedQuery = stringify(updatedQuery);\n return `${url}?${parsedQuery}${hashBit}`;\n};\n\nexport default updateSort;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AAAyC,SAAAC,QAAAC,MAAA,EAAAC,cAAA,QAAAC,IAAA,GAAAC,MAAA,CAAAD,IAAA,CAAAF,MAAA,OAAAG,MAAA,CAAAC,qBAAA,QAAAC,OAAA,GAAAF,MAAA,CAAAC,qBAAA,CAAAJ,MAAA,GAAAC,cAAA,KAAAI,OAAA,GAAAA,OAAA,CAAAC,MAAA,WAAAC,GAAA,WAAAJ,MAAA,CAAAK,wBAAA,CAAAR,MAAA,EAAAO,GAAA,EAAAE,UAAA,OAAAP,IAAA,CAAAQ,IAAA,CAAAC,KAAA,CAAAT,IAAA,EAAAG,OAAA,YAAAH,IAAA;AAAA,SAAAU,cAAAC,MAAA,aAAAC,C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;AAAAmB,OAAA,cAAAD,QAAA"}
1
+ {"version":3,"file":"update-sort.js","names":["_queryString","require","ownKeys","object","enumerableOnly","keys","Object","getOwnPropertySymbols","symbols","filter","sym","getOwnPropertyDescriptor","enumerable","push","apply","_objectSpread","target","i","arguments","length","source","forEach","key","_defineProperty2","getOwnPropertyDescriptors","defineProperties","defineProperty","updateSort","value","query","url","_value$split","split","_value$split2","_slicedToArray2","newSortBy","newSort","updatedQuery","sortby","sort","parsedQuery","stringify","concat","_default","exports"],"sources":["../../../../src/components/SearchFilterSort/helpers/update-sort.js"],"sourcesContent":["import { stringify } from 'query-string';\n\nconst updateSort = (value, query, url) => {\n const [newSortBy, newSort] = value.split(':');\n const updatedQuery = { ...query, sortby: newSortBy, sort: newSort };\n const parsedQuery = stringify(updatedQuery);\n return `${url}?${parsedQuery}`;\n};\n\nexport default updateSort;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AAAyC,SAAAC,QAAAC,MAAA,EAAAC,cAAA,QAAAC,IAAA,GAAAC,MAAA,CAAAD,IAAA,CAAAF,MAAA,OAAAG,MAAA,CAAAC,qBAAA,QAAAC,OAAA,GAAAF,MAAA,CAAAC,qBAAA,CAAAJ,MAAA,GAAAC,cAAA,KAAAI,OAAA,GAAAA,OAAA,CAAAC,MAAA,WAAAC,GAAA,WAAAJ,MAAA,CAAAK,wBAAA,CAAAR,MAAA,EAAAO,GAAA,EAAAE,UAAA,OAAAP,IAAA,CAAAQ,IAAA,CAAAC,KAAA,CAAAT,IAAA,EAAAG,OAAA,YAAAH,IAAA;AAAA,SAAAU,cAAAC,MAAA,aAAAC,CAAA,MAAAA,CAAA,GAAAC,SAAA,CAAAC,MAAA,EAAAF,CAAA,UAAAG,MAAA,WAAAF,SAAA,CAAAD,CAAA,IAAAC,SAAA,CAAAD,CAAA,QAAAA,CAAA,OAAAf,OAAA,CAAAI,MAAA,CAAAc,MAAA,OAAAC,OAAA,WAAAC,GAAA,QAAAC,gBAAA,aAAAP,MAAA,EAAAM,GAAA,EAAAF,MAAA,CAAAE,GAAA,SAAAhB,MAAA,CAAAkB,yBAAA,GAAAlB,MAAA,CAAAmB,gBAAA,CAAAT,MAAA,EAAAV,MAAA,CAAAkB,yBAAA,CAAAJ,MAAA,KAAAlB,OAAA,CAAAI,MAAA,CAAAc,MAAA,GAAAC,OAAA,WAAAC,GAAA,IAAAhB,MAAA,CAAAoB,cAAA,CAAAV,MAAA,EAAAM,GAAA,EAAAhB,MAAA,CAAAK,wBAAA,CAAAS,MAAA,EAAAE,GAAA,iBAAAN,MAAA;AAEzC,IAAMW,UAAU,GAAG,SAAbA,UAAUA,CAAIC,KAAK,EAAEC,KAAK,EAAEC,GAAG,EAAK;EACxC,IAAAC,YAAA,GAA6BH,KAAK,CAACI,KAAK,CAAC,GAAG,CAAC;IAAAC,aAAA,OAAAC,eAAA,aAAAH,YAAA;IAAtCI,SAAS,GAAAF,aAAA;IAAEG,OAAO,GAAAH,aAAA;EACzB,IAAMI,YAAY,GAAAtB,aAAA,CAAAA,aAAA,KAAQc,KAAK;IAAES,MAAM,EAAEH,SAAS;IAAEI,IAAI,EAAEH;EAAO,EAAE;EACnE,IAAMI,WAAW,GAAG,IAAAC,sBAAS,EAACJ,YAAY,CAAC;EAC3C,UAAAK,MAAA,CAAUZ,GAAG,OAAAY,MAAA,CAAIF,WAAW;AAC9B,CAAC;AAAC,IAAAG,QAAA,GAEahB,UAAU;AAAAiB,OAAA,cAAAD,QAAA"}
@@ -66,15 +66,12 @@ var buildComplexProps = function buildComplexProps(shouldAddCategoryProps, props
66
66
  var _ref$relations = _ref.relations,
67
67
  relations = _ref$relations === void 0 ? [] : _ref$relations,
68
68
  _ref$dynamicPropertie = _ref.dynamicProperties,
69
- dynamicProperties = _ref$dynamicPropertie === void 0 ? {} : _ref$dynamicPropertie,
70
- _ref$properties = _ref.properties,
71
- properties = _ref$properties === void 0 ? {} : _ref$properties;
69
+ dynamicProperties = _ref$dynamicPropertie === void 0 ? {} : _ref$dynamicPropertie;
72
70
  return Object.keys(props).map(function (base) {
73
71
  var nestedProps = props[base];
74
72
  var hasLink = !!linkProps.find(function (linkProp) {
75
73
  return linkProp.includes(base);
76
74
  });
77
- var matchingProperty = !!properties[base];
78
75
  var matchingRelation = relations.find(function (_ref2) {
79
76
  var localField = _ref2.localField;
80
77
  return localField === base;
@@ -83,7 +80,7 @@ var buildComplexProps = function buildComplexProps(shouldAddCategoryProps, props
83
80
  return dynamicKey === base;
84
81
  });
85
82
  if (matchingRelation && !nestedProps.includes('id')) nestedProps.push('id');
86
- if (hasLink && (!!matchingProperty || !!matchingRelation || !!matchingDynamicProp)) nestedProps.push('url');
83
+ if (hasLink && (!!matchingRelation || !!matchingDynamicProp)) nestedProps.push('url');
87
84
  var jointNestedProps = nestedProps.join(',');
88
85
  if (base === 'category' && shouldAddCategoryProps) return "".concat(base, "{").concat(jointNestedProps, ", ").concat(categoryProps, "}");
89
86
  if (base.includes('published')) {
@@ -1 +1 @@
1
- {"version":3,"file":"build-props-query.js","names":["_constants","require","defaultProps","ID","categoryProps","checkProps","props","Object","keys","filter","prop","CATEGORY_ID","length","buildPropsQuery","entitySchema","extraProps","arguments","undefined","cardOptions","linkProps","parsedSchema","getEntitySchema","extraPropsHaveCategory","includes","_getTypeBaseProps","getTypeBaseProps","typeBasedProps","shouldAddCategoryProps","allProps","concat","_toConsumableArray2","uniqueProps","Set","basicProps","nestedProps","forEach","push","_prop$split","split","_prop$split2","_slicedToArray2","base","nested","complexProps","buildComplexProps","join","_ref","_ref$relations","relations","_ref$dynamicPropertie","dynamicProperties","_ref$properties","properties","map","hasLink","find","linkProp","matchingProperty","matchingRelation","_ref2","localField","matchingDynamicProp","dynamicKey","jointNestedProps","isCard","_ref3","_ref3$displayCategory","displayCategory","_ref3$displayThumbnai","displayThumbnail","interfaces","isContent","hasCategory","hasPreheader","PREHEADER_PROP","apply","getCategoyProps","getContentProps","url","_ref4","HEADLINE_PROP","_default","exports"],"sources":["../../src/helpers/build-props-query.js"],"sourcesContent":["import { CATEGORY_ID, ID, PREHEADER_PROP, HEADLINE_PROP } from '../constants';\n\nconst defaultProps = [ID, 'name'];\nconst categoryProps = 'id publishedListingPage{id, url}';\n\nconst checkProps = props =>\n !!(props && Object.keys(props).filter(prop => prop === CATEGORY_ID).length);\n\nconst buildPropsQuery = (entitySchema, extraProps = [], cardOptions = null, linkProps = []) => {\n const parsedSchema = entitySchema.getEntitySchema ? entitySchema.getEntitySchema : entitySchema;\n const extraPropsHaveCategory = !!extraProps.filter(prop => prop.includes('category.')).length;\n const { typeBasedProps, shouldAddCategoryProps } = getTypeBaseProps(\n parsedSchema,\n cardOptions,\n extraPropsHaveCategory\n );\n\n const allProps = [...typeBasedProps, ...extraProps];\n const uniqueProps = [...new Set([...allProps])];\n const basicProps = [];\n const nestedProps = {};\n uniqueProps.forEach(prop => {\n if (prop) {\n if (!prop.includes('.')) {\n basicProps.push(prop);\n return;\n }\n const [base, nested] = prop.split('.');\n if (!nestedProps[base]) nestedProps[base] = [nested];\n else nestedProps[base].push(nested);\n }\n });\n\n const complexProps = buildComplexProps(\n shouldAddCategoryProps,\n nestedProps,\n parsedSchema,\n linkProps\n );\n\n return [...basicProps, ...complexProps].join(',');\n};\n\nconst buildComplexProps = (\n shouldAddCategoryProps,\n props,\n { relations = [], dynamicProperties = {}, properties = {} },\n linkProps\n) =>\n Object.keys(props).map(base => {\n const nestedProps = props[base];\n const hasLink = !!linkProps.find(linkProp => linkProp.includes(base));\n const matchingProperty = !!properties[base];\n const matchingRelation = relations.find(({ localField }) => localField === base);\n const matchingDynamicProp = Object.keys(dynamicProperties).find(\n dynamicKey => dynamicKey === base\n );\n\n if (matchingRelation && !nestedProps.includes('id')) nestedProps.push('id');\n if (hasLink && (!!matchingProperty || !!matchingRelation || !!matchingDynamicProp))\n nestedProps.push('url');\n const jointNestedProps = nestedProps.join(',');\n if (base === 'category' && shouldAddCategoryProps)\n return `${base}{${jointNestedProps}, ${categoryProps}}`;\n if (base.includes('published')) {\n return `${base}{${jointNestedProps},url}`;\n }\n return `${base}{${jointNestedProps}}`;\n });\n\nconst getTypeBaseProps = (entitySchema, cardOptions, extraPropsHaveCategory) => {\n const isCard = !!cardOptions;\n const { displayCategory = true, displayThumbnail = true } = cardOptions || {};\n\n const shouldAddCategoryProps =\n (isCard && displayCategory) || (!isCard && !extraPropsHaveCategory);\n\n if (!isCard) return { typeBasedProps: [ID], shouldAddCategoryProps };\n\n const { interfaces, properties, dynamicProperties, relations } = entitySchema;\n\n const isContent = !!interfaces.includes('content/content');\n const hasCategory = checkProps(properties) || checkProps(dynamicProperties);\n const hasPreheader = properties[PREHEADER_PROP];\n\n const typeBasedProps = [...defaultProps];\n\n typeBasedProps.push(...getCategoyProps(shouldAddCategoryProps, hasCategory, hasPreheader));\n typeBasedProps.push(...getContentProps(isContent));\n\n if (properties.url || dynamicProperties.url) typeBasedProps.push('url');\n\n if (displayThumbnail && relations.find(({ localField }) => localField === 'image')) {\n typeBasedProps.push('image.id', 'image.url', 'image.data');\n }\n\n return { typeBasedProps, shouldAddCategoryProps };\n};\n\nconst getContentProps = isContent => (isContent ? ['url', 'sponsored', 'featured'] : []);\n\nconst getCategoyProps = (shouldAddCategoryProps, hasCategory, hasPreheader) => {\n if (!shouldAddCategoryProps) return [];\n const props = [];\n if (hasCategory)\n props.push('category.name', 'category.listingPageId', 'category.listingPageEntity');\n\n if (hasPreheader) {\n props.push(`${PREHEADER_PROP}{name}`);\n props.push(HEADLINE_PROP);\n }\n\n return props;\n};\n\nexport default buildPropsQuery;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,UAAA,GAAAC,OAAA;AAEA,IAAMC,YAAY,GAAG,CAACC,aAAE,EAAE,MAAM,CAAC;AACjC,IAAMC,aAAa,GAAG,kCAAkC;AAExD,IAAMC,UAAU,GAAG,SAAbA,UAAUA,CAAGC,KAAK;EAAA,OACtB,CAAC,EAAEA,KAAK,IAAIC,MA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","require","defaultProps","ID","categoryProps","checkProps","props","Object","keys","filter","prop","CATEGORY_ID","length","buildPropsQuery","entitySchema","extraProps","arguments","undefined","cardOptions","linkProps","parsedSchema","getEntitySchema","extraPropsHaveCategory","includes","_getTypeBaseProps","getTypeBaseProps","typeBasedProps","shouldAddCategoryProps","allProps","concat","_toConsumableArray2","uniqueProps","Set","basicProps","nestedProps","forEach","push","_prop$split","split","_prop$split2","_slicedToArray2","base","nested","complexProps","buildComplexProps","join","_ref","_ref$relations","relations","_ref$dynamicPropertie","dynamicProperties","map","hasLink","find","linkProp","matchingRelation","_ref2","localField","matchingDynamicProp","dynamicKey","jointNestedProps","isCard","_ref3","_ref3$displayCategory","displayCategory","_ref3$displayThumbnai","displayThumbnail","interfaces","properties","isContent","hasCategory","hasPreheader","PREHEADER_PROP","apply","getCategoyProps","getContentProps","url","_ref4","HEADLINE_PROP","_default","exports"],"sources":["../../src/helpers/build-props-query.js"],"sourcesContent":["import { CATEGORY_ID, ID, PREHEADER_PROP, HEADLINE_PROP } from '../constants';\n\nconst defaultProps = [ID, 'name'];\nconst categoryProps = 'id publishedListingPage{id, url}';\n\nconst checkProps = props =>\n !!(props && Object.keys(props).filter(prop => prop === CATEGORY_ID).length);\n\nconst buildPropsQuery = (entitySchema, extraProps = [], cardOptions = null, linkProps = []) => {\n const parsedSchema = entitySchema.getEntitySchema ? entitySchema.getEntitySchema : entitySchema;\n const extraPropsHaveCategory = !!extraProps.filter(prop => prop.includes('category.')).length;\n const { typeBasedProps, shouldAddCategoryProps } = getTypeBaseProps(\n parsedSchema,\n cardOptions,\n extraPropsHaveCategory\n );\n\n const allProps = [...typeBasedProps, ...extraProps];\n const uniqueProps = [...new Set([...allProps])];\n const basicProps = [];\n const nestedProps = {};\n uniqueProps.forEach(prop => {\n if (prop) {\n if (!prop.includes('.')) {\n basicProps.push(prop);\n return;\n }\n const [base, nested] = prop.split('.');\n if (!nestedProps[base]) nestedProps[base] = [nested];\n else nestedProps[base].push(nested);\n }\n });\n\n const complexProps = buildComplexProps(\n shouldAddCategoryProps,\n nestedProps,\n parsedSchema,\n linkProps\n );\n\n return [...basicProps, ...complexProps].join(',');\n};\n\nconst buildComplexProps = (\n shouldAddCategoryProps,\n props,\n { relations = [], dynamicProperties = {} },\n linkProps\n) =>\n Object.keys(props).map(base => {\n const nestedProps = props[base];\n const hasLink = !!linkProps.find(linkProp => linkProp.includes(base));\n const matchingRelation = relations.find(({ localField }) => localField === base);\n const matchingDynamicProp = Object.keys(dynamicProperties).find(\n dynamicKey => dynamicKey === base\n );\n\n if (matchingRelation && !nestedProps.includes('id')) nestedProps.push('id');\n if (hasLink && (!!matchingRelation || !!matchingDynamicProp)) nestedProps.push('url');\n const jointNestedProps = nestedProps.join(',');\n if (base === 'category' && shouldAddCategoryProps)\n return `${base}{${jointNestedProps}, ${categoryProps}}`;\n if (base.includes('published')) {\n return `${base}{${jointNestedProps},url}`;\n }\n return `${base}{${jointNestedProps}}`;\n });\n\nconst getTypeBaseProps = (entitySchema, cardOptions, extraPropsHaveCategory) => {\n const isCard = !!cardOptions;\n const { displayCategory = true, displayThumbnail = true } = cardOptions || {};\n\n const shouldAddCategoryProps =\n (isCard && displayCategory) || (!isCard && !extraPropsHaveCategory);\n\n if (!isCard) return { typeBasedProps: [ID], shouldAddCategoryProps };\n\n const { interfaces, properties, dynamicProperties, relations } = entitySchema;\n\n const isContent = !!interfaces.includes('content/content');\n const hasCategory = checkProps(properties) || checkProps(dynamicProperties);\n const hasPreheader = properties[PREHEADER_PROP];\n\n const typeBasedProps = [...defaultProps];\n\n typeBasedProps.push(...getCategoyProps(shouldAddCategoryProps, hasCategory, hasPreheader));\n typeBasedProps.push(...getContentProps(isContent));\n\n if (properties.url || dynamicProperties.url) typeBasedProps.push('url');\n\n if (displayThumbnail && relations.find(({ localField }) => localField === 'image')) {\n typeBasedProps.push('image.id', 'image.url', 'image.data');\n }\n\n return { typeBasedProps, shouldAddCategoryProps };\n};\n\nconst getContentProps = isContent => (isContent ? ['url', 'sponsored', 'featured'] : []);\n\nconst getCategoyProps = (shouldAddCategoryProps, hasCategory, hasPreheader) => {\n if (!shouldAddCategoryProps) return [];\n const props = [];\n if (hasCategory)\n props.push('category.name', 'category.listingPageId', 'category.listingPageEntity');\n\n if (hasPreheader) {\n props.push(`${PREHEADER_PROP}{name}`);\n props.push(HEADLINE_PROP);\n }\n\n return props;\n};\n\nexport default buildPropsQuery;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,UAAA,GAAAC,OAAA;AAEA,IAAMC,YAAY,GAAG,CAACC,aAAE,EAAE,MAAM,CAAC;AACjC,IAAMC,aAAa,GAAG,kCAAkC;AAExD,IAAMC,UAAU,GAAG,SAAbA,UAAUA,CAAGC,KAAK;EAAA,OACtB,CAAC,EAAEA,KAAK,IAAIC,MAAM,CAACC,IAAI,CAACF,KAAK,CAAC,CAACG,MAAM,CAAC,UAAAC,IAAI;IAAA,OAAIA,IAAI,KAAKC,sBAAW;EAAA,EAAC,CAACC,MAAM,CAAC;AAAA;AAE7E,IAAMC,eAAe,GAAG,SAAlBA,eAAeA,CAAIC,YAAY,EAA0D;EAAA,IAAxDC,UAAU,GAAAC,SAAA,CAAAJ,MAAA,QAAAI,SAAA,QAAAC,SAAA,GAAAD,SAAA,MAAG,EAAE;EAAA,IAAEE,WAAW,GAAAF,SAAA,CAAAJ,MAAA,QAAAI,SAAA,QAAAC,SAAA,GAAAD,SAAA,MAAG,IAAI;EAAA,IAAEG,SAAS,GAAAH,SAAA,CAAAJ,MAAA,QAAAI,SAAA,QAAAC,SAAA,GAAAD,SAAA,MAAG,EAAE;EACxF,IAAMI,YAAY,GAAGN,YAAY,CAACO,eAAe,GAAGP,YAAY,CAACO,eAAe,GAAGP,YAAY;EAC/F,IAAMQ,sBAAsB,GAAG,CAAC,CAACP,UAAU,CAACN,MAAM,CAAC,UAAAC,IAAI;IAAA,OAAIA,IAAI,CAACa,QAAQ,CAAC,WAAW,CAAC;EAAA,EAAC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wBAAwB,EAAE,4BAA4B,CAAC;EAErF,IAAImC,YAAY,EAAE;IAChBjE,KAAK,CAAC8B,IAAI,IAAAP,MAAA,CAAI2C,yBAAc,WAAQ,CAAC;IACrClE,KAAK,CAAC8B,IAAI,CAAC0C,wBAAa,CAAC;EAC3B;EAEA,OAAOxE,KAAK;AACd,CAAC;AAAC,IAAAyE,QAAA,GAEalE,eAAe;AAAAmE,OAAA,cAAAD,QAAA"}
@@ -8,6 +8,7 @@ Object.defineProperty(exports, "__esModule", {
8
8
  exports["default"] = void 0;
9
9
  require("core-js/modules/es.array.is-array.js");
10
10
  require("core-js/modules/es.array.map.js");
11
+ require("core-js/modules/es.array.concat.js");
11
12
  require("core-js/modules/es.array.join.js");
12
13
  var _react = _interopRequireDefault(require("react"));
13
14
  var _BlazeLink = _interopRequireDefault(require("../components/BlazeLink"));
@@ -19,11 +20,11 @@ var getWrappedValueWithLink = function getWrappedValueWithLink(value, link) {
19
20
  url = arrValue.url;
20
21
  var keyValue = arrValue[keyField];
21
22
  var isLastItem = index === value.length - 1;
22
- var keyFieldValue = isLastItem ? keyValue : /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, keyValue, ", ");
23
+ var keyFieldValue = isLastItem ? keyValue : keyValue.concat(',');
23
24
  return url ? /*#__PURE__*/_react["default"].createElement(_BlazeLink["default"], {
24
25
  key: [keyPrefix, index].join('-'),
25
26
  href: url
26
- }, /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, keyFieldValue, " ")) : /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, keyFieldValue, " ");
27
+ }, "".concat(keyFieldValue, " ")) : "".concat(keyFieldValue, " ");
27
28
  });
28
29
  return arrayResults.length ? arrayResults : null;
29
30
  }
@@ -1 +1 @@
1
- {"version":3,"file":"get-wrapped-value-with-link.js","names":["_react","_interopRequireDefault","require","_BlazeLink","getWrappedValueWithLink","value","link","keyPrefix","arguments","length","undefined","Array","isArray","arrayResults","map","arrValue","index","keyField","url","keyValue","isLastItem","keyFieldValue","createElement","Fragment","key","join","href","_default","exports"],"sources":["../../src/helpers/get-wrapped-value-with-link.js"],"sourcesContent":["import React from 'react';\nimport BlazeLink from '../components/BlazeLink';\n\nconst getWrappedValueWithLink = (value, link, keyPrefix = '') => {\n if (Array.isArray(value)) {\n const arrayResults = value.map((arrValue, index) => {\n const { keyField, url } = arrValue;\n const keyValue = arrValue[keyField];\n\n const isLastItem = index === value.length - 1;\n const keyFieldValue = isLastItem ? keyValue : <>{keyValue}, </>;\n\n return url ? (\n <BlazeLink key={[keyPrefix, index].join('-')} href={url}>\n {<>{keyFieldValue} </>}\n </BlazeLink>\n ) : (\n <>{keyFieldValue} </>\n );\n });\n\n return arrayResults.length ? arrayResults : null;\n }\n\n return link ? <BlazeLink href={link}>{value}</BlazeLink> : value;\n};\n\nexport default getWrappedValueWithLink;\n"],"mappings":";;;;;;;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,UAAA,GAAAF,sBAAA,CAAAC,OAAA;AAEA,IAAME,uBAAuB,GAAG,SAA1BA,uBAAuBA,CAAIC,KAAK,EAAEC,IAAI,EAAqB;EAAA,IAAnBC,SAAS,GAAAC,SAAA,CAAAC,MAAA,QAAAD,SAAA,QAAAE,SAAA,GAAAF,SAAA,MAAG,EAAE;EAC1D,IAAIG,KAAK,CAACC,OAAO,CAACP,KAAK,CAAC,EAAE;IACxB,IAAMQ,YAAY,GAAGR,KAAK,CAACS,GAAG,CAAC,UAACC,QAAQ,EAAEC,KAAK,EAAK;MAClD,IAAQC,QAAQ,GAAUF,QAAQ,CAA1BE,QAAQ;QAAEC,GAAG,GAAKH,QAAQ,CAAhBG,GAAG;MACrB,IAAMC,QAAQ,GAAGJ,QAAQ,CAACE,QAAQ,CAAC;MAEnC,IAAMG,UAAU,GAAGJ,KAAK,KAAKX,KAAK,CAACI,MAAM,GAAG,CAAC;MAC7C,IAAMY,aAAa,GAAGD,UAAU,GAAGD,QAAQ,gBAAGnB,MAAA,YAAAsB,aAAA,CAAAtB,MAAA,YAAAuB,QAAA,QAAGJ,QAAQ,EAAC,IAAI,CAAC;MAE/D,OAAOD,GAAG,gBACRlB,MAAA,YAAAsB,aAAA,CAACnB,UAAA,WAAS;QAACqB,GAAG,EAAE,CAACjB,SAAS,EAAES,KAAK,CAAC,CAACS,IAAI,CAAC,GAAG,CAAE;QAACC,IAAI,EAAER;MAAI,gBACrDlB,MAAA,YAAAsB,aAAA,CAAAtB,MAAA,YAAAuB,QAAA,QAAGF,aAAa,EAAC,GAAG,CACZ,CAAC,gBAEZrB,MAAA,YAAAsB,aAAA,CAAAtB,MAAA,YAAAuB,QAAA,QAAGF,aAAa,EAAC,GAAG,CACrB;IACH,CAAC,CAAC;IAEF,OAAOR,YAAY,CAACJ,MAAM,GAAGI,YAAY,GAAG,IAAI;EAClD;EAEA,OAAOP,IAAI,gBAAGN,MAAA,YAAAsB,aAAA,CAACnB,UAAA,WAAS;IAACuB,IAAI,EAAEpB;EAAK,GAAED,KAAiB,CAAC,GAAGA,KAAK;AAClE,CAAC;AAAC,IAAAsB,QAAA,GAEavB,uBAAuB;AAAAwB,OAAA,cAAAD,QAAA"}
1
+ {"version":3,"file":"get-wrapped-value-with-link.js","names":["_react","_interopRequireDefault","require","_BlazeLink","getWrappedValueWithLink","value","link","keyPrefix","arguments","length","undefined","Array","isArray","arrayResults","map","arrValue","index","keyField","url","keyValue","isLastItem","keyFieldValue","concat","createElement","key","join","href","_default","exports"],"sources":["../../src/helpers/get-wrapped-value-with-link.js"],"sourcesContent":["import React from 'react';\nimport BlazeLink from '../components/BlazeLink';\n\nconst getWrappedValueWithLink = (value, link, keyPrefix = '') => {\n if (Array.isArray(value)) {\n const arrayResults = value.map((arrValue, index) => {\n const { keyField, url } = arrValue;\n const keyValue = arrValue[keyField];\n const isLastItem = index === value.length - 1;\n const keyFieldValue = isLastItem ? keyValue : keyValue.concat(',');\n\n return url ? (\n <BlazeLink key={[keyPrefix, index].join('-')} href={url}>{`${keyFieldValue} `}</BlazeLink>\n ) : (\n `${keyFieldValue} `\n );\n });\n\n return arrayResults.length ? arrayResults : null;\n }\n\n return link ? <BlazeLink href={link}>{value}</BlazeLink> : value;\n};\n\nexport default getWrappedValueWithLink;\n"],"mappings":";;;;;;;;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,UAAA,GAAAF,sBAAA,CAAAC,OAAA;AAEA,IAAME,uBAAuB,GAAG,SAA1BA,uBAAuBA,CAAIC,KAAK,EAAEC,IAAI,EAAqB;EAAA,IAAnBC,SAAS,GAAAC,SAAA,CAAAC,MAAA,QAAAD,SAAA,QAAAE,SAAA,GAAAF,SAAA,MAAG,EAAE;EAC1D,IAAIG,KAAK,CAACC,OAAO,CAACP,KAAK,CAAC,EAAE;IACxB,IAAMQ,YAAY,GAAGR,KAAK,CAACS,GAAG,CAAC,UAACC,QAAQ,EAAEC,KAAK,EAAK;MAClD,IAAQC,QAAQ,GAAUF,QAAQ,CAA1BE,QAAQ;QAAEC,GAAG,GAAKH,QAAQ,CAAhBG,GAAG;MACrB,IAAMC,QAAQ,GAAGJ,QAAQ,CAACE,QAAQ,CAAC;MACnC,IAAMG,UAAU,GAAGJ,KAAK,KAAKX,KAAK,CAACI,MAAM,GAAG,CAAC;MAC7C,IAAMY,aAAa,GAAGD,UAAU,GAAGD,QAAQ,GAAGA,QAAQ,CAACG,MAAM,CAAC,GAAG,CAAC;MAElE,OAAOJ,GAAG,gBACRlB,MAAA,YAAAuB,aAAA,CAACpB,UAAA,WAAS;QAACqB,GAAG,EAAE,CAACjB,SAAS,EAAES,KAAK,CAAC,CAACS,IAAI,CAAC,GAAG,CAAE;QAACC,IAAI,EAAER;MAAI,MAAAI,MAAA,CAAKD,aAAa,MAAe,CAAC,MAAAC,MAAA,CAEvFD,aAAa,MACjB;IACH,CAAC,CAAC;IAEF,OAAOR,YAAY,CAACJ,MAAM,GAAGI,YAAY,GAAG,IAAI;EAClD;EAEA,OAAOP,IAAI,gBAAGN,MAAA,YAAAuB,aAAA,CAACpB,UAAA,WAAS;IAACuB,IAAI,EAAEpB;EAAK,GAAED,KAAiB,CAAC,GAAGA,KAAK;AAClE,CAAC;AAAC,IAAAsB,QAAA,GAEavB,uBAAuB;AAAAwB,OAAA,cAAAD,QAAA"}
@@ -275,12 +275,6 @@ Object.defineProperty(exports, "parseTextBlock", {
275
275
  return _parseTextBlock["default"];
276
276
  }
277
277
  });
278
- Object.defineProperty(exports, "processDataSummaryValue", {
279
- enumerable: true,
280
- get: function get() {
281
- return _processDataSummaryValue["default"];
282
- }
283
- });
284
278
  Object.defineProperty(exports, "removeExtraItems", {
285
279
  enumerable: true,
286
280
  get: function get() {
@@ -382,5 +376,4 @@ var _getParsedPropValues = _interopRequireDefault(require("./get-parsed-prop-val
382
376
  var _getSanitizedPropValues = _interopRequireDefault(require("./get-sanitized-prop-values"));
383
377
  var _appendImages = _interopRequireDefault(require("./append-images"));
384
378
  var _parseTextBlock = _interopRequireDefault(require("./parse-TextBlock"));
385
- var _processDataSummaryValue = _interopRequireDefault(require("./process-data-summary-value"));
386
379
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["_buildInheritedFilters","_interopRequireDefault","require","_buildLinkExtraProps","_buildPropsQuery","_buildQueryFields","_buildRawQuery","_buildRawQueryBase","_buildSearchValuesCheckboxSelect","_buildSearchValuesText","_buildSetFilters","_checkPropsToUse","_getElasticsearchOperator","_getClickWrapperOptions","_getEntitiesWithBanner","_getEntityData","_getEntityRenderProps","_getGenericProps","_getGenericRenderVariables","_getImageIds","_getInheritedFilters","_getModifiers","_getNotEqualQuery","_getPaginationIndex","_getParsedSummaryValue","_getQueryFilters","_getQueryProps","_getRequiredSchemas","_getSearchFilterType","_getUnpublishedEntityName","_getWrappedValueWithLink","_getItemsToDisplayIds","_isBrowser","_isFilterEntitysId","_isObject","_isUsingRelationImage","_parsePropsToDisplay","_renderChildren","_shouldRenderWaypoint","_shouldShowProperty","_sortResponseData","_splitChildren","_getCurrentOffset","_updateChildrensParent","_getDisplayCountData","_buildImageProperties","_getUpdatedFilterBy","_checkForError","_removeUnwantedCharacters","_hasChildren","_removeExtraItems","_getParsedPropValues","_getSanitizedPropValues","_appendImages","_parseTextBlock","_processDataSummaryValue"],"sources":["../../src/helpers/index.js"],"sourcesContent":["export { default as buildInheritedFilters } from './build-inherited-filters';\nexport { default as buildLinkExtraProps } from './build-link-extra-props';\nexport { default as buildPropsQuery } from './build-props-query';\nexport { default as buildQueryFields } from './build-query-fields';\nexport { default as buildRawQuery } from './build-raw-query';\nexport { default as buildRawQueryBase } from './build-raw-query-base';\nexport { default as buildSearchValuesCheckboxSelect } from './build-search-values-checkbox-select';\nexport { default as buildSearchValuesText } from './build-search-values-text';\nexport { default as buildSetFilters } from './build-set-filters';\nexport { default as checkPropsToUse } from './check-props-to-use';\nexport { default as getElasticsearchOperator } from './get-elasticsearch-operator';\nexport { default as getClickWrapperOptions } from './get-click-wrapper-options';\nexport { default as getEntitiesWithBanner } from './get-entities-with-banner';\nexport { default as getEntityData } from './get-entity-data';\nexport { default as getEntityRenderProps } from './get-entity-render-props';\nexport { default as getGenericProps } from './get-generic-props';\nexport { default as getGenericRenderVariables } from './get-generic-render-variables';\nexport { default as getImageIds } from './get-image-ids';\nexport { default as getInheritedFilters } from './get-inherited-filters';\nexport { default as getModifiers } from './get-modifiers';\nexport { default as getNotEqualQuery } from './get-not-equal-query';\nexport { default as getPaginationIndex } from './get-pagination-index';\nexport { default as getParsedSummaryValue } from './get-parsed-summary-value';\nexport { default as getQueryFilters } from './get-query-filters';\nexport { default as getQueryProps } from './get-query-props';\nexport { default as getRequiredSchemas } from './get-required-schemas';\nexport { default as getSearchFilterType } from './get-search-filter-type';\nexport { default as getUnpublishedEntityName } from './get-unpublished-entity-name';\nexport { default as getWrappedValueWithLink } from './get-wrapped-value-with-link';\nexport { default as getItemsToDisplayIds } from './get-items-to-display-ids';\nexport { default as isBrowser } from './is-browser';\nexport { default as isFilterEntitysId } from './is-filter-entitys-id';\nexport { default as isObject } from './is-object';\nexport { default as isUsingRelationImage } from './is-using-relation-image';\nexport { default as parsePropsToDisplay } from './parse-props-to-display';\nexport { default as renderChildren } from './render-children';\nexport { default as shouldRenderWaypoint } from './should-render-waypoint';\nexport { default as shouldShowProperty } from './should-show-property';\nexport { default as sortResponseData } from './sort-response-data';\nexport { default as splitChildren } from './split-children';\nexport { default as getCurrentOffset } from './get-current-offset';\nexport { default as updateChildrensParent } from './update-childrens-parent';\nexport { default as getDisplayCountData } from './get-display-count-data';\nexport { default as buildImageProperties } from './build-image-properties';\nexport { default as getUpdatedFilterBy } from './get-updated-filter-by';\nexport { default as checkForError } from './check-for-error';\nexport { default as removeUnwantedCharacters } from './remove-unwanted-characters';\nexport { default as hasChildren } from './has-children';\nexport { default as removeExtraItems } from './remove-extra-items';\nexport { default as getParsedPropValues } from './get-parsed-prop-values';\nexport { default as getSanitizedPropValues } from './get-sanitized-prop-values';\nexport { default as appendImages } from './append-images';\nexport { default as parseTextBlock } from './parse-TextBlock';\nexport { default as processDataSummaryValue } from './process-data-summary-value';\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,sBAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,oBAAA,GAAAF,sBAAA,CAAAC,OAAA;AACA,IAA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AqD,wBAAA,GAAAtD,sBAAA,CAAAC,OAAA"}
1
+ {"version":3,"file":"index.js","names":["_buildInheritedFilters","_interopRequireDefault","require","_buildLinkExtraProps","_buildPropsQuery","_buildQueryFields","_buildRawQuery","_buildRawQueryBase","_buildSearchValuesCheckboxSelect","_buildSearchValuesText","_buildSetFilters","_checkPropsToUse","_getElasticsearchOperator","_getClickWrapperOptions","_getEntitiesWithBanner","_getEntityData","_getEntityRenderProps","_getGenericProps","_getGenericRenderVariables","_getImageIds","_getInheritedFilters","_getModifiers","_getNotEqualQuery","_getPaginationIndex","_getParsedSummaryValue","_getQueryFilters","_getQueryProps","_getRequiredSchemas","_getSearchFilterType","_getUnpublishedEntityName","_getWrappedValueWithLink","_getItemsToDisplayIds","_isBrowser","_isFilterEntitysId","_isObject","_isUsingRelationImage","_parsePropsToDisplay","_renderChildren","_shouldRenderWaypoint","_shouldShowProperty","_sortResponseData","_splitChildren","_getCurrentOffset","_updateChildrensParent","_getDisplayCountData","_buildImageProperties","_getUpdatedFilterBy","_checkForError","_removeUnwantedCharacters","_hasChildren","_removeExtraItems","_getParsedPropValues","_getSanitizedPropValues","_appendImages","_parseTextBlock"],"sources":["../../src/helpers/index.js"],"sourcesContent":["export { default as buildInheritedFilters } from './build-inherited-filters';\nexport { default as buildLinkExtraProps } from './build-link-extra-props';\nexport { default as buildPropsQuery } from './build-props-query';\nexport { default as buildQueryFields } from './build-query-fields';\nexport { default as buildRawQuery } from './build-raw-query';\nexport { default as buildRawQueryBase } from './build-raw-query-base';\nexport { default as buildSearchValuesCheckboxSelect } from './build-search-values-checkbox-select';\nexport { default as buildSearchValuesText } from './build-search-values-text';\nexport { default as buildSetFilters } from './build-set-filters';\nexport { default as checkPropsToUse } from './check-props-to-use';\nexport { default as getElasticsearchOperator } from './get-elasticsearch-operator';\nexport { default as getClickWrapperOptions } from './get-click-wrapper-options';\nexport { default as getEntitiesWithBanner } from './get-entities-with-banner';\nexport { default as getEntityData } from './get-entity-data';\nexport { default as getEntityRenderProps } from './get-entity-render-props';\nexport { default as getGenericProps } from './get-generic-props';\nexport { default as getGenericRenderVariables } from './get-generic-render-variables';\nexport { default as getImageIds } from './get-image-ids';\nexport { default as getInheritedFilters } from './get-inherited-filters';\nexport { default as getModifiers } from './get-modifiers';\nexport { default as getNotEqualQuery } from './get-not-equal-query';\nexport { default as getPaginationIndex } from './get-pagination-index';\nexport { default as getParsedSummaryValue } from './get-parsed-summary-value';\nexport { default as getQueryFilters } from './get-query-filters';\nexport { default as getQueryProps } from './get-query-props';\nexport { default as getRequiredSchemas } from './get-required-schemas';\nexport { default as getSearchFilterType } from './get-search-filter-type';\nexport { default as getUnpublishedEntityName } from './get-unpublished-entity-name';\nexport { default as getWrappedValueWithLink } from './get-wrapped-value-with-link';\nexport { default as getItemsToDisplayIds } from './get-items-to-display-ids';\nexport { default as isBrowser } from './is-browser';\nexport { default as isFilterEntitysId } from './is-filter-entitys-id';\nexport { default as isObject } from './is-object';\nexport { default as isUsingRelationImage } from './is-using-relation-image';\nexport { default as parsePropsToDisplay } from './parse-props-to-display';\nexport { default as renderChildren } from './render-children';\nexport { default as shouldRenderWaypoint } from './should-render-waypoint';\nexport { default as shouldShowProperty } from './should-show-property';\nexport { default as sortResponseData } from './sort-response-data';\nexport { default as splitChildren } from './split-children';\nexport { default as getCurrentOffset } from './get-current-offset';\nexport { default as updateChildrensParent } from './update-childrens-parent';\nexport { default as getDisplayCountData } from './get-display-count-data';\nexport { default as buildImageProperties } from './build-image-properties';\nexport { default as getUpdatedFilterBy } from './get-updated-filter-by';\nexport { default as checkForError } from './check-for-error';\nexport { default as removeUnwantedCharacters } from './remove-unwanted-characters';\nexport { default as hasChildren } from './has-children';\nexport { default as removeExtraItems } from './remove-extra-items';\nexport { default as getParsedPropValues } from './get-parsed-prop-values';\nexport { default as getSanitizedPropValues } from './get-sanitized-prop-values';\nexport { default as appendImages } from './append-images';\nexport { default as parseTextBlock } from './parse-TextBlock';\n"],"mappings":";;;;;;;;;;;;;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AAA,GAAA5C,sBAAA,CAAAC,OAAA;AACA,IAAA4C,mBAAA,GAAA7C,sBAAA,CAAAC,OAAA;AACA,IAAA6C,cAAA,GAAA9C,sBAAA,CAAAC,OAAA;AACA,IAAA8C,yBAAA,GAAA/C,sBAAA,CAAAC,OAAA;AACA,IAAA+C,YAAA,GAAAhD,sBAAA,CAAAC,OAAA;AACA,IAAAgD,iBAAA,GAAAjD,sBAAA,CAAAC,OAAA;AACA,IAAAiD,oBAAA,GAAAlD,sBAAA,CAAAC,OAAA;AACA,IAAAkD,uBAAA,GAAAnD,sBAAA,CAAAC,OAAA;AACA,IAAAmD,aAAA,GAAApD,sBAAA,CAAAC,OAAA;AACA,IAAAoD,eAAA,GAAArD,sBAAA,CAAAC,OAAA"}
@@ -16,14 +16,12 @@ require("core-js/modules/es.array.filter.js");
16
16
  require("core-js/modules/es.object.to-string.js");
17
17
  require("core-js/modules/es.array.map.js");
18
18
  require("core-js/modules/es.string.bold.js");
19
- require("core-js/modules/es.array.is-array.js");
20
19
  var _react = _interopRequireWildcard(require("react"));
21
20
  var _lodash = _interopRequireDefault(require("lodash.at"));
22
21
  var _isObject = _interopRequireDefault(require("./is-object"));
23
22
  var _getParsedPropValues = _interopRequireDefault(require("./get-parsed-prop-values"));
24
23
  var _getSanitizedPropValues = _interopRequireDefault(require("./get-sanitized-prop-values"));
25
24
  var _constants = require("../constants");
26
- var _processDataSummaryValue = _interopRequireDefault(require("./process-data-summary-value"));
27
25
  function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
28
26
  function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
29
27
  // TODO this helper should be removed if database is wiped clean and all elements change to new props struc
@@ -31,13 +29,13 @@ var parsePropsToDisplay = function parsePropsToDisplay() {
31
29
  var props = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
32
30
  var propsToDisplay = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];
33
31
  if (!(0, _isObject["default"])(propsToDisplay[0])) return (0, _lodash["default"])(props, propsToDisplay).filter(Boolean);
34
- return propsToDisplay.map(function (options, currentIndex) {
35
- var bold = options.bold,
36
- propertiesToDisplay = options.propertiesToDisplay,
37
- prefix = options.prefix,
38
- suffix = options.suffix,
39
- shouldStrip = options.shouldStrip,
40
- enableLink = options.enableLink;
32
+ return propsToDisplay.map(function (_ref, currentIndex) {
33
+ var bold = _ref.bold,
34
+ propertiesToDisplay = _ref.propertiesToDisplay,
35
+ prefix = _ref.prefix,
36
+ suffix = _ref.suffix,
37
+ shouldStrip = _ref.shouldStrip,
38
+ enableLink = _ref.enableLink;
41
39
  var Wrapper = bold ? _constants.BOLD_TAG : _react.Fragment;
42
40
  var parsedPropValues = (0, _getParsedPropValues["default"])({
43
41
  propertiesToDisplay: propertiesToDisplay,
@@ -48,10 +46,7 @@ var parsePropsToDisplay = function parsePropsToDisplay() {
48
46
  var sanitizedPropValues = (0, _getSanitizedPropValues["default"])(parsedPropValues);
49
47
  if (!sanitizedPropValues || !sanitizedPropValues.length) return null;
50
48
  var stringEndBlank = currentIndex + 1 === propsToDisplay.length ? '' : _constants.BLANK_SPACE_UNICODE_STRING;
51
- var processedValue = Array.isArray(sanitizedPropValues) ? sanitizedPropValues.map(function (value) {
52
- return (0, _processDataSummaryValue["default"])(value, options);
53
- }) : (0, _processDataSummaryValue["default"])(sanitizedPropValues, options);
54
- return /*#__PURE__*/_react["default"].createElement(Wrapper, null, prefix, " ", processedValue, " ", suffix, stringEndBlank);
49
+ return /*#__PURE__*/_react["default"].createElement(Wrapper, null, prefix, " ", sanitizedPropValues, " ", suffix, stringEndBlank);
55
50
  });
56
51
  };
57
52
  var _default = parsePropsToDisplay;
@@ -1 +1 @@
1
- {"version":3,"file":"parse-props-to-display.js","names":["_react","_interopRequireWildcard","require","_lodash","_interopRequireDefault","_isObject","_getParsedPropValues","_getSanitizedPropValues","_constants","_processDataSummaryValue","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","obj","__esModule","_typeof","cache","has","get","newObj","hasPropertyDescriptor","Object","defineProperty","getOwnPropertyDescriptor","key","prototype","hasOwnProperty","call","desc","set","parsePropsToDisplay","props","arguments","length","undefined","propsToDisplay","isObject","at","filter","Boolean","map","options","currentIndex","bold","propertiesToDisplay","prefix","suffix","shouldStrip","enableLink","Wrapper","BOLD_TAG","Fragment","parsedPropValues","getParsedPropValues","sanitizedPropValues","getSanitizedPropValues","stringEndBlank","BLANK_SPACE_UNICODE_STRING","processedValue","Array","isArray","value","processDataSummaryValue","createElement","_default","exports"],"sources":["../../src/helpers/parse-props-to-display.js"],"sourcesContent":["import React, { Fragment } from 'react';\nimport at from 'lodash.at';\nimport isObject from './is-object';\nimport getParsedPropValues from './get-parsed-prop-values';\nimport getSanitizedPropValues from './get-sanitized-prop-values';\nimport { BOLD_TAG, BLANK_SPACE_UNICODE_STRING } from '../constants';\nimport processDataSummaryValue from './process-data-summary-value';\n\n// TODO this helper should be removed if database is wiped clean and all elements change to new props struc\nconst parsePropsToDisplay = (props = {}, propsToDisplay = []) => {\n if (!isObject(propsToDisplay[0])) return at(props, propsToDisplay).filter(Boolean);\n\n return propsToDisplay.map((options, currentIndex) => {\n const { bold, propertiesToDisplay, prefix, suffix, shouldStrip, enableLink } = options;\n const Wrapper = bold ? BOLD_TAG : Fragment;\n\n const parsedPropValues = getParsedPropValues({\n propertiesToDisplay,\n props,\n enableLink,\n shouldStrip\n });\n\n const sanitizedPropValues = getSanitizedPropValues(parsedPropValues);\n if (!sanitizedPropValues || !sanitizedPropValues.length) return null;\n const stringEndBlank =\n currentIndex + 1 === propsToDisplay.length ? '' : BLANK_SPACE_UNICODE_STRING;\n\n const processedValue = Array.isArray(sanitizedPropValues)\n ? sanitizedPropValues.map(value => processDataSummaryValue(value, options))\n : processDataSummaryValue(sanitizedPropValues, options);\n\n return (\n <Wrapper>\n {prefix} {processedValue} {suffix}\n {stringEndBlank}\n </Wrapper>\n );\n });\n};\n\nexport default parsePropsToDisplay;\n"],"mappings":";;;;;;;;;;;;;;;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,OAAA,GAAAC,sBAAA,CAAAF,OAAA;AACA,IAAAG,SAAA,GAAAD,sBAAA,CAAAF,OAAA;AACA,IAAAI,oBAAA,GAAAF,sBAAA,CAAAF,OAAA;AACA,IAAAK,uBAAA,GAAAH,sBAAA,CAAAF,OAAA;AACA,IAAAM,UAAA,GAAAN,OAAA;AACA,IAAAO,wBAAA,GAAAL,sBAAA,CAAAF,OAAA;AAAmE,SAAAQ,yBAAAC,WAAA,eAAAC,OAAA,kCAAAC,iBAAA,OAAAD,OAAA,QAAAE,gBAAA,OAAAF,OAAA,YAAAF,wBAAA,YAAAA,yBAAAC,WAAA,WAAAA,WAAA,GAAAG,gBAAA,GAAAD,iBAAA,KAAAF,WAAA;AAAA,SAAAV,wBAAAc,GAAA,EAAAJ,WAAA,SAAAA,WAAA,IAAAI,GAAA,IAAAA,GAAA,CAAAC,UAAA,WAAAD,GAAA,QAAAA,GAAA,aAAAE,OAAA,CAAAF,GAAA,yBAAAA,GAAA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_react","_interopRequireWildcard","require","_lodash","_interopRequireDefault","_isObject","_getParsedPropValues","_getSanitizedPropValues","_constants","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","obj","__esModule","_typeof","cache","has","get","newObj","hasPropertyDescriptor","Object","defineProperty","getOwnPropertyDescriptor","key","prototype","hasOwnProperty","call","desc","set","parsePropsToDisplay","props","arguments","length","undefined","propsToDisplay","isObject","at","filter","Boolean","map","_ref","currentIndex","bold","propertiesToDisplay","prefix","suffix","shouldStrip","enableLink","Wrapper","BOLD_TAG","Fragment","parsedPropValues","getParsedPropValues","sanitizedPropValues","getSanitizedPropValues","stringEndBlank","BLANK_SPACE_UNICODE_STRING","createElement","_default","exports"],"sources":["../../src/helpers/parse-props-to-display.js"],"sourcesContent":["import React, { Fragment } from 'react';\nimport at from 'lodash.at';\nimport isObject from './is-object';\nimport getParsedPropValues from './get-parsed-prop-values';\nimport getSanitizedPropValues from './get-sanitized-prop-values';\nimport { BOLD_TAG, BLANK_SPACE_UNICODE_STRING } from '../constants';\n\n// TODO this helper should be removed if database is wiped clean and all elements change to new props struc\nconst parsePropsToDisplay = (props = {}, propsToDisplay = []) => {\n if (!isObject(propsToDisplay[0])) return at(props, propsToDisplay).filter(Boolean);\n\n return propsToDisplay.map(\n ({ bold, propertiesToDisplay, prefix, suffix, shouldStrip, enableLink }, currentIndex) => {\n const Wrapper = bold ? BOLD_TAG : Fragment;\n\n const parsedPropValues = getParsedPropValues({\n propertiesToDisplay,\n props,\n enableLink,\n shouldStrip\n });\n\n const sanitizedPropValues = getSanitizedPropValues(parsedPropValues);\n if (!sanitizedPropValues || !sanitizedPropValues.length) return null;\n const stringEndBlank =\n currentIndex + 1 === propsToDisplay.length ? '' : BLANK_SPACE_UNICODE_STRING;\n\n return (\n <Wrapper>\n {prefix} {sanitizedPropValues} {suffix}\n {stringEndBlank}\n </Wrapper>\n );\n }\n );\n};\n\nexport default parsePropsToDisplay;\n"],"mappings":";;;;;;;;;;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AAO,IAAI;IACpE,IAAMuB,cAAc,GAClBd,YAAY,GAAG,CAAC,KAAKP,cAAc,CAACF,MAAM,GAAG,EAAE,GAAGwB,qCAA0B;IAE9E,oBACE1D,MAAA,YAAA2D,aAAA,CAACT,OAAO,QACLJ,MAAM,EAAC,GAAC,EAACS,mBAAmB,EAAC,GAAC,EAACR,MAAM,EACrCU,cACM,CAAC;EAEd,CACF,CAAC;AACH,CAAC;AAAC,IAAAG,QAAA,GAEa7B,mBAAmB;AAAA8B,OAAA,cAAAD,QAAA"}
@@ -1,6 +1,6 @@
1
1
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
2
  import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
3
- const _excluded = ["code", "parserOptions", "disableWrapper"];
3
+ const _excluded = ["code", "parserOptions"];
4
4
  function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
5
5
  function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
6
6
  import React, { memo } from 'react';
@@ -14,15 +14,13 @@ import { wrapScriptTags } from './helpers';
14
14
  const Code = memo(_ref => {
15
15
  let {
16
16
  code: embedCode,
17
- parserOptions,
18
- disableWrapper
17
+ parserOptions
19
18
  } = _ref,
20
19
  otherProps = _objectWithoutProperties(_ref, _excluded);
21
20
  if (!embedCode) return null;
22
21
  const parsedCode = parseHTML(embedCode, parserOptions);
23
22
  const wrappedCode = wrapScriptTags(parsedCode);
24
23
  const modifiers = getClassModifiers(CODE, _objectSpread({}, otherProps));
25
- if (disableWrapper) return wrappedCode;
26
24
  return /*#__PURE__*/React.createElement(Wrapper, {
27
25
  modifiers: modifiers
28
26
  }, wrappedCode);
@@ -30,14 +28,12 @@ const Code = memo(_ref => {
30
28
  Code.propTypes = {
31
29
  code: PropTypes.string,
32
30
  modifier: PropTypes.string,
33
- parserOptions: PropTypes.object,
34
- disableWrapper: PropTypes.bool
31
+ parserOptions: PropTypes.object
35
32
  };
36
33
  Code.defaultProps = {
37
34
  code: '',
38
35
  modifier: '',
39
- parserOptions: {},
40
- disableWrapper: false
36
+ parserOptions: {}
41
37
  };
42
38
  export default withTitle(Code);
43
39
  //# sourceMappingURL=Code.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Code.js","names":["React","memo","PropTypes","parseHTML","Wrapper","withTitle","getClassModifiers","CODE","wrapScriptTags","Code","_ref","code","embedCode","parserOptions","disableWrapper","otherProps","_objectWithoutProperties","_excluded","parsedCode","wrappedCode","modifiers","_objectSpread","createElement","propTypes","string","modifier","object","bool","defaultProps"],"sources":["../../../src/components/Code/Code.js"],"sourcesContent":["import React, { memo } from 'react';\nimport PropTypes from 'prop-types';\nimport parseHTML from 'html-react-parser';\nimport Wrapper from '../Wrapper';\nimport { withTitle } from '../../HOC';\nimport { getClassModifiers } from '../../utils';\nimport { CODE } from '../../constants';\nimport { wrapScriptTags } from './helpers';\n\nconst Code = memo(({ code: embedCode, parserOptions, disableWrapper, ...otherProps }) => {\n if (!embedCode) return null;\n\n const parsedCode = parseHTML(embedCode, parserOptions);\n const wrappedCode = wrapScriptTags(parsedCode);\n const modifiers = getClassModifiers(CODE, { ...otherProps });\n\n if (disableWrapper) return wrappedCode;\n\n return <Wrapper modifiers={modifiers}>{wrappedCode}</Wrapper>;\n});\n\nCode.propTypes = {\n code: PropTypes.string,\n modifier: PropTypes.string,\n parserOptions: PropTypes.object,\n disableWrapper: PropTypes.bool\n};\n\nC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AAE,EAAE;EACZZ,aAAa,EAAE,CAAC,CAAC;EACjBC,cAAc,EAAE;AAClB,CAAC;AAED,eAAeT,SAAS,CAACI,IAAI,CAAC"}
1
+ {"version":3,"file":"Code.js","names":["React","memo","PropTypes","parseHTML","Wrapper","withTitle","getClassModifiers","CODE","wrapScriptTags","Code","_ref","code","embedCode","parserOptions","otherProps","_objectWithoutProperties","_excluded","parsedCode","wrappedCode","modifiers","_objectSpread","createElement","propTypes","string","modifier","object","defaultProps"],"sources":["../../../src/components/Code/Code.js"],"sourcesContent":["import React, { memo } from 'react';\nimport PropTypes from 'prop-types';\nimport parseHTML from 'html-react-parser';\nimport Wrapper from '../Wrapper';\nimport { withTitle } from '../../HOC';\nimport { getClassModifiers } from '../../utils';\nimport { CODE } from '../../constants';\nimport { wrapScriptTags } from './helpers';\n\nconst Code = memo(({ code: embedCode, parserOptions, ...otherProps }) => {\n if (!embedCode) return null;\n\n const parsedCode = parseHTML(embedCode, parserOptions);\n const wrappedCode = wrapScriptTags(parsedCode);\n const modifiers = getClassModifiers(CODE, { ...otherProps });\n\n return <Wrapper modifiers={modifiers}>{wrappedCode}</Wrapper>;\n});\n\nCode.propTypes = {\n code: PropTypes.string,\n modifier: PropTypes.string,\n parserOptions: PropTypes.object\n};\n\nCode.defaultProps = {\n code: '',\n modifier: '',\n parserOptions: {}\n};\n\nexport default withTitle(Code);\n"],"mappings":";;;;;AAAA,OAAOA,KAAK,IAAIC,IAAI,QAAQ,OAAO;AACnC,OAAOC,SAAS,MAAM,YAAY;AAClC,OAAOC,SAAS,MAAM,mBAAmB;AACzC,OAAOC,OAAO,MAAM,YAAY;AAChC,SAASC,SAAS,QAAQ,WAAW;AACrC,SAASC,iBAAiB,QAAQ,aAAa;AAC/C,SAASC,IAAI,QAAQ,iBAAiB;AACtC,SAASC,cAAc,QAAQ,WAAW;AAE1C,MAAMC,IAAI,GAAGR,IAAI,CAACS,IAAA,IAAuD;EAAA,IAAtD;MAAEC,IAAI,EAAEC,SAAS;MAAEC;IAA6B,CAAC,GAAAH,IAAA;IAAZI,UAAU,GAAAC,wBAAA,CAAAL,IAAA,EAAAM,SAAA;EAChE,IAAI,CAACJ,SAAS,EAAE,OAAO,IAAI;EAE3B,MAAMK,UAAU,GAAGd,SAAS,CAACS,SAAS,EAAEC,aAAa,CAAC;EACtD,MAAMK,WAAW,GAAGV,cAAc,CAACS,UAAU,CAAC;EAC9C,MAAME,SAAS,GAAGb,iBAAiB,CAACC,IAAI,EAAAa,aAAA,KAAON,UAAU,CAAE,CAAC;EAE5D,oBAAOd,KAAA,CAAAqB,aAAA,CAACjB,OAAO;IAACe,SAAS,EAAEA;EAAU,GAAED,WAAqB,CAAC;AAC/D,CAAC,CAAC;AAEFT,IAAI,CAACa,SAAS,GAAG;EACfX,IAAI,EAAET,SAAS,CAACqB,MAAM;EACtBC,QAAQ,EAAEtB,SAAS,CAACqB,MAAM;EAC1BV,aAAa,EAAEX,SAAS,CAACuB;AAC3B,CAAC;AAEDhB,IAAI,CAACiB,YAAY,GAAG;EAClBf,IAAI,EAAE,EAAE;EACRa,QAAQ,EAAE,EAAE;EACZX,aAAa,EAAE,CAAC;AAClB,CAAC;AAED,eAAeR,SAAS,CAACI,IAAI,CAAC"}
@@ -3,7 +3,6 @@ import flatten from 'lodash.flatten';
3
3
  import getLinkToPublishedContent from './get-link-to-published-content';
4
4
  import getLoopPropsLimit from './get-loop-props-limit';
5
5
  import getPropValue from './get-prop-value';
6
- import { processDataSummaryValue } from '../../../helpers';
7
6
  const getLoopValue = value => {
8
7
  const {
9
8
  keyField
@@ -46,9 +45,8 @@ const buildLoopPropsContent = (loopProps = [], propsToDisplay = [], limit = 0, d
46
45
  const loopValue = loopValues[key];
47
46
  const propValue = loopValue ? getLoopValue(loopValue[i]) : regularValues[key];
48
47
  if (!propValue) return null;
49
- const processedValue = processDataSummaryValue(propValue, options);
50
48
  const linkToPublishedContent = getLinkToPublishedContent(key, data);
51
- return [upperFirst(label), processedValue, linkToPublishedContent, modifier];
49
+ return [upperFirst(label), propValue, linkToPublishedContent, modifier];
52
50
  });
53
51
  })).filter(Boolean);
54
52
  loopPropsWithContent.push(propsArray);
@@ -1 +1 @@
1
- {"version":3,"file":"build-loop-props-content.js","names":["upperFirst","flatten","getLinkToPublishedContent","getLoopPropsLimit","getPropValue","processDataSummaryValue","getLoopValue","value","keyField","separateValues","propsToDisplay","loopProps","data","regularValues","loopValues","forEach","options","propertiesToDisplay","prop","isArrayValue","Array","isArray","isLoopableProp","includes","buildLoopPropsContent","limit","loopPropsWithContent","loopLimit","i","propsArray","map","label","modifier","key","loopValue","propValue","processedValue","linkToPublishedContent","filter","Boolean","push"],"sources":["../../../../src/components/DataSummary/helpers/build-loop-props-content.js"],"sourcesContent":["import upperFirst from 'lodash.upperfirst';\nimport flatten from 'lodash.flatten';\nimport getLinkToPublishedContent from './get-link-to-published-content';\nimport getLoopPropsLimit from './get-loop-props-limit';\nimport getPropValue from './get-prop-value';\nimport { processDataSummaryValue } from '../../../helpers';\n\nconst getLoopValue = value => {\n const { keyField } = value;\n return value[keyField];\n};\n\nconst separateValues = (propsToDisplay, loopProps, data) => {\n const regularValues = {};\n const loopValues = {};\n\n propsToDisplay.forEach(options => {\n const { propertiesToDisplay } = options;\n propertiesToDisplay.forEach(prop => {\n const value = getPropValue(prop, data, options);\n const isArrayValue = Array.isArray(value);\n if (!value) return;\n const isLoopableProp = loopProps.includes(prop) && isArrayValue;\n\n if (isLoopableProp) {\n loopValues[prop] = value;\n } else {\n regularValues[prop] = value;\n }\n });\n });\n return [regularValues, loopValues];\n};\n\nconst buildLoopPropsContent = (loopProps = [], propsToDisplay = [], limit = 0, data = {}) => {\n const loopPropsWithContent = [];\n const [regularValues, loopValues] = separateValues(propsToDisplay, loopProps, data);\n\n const loopLimit = getLoopPropsLimit(loopValues, limit);\n\n for (let i = 0; i < loopLimit; i += 1) {\n const propsArray = flatten(\n propsToDisplay.map(options => {\n const { propertiesToDisplay, label, modifier = '' } = options;\n\n return propertiesToDisplay.map(key => {\n const loopValue = loopValues[key];\n const propValue = loopValue ? getLoopValue(loopValue[i]) : regularValues[key];\n if (!propValue) return null;\n\n const processedValue = processDataSummaryValue(propValue, options);\n const linkToPublishedContent = getLinkToPublishedContent(key, data);\n return [upperFirst(label), processedValue, linkToPublishedContent, modifier];\n });\n })\n ).filter(Boolean);\n loopPropsWithContent.push(propsArray);\n }\n\n return flatten(loopPropsWithContent);\n};\n\nexport default buildLoopPropsContent;\n"],"mappings":"AAAA,OAAOA,UAAU,MAAM,mBAAmB;AAC1C,OAAOC,OAAO,MAAM,gBAAgB;AACpC,OAAOC,yBAAyB,MAAM,iCAAiC;AACvE,OAAOC,iBAAiB,MAAM,wBAAwB;AACtD,OAAOC,YAAY,MAAM,kBAAkB;AAC3C,SAASC,uBAAuB,QAAQ,kBAAkB;AAE1D,MAAMC,YAAY,GAAGC,KAAK,IAAI;EAC5B,MAAM;IAAEC;EAAS,CAAC,GAAGD,KAAK;EAC1B,OAAOA,KAAK,CAACC,QAAQ,CAAC;AACxB,CAAC;AAED,MAAMC,cAAc,GAAGA,CAACC,cAAc,EAAEC,SAAS,EAAEC,IAAI,KAAK;EAC1D,MAAMC,aAAa,GAAG,CAAC,CAAC;EACxB,MAAMC,UAAU,GAAG,CAAC,CAAC;EAErBJ,cAAc,CAACK,OAAO,CAACC,OAAO,IAAI;IAChC,MAAM;MAAEC;IAAoB,CAAC,GAAGD,OAAO;IACvCC,mBAAmB,CAACF,OAAO,CAACG,IAAI,IAAI;MAClC,MAAMX,KAAK,GAAGH,YAAY,CAACc,IAAI,EAAEN,IAAI,EAAEI,OAAO,CAAC;MAC/C,MAAMG,YAAY,GAAGC,KAAK,CAACC,OAAO,CAACd,KAAK,CAAC;MACzC,IAAI,CAACA,KAAK,EAAE;MACZ,MAAMe,cAAc,GAAGX,SAAS,CAACY,QAAQ,CAACL,IAAI,CAAC,IAAIC,YAAY;MAE/D,IAAIG,cAAc,EAAE;QAClBR,UAAU,CAACI,IAAI,C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AK,CAAC,EAAEK,cAAc,EAAEC,sBAAsB,EAAEL,QAAQ,CAAC;MAC9E,CAAC,CAAC;IACJ,CAAC,CACH,CAAC,CAACM,MAAM,CAACC,OAAO,CAAC;IACjBb,oBAAoB,CAACc,IAAI,CAACX,UAAU,CAAC;EACvC;EAEA,OAAO5B,OAAO,CAACyB,oBAAoB,CAAC;AACtC,CAAC;AAED,eAAeF,qBAAqB"}
1
+ {"version":3,"file":"build-loop-props-content.js","names":["upperFirst","flatten","getLinkToPublishedContent","getLoopPropsLimit","getPropValue","getLoopValue","value","keyField","separateValues","propsToDisplay","loopProps","data","regularValues","loopValues","forEach","options","propertiesToDisplay","prop","isArrayValue","Array","isArray","isLoopableProp","includes","buildLoopPropsContent","limit","loopPropsWithContent","loopLimit","i","propsArray","map","label","modifier","key","loopValue","propValue","linkToPublishedContent","filter","Boolean","push"],"sources":["../../../../src/components/DataSummary/helpers/build-loop-props-content.js"],"sourcesContent":["import upperFirst from 'lodash.upperfirst';\nimport flatten from 'lodash.flatten';\nimport getLinkToPublishedContent from './get-link-to-published-content';\nimport getLoopPropsLimit from './get-loop-props-limit';\nimport getPropValue from './get-prop-value';\n\nconst getLoopValue = value => {\n const { keyField } = value;\n return value[keyField];\n};\n\nconst separateValues = (propsToDisplay, loopProps, data) => {\n const regularValues = {};\n const loopValues = {};\n\n propsToDisplay.forEach(options => {\n const { propertiesToDisplay } = options;\n propertiesToDisplay.forEach(prop => {\n const value = getPropValue(prop, data, options);\n const isArrayValue = Array.isArray(value);\n if (!value) return;\n const isLoopableProp = loopProps.includes(prop) && isArrayValue;\n\n if (isLoopableProp) {\n loopValues[prop] = value;\n } else {\n regularValues[prop] = value;\n }\n });\n });\n return [regularValues, loopValues];\n};\n\nconst buildLoopPropsContent = (loopProps = [], propsToDisplay = [], limit = 0, data = {}) => {\n const loopPropsWithContent = [];\n const [regularValues, loopValues] = separateValues(propsToDisplay, loopProps, data);\n\n const loopLimit = getLoopPropsLimit(loopValues, limit);\n\n for (let i = 0; i < loopLimit; i += 1) {\n const propsArray = flatten(\n propsToDisplay.map(options => {\n const { propertiesToDisplay, label, modifier = '' } = options;\n\n return propertiesToDisplay.map(key => {\n const loopValue = loopValues[key];\n const propValue = loopValue ? getLoopValue(loopValue[i]) : regularValues[key];\n if (!propValue) return null;\n const linkToPublishedContent = getLinkToPublishedContent(key, data);\n return [upperFirst(label), propValue, linkToPublishedContent, modifier];\n });\n })\n ).filter(Boolean);\n loopPropsWithContent.push(propsArray);\n }\n\n return flatten(loopPropsWithContent);\n};\n\nexport default buildLoopPropsContent;\n"],"mappings":"AAAA,OAAOA,UAAU,MAAM,mBAAmB;AAC1C,OAAOC,OAAO,MAAM,gBAAgB;AACpC,OAAOC,yBAAyB,MAAM,iCAAiC;AACvE,OAAOC,iBAAiB,MAAM,wBAAwB;AACtD,OAAOC,YAAY,MAAM,kBAAkB;AAE3C,MAAMC,YAAY,GAAGC,KAAK,IAAI;EAC5B,MAAM;IAAEC;EAAS,CAAC,GAAGD,KAAK;EAC1B,OAAOA,KAAK,CAACC,QAAQ,CAAC;AACxB,CAAC;AAED,MAAMC,cAAc,GAAGA,CAACC,cAAc,EAAEC,SAAS,EAAEC,IAAI,KAAK;EAC1D,MAAMC,aAAa,GAAG,CAAC,CAAC;EACxB,MAAMC,UAAU,GAAG,CAAC,CAAC;EAErBJ,cAAc,CAACK,OAAO,CAACC,OAAO,IAAI;IAChC,MAAM;MAAEC;IAAoB,CAAC,GAAGD,OAAO;IACvCC,mBAAmB,CAACF,OAAO,CAACG,IAAI,IAAI;MAClC,MAAMX,KAAK,GAAGF,YAAY,CAACa,IAAI,EAAEN,IAAI,EAAEI,OAAO,CAAC;MAC/C,MAAMG,YAAY,GAAGC,KAAK,CAACC,OAAO,CAACd,KAAK,CAAC;MACzC,IAAI,CAACA,KAAK,EAAE;MACZ,MAAMe,cAAc,GAAGX,SAAS,CAACY,QAAQ,CAACL,IAAI,CAAC,IAAIC,YAAY;MAE/D,IAAIG,cAAc,EA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EJ,QAAQ,CAAC;MACzE,CAAC,CAAC;IACJ,CAAC,CACH,CAAC,CAACK,MAAM,CAACC,OAAO,CAAC;IACjBZ,oBAAoB,CAACa,IAAI,CAACV,UAAU,CAAC;EACvC;EAEA,OAAO3B,OAAO,CAACwB,oBAAoB,CAAC;AACtC,CAAC;AAED,eAAeF,qBAAqB"}
@@ -1,6 +1,6 @@
1
1
  import upperFirst from 'lodash.upperfirst';
2
2
  import flatten from 'lodash.flatten';
3
- import { isObject, processDataSummaryValue } from '../../../helpers';
3
+ import { isObject } from '../../../helpers';
4
4
  import getLinkToPublishedContent from './get-link-to-published-content';
5
5
  import getPropValue from './get-prop-value';
6
6
  import getLinkBasedOnValue from './get-link-based-on-value';
@@ -25,9 +25,8 @@ const buildPropsToDisplayWithContent = (props, propsToDisplay = []) => {
25
25
  if (!key) return null;
26
26
  const objPropValue = getPropValue(key, props, options);
27
27
  if (!objPropValue) return null;
28
- const processedValue = processDataSummaryValue(objPropValue, options);
29
- const link = getLink(enableLink, key, props, processedValue);
30
- return [upperFirst(label), processedValue, link, modifier];
28
+ const link = getLink(enableLink, key, props, objPropValue);
29
+ return [upperFirst(label), objPropValue, link, modifier];
31
30
  });
32
31
  })).filter(Boolean);
33
32
  };
@@ -1 +1 @@
1
- {"version":3,"file":"build-props-to-display-with-content.js","names":["upperFirst","flatten","isObject","processDataSummaryValue","getLinkToPublishedContent","getPropValue","getLinkBasedOnValue","buildPropsToDisplayWithContent","props","propsToDisplay","map","key","propValue","propName","split","join","filter","Boolean","options","propertiesToDisplay","label","modifier","enableLink","objPropValue","processedValue","link","getLink"],"sources":["../../../../src/components/DataSummary/helpers/build-props-to-display-with-content.js"],"sourcesContent":["import upperFirst from 'lodash.upperfirst';\nimport flatten from 'lodash.flatten';\nimport { isObject, processDataSummaryValue } from '../../../helpers';\nimport getLinkToPublishedContent from './get-link-to-published-content';\nimport getPropValue from './get-prop-value';\nimport getLinkBasedOnValue from './get-link-based-on-value';\n\nconst buildPropsToDisplayWithContent = (props, propsToDisplay = []) => {\n if (!isObject(propsToDisplay[0])) {\n return propsToDisplay\n .map(key => {\n if (!key) return null;\n const propValue = getPropValue(key, props);\n if (!propValue) return null;\n const propName = key.split('.').join(' ');\n return [upperFirst(propName), propValue, '', ''];\n })\n .filter(Boolean);\n }\n\n return flatten(\n propsToDisplay.map(options => {\n const { propertiesToDisplay, label, modifier = '', enableLink } = options;\n return propertiesToDisplay.map(key => {\n if (!key) return null;\n\n const objPropValue = getPropValue(key, props, options);\n if (!objPropValue) return null;\n\n const processedValue = processDataSummaryValue(objPropValue, options);\n\n const link = getLink(enableLink, key, props, processedValue);\n\n return [upperFirst(label), processedValue, link, modifier];\n });\n })\n ).filter(Boolean);\n};\n\nexport default buildPropsToDisplayWithContent;\n\nfunction getLink(enableLink, key, props, objPropValue) {\n let link = '';\n if (enableLink) {\n link = getLinkToPublishedContent(key, props);\n if (!link) {\n link = getLinkBasedOnValue(objPropValue);\n }\n }\n return link;\n}\n"],"mappings":"AAAA,OAAOA,UAAU,MAAM,mBAAmB;AAC1C,OAAOC,OAAO,MAAM,gBAAgB;AACpC,SAASC,QAAQ,EAAEC,uBAAuB,QAAQ,kBAAkB;AACpE,OAAOC,yBAAyB,MAAM,iCAAiC;AACvE,OAAOC,YAAY,MAAM,kBAAkB;AAC3C,OAAOC,mBAAmB,MAAM,2BAA2B;AAE3D,MAAMC,8BAA8B,GAAGA,CAACC,KAAK,EAAEC,cAAc,GAAG,EAAE,KAAK;EACrE,IAAI,CAACP,QAAQ,CAACO,cAAc,CAAC,CAAC,CAAC,CAAC,EAAE;IAChC,OAAOA,cAAc,CAClBC,GAAG,CAACC,GAAG,IAAI;MACV,IAAI,CAACA,GAAG,EAAE,OAAO,IAAI;MACrB,MAAMC,SAAS,GAAGP,YAAY,CAACM,GAAG,EAAEH,KAAK,CAAC;MAC1C,IAAI,CAACI,SAAS,EAAE,OAAO,IAAI;MAC3B,MAAMC,QAAQ,GAAGF,GAAG,CAACG,KAAK,C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AI;AACb"}
1
+ {"version":3,"file":"build-props-to-display-with-content.js","names":["upperFirst","flatten","isObject","getLinkToPublishedContent","getPropValue","getLinkBasedOnValue","buildPropsToDisplayWithContent","props","propsToDisplay","map","key","propValue","propName","split","join","filter","Boolean","options","propertiesToDisplay","label","modifier","enableLink","objPropValue","link","getLink"],"sources":["../../../../src/components/DataSummary/helpers/build-props-to-display-with-content.js"],"sourcesContent":["import upperFirst from 'lodash.upperfirst';\nimport flatten from 'lodash.flatten';\nimport { isObject } from '../../../helpers';\nimport getLinkToPublishedContent from './get-link-to-published-content';\nimport getPropValue from './get-prop-value';\nimport getLinkBasedOnValue from './get-link-based-on-value';\n\nconst buildPropsToDisplayWithContent = (props, propsToDisplay = []) => {\n if (!isObject(propsToDisplay[0])) {\n return propsToDisplay\n .map(key => {\n if (!key) return null;\n const propValue = getPropValue(key, props);\n if (!propValue) return null;\n const propName = key.split('.').join(' ');\n return [upperFirst(propName), propValue, '', ''];\n })\n .filter(Boolean);\n }\n\n return flatten(\n propsToDisplay.map(options => {\n const { propertiesToDisplay, label, modifier = '', enableLink } = options;\n return propertiesToDisplay.map(key => {\n if (!key) return null;\n\n const objPropValue = getPropValue(key, props, options);\n if (!objPropValue) return null;\n\n const link = getLink(enableLink, key, props, objPropValue);\n\n return [upperFirst(label), objPropValue, link, modifier];\n });\n })\n ).filter(Boolean);\n};\n\nexport default buildPropsToDisplayWithContent;\nfunction getLink(enableLink, key, props, objPropValue) {\n let link = '';\n if (enableLink) {\n link = getLinkToPublishedContent(key, props);\n if (!link) {\n link = getLinkBasedOnValue(objPropValue);\n }\n }\n return link;\n}\n"],"mappings":"AAAA,OAAOA,UAAU,MAAM,mBAAmB;AAC1C,OAAOC,OAAO,MAAM,gBAAgB;AACpC,SAASC,QAAQ,QAAQ,kBAAkB;AAC3C,OAAOC,yBAAyB,MAAM,iCAAiC;AACvE,OAAOC,YAAY,MAAM,kBAAkB;AAC3C,OAAOC,mBAAmB,MAAM,2BAA2B;AAE3D,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B;AAC7C,SAASkB,OAAOA,CAACH,UAAU,EAAEX,GAAG,EAAEH,KAAK,EAAEe,YAAY,EAAE;EACrD,IAAIC,IAAI,GAAG,EAAE;EACb,IAAIF,UAAU,EAAE;IACdE,IAAI,GAAGpB,yBAAyB,CAACO,GAAG,EAAEH,KAAK,CAAC;IAC5C,IAAI,CAACgB,IAAI,EAAE;MACTA,IAAI,GAAGlB,mBAAmB,CAACiB,YAAY,CAAC;IAC1C;EACF;EACA,OAAOC,IAAI;AACb"}
@@ -1,6 +1,7 @@
1
+ import _extends from "@babel/runtime/helpers/extends";
1
2
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
3
  import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
3
- const _excluded = ["type", "children", "settings", "modifier", "backgroundImage", "tagType"];
4
+ const _excluded = ["type", "children", "settings", "modifier", "backgroundImage", "tagType", "dataNoSnippet"];
4
5
  function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
5
6
  function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
6
7
  import React from 'react';
@@ -18,7 +19,8 @@ const Layout = _ref => {
18
19
  settings,
19
20
  modifier,
20
21
  backgroundImage,
21
- tagType
22
+ tagType,
23
+ dataNoSnippet
22
24
  } = _ref,
23
25
  otherProps = _objectWithoutProperties(_ref, _excluded);
24
26
  const {
@@ -39,12 +41,14 @@ const Layout = _ref => {
39
41
  }, otherProps));
40
42
  const additionalRowModifier = checkIfRowHasColumns(type, children) ? ' display-row' : '';
41
43
  if (type === COLUMN && !hasChildren(children)) return null;
42
- return /*#__PURE__*/React.createElement(Wrapper, {
44
+ const otherWrapperProps = {};
45
+ if (dataNoSnippet) otherWrapperProps['data-nosnippet'] = true;
46
+ return /*#__PURE__*/React.createElement(Wrapper, _extends({
43
47
  tagType: tagType,
44
48
  className: type,
45
49
  modifiers: `${classModifiers}${additionalRowModifier}`,
46
50
  style: style
47
- }, title && /*#__PURE__*/React.createElement("h2", {
51
+ }, otherWrapperProps), title && /*#__PURE__*/React.createElement("h2", {
48
52
  className: "heading heading--section"
49
53
  }, title), renderChildren(children, otherProps));
50
54
  };
@@ -56,6 +60,7 @@ Layout.propTypes = {
56
60
  modifier: PropTypes.string,
57
61
  backgroundImage: PropTypes.string,
58
62
  tagType: PropTypes.string,
63
+ dataNoSnippet: PropTypes.bool,
59
64
  children: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.node), PropTypes.node]).isRequired
60
65
  };
61
66
  Layout.defaultProps = {
@@ -64,7 +69,8 @@ Layout.defaultProps = {
64
69
  },
65
70
  backgroundImage: '',
66
71
  modifier: '',
67
- tagType: ''
72
+ tagType: '',
73
+ dataNoSnippet: false
68
74
  };
69
75
  export default Layout;
70
76
  //# sourceMappingURL=Layout.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Layout.js","names":["React","PropTypes","Wrapper","getClassModifiers","useGetImages","getStylesToUpdate","checkIfRowHasColumns","renderChildren","hasChildren","COLUMN","Layout","_ref","type","children","settings","modifier","backgroundImage","tagType","otherProps","_objectWithoutProperties","_excluded","data","getFile","url","style","title","classModifiers","_objectSpread","additionalRowModifier","createElement","className","modifiers","propTypes","string","isRequired","shape","oneOfType","arrayOf","node","defaultProps"],"sources":["../../../src/components/Layout/Layout.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport Wrapper from '../Wrapper';\nimport { getClassModifiers } from '../../utils';\nimport { useGetImages } from '../../hooks';\nimport { getStylesToUpdate, checkIfRowHasColumns } from './helpers';\nimport { renderChildren, hasChildren } from '../../helpers';\nimport { COLUMN } from '../../constants';\n\nconst Layout = ({\n type,\n children,\n settings,\n modifier,\n backgroundImage,\n tagType,\n ...otherProps\n}) => {\n const {\n data: { getFile: { url = null } = {} }\n } = useGetImages(backgroundImage);\n\n const style = getStylesToUpdate({ backgroundImage: url });\n const { title } = settings;\n\n const classModifiers = getClassModifiers(type, { modifier, ...otherProps });\n const additionalRowModifier = checkIfRowHasColumns(type, children) ? ' display-row' : '';\n\n if (type === COLUMN && !hasChildren(children)) return null;\n\n return (\n <Wrapper\n tagType={tagType}\n className={type}\n modifiers={`${classModifiers}${additionalRowModifier}`}\n style={style}>\n {title && <h2 className=\"heading heading--section\">{title}</h2>}\n {renderChildren(children, otherProps)}\n </Wrapper>\n );\n};\n\nLayout.propTypes = {\n type: PropTypes.string.isRequired,\n settings: PropTypes.shape({\n title: PropTypes.string\n }),\n modifier: PropTypes.string,\n backgroundImage: PropTypes.string,\n tagType: PropTypes.string,\n children: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.node), PropTypes.node]).isRequired\n};\n\nLayout.defaultProps = {\n settings: {\n title: ''\n },\n backgroundImage: '',\n modifier: '',\n tagType: ''\n};\n\nexport default Layout;\n"],"mappings":";;;;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,OAAOC,SAAS,MAAM,YAAY;AAClC,OAAOC,OAAO,MAAM,YAAY;AAChC,SAASC,iBAAiB,QAAQ,aAAa;AAC/C,SAASC,YAAY,QAAQ,aAAa;AAC1C,SAASC,iBAAiB,EAAEC,oBAAoB,QAAQ,WAAW;AACnE,SAASC,cAAc,EAAEC,WAAW,QAAQ,eAAe;AAC3D,SAASC,MAAM,QAAQ,iBAAiB;AAExC,MAAMC,MAAM,GAAGC,IAAA,IAQT;EAAA,IARU;MACdC,IAAI;MACJC,QAAQ;MACRC,QAAQ;MACRC,QAAQ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eAAe,EAAEf,SAAS,CAACgC,MAAM;EACjChB,OAAO,EAAEhB,SAAS,CAACgC,MAAM;EACzBpB,QAAQ,EAAEZ,SAAS,CAACmC,SAAS,CAAC,CAACnC,SAAS,CAACoC,OAAO,CAACpC,SAAS,CAACqC,IAAI,CAAC,EAAErC,SAAS,CAACqC,IAAI,CAAC,CAAC,CAACJ;AACrF,CAAC;AAEDxB,MAAM,CAAC6B,YAAY,GAAG;EACpBzB,QAAQ,EAAE;IACRW,KAAK,EAAE;EACT,CAAC;EACDT,eAAe,EAAE,EAAE;EACnBD,QAAQ,EAAE,EAAE;EACZE,OAAO,EAAE;AACX,CAAC;AAED,eAAeP,MAAM"}
1
+ {"version":3,"file":"Layout.js","names":["React","PropTypes","Wrapper","getClassModifiers","useGetImages","getStylesToUpdate","checkIfRowHasColumns","renderChildren","hasChildren","COLUMN","Layout","_ref","type","children","settings","modifier","backgroundImage","tagType","dataNoSnippet","otherProps","_objectWithoutProperties","_excluded","data","getFile","url","style","title","classModifiers","_objectSpread","additionalRowModifier","otherWrapperProps","createElement","_extends","className","modifiers","propTypes","string","isRequired","shape","bool","oneOfType","arrayOf","node","defaultProps"],"sources":["../../../src/components/Layout/Layout.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport Wrapper from '../Wrapper';\nimport { getClassModifiers } from '../../utils';\nimport { useGetImages } from '../../hooks';\nimport { getStylesToUpdate, checkIfRowHasColumns } from './helpers';\nimport { renderChildren, hasChildren } from '../../helpers';\nimport { COLUMN } from '../../constants';\n\nconst Layout = ({\n type,\n children,\n settings,\n modifier,\n backgroundImage,\n tagType,\n dataNoSnippet,\n ...otherProps\n}) => {\n const {\n data: { getFile: { url = null } = {} }\n } = useGetImages(backgroundImage);\n\n const style = getStylesToUpdate({ backgroundImage: url });\n const { title } = settings;\n\n const classModifiers = getClassModifiers(type, { modifier, ...otherProps });\n const additionalRowModifier = checkIfRowHasColumns(type, children) ? ' display-row' : '';\n\n if (type === COLUMN && !hasChildren(children)) return null;\n\n const otherWrapperProps = {};\n if (dataNoSnippet) otherWrapperProps['data-nosnippet'] = true;\n\n return (\n <Wrapper\n tagType={tagType}\n className={type}\n modifiers={`${classModifiers}${additionalRowModifier}`}\n style={style}\n {...otherWrapperProps}>\n {title && <h2 className=\"heading heading--section\">{title}</h2>}\n {renderChildren(children, otherProps)}\n </Wrapper>\n );\n};\n\nLayout.propTypes = {\n type: PropTypes.string.isRequired,\n settings: PropTypes.shape({\n title: PropTypes.string\n }),\n modifier: PropTypes.string,\n backgroundImage: PropTypes.string,\n tagType: PropTypes.string,\n dataNoSnippet: PropTypes.bool,\n children: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.node), PropTypes.node]).isRequired\n};\n\nLayout.defaultProps = {\n settings: {\n title: ''\n },\n backgroundImage: '',\n modifier: '',\n tagType: '',\n dataNoSnippet: false\n};\n\nexport default Layout;\n"],"mappings":";;;;;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,OAAOC,SAAS,MAAM,YAAY;AAClC,OAAOC,OAAO,MAAM,YAAY;AAChC,SAASC,iBAAiB,QAAQ,aAAa;AAC/C,SAASC,YAAY,QAAQ,aAAa;AAC1C,SAASC,iBAAiB,EAAEC,oBAAoB,QAAQ,WAAW;AACnE,SAASC,cAAc,EAAEC,WAAW,QAAQ,eAAe;AAC3D,SAASC,MAAM,QAAQ,iBAAiB;AAExC,MAAMC,MAAM,GAAGC,IAAA,IAST;EAAA,IATU;MACdC,IAAI;MACJC,QAAQ;MACRC,QAAQ;MACRC,QAAQ;MACRC,eAAe;MACfC,OAAO;MACPC;IAEF,CAAC,GAAAP,IAAA;IADIQ,UAAU,GAAAC,wBAAA,CAAAT,IAAA,EAAAU,SAAA;EAEb,MAAM;IACJC,IAAI,EAAE;MAAEC,OAAO,EAAE;QAAEC,GAAG,GAAG;MAAK,CAAC,GAAG,CAAC;IAAE;EACvC,CAAC,GAAGpB,YAAY,CAACY,eAAe,CAAC;EAEjC,MAAMS,KAA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