wickes-css2 2.105.0-develop.10 → 2.105.0-develop.11

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.
@@ -4666,6 +4666,12 @@ Wick.BigWinsProto = function () {
4666
4666
  index = (index + 1) % ORDER.length;
4667
4667
  return ORDER[index];
4668
4668
  }
4669
+ function resetBillieModalScroll($modal) {
4670
+ var $body = $modal.find(".modal-body");
4671
+ var $content = $modal.find(".modal-content");
4672
+ $body.scrollTop(0);
4673
+ $content.attr("data-scroll-state", "top");
4674
+ }
4669
4675
  function applyBillieTerms(terms) {
4670
4676
  var copy = COPY[terms] || COPY['30'];
4671
4677
  var $modal = $('#billieLearnMoreModal');
@@ -4673,7 +4679,16 @@ Wick.BigWinsProto = function () {
4673
4679
  $modal.find('.js-billie-repayment-line').text(copy.repayment);
4674
4680
  $modal.attr('data-billie-terms', terms);
4675
4681
  }
4676
- $(document).on('click', '.billie__link', function (e) {
4682
+ $(document).on("shown.bs.modal", "#billieLearnMoreModal", function () {
4683
+ var $modal = $(this);
4684
+ requestAnimationFrame(function () {
4685
+ return resetBillieModalScroll($modal);
4686
+ });
4687
+ });
4688
+ $(document).on("hidden.bs.modal", "#billieLearnMoreModal", function () {
4689
+ resetBillieModalScroll($(this));
4690
+ });
4691
+ $(document).on("click", ".billie__link", function (e) {
4677
4692
  e.preventDefault();
4678
4693
  var terms = nextTerms();
4679
4694
  applyBillieTerms(terms);