@mjhls/mjh-framework 1.0.832-scroll-fix-v2 → 1.0.833-d4d-52

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 (162) hide show
  1. package/README.md +168 -168
  2. package/dist/cjs/AD300x250.js +2 -2
  3. package/dist/cjs/AD300x250x600.js +2 -2
  4. package/dist/cjs/AD728x90.js +3 -3
  5. package/dist/cjs/ADFloatingFooter.js +1 -1
  6. package/dist/cjs/ADGutter.js +1 -1
  7. package/dist/cjs/ADSkyscraper.js +1 -1
  8. package/dist/cjs/ADSponsoredResources.js +1 -1
  9. package/dist/cjs/ADWebcast.js +1 -1
  10. package/dist/cjs/ADWelcome.js +1 -1
  11. package/dist/cjs/AdSlot.js +1 -1
  12. package/dist/cjs/AdSlotsProvider.js +2 -2
  13. package/dist/cjs/AlgoliaSearch.js +36 -18
  14. package/dist/cjs/ArticleCarousel.js +1 -1
  15. package/dist/cjs/ArticleProgramLandingPage.js +5 -5
  16. package/dist/cjs/ArticleSeriesLandingPage.js +5 -5
  17. package/dist/cjs/ArticleSeriesListing.js +3 -3
  18. package/dist/cjs/Auth.js +6 -41
  19. package/dist/cjs/AuthWrapper.js +189 -228
  20. package/dist/cjs/CMEDeck.js +3 -3
  21. package/dist/cjs/Column3.js +3 -3
  22. package/dist/cjs/ConferenceArticleCard.js +16 -16
  23. package/dist/cjs/DeckContent.js +13 -13
  24. package/dist/cjs/DeckQueue.js +4 -4
  25. package/dist/cjs/EventsDeck.js +21 -21
  26. package/dist/cjs/ExternalResources.js +5 -5
  27. package/dist/cjs/Feature.js +2 -2
  28. package/dist/cjs/ForbesHero.js +1 -1
  29. package/dist/cjs/GridContent.js +8 -8
  30. package/dist/cjs/GridHero.js +1 -1
  31. package/dist/cjs/HamMagazine.js +15 -15
  32. package/dist/cjs/HighlightenVideo.js +1 -1
  33. package/dist/cjs/HorizontalArticleListing.js +4 -4
  34. package/dist/cjs/HorizontalHero.js +1 -1
  35. package/dist/cjs/IssueContentDeck.js +1 -1
  36. package/dist/cjs/IssueDeck.js +1 -1
  37. package/dist/cjs/IssueLanding.js +36 -36
  38. package/dist/cjs/KMTracker.js +15 -15
  39. package/dist/cjs/LeftNav.js +1 -1
  40. package/dist/cjs/MasterDeck.js +13 -13
  41. package/dist/cjs/MediaSeriesLanding.js +193 -149
  42. package/dist/cjs/NavMagazine.js +14 -14
  43. package/dist/cjs/NavNative.js +12 -12
  44. package/dist/cjs/OncliveHero.js +1 -1
  45. package/dist/cjs/OncliveLargeHero.js +1 -1
  46. package/dist/cjs/PartnerDetailListing.js +7 -7
  47. package/dist/cjs/PubSection.js +5 -5
  48. package/dist/cjs/PublicationLanding.js +26 -26
  49. package/dist/cjs/QueueDeckExpanded.js +7 -7
  50. package/dist/cjs/RelatedContent.js +29 -29
  51. package/dist/cjs/RelatedTopicsDropdown.js +10 -10
  52. package/dist/cjs/SeriesListingDeck.js +3 -3
  53. package/dist/cjs/{SeriesSlider-7d308aac.js → SeriesSlider-10bc3826.js} +10 -10
  54. package/dist/cjs/SideFooter.js +2 -2
  55. package/dist/cjs/{SocialSearchComponent-42b9d251.js → SocialSearchComponent-560a666e.js} +3 -3
  56. package/dist/cjs/TaxonomyDescription.js +4 -4
  57. package/dist/cjs/TemplateNormal.js +2 -2
  58. package/dist/cjs/Ustream.js +2 -2
  59. package/dist/cjs/VerticalHero.js +1 -1
  60. package/dist/cjs/VideoProgramLandingPage.js +5 -5
  61. package/dist/cjs/VideoSeriesCard.js +2 -2
  62. package/dist/cjs/VideoSeriesLandingPage.js +5 -5
  63. package/dist/cjs/VideoSeriesListing.js +3 -3
  64. package/dist/cjs/View.js +18 -15
  65. package/dist/cjs/YahooHero.js +1 -1
  66. package/dist/cjs/YoutubeGroup.js +10 -10
  67. package/dist/cjs/{brightcove-react-player-loader.es-5c98aec7.js → brightcove-react-player-loader.es-4ba0d3d5.js} +3 -4
  68. package/dist/cjs/getRelatedArticle.js +126 -62
  69. package/dist/cjs/getSerializers.js +4 -4
  70. package/dist/cjs/{getTargeting-15ad167c.js → getTargeting-ea2ea5e7.js} +9 -9
  71. package/dist/cjs/getTargeting.js +1 -1
  72. package/dist/cjs/{index-6367b7bf.js → index-5be2866f.js} +17 -16
  73. package/dist/cjs/{index-5d106b44.js → index-b10010e9.js} +12 -12
  74. package/dist/cjs/{index-e2e62963.js → index-f0677b9d.js} +10 -0
  75. package/dist/cjs/{index.es-f3e47207.js → index.es-13533f24.js} +4 -20
  76. package/dist/cjs/index.js +12 -12
  77. package/dist/cjs/{main-7b5e57b0.js → main-11ec04d2.js} +28 -32
  78. package/dist/cjs/{moment-ca3bd9fb.js → moment-66a6a284.js} +8 -10
  79. package/dist/cjs/timeDifferenceCalc.js +1 -1
  80. package/dist/esm/AD300x250.js +2 -2
  81. package/dist/esm/AD300x250x600.js +2 -2
  82. package/dist/esm/AD728x90.js +3 -3
  83. package/dist/esm/ADFloatingFooter.js +1 -1
  84. package/dist/esm/ADGutter.js +1 -1
  85. package/dist/esm/ADSkyscraper.js +1 -1
  86. package/dist/esm/ADSponsoredResources.js +1 -1
  87. package/dist/esm/ADWebcast.js +1 -1
  88. package/dist/esm/ADWelcome.js +1 -1
  89. package/dist/esm/AdSlot.js +1 -1
  90. package/dist/esm/AdSlotsProvider.js +2 -2
  91. package/dist/esm/AlgoliaSearch.js +35 -17
  92. package/dist/esm/ArticleCarousel.js +1 -1
  93. package/dist/esm/ArticleProgramLandingPage.js +5 -5
  94. package/dist/esm/ArticleSeriesLandingPage.js +5 -5
  95. package/dist/esm/ArticleSeriesListing.js +3 -3
  96. package/dist/esm/Auth.js +7 -42
  97. package/dist/esm/AuthWrapper.js +189 -228
  98. package/dist/esm/CMEDeck.js +3 -3
  99. package/dist/esm/Column3.js +3 -3
  100. package/dist/esm/ConferenceArticleCard.js +16 -16
  101. package/dist/esm/DeckContent.js +13 -13
  102. package/dist/esm/DeckQueue.js +4 -4
  103. package/dist/esm/EventsDeck.js +21 -21
  104. package/dist/esm/ExternalResources.js +5 -5
  105. package/dist/esm/Feature.js +2 -2
  106. package/dist/esm/ForbesHero.js +1 -1
  107. package/dist/esm/GridContent.js +8 -8
  108. package/dist/esm/GridHero.js +1 -1
  109. package/dist/esm/HamMagazine.js +15 -15
  110. package/dist/esm/HighlightenVideo.js +1 -1
  111. package/dist/esm/HorizontalArticleListing.js +4 -4
  112. package/dist/esm/HorizontalHero.js +1 -1
  113. package/dist/esm/IssueContentDeck.js +1 -1
  114. package/dist/esm/IssueDeck.js +1 -1
  115. package/dist/esm/IssueLanding.js +36 -36
  116. package/dist/esm/KMTracker.js +15 -15
  117. package/dist/esm/LeftNav.js +1 -1
  118. package/dist/esm/MasterDeck.js +13 -13
  119. package/dist/esm/MediaSeriesLanding.js +193 -149
  120. package/dist/esm/NavMagazine.js +14 -14
  121. package/dist/esm/NavNative.js +12 -12
  122. package/dist/esm/OncliveHero.js +1 -1
  123. package/dist/esm/OncliveLargeHero.js +1 -1
  124. package/dist/esm/PartnerDetailListing.js +7 -7
  125. package/dist/esm/PubSection.js +5 -5
  126. package/dist/esm/PublicationLanding.js +26 -26
  127. package/dist/esm/QueueDeckExpanded.js +7 -7
  128. package/dist/esm/RelatedContent.js +29 -29
  129. package/dist/esm/RelatedTopicsDropdown.js +10 -10
  130. package/dist/esm/SeriesListingDeck.js +3 -3
  131. package/dist/esm/{SeriesSlider-3c4bfe38.js → SeriesSlider-31dcb72b.js} +10 -10
  132. package/dist/esm/SideFooter.js +2 -2
  133. package/dist/esm/{SocialSearchComponent-94f6554c.js → SocialSearchComponent-82ac7d6d.js} +3 -3
  134. package/dist/esm/TaxonomyDescription.js +4 -4
  135. package/dist/esm/TemplateNormal.js +2 -2
  136. package/dist/esm/Ustream.js +2 -2
  137. package/dist/esm/VerticalHero.js +1 -1
  138. package/dist/esm/VideoProgramLandingPage.js +5 -5
  139. package/dist/esm/VideoSeriesCard.js +2 -2
  140. package/dist/esm/VideoSeriesLandingPage.js +5 -5
  141. package/dist/esm/VideoSeriesListing.js +3 -3
  142. package/dist/esm/View.js +18 -15
  143. package/dist/esm/YahooHero.js +1 -1
  144. package/dist/esm/YoutubeGroup.js +10 -10
  145. package/dist/esm/{brightcove-react-player-loader.es-4abff0b1.js → brightcove-react-player-loader.es-e1c6b0f2.js} +3 -4
  146. package/dist/esm/getRelatedArticle.js +126 -62
  147. package/dist/esm/getSerializers.js +4 -4
  148. package/dist/esm/{getTargeting-82e86707.js → getTargeting-831bc794.js} +9 -9
  149. package/dist/esm/getTargeting.js +1 -1
  150. package/dist/esm/{index-04d3dda1.js → index-b3bd543b.js} +12 -12
  151. package/dist/esm/{index-aaa2dae0.js → index-b68072f5.js} +10 -1
  152. package/dist/esm/{index-c00b0bbb.js → index-d2f90501.js} +17 -16
  153. package/dist/esm/{index.es-c6222053.js → index.es-7dda2f0a.js} +4 -20
  154. package/dist/esm/index.js +12 -12
  155. package/dist/esm/{main-747e7d25.js → main-aef58dbc.js} +28 -32
  156. package/dist/esm/{moment-b6f49411.js → moment-12415288.js} +8 -10
  157. package/dist/esm/timeDifferenceCalc.js +1 -1
  158. package/package.json +110 -110
  159. /package/dist/cjs/{ADInfeed-0158bee3.js → ADInfeed-912f52c2.js} +0 -0
  160. /package/dist/cjs/{ADlgInfeed-3583144f.js → ADlgInfeed-98acbab8.js} +0 -0
  161. /package/dist/esm/{ADInfeed-427022e9.js → ADInfeed-813279c7.js} +0 -0
  162. /package/dist/esm/{ADlgInfeed-28d3f944.js → ADlgInfeed-8ba1523a.js} +0 -0
