@mjhls/mjh-framework 1.0.689-segment → 1.0.689

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.
@@ -85,23 +85,13 @@ var NavNative = function NavNative(props) {
85
85
  var topNavHeight = document.querySelector('.nav-brands') && document.querySelector('.nav-brands').offsetHeight;
86
86
  // Setting the top of the search component based on the offset of navigation component.
87
87
  searchRef.current.style.top = (topNavHeight ? topNavHeight + navRef.current.offsetHeight : navRef.current.offsetHeight) + 1 + 'px';
88
- }, []);
89
-
90
- useEffect(function () {
91
-
92
- var navdropdowns = navRef.current.querySelectorAll('#basic-nav-dropdown');
93
- console.log('navdropdowns:', navdropdowns);
94
88
 
95
89
  setTimeout(function () {
96
-
97
90
  var segmentLinks = navRef.current.querySelectorAll('a[needsegmentsupport="true"]');
98
- console.log('segmentLinks:', segmentLinks);
99
91
  for (var i = 0; i < segmentLinks.length; i++) {
100
92
  var link = segmentLinks[i];
101
93
  var href = link.getAttribute('href');
102
94
  var newRef = Segment.getURL(href, { needSegmentSupport: true });
103
- console.log('href:', href);
104
- console.log('newRef:', newRef);
105
95
  link.setAttribute('href', newRef);
106
96
  }
107
97
  }, 1000);
@@ -426,19 +416,15 @@ var NavNative = function NavNative(props) {
426
416
  { key: 'subnav-' + index },
427
417
  React__default.createElement(
428
418
  NavDropdown,
429
- { key: index, title: row.name, id: 'basic-nav-dropdown', renderMenuOnMount: true },
419
+ { key: index, title: row.name, id: 'basic-nav-dropdown' },
430
420
  row.subQuery && row.subQuery.map(function (ddRow, subIndex) {
431
421
  if (ddRow.type === 'divider') {
432
422
  return React__default.createElement(NavDropdown.Divider, { key: subIndex });
433
423
  } else {
434
424
  return ddRow.url && ddRow.name ? React__default.createElement(
435
- NavDropdown.Item,
436
- null,
437
- React__default.createElement(
438
- NavDropdown.Link,
439
- { key: subIndex, needsegmentsupport: ddRow.needSegmentSupport ? 'true' : '', href: ddRow.url, target: ddRow.blank ? '_blank' : '_self', className: 'dropdown-item' },
440
- ddRow.name
441
- )
425
+ 'a',
426
+ { key: subIndex, needsegmentsupport: ddRow.needSegmentSupport ? 'true' : '', href: ddRow.url, target: ddRow.blank ? '_blank' : '_self', className: 'dropdown-item' },
427
+ ddRow.name
442
428
  ) : null;
443
429
  }
444
430
  })