Sha256: 8aa1755646e4a66b12e0b1baae0919db6e41a41aecb05e7b99acaab41f8b19ac

Contents?: true

Size: 1.24 KB

Versions: 64

Compression:

Stored size: 1.24 KB

Contents

module OpsManagerUiDrivers
  module AnimationHelper
    def disable_css_transitions!(page_context = browser)
      page_context.execute_script <<-JS
        // Turn off jQuery animations.
        jQuery.fx.off = true;

        // Turn off CSS transitions.
        var animationStyles = document.createElement('style');
        animationStyles.type = 'text/css';
        animationStyles.innerHTML = '* {' +
                                    '  -webkit-transition: none !important;' +
                                    '  -moz-transition: none !important;' +
                                    '  -ms-transition: none !important;' +
                                    '  -o-transition: none !important;' +
                                    '  transition: none !important;' +
                                    '  -webkit-animation: none !important;' +
                                    '  -moz-animation: none !important;' +
                                    '  -o-animation: none !important;' +
                                    '  -ms-animation: none !important;' +
                                    '  animation: none !important;' +
                                    '}'
        document.head.appendChild(animationStyles);
      JS
    end
  end
end

Version data entries

64 entries across 64 versions & 1 rubygems

Version Path
ops_manager_ui_drivers-2.42.0 lib/ops_manager_ui_drivers/animation_helper.rb
ops_manager_ui_drivers-2.41.0 lib/ops_manager_ui_drivers/animation_helper.rb
ops_manager_ui_drivers-2.40.1 lib/ops_manager_ui_drivers/animation_helper.rb
ops_manager_ui_drivers-2.40.0 lib/ops_manager_ui_drivers/animation_helper.rb
ops_manager_ui_drivers-2.39.0 lib/ops_manager_ui_drivers/animation_helper.rb
ops_manager_ui_drivers-2.38.0 lib/ops_manager_ui_drivers/animation_helper.rb
ops_manager_ui_drivers-2.37.0 lib/ops_manager_ui_drivers/animation_helper.rb
ops_manager_ui_drivers-2.36.0 lib/ops_manager_ui_drivers/animation_helper.rb
ops_manager_ui_drivers-2.35.2 lib/ops_manager_ui_drivers/animation_helper.rb
ops_manager_ui_drivers-2.35.1 lib/ops_manager_ui_drivers/animation_helper.rb
ops_manager_ui_drivers-2.35.0 lib/ops_manager_ui_drivers/animation_helper.rb
ops_manager_ui_drivers-2.34.1 lib/ops_manager_ui_drivers/animation_helper.rb
ops_manager_ui_drivers-2.34.0 lib/ops_manager_ui_drivers/animation_helper.rb
ops_manager_ui_drivers-2.33.1 lib/ops_manager_ui_drivers/animation_helper.rb
ops_manager_ui_drivers-2.33.0 lib/ops_manager_ui_drivers/animation_helper.rb
ops_manager_ui_drivers-2.32.1 lib/ops_manager_ui_drivers/animation_helper.rb
ops_manager_ui_drivers-2.32.0 lib/ops_manager_ui_drivers/animation_helper.rb
ops_manager_ui_drivers-2.31.3 lib/ops_manager_ui_drivers/animation_helper.rb
ops_manager_ui_drivers-2.31.2 lib/ops_manager_ui_drivers/animation_helper.rb
ops_manager_ui_drivers-2.31.1 lib/ops_manager_ui_drivers/animation_helper.rb