@@ -21,18 +21,18 @@ import 'react-bootstrap/Container';
21
21
  import 'react-bootstrap/Row';
22
22
  import 'react-bootstrap/Col';
23
23
  import 'react-bootstrap/Card';
24
- import { m as moment } from './moment-b6f49411.js';
24
+ import { m as moment } from './moment-12415288.js';
25
25
  import 'next/router';
26
26
  import './isSymbol-1981418f.js';
27
27
  import './debounce-9207d8ee.js';
28
28
  import './toNumber-2f7a84cd.js';
29
- import './index.es-c6222053.js';
29
+ import './index.es-7dda2f0a.js';
30
30
  import ReactDOM from 'react-dom';
31
31
  import './visibility-sensor-f40c2564.js';
32
32
  import './index-51a80699.js';
33
33
  import urlFor from './urlFor.js';
34
34
  import { L as LazyLoad } from './index-6c12bdd5.js';
35
- import './main-747e7d25.js';
35
+ import './main-aef58dbc.js';
36
36
  import './entities-7cc3bf45.js';
37
37
  import { _ as _slicedToArray } from './slicedToArray-641f241f.js';
38
38
  import './stringify-4330ccdc.js';
@@ -40,9 +40,9 @@ import { a as _asyncToGenerator, r as regenerator } from './asyncToGenerator-fc1
40
40
  import './Segment.js';
41
41
  import './Beam.js';
42
42
  import './AdSlot.js';
43
- import './ADInfeed-427022e9.js';
43
+ import './ADInfeed-813279c7.js';
44
44
  import './lodash-ec8c6b48.js';
45
- import './ADlgInfeed-28d3f944.js';
45
+ import './ADlgInfeed-8ba1523a.js';
46
46
  import { B as BlockContent } from './BlockContent-d05b5b23.js';
47
47
  import './index-c7e2ac95.js';
48
48
  import './smoothscroll-0cd4c7a6.js';
