@mjhls/mjh-framework 1.0.1082-404-v9 → 1.0.1082-c1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/View.js +11 -7
- package/dist/esm/View.js +11 -7
- package/package.json +1 -1
package/dist/cjs/View.js
CHANGED
|
@@ -124,7 +124,8 @@ var getDocumentGroupUrl = function getDocumentGroupUrl(docGroup) {
|
|
|
124
124
|
if (typeof url !== 'undefined') {
|
|
125
125
|
url = url + '/' + docGroup.path;
|
|
126
126
|
} else {
|
|
127
|
-
url = '/' + docGroup.path
|
|
127
|
+
// url = '/' + docGroup.path
|
|
128
|
+
return null;
|
|
128
129
|
}
|
|
129
130
|
|
|
130
131
|
return url;
|
|
@@ -147,7 +148,8 @@ var getDocumentGroupName = function getDocumentGroupName(docGroup) {
|
|
|
147
148
|
if (typeof name !== 'undefined') {
|
|
148
149
|
name = name + ' | <b>' + docGroup.name + '</b>';
|
|
149
150
|
} else {
|
|
150
|
-
name = '<b>' + docGroup.name + '</b>'
|
|
151
|
+
// name = '<b>' + docGroup.name + '</b>'
|
|
152
|
+
return null;
|
|
151
153
|
}
|
|
152
154
|
|
|
153
155
|
return name && typeof name != 'undefined' ? name : null;
|
|
@@ -197,7 +199,7 @@ var DocumentGroup = function DocumentGroup(_ref) {
|
|
|
197
199
|
{ style: { textAlign: 'center', fontWeight: 600 } },
|
|
198
200
|
article.documentGroupMapping && article.documentGroupMapping[0] && article.documentGroupMapping[0].parent && article.documentGroupMapping[0].parent.parent && article.documentGroupMapping[0].parent.parent.contextText ? article.documentGroupMapping[0].parent.parent.contextText : article.documentGroup && article.documentGroup.parent && article.documentGroup.parent.parent && article.documentGroup.parent.parent.contextText ? article.documentGroup.parent.parent.contextText : null
|
|
199
201
|
),
|
|
200
|
-
React__default["default"].createElement(
|
|
202
|
+
url && name && React__default["default"].createElement(
|
|
201
203
|
'a',
|
|
202
204
|
{
|
|
203
205
|
href: url,
|
|
@@ -1264,6 +1266,7 @@ var Article = React__default["default"].memo(React.forwardRef(function (props, r
|
|
|
1264
1266
|
};
|
|
1265
1267
|
|
|
1266
1268
|
var RelevantTopics = function RelevantTopics() {
|
|
1269
|
+
|
|
1267
1270
|
if (content_placement && content_placement.length > 0 || documentGroupMapping && documentGroupMapping.length > 0) {
|
|
1268
1271
|
var relatedLinks = [];
|
|
1269
1272
|
if (documentGroupMapping && documentGroupMapping.length > 0) {
|
|
@@ -1273,9 +1276,10 @@ var Article = React__default["default"].memo(React.forwardRef(function (props, r
|
|
|
1273
1276
|
}
|
|
1274
1277
|
|
|
1275
1278
|
var doc_url = cpModificationRequired ? getDocumentGroupUrl(documentGroup) : documentGroup.ancestor ? documentGroup.parent && !documentGroup.path.includes('/') ? '/' + documentGroup.ancestor + '/' + documentGroup.parent.identifier.current + '/' + documentGroup.path : '/' + documentGroup.ancestor + '/' + documentGroup.path : documentGroup.parent ? !documentGroup.path.includes('/') ? '/' + documentGroup.parent.identifier.current + '/' + documentGroup.path : '/' + documentGroup.path : '/' + documentGroup.path;
|
|
1276
|
-
|
|
1277
1279
|
var href = '' + doc_url;
|
|
1278
1280
|
relatedLinks = [].concat(toConsumableArray._toConsumableArray(relatedLinks), [{ label: documentGroup.name, href: href }]);
|
|
1281
|
+
var doc_url1 = cpModificationRequired ? getDocumentGroupUrl(documentGroup) : documentGroup.ancestor ? documentGroup.parent && !documentGroup.path.includes('/') ? !documentGroup.ancestor.includes('/') ? '/' + documentGroup.ancestor + '/' + documentGroup.parent.identifier.current + '/' + documentGroup.path : '/' + documentGroup.parent.identifier.current + '/' + documentGroup.path : !documentGroup.ancestor.includes('/') ? documentGroup.ancestor + '/' + documentGroup.path : '/' + documentGroup.path : documentGroup.parent ? !documentGroup.path.includes('/') ? '/' + documentGroup.parent.identifier.current + '/' + documentGroup.path : '/' + documentGroup.path : '/' + documentGroup.path;
|
|
1282
|
+
console.log("++++++++++++++DOC_URL1", doc_url1);
|
|
1279
1283
|
// if (documentGroup.parent) {
|
|
1280
1284
|
// relatedLinks = [
|
|
1281
1285
|
// ...relatedLinks,
|
|
@@ -1299,8 +1303,8 @@ var Article = React__default["default"].memo(React.forwardRef(function (props, r
|
|
|
1299
1303
|
return null;
|
|
1300
1304
|
}
|
|
1301
1305
|
|
|
1302
|
-
var cp_url = cpModificationRequired ? getTargeting.getContentPlacementUrl(cp) : cp.ancestor ? cp.parent && !cp.path.includes('/') ?
|
|
1303
|
-
var href = '' + cp_url;
|
|
1306
|
+
var cp_url = cpModificationRequired ? getTargeting.getContentPlacementUrl(cp) : cp.ancestor ? cp.parent && !cp.path.includes('/') ? cp.ancestor + '/' + cp.parent + '/' + cp.path : cp.ancestor + '/' + cp.path : cp.parent ? !cp.path.includes('/') ? cp.parent + '/' + cp.path : '' + cp.path : '' + cp.path;
|
|
1307
|
+
var href = '/' + cp_url;
|
|
1304
1308
|
relatedLinks = [].concat(toConsumableArray._toConsumableArray(relatedLinks), [{ label: cp.name, href: href }]);
|
|
1305
1309
|
});
|
|
1306
1310
|
}
|
|
@@ -1321,7 +1325,7 @@ var Article = React__default["default"].memo(React.forwardRef(function (props, r
|
|
|
1321
1325
|
{ key: index, className: 'related-link' },
|
|
1322
1326
|
React__default["default"].createElement(
|
|
1323
1327
|
'a',
|
|
1324
|
-
{ className: 'related-links
|
|
1328
|
+
{ className: 'related-links', style: { color: 'blue' }, href: relatedLink.href },
|
|
1325
1329
|
relatedLink.label
|
|
1326
1330
|
),
|
|
1327
1331
|
React__default["default"].createElement(
|
package/dist/esm/View.js
CHANGED
|
@@ -114,7 +114,8 @@ var getDocumentGroupUrl = function getDocumentGroupUrl(docGroup) {
|
|
|
114
114
|
if (typeof url !== 'undefined') {
|
|
115
115
|
url = url + '/' + docGroup.path;
|
|
116
116
|
} else {
|
|
117
|
-
url = '/' + docGroup.path
|
|
117
|
+
// url = '/' + docGroup.path
|
|
118
|
+
return null;
|
|
118
119
|
}
|
|
119
120
|
|
|
120
121
|
return url;
|
|
@@ -137,7 +138,8 @@ var getDocumentGroupName = function getDocumentGroupName(docGroup) {
|
|
|
137
138
|
if (typeof name !== 'undefined') {
|
|
138
139
|
name = name + ' | <b>' + docGroup.name + '</b>';
|
|
139
140
|
} else {
|
|
140
|
-
name = '<b>' + docGroup.name + '</b>'
|
|
141
|
+
// name = '<b>' + docGroup.name + '</b>'
|
|
142
|
+
return null;
|
|
141
143
|
}
|
|
142
144
|
|
|
143
145
|
return name && typeof name != 'undefined' ? name : null;
|
|
@@ -187,7 +189,7 @@ var DocumentGroup = function DocumentGroup(_ref) {
|
|
|
187
189
|
{ style: { textAlign: 'center', fontWeight: 600 } },
|
|
188
190
|
article.documentGroupMapping && article.documentGroupMapping[0] && article.documentGroupMapping[0].parent && article.documentGroupMapping[0].parent.parent && article.documentGroupMapping[0].parent.parent.contextText ? article.documentGroupMapping[0].parent.parent.contextText : article.documentGroup && article.documentGroup.parent && article.documentGroup.parent.parent && article.documentGroup.parent.parent.contextText ? article.documentGroup.parent.parent.contextText : null
|
|
189
191
|
),
|
|
190
|
-
React__default.createElement(
|
|
192
|
+
url && name && React__default.createElement(
|
|
191
193
|
'a',
|
|
192
194
|
{
|
|
193
195
|
href: url,
|
|
@@ -1254,6 +1256,7 @@ var Article = React__default.memo(forwardRef(function (props, ref) {
|
|
|
1254
1256
|
};
|
|
1255
1257
|
|
|
1256
1258
|
var RelevantTopics = function RelevantTopics() {
|
|
1259
|
+
|
|
1257
1260
|
if (content_placement && content_placement.length > 0 || documentGroupMapping && documentGroupMapping.length > 0) {
|
|
1258
1261
|
var relatedLinks = [];
|
|
1259
1262
|
if (documentGroupMapping && documentGroupMapping.length > 0) {
|
|
@@ -1263,9 +1266,10 @@ var Article = React__default.memo(forwardRef(function (props, ref) {
|
|
|
1263
1266
|
}
|
|
1264
1267
|
|
|
1265
1268
|
var doc_url = cpModificationRequired ? getDocumentGroupUrl(documentGroup) : documentGroup.ancestor ? documentGroup.parent && !documentGroup.path.includes('/') ? '/' + documentGroup.ancestor + '/' + documentGroup.parent.identifier.current + '/' + documentGroup.path : '/' + documentGroup.ancestor + '/' + documentGroup.path : documentGroup.parent ? !documentGroup.path.includes('/') ? '/' + documentGroup.parent.identifier.current + '/' + documentGroup.path : '/' + documentGroup.path : '/' + documentGroup.path;
|
|
1266
|
-
|
|
1267
1269
|
var href = '' + doc_url;
|
|
1268
1270
|
relatedLinks = [].concat(_toConsumableArray(relatedLinks), [{ label: documentGroup.name, href: href }]);
|
|
1271
|
+
var doc_url1 = cpModificationRequired ? getDocumentGroupUrl(documentGroup) : documentGroup.ancestor ? documentGroup.parent && !documentGroup.path.includes('/') ? !documentGroup.ancestor.includes('/') ? '/' + documentGroup.ancestor + '/' + documentGroup.parent.identifier.current + '/' + documentGroup.path : '/' + documentGroup.parent.identifier.current + '/' + documentGroup.path : !documentGroup.ancestor.includes('/') ? documentGroup.ancestor + '/' + documentGroup.path : '/' + documentGroup.path : documentGroup.parent ? !documentGroup.path.includes('/') ? '/' + documentGroup.parent.identifier.current + '/' + documentGroup.path : '/' + documentGroup.path : '/' + documentGroup.path;
|
|
1272
|
+
console.log("++++++++++++++DOC_URL1", doc_url1);
|
|
1269
1273
|
// if (documentGroup.parent) {
|
|
1270
1274
|
// relatedLinks = [
|
|
1271
1275
|
// ...relatedLinks,
|
|
@@ -1289,8 +1293,8 @@ var Article = React__default.memo(forwardRef(function (props, ref) {
|
|
|
1289
1293
|
return null;
|
|
1290
1294
|
}
|
|
1291
1295
|
|
|
1292
|
-
var cp_url = cpModificationRequired ? getContentPlacementUrl(cp) : cp.ancestor ? cp.parent && !cp.path.includes('/') ?
|
|
1293
|
-
var href = '' + cp_url;
|
|
1296
|
+
var cp_url = cpModificationRequired ? getContentPlacementUrl(cp) : cp.ancestor ? cp.parent && !cp.path.includes('/') ? cp.ancestor + '/' + cp.parent + '/' + cp.path : cp.ancestor + '/' + cp.path : cp.parent ? !cp.path.includes('/') ? cp.parent + '/' + cp.path : '' + cp.path : '' + cp.path;
|
|
1297
|
+
var href = '/' + cp_url;
|
|
1294
1298
|
relatedLinks = [].concat(_toConsumableArray(relatedLinks), [{ label: cp.name, href: href }]);
|
|
1295
1299
|
});
|
|
1296
1300
|
}
|
|
@@ -1311,7 +1315,7 @@ var Article = React__default.memo(forwardRef(function (props, ref) {
|
|
|
1311
1315
|
{ key: index, className: 'related-link' },
|
|
1312
1316
|
React__default.createElement(
|
|
1313
1317
|
'a',
|
|
1314
|
-
{ className: 'related-links
|
|
1318
|
+
{ className: 'related-links', style: { color: 'blue' }, href: relatedLink.href },
|
|
1315
1319
|
relatedLink.label
|
|
1316
1320
|
),
|
|
1317
1321
|
React__default.createElement(
|