Skip to content

Commit

Permalink
Add KeyframeEffect.getKeyframes() and setKeyframes() to standard JS e…
Browse files Browse the repository at this point in the history
…xterns

PiperOrigin-RevId: 563236510
  • Loading branch information
rahul-kamat authored and copybara-github committed Sep 6, 2023
1 parent 73cf670 commit 49501b2
Showing 1 changed file with 52 additions and 0 deletions.
52 changes: 52 additions & 0 deletions externs/browser/web_animations.js
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,58 @@ KeyframeEffectReadOnly.prototype.timing;
*/
var KeyframeEffect = function(target, frames, options) {};

/**
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/KeyframeEffect/getKeyframes)
* @public
* @return {!Array<!ComputedKeyframe>}
*/
KeyframeEffect.prototype.getKeyframes = function() {};

/**
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/KeyframeEffect/setKeyframes)
* @public
* @param {(null|!PropertyIndexedKeyframes|!Array<!Keyframe>)} keyframes
* @return {void}
*/
KeyframeEffect.prototype.setKeyframes = function(keyframes) {};

/**
* @record
*/
var ComputedKeyframe = function() {};

/** @type {string} */
ComputedKeyframe.prototype.composite;
/** @type {number} */
ComputedKeyframe.prototype.computedOffset;
/** @type {string} */
ComputedKeyframe.prototype.easing;
/** @type {(null|number)} */
ComputedKeyframe.prototype.offset;

/**
* @record
*/
var PropertyIndexedKeyframes = function() {};

/** @type {(undefined|string|!Array<string>)} */
PropertyIndexedKeyframes.prototype.composite;
/** @type {(undefined|string|!Array<string>)} */
PropertyIndexedKeyframes.prototype.easing;
/** @type {(undefined|number|!Array<(null|number)>)} */
PropertyIndexedKeyframes.prototype.offset;

/**
* @record
*/
var Keyframe = function() {};

/** @type {(undefined|string)} */
Keyframe.prototype.composite;
/** @type {(undefined|string)} */
Keyframe.prototype.easing;
/** @type {(undefined|null|number)} */
Keyframe.prototype.offset;

/**
* @record
Expand Down

0 comments on commit 49501b2

Please sign in to comment.