Ohm-Management - Projektarbeit B-ME
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

animationFrame.d.ts 1.1KB

12345678910111213141516171819202122232425262728293031323334
  1. import { AnimationFrameScheduler } from './AnimationFrameScheduler';
  2. /**
  3. *
  4. * Animation Frame Scheduler
  5. *
  6. * <span class="informal">Perform task when `window.requestAnimationFrame` would fire</span>
  7. *
  8. * When `animationFrame` scheduler is used with delay, it will fall back to {@link asyncScheduler} scheduler
  9. * behaviour.
  10. *
  11. * Without delay, `animationFrame` scheduler can be used to create smooth browser animations.
  12. * It makes sure scheduled task will happen just before next browser content repaint,
  13. * thus performing animations as efficiently as possible.
  14. *
  15. * ## Example
  16. * Schedule div height animation
  17. * ```javascript
  18. * const div = document.querySelector('.some-div');
  19. *
  20. * Rx.Scheduler.animationFrame.schedule(function(height) {
  21. * div.style.height = height + "px";
  22. *
  23. * this.schedule(height + 1); // `this` references currently executing Action,
  24. * // which we reschedule with new state
  25. * }, 0, 0);
  26. *
  27. * // You will see .some-div element growing in height
  28. * ```
  29. *
  30. * @static true
  31. * @name animationFrame
  32. * @owner Scheduler
  33. */
  34. export declare const animationFrame: AnimationFrameScheduler;