@mjhls/mjh-framework 1.0.1030-disable-native-test → 1.0.1030

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 CHANGED
@@ -1087,19 +1087,19 @@ var Article = React__default["default"].memo(React.forwardRef(function (props, r
1087
1087
  }
1088
1088
 
1089
1089
  // If sponsored flag, disable contextual ads
1090
- if (sponsoredFlag || article.disableNativeAds) {
1090
+ if (sponsoredFlag) {
1091
1091
  article.contextualVideoAD = false;
1092
1092
  article.contextualAD = false;
1093
+ showRelatedArticles = false;
1093
1094
  }
1094
-
1095
- if (article.disableRelatedContent || sponsoredFlag) {
1095
+ if (article.disableRelatedContent) {
1096
1096
  showRelatedArticles = false;
1097
1097
  }
1098
1098
  // This was being done in ArticleQueue2 which wasnt effecting articles excluded from infinite scroll, moved inside article component
1099
1099
  if (!sponsoredFlag && Ads.getVideoContextualAD) {
1100
1100
  article.contextualVideoAD = Ads.getVideoContextualAD(getTargeting.getTargeting(props, 'in-context_video'));
1101
1101
  }
1102
- if (!sponsoredFlag && Ads.getNativeContextualAD && !article.disableNativeAds) {
1102
+ if (!sponsoredFlag && Ads.getNativeContextualAD) {
1103
1103
  article.contextualAD = Ads.getNativeContextualAD(getTargeting.getTargeting(props, 'native-ad'));
1104
1104
  }
1105
1105
 
@@ -1751,8 +1751,7 @@ var Article = React__default["default"].memo(React.forwardRef(function (props, r
1751
1751
  ),
1752
1752
  React__default["default"].createElement(
1753
1753
  'div',
1754
- {
1755
- className: 'mb-3 doc-group-container',
1754
+ { className: 'mb-3 doc-group-container',
1756
1755
  style: {
1757
1756
  display: 'flex',
1758
1757
  justifyContent: 'space-between',
@@ -2693,33 +2692,6 @@ View.returnGetInitialProps = function () {
2693
2692
  article.relatedArticle = _context.sent;
2694
2693
 
2695
2694
  case 35:
2696
-
2697
- //check documentGroup and documentGroupMapping for disableNativeAds:true
2698
- if (article.documentGroup && article.documentGroup.length) {
2699
- article.documentGroup.forEach(function (docGroup) {
2700
- var node = docGroup.parent ? docGroup.parent : null;
2701
- if (docGroup.disableNativeAds) {
2702
- article.disableNativeAds = true;
2703
- }
2704
- while (node) {
2705
- if (node.disableNativeAds) [article.disableNativeAds = true];
2706
- node = node.parent || null;
2707
- }
2708
- });
2709
- }
2710
- if (article.documentGroupMapping && article.documentGroupMapping.length) {
2711
- article.documentGroupMapping.forEach(function (docGroup) {
2712
- var node = docGroup.parent ? docGroup.parent : null;
2713
- if (docGroup.disableNativeAds) {
2714
- article.disableNativeAds = true;
2715
- }
2716
- while (node) {
2717
- if (node.disableNativeAds) [article.disableNativeAds = true];
2718
- node = node.parent || null;
2719
- }
2720
- });
2721
- }
2722
-
2723
2695
  return _context.abrupt('return', {
2724
2696
  url: url,
2725
2697
  sao: sao,
@@ -2731,7 +2703,7 @@ View.returnGetInitialProps = function () {
2731
2703
  sponsoredFlag: sponsoredFlag
2732
2704
  });
2733
2705
 
2734
- case 38:
2706
+ case 36:
2735
2707
  case 'end':
2736
2708
  return _context.stop();
2737
2709
  }
package/dist/esm/View.js CHANGED
@@ -1077,19 +1077,19 @@ var Article = React__default.memo(forwardRef(function (props, ref) {
1077
1077
  }
1078
1078
 
1079
1079
  // If sponsored flag, disable contextual ads
1080
- if (sponsoredFlag || article.disableNativeAds) {
1080
+ if (sponsoredFlag) {
1081
1081
  article.contextualVideoAD = false;
1082
1082
  article.contextualAD = false;
1083
+ showRelatedArticles = false;
1083
1084
  }
1084
-
1085
- if (article.disableRelatedContent || sponsoredFlag) {
1085
+ if (article.disableRelatedContent) {
1086
1086
  showRelatedArticles = false;
1087
1087
  }
1088
1088
  // This was being done in ArticleQueue2 which wasnt effecting articles excluded from infinite scroll, moved inside article component
1089
1089
  if (!sponsoredFlag && Ads.getVideoContextualAD) {
1090
1090
  article.contextualVideoAD = Ads.getVideoContextualAD(getTargeting(props, 'in-context_video'));
1091
1091
  }
1092
- if (!sponsoredFlag && Ads.getNativeContextualAD && !article.disableNativeAds) {
1092
+ if (!sponsoredFlag && Ads.getNativeContextualAD) {
1093
1093
  article.contextualAD = Ads.getNativeContextualAD(getTargeting(props, 'native-ad'));
1094
1094
  }
1095
1095
 
@@ -1741,8 +1741,7 @@ var Article = React__default.memo(forwardRef(function (props, ref) {
1741
1741
  ),
1742
1742
  React__default.createElement(
1743
1743
  'div',
1744
- {
1745
- className: 'mb-3 doc-group-container',
1744
+ { className: 'mb-3 doc-group-container',
1746
1745
  style: {
1747
1746
  display: 'flex',
1748
1747
  justifyContent: 'space-between',
@@ -2683,33 +2682,6 @@ View.returnGetInitialProps = function () {
2683
2682
  article.relatedArticle = _context.sent;
2684
2683
 
2685
2684
  case 35:
2686
-
2687
- //check documentGroup and documentGroupMapping for disableNativeAds:true
2688
- if (article.documentGroup && article.documentGroup.length) {
2689
- article.documentGroup.forEach(function (docGroup) {
2690
- var node = docGroup.parent ? docGroup.parent : null;
2691
- if (docGroup.disableNativeAds) {
2692
- article.disableNativeAds = true;
2693
- }
2694
- while (node) {
2695
- if (node.disableNativeAds) [article.disableNativeAds = true];
2696
- node = node.parent || null;
2697
- }
2698
- });
2699
- }
2700
- if (article.documentGroupMapping && article.documentGroupMapping.length) {
2701
- article.documentGroupMapping.forEach(function (docGroup) {
2702
- var node = docGroup.parent ? docGroup.parent : null;
2703
- if (docGroup.disableNativeAds) {
2704
- article.disableNativeAds = true;
2705
- }
2706
- while (node) {
2707
- if (node.disableNativeAds) [article.disableNativeAds = true];
2708
- node = node.parent || null;
2709
- }
2710
- });
2711
- }
2712
-
2713
2685
  return _context.abrupt('return', {
2714
2686
  url: url,
2715
2687
  sao: sao,
@@ -2721,7 +2693,7 @@ View.returnGetInitialProps = function () {
2721
2693
  sponsoredFlag: sponsoredFlag
2722
2694
  });
2723
2695
 
2724
- case 38:
2696
+ case 36:
2725
2697
  case 'end':
2726
2698
  return _context.stop();
2727
2699
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mjhls/mjh-framework",
3
- "version": "1.0.1030-disable-native-test",
3
+ "version": "1.0.1030",
4
4
  "description": "Foundation Framework",
5
5
  "author": "mjh-framework",
6
6
  "license": "MIT",