@@ -50,9 +50,9 @@ import './GroupDeck.js';
50
50
  import 'react-bootstrap';
51
51
  import './iconBase-602d52fe.js';
52
52
  import './index.esm-3fdda599.js';
53
- import { g as getSerializers } from './index-04d3dda1.js';
53
+ import { g as getSerializers } from './index-b3bd543b.js';
54
54
  import './util-7700fc59.js';
55
- import './brightcove-react-player-loader.es-4abff0b1.js';
55
+ import './brightcove-react-player-loader.es-e1c6b0f2.js';
56
56
  import 'next/head';
57
57
  import 'react-share';
58
58
  import './SocialShare.js';
@@ -62,7 +62,7 @@ import 'react-bootstrap/Button';
62
62
  import 'react-bootstrap/Figure';
63
63
  import MasterDeck from './MasterDeck.js';
64
64
  import { _ as _defineProperty } from './defineProperty-94fd8bfc.js';
65
- import { _ as _objectWithoutPropertiesLoose, a as _extends, c as classnames } from './index-aaa2dae0.js';
65
+ import { _ as _objectWithoutPropertiesLoose, b as _extends, a as _setPrototypeOf, c as classnames } from './index-b68072f5.js';
66
66
  import { s as styleInject } from './style-inject.es-1f59c1d0.js';
67
67
  import Link from 'next/link';
68
68
 
