Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #580632

    Hello, is it possible to slow down the counting speed of the animated numbers?
    Because on my page: http://www.ericsmeets.nl/testserver/over-de-school/#aanbod I have some small numbers like 4, 7 and 8.
    But the animation is hardly visible, hence the question.

    Thanks!

    #580644

    Hey EricSmeets!

    Thank you for using Enfold.

    You can edit js > shortcodes.js, find this code on line 2688:

    var number_container = $(this), elements = number_container.find('.avia-single-number'), countTimer = number_container.data('timer') || 3000;

    let us know if that works out for you

    Best regards,
    Basilis

    #580703

    I tried editing this, but there was no difference in the speed with small numbers < 10.
    There was a difference if I tried to make a number 500 for example. But I won’t have such high numbers.
    Any idea?

    • This reply was modified 8 years, 10 months ago by EricSmeets.
    #581967

    Is there something I done wrong?

    #583189

    Hi!

    If you input the number 100 or any number less than that, the animated number will start from 000 and it will increment by 1 so it will go like 001 to 002 to 003 and so on and so forth until it reach the number 100. Unfortunately, it’s not possible to control the speed of the requestAnimationFrame function which is responsible for the animation without creating a custom script. You might want to consult a freelance developer: http://kriesi.at/contact/customization

    Regards,
    Ismael

    #1086393

    Hi there,

    it seems as since 2016 the script has moved to
    enfold/config-templatebuilder/avia-shortcodes/numbers/numbers.js

    Whereas, an adaption of the code still does not work.

    I tried to change the number from
    var number_container = $(this), elements = number_container.find(‘.__av-single-number’), countTimer = number_container.data(‘timer’) || 3000;
    to
    var number_container = $(this), elements = number_container.find(‘.__av-single-number’), countTimer = number_container.data(‘timer’) || 15000;

    But the speed of the numbers doesn’t get any slower.

    Greets,
    Alex

    • This reply was modified 5 years, 8 months ago by pixellovers.
    #1087870

    Hi,
    Sorry for the late reply, unfortunately for small numbers changing the “3000” will not slow the count down, it is designed for larger numbers with more than two places.
    This is what the last reply in this thread was trying to say:

    Unfortunately, it’s not possible to control the speed of the requestAnimationFrame function which is responsible for the animation without creating a custom script. You might want to consult a freelance developer: http://kriesi.at/contact/customization

    Also here: https://developer.mozilla.org/en-US/docs/Web/API/window/requestAnimationFrame

    The number of callbacks is usually 60 times per second, but will generally match the display refresh rate in most web browsers as per W3C recommendation.

    Best regards,
    Mike

Viewing 7 posts - 1 through 7 (of 7 total)
  • You must be logged in to reply to this topic.