255. Araxis Merge File Comparison Report

Produced by Araxis Merge on 2023-03-13 03:01:08 +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.

255.1 Files compared

#LocationFileLast Modified
12023-03-13 03:01:08 +0000
2Porto v4.0.5/Porto Theme/app/design/frontend/Smartwave/porto/Smartwave_Porto/web/jsanimate.js2021-04-10 11:14:59 +0000

255.2 Comparison summary

DescriptionBetween
Files 1 and 2
Text BlocksLines
Unchanged00
Changed00
Inserted1135
Removed00

255.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

255.4 Active regular expressions

No regular expressions were active.

255.5 Comparison detail

    1 /**
    2  *
    3  * Do not edit or add to this file if you wish to upgrade this extension to newer
    4  * version in the future.
    5  *
    6  */
    7 
    8 define([
    9     'jquery'
    10 ], function ($) {
    11     "use strict";
    12     theme = theme || {};
    13 
    14     $.extend(theme, {
    15   »     »       requestTimeout: function(fn, delay) {
    16   »     »       »       var handler = window.requestAnimationFrame || window.webkitRequestAnimationFrame || window.mozRequestAnimationFrame;
    17   »     »       »       if ( ! handler ) {
    18   »     »       »       »       return setTimeout(fn, delay);
    19   »     »       »       }
    20   »     »       »       var start, rt = new Object();
    21 
    22   »     »       »       function loop( timestamp ) {
    23   »     »       »       »       if ( ! start ) {
    24   »     »       »       »       »       start = timestamp;
    25   »     »       »       »       }
    26   »     »       »       »       var progress = timestamp - start;
    27   »     »       »       »       progress >= delay ? fn.call() : rt.val = handler( loop );
    28   »     »       »       };
    29 
    30   »     »       »       rt.val = handler( loop );
    31   »     »       »       return rt;
    32   »     »       }
    33   »     });
    34 
    35   »     var instanceName = '__animate';
    36 
    37   »     var Animate = function($el, opts) {
    38   »     »       return this.initialize($el, opts);
    39   »     };
    40 
    41   »     Animate.defaults = {
    42   »     »       accX: 0,
    43   »     »       accY: -120,
    44   »     »       delay: 1,
    45   »     »       duration: 1000
    46   »     };
    47 
    48   »     Animate.prototype = {
    49   »     »       initialize: function($el, opts) {
    50   »     »       »       if ($el.data(instanceName)) {
    51   »     »       »       »       return this;
    52   »     »       »       }
    53 
    54   »     »       »       this.$el = $el;
    55 
    56   »     »       »       this
    57   »     »       »       »       .setData()
    58   »     »       »       »       .setOptions(opts)
    59   »     »       »       »       .build();
    60 
    61   »     »       »       return this;
    62   »     »       },
    63 
    64   »     »       setData: function() {
    65   »     »       »       this.$el.data(instanceName, true);
    66 
    67   »     »       »       return this;
    68   »     »       },
    69 
    70   »     »       setOptions: function(opts) {
    71   »     »       »       this.options = $.extend(true, {}, Animate.defaults, opts, {
    72   »     »       »       »       wrapper: this.$el
    73   »     »       »       });
    74 
    75   »     »       »       return this;
    76   »     »       },
    77 
    78   »     »       build: function() {
    79   »     »       »       var self = this,
    80   »     »       »       »       $el = this.options.wrapper,
    81   »     »       »       »       delay = 0,
    82   »     »       »       »       duration = 0;
    83 
    84   »     »       »       $el.addClass('appear-animation');
    85   »     »       »       if (!$('html').hasClass('no-csstransitions') && window.innerWidth > 767) {
    86   »     »       »       »       var el_obj = $el.get(0);
    87 
    88   »     »       »       »       theme.appear(el_obj, function() {
    89   »     »       »       »       »       delay = Math.abs($el.data('appear-animation-delay') ? $el.data('appear-animation-delay') : self.options.delay);
    90   »     »       »       »       »       if (delay > 1) {
    91   »     »       »       »       »       »       el_obj.style.animationDelay = delay + 'ms';
    92   »     »       »       »       »       }
    93 
    94   »     »       »       »       »       duration = Math.abs($el.data('appear-animation-duration') ? $el.data('appear-animation-duration') : self.options.duration);
    95   »     »       »       »       »       if (duration != 1000) {
    96   »     »       »       »       »       »       el_obj.style.animationDuration = duration + 'ms';
    97   »     »       »       »       »       }
    98 
    99   »     »       »       »       »       if ($el.find('.porto-lazyload:not(.lazy-load-loaded)').length) {
    100   »     »       »       »       »       »       $el.find('.porto-lazyload:not(.lazy-load-loaded)').trigger('appear');
    101   »     »       »       »       »       }
    102   »     »       »       »       »       $el.addClass($el.data('appear-animation') + ' appear-animation-visible');
    103 
    104   »     »       »       »       }, {
    105   »     »       »       »       »       accX: self.options.accX,
    106   »     »       »       »       »       accY: self.options.accY
    107   »     »       »       »       });
    108 
    109   »     »       »       } else {
    110   »     »       »       »       $el.addClass('appear-animation-visible');
    111   »     »       »       }
    112 
    113   »     »       »       return this;
    114   »     »       }
    115   »     };
    116 
    117   »     // expose to scope
    118   »     $.extend(theme, {
    119   »     »       Animate: Animate
    120   »     });
    121 
    122   »     // jquery plugin
    123   »     $.fn.themeAnimate = function(opts) {
    124   »     »       return this.map(function() {
    125   »     »       »       var $this = $(this);
    126 
    127   »     »       »       if ($this.data(instanceName)) {
    128   »     »       »       »       return $this;
    129   »     »       »       } else {
    130   »     »       »       »       return new theme.Animate($this, opts);
    131   »     »       »       }
    132 
    133   »     »       });
    134   »     };
    135 });