@@ -174,7 +174,7 @@ function useUncontrolled(props, config) {
174
174
  function _inheritsLoose(subClass, superClass) {
175
175
  subClass.prototype = Object.create(superClass.prototype);
176
176
  subClass.prototype.constructor = subClass;
177
- subClass.__proto__ = superClass;
177
+ _setPrototypeOf(subClass, superClass);
178
178
  }
179
179
 
180
180
  var ThemeContext = React.createContext({});
@@ -1843,6 +1843,20 @@ function setChainedTimeout(handleRef, fn, timeoutAtMs) {
1843
1843
  /**
1844
1844
  * Returns a controller object for setting a timeout that is properly cleaned up
1845
1845
  * once the component unmounts. New timeouts cancel and replace existing ones.
1846
+ *
1847
+ *
1848
+ *
1849
+ * ```tsx
1850
+ * const { set, clear } = useTimeout();
1851
+ * const [hello, showHello] = useState(false);
1852
+ * //Display hello after 5 seconds
1853
+ * set(() => showHello(true), 5000);
1854
+ * return (
1855
+ * <div className="App">
1856
+ * {hello ? <h3>Hello</h3> : null}
1857
+ * </div>
1858
+ * );
1859
+ * ```
1846
1860
  */
1847
1861
 
1848
1862
 
@@ -2601,21 +2615,50 @@ function getBasePlacement(placement) {
2601
2615
  return placement.split('-')[0];
2602
2616
  }
2603
2617
 
2604
- // Returns the layout rect of an element relative to its offsetParent. Layout
2618
+ function getBoundingClientRect(element) {
2619
+ var rect = element.getBoundingClientRect();
2620
+ return {
2621
+ width: rect.width,
2622
+ height: rect.height,
2623
+ top: rect.top,
2624
+ right: rect.right,
2625
+ bottom: rect.bottom,
2626
+ left: rect.left,
2627
+ x: rect.left,
2628
+ y: rect.top
2629
+ };
2630
+ }
2631
+
2605
2632
  // means it doesn't take into account transforms.
2633
+
2606
2634
  function getLayoutRect(element) {
2635
+ var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.
2636
+ // Fixes https://github.com/popperjs/popper-core/issues/1223
2637
+
2638
+ var width = element.offsetWidth;
2639
+ var height = element.offsetHeight;
2640
+
2641
+ if (Math.abs(clientRect.width - width) <= 1) {
2642
+ width = clientRect.width;
2643
+ }
2644
+
2645
+ if (Math.abs(clientRect.height - height) <= 1) {
2646
+ height = clientRect.height;
2647
+ }
2648
+
2607
2649
  return {
2608
2650
  x: element.offsetLeft,
2609
2651
  y: element.offsetTop,
2610
- width: element.offsetWidth,
2611
- height: element.offsetHeight
2652
+ width: width,
2653
+ height: height
2612
2654
  };
2613
2655
  }
2614
2656
 
2615
- /*:: import type { Window } from '../types'; */
2616
-
2617
- /*:: declare function getWindow(node: Node | Window): Window; */
2618
2657
  function getWindow(node) {
2658
+ if (node == null) {
2659
+ return window;
2660
+ }
2661
+
2619
2662
  if (node.toString() !== '[object Window]') {
2620
2663
  var ownerDocument = node.ownerDocument;
2621
2664
  return ownerDocument ? ownerDocument.defaultView || window : window;
@@ -2624,26 +2667,22 @@ function getWindow(node) {
2624
2667
  return node;
2625
2668
  }
2626
2669
 
2627
- /*:: declare function isElement(node: mixed): boolean %checks(node instanceof
2628
- Element); */
2629
-
2630
2670
  function isElement(node) {
2631
2671
  var OwnElement = getWindow(node).Element;
2632
2672
  return node instanceof OwnElement || node instanceof Element;
2633
2673
  }
2634
- /*:: declare function isHTMLElement(node: mixed): boolean %checks(node instanceof
2635
- HTMLElement); */
2636
-
2637
2674
 
2638
2675
  function isHTMLElement(node) {
2639
2676
  var OwnElement = getWindow(node).HTMLElement;
2640
2677
  return node instanceof OwnElement || node instanceof HTMLElement;
2641
2678
  }
2642
- /*:: declare function isShadowRoot(node: mixed): boolean %checks(node instanceof
2643
- ShadowRoot); */
2644
-
2645
2679
 
2646
2680
  function isShadowRoot(node) {
2681
+ // IE 11 has no ShadowRoot
2682
+ if (typeof ShadowRoot === 'undefined') {
2683
+ return false;
2684
+ }
2685
+
2647
2686
  var OwnElement = getWindow(node).ShadowRoot;
2648
2687
  return node instanceof OwnElement || node instanceof ShadowRoot;
2649
2688
  }
@@ -2660,7 +2699,7 @@ function contains(parent, child) {
2660
2699
  do {
2661
2700
  if (next && parent.isSameNode(next)) {
2662
2701
  return true;
2663
- } // $FlowFixMe: need a better way to handle this...
2702
+ } // $FlowFixMe[prop-missing]: need a better way to handle this...
2664
2703
 
2665
2704
 
2666
2705
  next = next.parentNode || next.host;
@@ -2684,8 +2723,9 @@ function isTableElement(element) {
2684
2723
  }
2685
2724
 
2686
2725
  function getDocumentElement(element) {
2687
- // $FlowFixMe: assume body is always available
2688
- return ((isElement(element) ? element.ownerDocument : element.document) || window.document).documentElement;
2726
+ // $FlowFixMe[incompatible-return]: assume body is always available
2727
+ return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]
2728
+ element.document) || window.document).documentElement;
2689
2729
  }
2690
2730
 
2691
2731
  function getParentNode(element) {
@@ -2693,12 +2733,13 @@ function getParentNode(element) {
2693
2733
  return element;
2694
2734
  }
2695
2735
 
2696
- return (// $FlowFixMe: this is a quicker (but less type safe) way to save quite some bytes from the bundle
2736
+ return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle
2737
+ // $FlowFixMe[incompatible-return]
2738
+ // $FlowFixMe[prop-missing]
2697
2739
  element.assignedSlot || // step into the shadow DOM of the parent of a slotted node
2698
- element.parentNode || // DOM Element detected
2699
- // $FlowFixMe: need a better way to handle this...
2700
- element.host || // ShadowRoot detected
2701
- // $FlowFixMe: HTMLElement is a Node
2740
+ element.parentNode || ( // DOM Element detected
2741
+ isShadowRoot(element) ? element.host : null) || // ShadowRoot detected
2742
+ // $FlowFixMe[incompatible-call]: HTMLElement is a Node
2702
2743
  getDocumentElement(element) // fallback
2703
2744
 
2704
2745
  );
@@ -2710,29 +2751,21 @@ function getTrueOffsetParent(element) {
2710
2751
  return null;
2711
2752
  }
2712
2753
 
2713
- var offsetParent = element.offsetParent;
2714
-
2715
- if (offsetParent) {
2716
- var html = getDocumentElement(offsetParent);
2717
-
2718
- if (getNodeName(offsetParent) === 'body' && getComputedStyle$2(offsetParent).position === 'static' && getComputedStyle$2(html).position !== 'static') {
2719
- return html;
2720
- }
2721
- }
2722
-
2723
- return offsetParent;
2754
+ return element.offsetParent;
2724
2755
  } // `.offsetParent` reports `null` for fixed elements, while absolute elements
2725
2756
  // return the containing block
2726
2757
 
2727
2758
 
2728
2759
  function getContainingBlock(element) {
2760
+ var isFirefox = navigator.userAgent.toLowerCase().indexOf('firefox') !== -1;
2729
2761
  var currentNode = getParentNode(element);
2730
2762
 
2731
2763
  while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {
2732
2764
  var css = getComputedStyle$2(currentNode); // This is non-exhaustive but covers the most common CSS properties that
2733
2765
  // create a containing block.
2766
+ // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block
2734
2767
 
2735
- if (css.transform !== 'none' || css.perspective !== 'none' || css.willChange && css.willChange !== 'auto') {
2768
+ if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {
2736
2769
  return currentNode;
2737
2770
  } else {
2738
2771
  currentNode = currentNode.parentNode;
@@ -2752,7 +2785,7 @@ function getOffsetParent(element) {
2752
2785
  offsetParent = getTrueOffsetParent(offsetParent);
2753
2786
  }
2754
2787
 
2755
- if (offsetParent && getNodeName(offsetParent) === 'body' && getComputedStyle$2(offsetParent).position === 'static') {
2788
+ if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle$2(offsetParent).position === 'static')) {
2756
2789
  return window;
2757
2790
  }
2758
2791
 
@@ -2763,8 +2796,12 @@ function getMainAxisFromPlacement(placement) {
2763
2796
  return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';
2764
2797
  }
2765
2798
 
2766
- function within(min, value, max) {
2767
- return Math.max(min, Math.min(value, max));
2799
+ var max = Math.max;
2800
+ var min = Math.min;
2801
+ var round = Math.round;
2802
+
2803
+ function within(min$1, value, max$1) {
2804
+ return max(min$1, min(value, max$1));
2768
2805
  }
2769
2806
 
2770
2807
  function getFreshSideObject() {
@@ -2777,7 +2814,7 @@ function getFreshSideObject() {
2777
2814
  }
2778
2815
 
2779
2816
  function mergePaddingObject(paddingObject) {
2780
- return Object.assign(Object.assign({}, getFreshSideObject()), paddingObject);
2817
+ return Object.assign({}, getFreshSideObject(), paddingObject);
2781
2818
  }
2782
2819
 
2783
2820
  function expandToHashMap(value, keys) {
@@ -2787,11 +2824,19 @@ function expandToHashMap(value, keys) {
2787
2824
  }, {});
2788
2825
  }
2789
2826
 
2827
+ var toPaddingObject = function toPaddingObject(padding, state) {
2828
+ padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {
2829
+ placement: state.placement
2830
+ })) : padding;
2831
+ return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));
2832
+ };
2833
+
2790
2834
  function arrow(_ref) {
2791
2835
  var _state$modifiersData$;
2792
2836
 
2793
2837
  var state = _ref.state,
2794
- name = _ref.name;
2838
+ name = _ref.name,
2839
+ options = _ref.options;
2795
2840
  var arrowElement = state.elements.arrow;
2796
2841
  var popperOffsets = state.modifiersData.popperOffsets;
2797
2842
  var basePlacement = getBasePlacement(state.placement);
@@ -2803,7 +2848,7 @@ function arrow(_ref) {
2803
2848
  return;
2804
2849
  }
2805
2850
 
2806
- var paddingObject = state.modifiersData[name + "#persistent"].padding;
2851
+ var paddingObject = toPaddingObject(options.padding, state);
2807
2852
  var arrowRect = getLayoutRect(arrowElement);
2808
2853
  var minProp = axis === 'y' ? top : left;
2809
2854
  var maxProp = axis === 'y' ? bottom : right;
@@ -2825,12 +2870,9 @@ function arrow(_ref) {
2825
2870
 
2826
2871
  function effect(_ref2) {
2827
2872
  var state = _ref2.state,
2828
- options = _ref2.options,
2829
- name = _ref2.name;
2873
+ options = _ref2.options;
2830
2874
  var _options$element = options.element,
2831
- arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element,
2832
- _options$padding = options.padding,
2833
- padding = _options$padding === void 0 ? 0 : _options$padding;
2875
+ arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;
2834
2876
 
2835
2877
  if (arrowElement == null) {
2836
2878
  return;
@@ -2860,9 +2902,6 @@ function effect(_ref2) {
2860
2902
  }
2861
2903
 
2862
2904
  state.elements.arrow = arrowElement;
2863
- state.modifiersData[name + "#persistent"] = {
2864
- padding: mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements))
2865
- };
2866
2905
  } // eslint-disable-next-line import/no-unused-modules
2867
2906
 
2868
2907
 
@@ -2885,14 +2924,14 @@ var unsetSides = {
2885
2924
  // Zooming can change the DPR, but it seems to report a value that will
2886
2925
  // cleanly divide the values into the appropriate subpixels.
2887
2926
 
2888
- function roundOffsets(_ref) {
2927
+ function roundOffsetsByDPR(_ref) {
2889
2928
  var x = _ref.x,
2890
2929
  y = _ref.y;
2891
2930
  var win = window;
2892
2931
  var dpr = win.devicePixelRatio || 1;
2893
2932
  return {
2894
- x: Math.round(x * dpr) / dpr || 0,
2895
- y: Math.round(y * dpr) / dpr || 0
2933
+ x: round(round(x * dpr) / dpr) || 0,
2934
+ y: round(round(y * dpr) / dpr) || 0
2896
2935
  };
2897
2936
  }
2898
2937
 
@@ -2905,11 +2944,14 @@ function mapToStyles(_ref2) {
2905
2944
  offsets = _ref2.offsets,
2906
2945
  position = _ref2.position,
2907
2946
  gpuAcceleration = _ref2.gpuAcceleration,
2908
- adaptive = _ref2.adaptive;
2947
+ adaptive = _ref2.adaptive,
2948
+ roundOffsets = _ref2.roundOffsets;
2909
2949
 
2910
- var _roundOffsets = roundOffsets(offsets),
2911
- x = _roundOffsets.x,
2912
- y = _roundOffsets.y;
2950
+ var _ref3 = roundOffsets === true ? roundOffsetsByDPR(offsets) : typeof roundOffsets === 'function' ? roundOffsets(offsets) : offsets,
2951
+ _ref3$x = _ref3.x,
2952
+ x = _ref3$x === void 0 ? 0 : _ref3$x,
2953
+ _ref3$y = _ref3.y,
2954
+ y = _ref3$y === void 0 ? 0 : _ref3$y;
2913
2955
 
2914
2956
  var hasX = offsets.hasOwnProperty('x');
2915
2957
  var hasY = offsets.hasOwnProperty('y');
@@ -2919,23 +2961,32 @@ function mapToStyles(_ref2) {
2919
2961
 
2920
2962
  if (adaptive) {
2921
2963
  var offsetParent = getOffsetParent(popper);
2964
+ var heightProp = 'clientHeight';
2965
+ var widthProp = 'clientWidth';
2922
2966
 
2923
2967
  if (offsetParent === getWindow(popper)) {
2924
2968
  offsetParent = getDocumentElement(popper);
2925
- } // $FlowFixMe: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it
2926
2969
 
2927
- /*:: offsetParent = (offsetParent: Element); */
2970
+ if (getComputedStyle$2(offsetParent).position !== 'static') {
2971
+ heightProp = 'scrollHeight';
2972
+ widthProp = 'scrollWidth';
2973
+ }
2974
+ } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it
2975
+
2928
2976
 
2977
+ offsetParent = offsetParent;
2929
2978
 
2930
2979
  if (placement === top) {
2931
- sideY = bottom;
2932
- y -= offsetParent.clientHeight - popperRect.height;
2980
+ sideY = bottom; // $FlowFixMe[prop-missing]
2981
+
2982
+ y -= offsetParent[heightProp] - popperRect.height;
2933
2983
  y *= gpuAcceleration ? 1 : -1;
2934
2984
  }
2935
2985
 
2936
2986
  if (placement === left) {
2937
- sideX = right;
2938
- x -= offsetParent.clientWidth - popperRect.width;
2987
+ sideX = right; // $FlowFixMe[prop-missing]
2988
+
2989
+ x -= offsetParent[widthProp] - popperRect.width;
2939
2990
  x *= gpuAcceleration ? 1 : -1;
2940
2991
  }
2941
2992
  }
@@ -2947,19 +2998,21 @@ function mapToStyles(_ref2) {
2947
2998
  if (gpuAcceleration) {
2948
2999
  var _Object$assign;
2949
3000
 
2950
- return Object.assign(Object.assign({}, commonStyles), {}, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) < 2 ? "translate(" + x + "px, " + y + "px)" : "translate3d(" + x + "px, " + y + "px, 0)", _Object$assign));
3001
+ return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) < 2 ? "translate(" + x + "px, " + y + "px)" : "translate3d(" + x + "px, " + y + "px, 0)", _Object$assign));
2951
3002
  }
2952
3003
 
2953
- return Object.assign(Object.assign({}, commonStyles), {}, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + "px" : '', _Object$assign2[sideX] = hasX ? x + "px" : '', _Object$assign2.transform = '', _Object$assign2));
3004
+ return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + "px" : '', _Object$assign2[sideX] = hasX ? x + "px" : '', _Object$assign2.transform = '', _Object$assign2));
2954
3005
  }
