181. Araxis Merge File Comparison Report

Produced by Araxis Merge on 2024-03-04 14:38:53 +0000. See www.araxis.com for information about Merge. This report uses XHTML and CSS2, and is best viewed with a modern standards-compliant browser. For optimum results when printing this report, use landscape orientation and enable printing of background images and colours in your browser.

181.1 Files compared

#LocationFileLast Modified
1/Users/coca/Documents/www/Porto v4.0.2/Theme Files/Magento 2.x/Porto Theme v4.0.7/app/design/frontend/Smartwave/porto/Smartwave_Porto/web/jsapear.js2022-12-02 08:40:55 +0000
2/Users/coca/Documents/www/Porto v4.0.2/Theme Files/Magento 2.x/Porto Theme v4.0.8/app/design/frontend/Smartwave/porto/Smartwave_Porto/web/jsapear.js2022-12-02 08:40:55 +0000

181.2 Comparison summary

DescriptionBetween
Files 1 and 2
Text BlocksLines
Unchanged1154
Changed00
Inserted00
Removed00

181.3 Comparison options

WhitespaceConsecutive whitespace is treated as a single space
Character caseDifferences in character case are significant
Line endingsDifferences in line endings (CR and LF characters) are ignored
CR/LF charactersNot shown in the comparison detail
Active line-pairing rules

181.4 Active regular expressions

No regular expressions were active.

181.5 Comparison detail

1 /** 1 /**
2  * 2  *
3  * Do not edit or add to this file if you wish to upgrade this extension to newer 3  * Do not edit or add to this file if you wish to upgrade this extension to newer
4  * version in the future. 4  * version in the future.
5  * 5  *
6  */ 6  */
7 window.theme = {}; 7 window.theme = {};
8 define([ 8 define([
9     'jquery' 9     'jquery'
10 ], function ($) { 10 ], function ($) {
11     "use strict"; 11     "use strict";
12     theme = theme || {}; 12     theme = theme || {};
13  13 
14     var checks = [], 14     var checks = [],
15       timerId = false, 15       timerId = false,
16       one, 16       one,
17       a, b, o, x, y, ax, ay, 17       a, b, o, x, y, ax, ay,
18       retryCounter = 0, 18       retryCounter = 0,
19       has_event = false; 19       has_event = false;
20  20 
21     var checkAll = function() { 21     var checkAll = function() {
22       if (!checks.length) { 22       if (!checks.length) {
23         if (retryCounter > 10) { 23         if (retryCounter > 10) {
24           window.removeEventListener('scroll', checkAll); 24           window.removeEventListener('scroll', checkAll);
25           window.removeEventListener('resize', checkAll); 25           window.removeEventListener('resize', checkAll);
26         } 26         }
27         retryCounter++; 27         retryCounter++;
28       } else { 28       } else {
29         for ( var i = checks.length; i--; ) { 29         for ( var i = checks.length; i--; ) {
30           one = checks[i]; 30           one = checks[i];
31           a = window.pageXOffset; 31           a = window.pageXOffset;
32           b = window.pageYOffset; 32           b = window.pageYOffset;
33           o = one.el.getBoundingClientRect(); 33           o = one.el.getBoundingClientRect();
34           x = o.left + a; 34           x = o.left + a;
35           y = o.top + b; 35           y = o.top + b;
36           ax = one.options.accX; 36           ax = one.options.accX;
37           ay = one.options.accY; 37           ay = one.options.accY;
38  38 
39           if (y + o.height + ay >= b && 39           if (y + o.height + ay >= b &&
40             y <= b + window.innerHeight + ay && 40             y <= b + window.innerHeight + ay &&
41             x + o.width + ax >= a && 41             x + o.width + ax >= a &&
42             x <= a + window.innerWidth + ax) { 42             x <= a + window.innerWidth + ax) {
43  43 
44             one.fn.call(one.el, one.data); 44             one.fn.call(one.el, one.data);
45             checks.splice(i, 1); 45             checks.splice(i, 1);
46           } 46           }
47         } 47         }
48       } 48       }
49       timerId = false; 49       timerId = false;
50     }; 50     };
51  51 
52     window.theme.appear = function(el, fn, options) { 52     window.theme.appear = function(el, fn, options) {
53       var settings = { 53       var settings = {
54         data: undefined, 54         data: undefined,
55         accX: 0, 55         accX: 0,
56         accY: 0 56         accY: 0
57       }; 57       };
58  58 
59       if ( options ) { 59       if ( options ) {
60         options.data && ( settings.data = options.data ); 60         options.data && ( settings.data = options.data );
61         options.accX && ( settings.accX = options.accX ); 61         options.accX && ( settings.accX = options.accX );
62         options.accY && ( settings.accY = options.accY ); 62         options.accY && ( settings.accY = options.accY );
63       } 63       }
64  64 
65       checks.push({ el: el, fn: fn, options: settings }); 65       checks.push({ el: el, fn: fn, options: settings });
66       if ( ! timerId ) { 66       if ( ! timerId ) {
67         timerId = theme.requestTimeout(checkAll, 100); 67         timerId = theme.requestTimeout(checkAll, 100);
68       } 68       }
69  69 
70       if ( ! has_event ) { 70       if ( ! has_event ) {
71         $( document.body ).on( 'appear_refresh', checkAll ); 71         $( document.body ).on( 'appear_refresh', checkAll );
72         window.addEventListener('scroll', checkAll, {passive: true}); 72         window.addEventListener('scroll', checkAll, {passive: true});
73         window.addEventListener('resize', checkAll); 73         window.addEventListener('resize', checkAll);
74         has_event = true; 74         has_event = true;
75       } 75       }
76     } 76     }
77 }); 77 });