2955
3006
 
2956
- function computeStyles(_ref3) {
2957
- var state = _ref3.state,
2958
- options = _ref3.options;
3007
+ function computeStyles(_ref4) {
3008
+ var state = _ref4.state,
3009
+ options = _ref4.options;
2959
3010
  var _options$gpuAccelerat = options.gpuAcceleration,
2960
3011
  gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,
2961
3012
  _options$adaptive = options.adaptive,
2962
- adaptive = _options$adaptive === void 0 ? true : _options$adaptive;
3013
+ adaptive = _options$adaptive === void 0 ? true : _options$adaptive,
3014
+ _options$roundOffsets = options.roundOffsets,
3015
+ roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;
2963
3016
 
2964
3017
  if (process.env.NODE_ENV !== "production") {
2965
3018
  var transitionProperty = getComputedStyle$2(state.elements.popper).transitionProperty || '';
@@ -2979,22 +3032,24 @@ function computeStyles(_ref3) {
2979
3032
  };
2980
3033
 
2981
3034
  if (state.modifiersData.popperOffsets != null) {
2982
- state.styles.popper = Object.assign(Object.assign({}, state.styles.popper), mapToStyles(Object.assign(Object.assign({}, commonStyles), {}, {
3035
+ state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {
2983
3036
  offsets: state.modifiersData.popperOffsets,
2984
3037
  position: state.options.strategy,
2985
- adaptive: adaptive
3038
+ adaptive: adaptive,
3039
+ roundOffsets: roundOffsets
2986
3040
  })));
2987
3041
  }
2988
3042
 
2989
3043
  if (state.modifiersData.arrow != null) {
2990
- state.styles.arrow = Object.assign(Object.assign({}, state.styles.arrow), mapToStyles(Object.assign(Object.assign({}, commonStyles), {}, {
3044
+ state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {
2991
3045
  offsets: state.modifiersData.arrow,
2992
3046
  position: 'absolute',
2993
- adaptive: false
3047
+ adaptive: false,
3048
+ roundOffsets: roundOffsets
2994
3049
  })));
2995
3050
  }
2996
3051
 
2997
- state.attributes.popper = Object.assign(Object.assign({}, state.attributes.popper), {}, {
3052
+ state.attributes.popper = Object.assign({}, state.attributes.popper, {
2998
3053
  'data-popper-placement': state.placement
2999
3054
  });
3000
3055
  } // eslint-disable-next-line import/no-unused-modules
@@ -3078,20 +3133,6 @@ function getOppositeVariationPlacement(placement) {
3078
3133
  });
3079
3134
  }
3080
3135
 
3081
- function getBoundingClientRect(element) {
3082
- var rect = element.getBoundingClientRect();
3083
- return {
3084
- width: rect.width,
3085
- height: rect.height,
3086
- top: rect.top,
3087
- right: rect.right,
3088
- bottom: rect.bottom,
3089
- left: rect.left,
3090
- x: rect.left,
3091
- y: rect.top
3092
- };
3093
- }
3094
-
3095
3136
  function getWindowScroll(node) {
3096
3137
  var win = getWindow(node);
3097
3138
  var scrollLeft = win.pageXOffset;
@@ -3154,16 +3195,18 @@ function getViewportRect(element) {
3154
3195
  // of the `<html>` and `<body>` rect bounds if horizontally scrollable
3155
3196
 
3156
3197
  function getDocumentRect(element) {
3198
+ var _element$ownerDocumen;
3199
+
3157
3200
  var html = getDocumentElement(element);
3158
3201
  var winScroll = getWindowScroll(element);
3159
- var body = element.ownerDocument.body;
3160
- var width = Math.max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);
3161
- var height = Math.max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);
3202
+ var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;
3203
+ var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);
3204
+ var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);
3162
3205
  var x = -winScroll.scrollLeft + getWindowScrollBarX(element);
3163
3206
  var y = -winScroll.scrollTop;
3164
3207
 
3165
3208
  if (getComputedStyle$2(body || html).direction === 'rtl') {
3166
- x += Math.max(html.clientWidth, body ? body.clientWidth : 0) - width;
3209
+ x += max(html.clientWidth, body ? body.clientWidth : 0) - width;
3167
3210
  }
3168
3211
 
3169
3212
  return {
@@ -3186,7 +3229,7 @@ function isScrollParent(element) {
3186
3229
 
3187
3230
  function getScrollParent(node) {
3188
3231
  if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {
3189
- // $FlowFixMe: assume body is always available
3232
+ // $FlowFixMe[incompatible-return]: assume body is always available
3190
3233
  return node.ownerDocument.body;
3191
3234
  }
3192
3235
 
@@ -3200,26 +3243,28 @@ function getScrollParent(node) {
3200
3243
  /*
3201
3244
  given a DOM element, return the list of all scroll parents, up the list of ancesors
3202
3245
  until we get to the top window object. This list is what we attach scroll listeners
3203
- to, because if any of these parent elements scroll, we'll need to re-calculate the
3246
+ to, because if any of these parent elements scroll, we'll need to re-calculate the
3204
3247
  reference element's position.
3205
3248
  */
3206
3249
 
3207
3250
  function listScrollParents(element, list) {
3251
+ var _element$ownerDocumen;
3252
+
3208
3253
  if (list === void 0) {
3209
3254
  list = [];
3210
3255
  }
3211
3256
 
3212
3257
  var scrollParent = getScrollParent(element);
3213
- var isBody = getNodeName(scrollParent) === 'body';
3258
+ var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);
3214
3259
  var win = getWindow(scrollParent);
3215
3260
  var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;
3216
3261
  var updatedList = list.concat(target);
3217
- return isBody ? updatedList : // $FlowFixMe: isBody tells us target will be an HTMLElement here
3262
+ return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here
3218
3263
  updatedList.concat(listScrollParents(getParentNode(target)));
3219
3264
  }
3220
3265
 
3221
3266
  function rectToClientRect(rect) {
3222
- return Object.assign(Object.assign({}, rect), {}, {
3267
+ return Object.assign({}, rect, {
3223
3268
  left: rect.x,
3224
3269
  top: rect.y,
3225
3270
  right: rect.x + rect.width,
@@ -3254,7 +3299,7 @@ function getClippingParents(element) {
3254
3299
 
3255
3300
  if (!isElement(clipperElement)) {
3256
3301
  return [];
3257
- } // $FlowFixMe: https://github.com/facebook/flow/issues/1414
3302
+ } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414
3258
3303
 
3259
3304
 
3260
3305
  return clippingParents.filter(function (clippingParent) {
@@ -3270,10 +3315,10 @@ function getClippingRect(element, boundary, rootBoundary) {
3270
3315
  var firstClippingParent = clippingParents[0];
3271
3316
  var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {
3272
3317
  var rect = getClientRectFromMixedType(element, clippingParent);
3273
- accRect.top = Math.max(rect.top, accRect.top);
3274
- accRect.right = Math.min(rect.right, accRect.right);
3275
- accRect.bottom = Math.min(rect.bottom, accRect.bottom);
3276
- accRect.left = Math.max(rect.left, accRect.left);
3318
+ accRect.top = max(rect.top, accRect.top);
3319
+ accRect.right = min(rect.right, accRect.right);
3320
+ accRect.bottom = min(rect.bottom, accRect.bottom);
3321
+ accRect.left = max(rect.left, accRect.left);
3277
3322
  return accRect;
3278
3323
  }, getClientRectFromMixedType(element, firstClippingParent));
3279
3324
  clippingRect.width = clippingRect.right - clippingRect.left;
@@ -3340,11 +3385,11 @@ function computeOffsets(_ref) {
3340
3385
 
3341
3386
  switch (variation) {
3342
3387
  case start:
3343
- offsets[mainAxis] = Math.floor(offsets[mainAxis]) - Math.floor(reference[len] / 2 - element[len] / 2);
3388
+ offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);
3344
3389
  break;
3345
3390
 
3346
3391
  case end:
3347
- offsets[mainAxis] = Math.floor(offsets[mainAxis]) + Math.ceil(reference[len] / 2 - element[len] / 2);
3392
+ offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);
3348
3393
  break;
3349
3394
  }
3350
3395
  }
@@ -3383,7 +3428,7 @@ function detectOverflow(state, options) {
3383
3428
  strategy: 'absolute',
3384
3429
  placement: placement
3385
3430
  });
3386
- var popperClientRect = rectToClientRect(Object.assign(Object.assign({}, popperRect), popperOffsets));
3431
+ var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));
3387
3432
  var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect
3388
3433
  // 0 or negative = within the clipping rect
3389
3434
 
@@ -3407,9 +3452,6 @@ function detectOverflow(state, options) {
3407
3452
  return overflowOffsets;
3408
3453
  }
3409
3454
 
3410
- /*:: type OverflowsMap = { [ComputedPlacement]: number }; */
3411
-
3412
- /*;; type OverflowsMap = { [key in ComputedPlacement]: number }; */
3413
3455
  function computeAutoPlacement(state, options) {
3414
3456
  if (options === void 0) {
3415
3457
  options = {};
@@ -3426,8 +3468,7 @@ function computeAutoPlacement(state, options) {
3426
3468
  var variation = getVariation(placement);
3427
3469
  var placements$1 = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {
3428
3470
  return getVariation(placement) === variation;
3429
- }) : basePlacements; // $FlowFixMe
3430
-
3471
+ }) : basePlacements;
3431
3472
  var allowedPlacements = placements$1.filter(function (placement) {
3432
3473
  return allowedAutoPlacements.indexOf(placement) >= 0;
3433
3474
  });
@@ -3438,7 +3479,7 @@ function computeAutoPlacement(state, options) {
3438
3479
  if (process.env.NODE_ENV !== "production") {
3439
3480
  console.error(['Popper: The `allowedAutoPlacements` option did not allow any', 'placements. Ensure the `placement` option matches the variation', 'of the allowed placements.', 'For example, "auto" cannot be used to allow "bottom-start".', 'Use "auto-start" instead.'].join(' '));
3440
3481
  }
3441
- } // $FlowFixMe: Flow seems to have problems with two array unions...
3482
+ } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...
3442
3483
 
3443
3484
 
3444
3485
  var overflows = allowedPlacements.reduce(function (acc, placement) {
@@ -3639,7 +3680,7 @@ function hide(_ref) {
3639
3680
  isReferenceHidden: isReferenceHidden,
3640
3681
  hasPopperEscaped: hasPopperEscaped
3641
3682
  };
3642
- state.attributes.popper = Object.assign(Object.assign({}, state.attributes.popper), {}, {
3683
+ state.attributes.popper = Object.assign({}, state.attributes.popper, {
3643
3684
  'data-popper-reference-hidden': isReferenceHidden,
3644
3685
  'data-popper-escaped': hasPopperEscaped
3645
3686
  });
@@ -3658,7 +3699,7 @@ function distanceAndSkiddingToXY(placement, rects, offset) {
3658
3699
  var basePlacement = getBasePlacement(placement);
3659
3700
  var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;
3660
3701
 
3661
- var _ref = typeof offset === 'function' ? offset(Object.assign(Object.assign({}, rects), {}, {
3702
+ var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {
3662
3703
  placement: placement
3663
3704
  })) : offset,
3664
3705
  skidding = _ref[0],
@@ -3764,7 +3805,7 @@ function preventOverflow(_ref) {
3764
3805
  var popperOffsets = state.modifiersData.popperOffsets;
3765
3806
  var referenceRect = state.rects.reference;
3766
3807
  var popperRect = state.rects.popper;
3767
- var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign(Object.assign({}, state.rects), {}, {
3808
+ var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {
3768
3809
  placement: state.placement
3769
3810
  })) : tetherOffset;
3770
3811
  var data = {
@@ -3776,13 +3817,13 @@ function preventOverflow(_ref) {
3776
3817
  return;
3777
3818
  }
3778
3819
 
3779
- if (checkMainAxis) {
3820
+ if (checkMainAxis || checkAltAxis) {
3780
3821
  var mainSide = mainAxis === 'y' ? top : left;
3781
3822
  var altSide = mainAxis === 'y' ? bottom : right;
3782
3823
  var len = mainAxis === 'y' ? 'height' : 'width';
3783
3824
  var offset = popperOffsets[mainAxis];
3784
- var min = popperOffsets[mainAxis] + overflow[mainSide];
3785
- var max = popperOffsets[mainAxis] - overflow[altSide];
3825
+ var min$1 = popperOffsets[mainAxis] + overflow[mainSide];
3826
+ var max$1 = popperOffsets[mainAxis] - overflow[altSide];
3786
3827
  var additive = tether ? -popperRect[len] / 2 : 0;
3787
3828
  var minLen = variation === start ? referenceRect[len] : popperRect[len];
3788
3829
  var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go
@@ -3809,26 +3850,29 @@ function preventOverflow(_ref) {
3809
3850
  var offsetModifierValue = state.modifiersData.offset ? state.modifiersData.offset[state.placement][mainAxis] : 0;
3810
3851
  var tetherMin = popperOffsets[mainAxis] + minOffset - offsetModifierValue - clientOffset;
3811
3852
  var tetherMax = popperOffsets[mainAxis] + maxOffset - offsetModifierValue;
3812
- var preventedOffset = within(tether ? Math.min(min, tetherMin) : min, offset, tether ? Math.max(max, tetherMax) : max);
3813
- popperOffsets[mainAxis] = preventedOffset;
3814
- data[mainAxis] = preventedOffset - offset;
3815
- }
3816
3853
 
3817
- if (checkAltAxis) {
3818
- var _mainSide = mainAxis === 'x' ? top : left;
3854
+ if (checkMainAxis) {
3855
+ var preventedOffset = within(tether ? min(min$1, tetherMin) : min$1, offset, tether ? max(max$1, tetherMax) : max$1);
3856
+ popperOffsets[mainAxis] = preventedOffset;
3857
+ data[mainAxis] = preventedOffset - offset;
3858
+ }
3859
+
3860
+ if (checkAltAxis) {
3861
+ var _mainSide = mainAxis === 'x' ? top : left;
3819
3862
 
3820
- var _altSide = mainAxis === 'x' ? bottom : right;
3863
+ var _altSide = mainAxis === 'x' ? bottom : right;
3821
3864
 
3822
- var _offset = popperOffsets[altAxis];
3865
+ var _offset = popperOffsets[altAxis];
3823
3866
 
3824
- var _min = _offset + overflow[_mainSide];
3867
+ var _min = _offset + overflow[_mainSide];
3825
3868
 
3826
- var _max = _offset - overflow[_altSide];
3869
+ var _max = _offset - overflow[_altSide];
3827
3870
 
3828
- var _preventedOffset = within(_min, _offset, _max);
3871
+ var _preventedOffset = within(tether ? min(_min, tetherMin) : _min, _offset, tether ? max(_max, tetherMax) : _max);
3829
3872
 
3830
- popperOffsets[altAxis] = _preventedOffset;
3831
- data[altAxis] = _preventedOffset - _offset;
3873
+ popperOffsets[altAxis] = _preventedOffset;
3874
+ data[altAxis] = _preventedOffset - _offset;
3875
+ }
3832
3876
  }
3833
3877
 
3834
3878
  state.modifiersData[name] = data;
@@ -4059,9 +4103,9 @@ function uniqueBy(arr, fn) {
4059
4103
  function mergeByName(modifiers) {
4060
4104
  var merged = modifiers.reduce(function (merged, current) {
4061
4105
  var existing = merged[current.name];
4062
- merged[current.name] = existing ? Object.assign(Object.assign(Object.assign({}, existing), current), {}, {
4063
- options: Object.assign(Object.assign({}, existing.options), current.options),
4064
- data: Object.assign(Object.assign({}, existing.data), current.data)
4106
+ merged[current.name] = existing ? Object.assign({}, existing, current, {
4107
+ options: Object.assign({}, existing.options, current.options),
4108
+ data: Object.assign({}, existing.data, current.data)
4065
4109
  }) : current;
4066
4110
  return merged;
4067
4111
  }, {}); // IE11 does not support Object.values
@@ -4107,7 +4151,7 @@ function popperGenerator(generatorOptions) {
4107
4151
  var state = {
4108
4152
  placement: 'bottom',
4109
4153
  orderedModifiers: [],
4110
- options: Object.assign(Object.assign({}, DEFAULT_OPTIONS), defaultOptions),
4154
+ options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),
4111
4155
  modifiersData: {},
4112
4156
  elements: {
4113
4157
  reference: reference,
@@ -4122,7 +4166,7 @@ function popperGenerator(generatorOptions) {
4122
4166
  state: state,
4123
4167
  setOptions: function setOptions(options) {
4124
4168
  cleanupModifierEffects();
4125
- state.options = Object.assign(Object.assign(Object.assign({}, defaultOptions), state.options), options);
4169
+ state.options = Object.assign({}, defaultOptions, state.options, options);
4126
4170
  state.scrollParents = {
4127
4171
  reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],
4128
4172
  popper: listScrollParents(popper)
@@ -9334,7 +9378,7 @@ var Tooltip = React.forwardRef(function (_ref, ref) {
9334
9378
  Tooltip.defaultProps = defaultProps$E;
9335
9379
  Tooltip.displayName = 'Tooltip';
9336
9380
 
9337
- var css = ".MediaSeriesCard-module_article__SAFYK {\r\n width: 100%;\r\n margin: 0 0 1rem 0;\r\n}\r\n.MediaSeriesCard-module_article__SAFYK a {\r\n display: flex;\r\n width: 100%;\r\n color: #000000;\r\n}\r\n.MediaSeriesCard-module_thumb__3jRAU {\r\n width: 25%;\r\n}\r\n.MediaSeriesCard-module_thumb__3jRAU img {\r\n width: 100%;\r\n height: auto;\r\n}\r\n.MediaSeriesCard-module_info__3L7_o {\r\n width: 75%;\r\n font-size: 1rem;\r\n}\r\n.MediaSeriesCard-module_info__3L7_o h2 {\r\n font-weight: bold;\r\n font-size: 1.25rem;\r\n margin: 0;\r\n}\r\n.MediaSeriesCard-module_published__E4oiz {\r\n color: #6d6d6d;\r\n margin: 0;\r\n}\r\n.MediaSeriesCard-module_summary__1xanh {\r\n margin: 0.5rem 0 0 0;\r\n}\r\n.MediaSeriesCard-module_author__e5fuR {\r\n margin: 0;\r\n}\r\n.MediaSeriesCard-module_author__e5fuR span {\r\n color: #6d6d6d;\r\n}\r\n.MediaSeriesCard-module_name__2m5KY {\r\n font-size: 1.3rem;\r\n font-weight: bold;\r\n}\r\n@media only screen and (max-width: 568px) {\r\n .MediaSeriesCard-module_article__SAFYK {\r\n margin: 1rem 0;\r\n box-shadow: 2px 4px 8px rgba(0,0,0,.2);\r\n }\r\n .MediaSeriesCard-module_article__SAFYK a {\r\n flex-direction: column;\r\n align-items: center;\r\n }\r\n .MediaSeriesCard-module_thumb__3jRAU {\r\n overflow: hidden;\r\n width: 100%;\r\n margin-bottom: 1rem;\r\n }\r\n .MediaSeriesCard-module_thumb__3jRAU img{\r\n border-radius: 10px 10px 0 0; \r\n }\r\n .MediaSeriesCard-module_thumb__3jRAU figure {\r\n margin: 0;\r\n }\r\n .MediaSeriesCard-module_info__3L7_o {\r\n width: 90%;\r\n padding: 0rem !important;\r\n }\r\n .MediaSeriesCard-module_info__3L7_o h2 {\r\n font-size: 1rem;\r\n }\r\n .MediaSeriesCard-module_name__2m5KY {\r\n font-size: 1rem;\r\n \r\n }\r\n}\r\n";
9381
+ var css = ".MediaSeriesCard-module_article__SAFYK {\n width: 100%;\n margin: 0 0 1rem 0;\n}\n.MediaSeriesCard-module_article__SAFYK a {\n display: flex;\n width: 100%;\n color: #000000;\n}\n.MediaSeriesCard-module_thumb__3jRAU {\n width: 25%;\n}\n.MediaSeriesCard-module_thumb__3jRAU img {\n width: 100%;\n height: auto;\n}\n.MediaSeriesCard-module_info__3L7_o {\n width: 75%;\n font-size: 1rem;\n}\n.MediaSeriesCard-module_info__3L7_o h2 {\n font-weight: bold;\n font-size: 1.25rem;\n margin: 0;\n}\n.MediaSeriesCard-module_published__E4oiz {\n color: #6d6d6d;\n margin: 0;\n}\n.MediaSeriesCard-module_summary__1xanh {\n margin: 0.5rem 0 0 0;\n}\n.MediaSeriesCard-module_author__e5fuR {\n margin: 0;\n}\n.MediaSeriesCard-module_author__e5fuR span {\n color: #6d6d6d;\n}\n.MediaSeriesCard-module_name__2m5KY {\n font-size: 1.3rem;\n font-weight: bold;\n}\n@media only screen and (max-width: 568px) {\n .MediaSeriesCard-module_article__SAFYK {\n margin: 1rem 0;\n box-shadow: 2px 4px 8px rgba(0,0,0,.2);\n }\n .MediaSeriesCard-module_article__SAFYK a {\n flex-direction: column;\n align-items: center;\n }\n .MediaSeriesCard-module_thumb__3jRAU {\n overflow: hidden;\n width: 100%;\n margin-bottom: 1rem;\n }\n .MediaSeriesCard-module_thumb__3jRAU img{\n border-radius: 10px 10px 0 0; \n }\n .MediaSeriesCard-module_thumb__3jRAU figure {\n margin: 0;\n }\n .MediaSeriesCard-module_info__3L7_o {\n width: 90%;\n padding: 0rem !important;\n }\n .MediaSeriesCard-module_info__3L7_o h2 {\n font-size: 1rem;\n }\n .MediaSeriesCard-module_name__2m5KY {\n font-size: 1rem;\n \n }\n}\n";
9338
9382
  var styles = { "article": "MediaSeriesCard-module_article__SAFYK", "thumb": "MediaSeriesCard-module_thumb__3jRAU", "info": "MediaSeriesCard-module_info__3L7_o", "published": "MediaSeriesCard-module_published__E4oiz", "summary": "MediaSeriesCard-module_summary__1xanh", "author": "MediaSeriesCard-module_author__e5fuR", "name": "MediaSeriesCard-module_name__2m5KY" };
9339
9383
  styleInject(css);
9340
9384
 
@@ -9421,11 +9465,11 @@ var Filter = function Filter(_ref) {
9421
9465
  _useState6 = _slicedToArray(_useState5, 2),
9422
9466
  grandChildData = _useState6[0],
9423
9467
  setGrandChildData = _useState6[1];
9424
- /*
9425
- {parent: showAll,
9426
- chidlren: show selected from parent,
9427
- grandchildren: show selected from children
9428
- }
9468
+ /*
9469
+ {parent: showAll,
9470
+ chidlren: show selected from parent,
9471
+ grandchildren: show selected from children
9472
+ }
9429
9473
  */
9430
9474
 
9431
9475